[jboss-cvs] JBossAS SVN: r57108 - in trunk: . admin-console aop aop/docs/reference/reference/en/modules aop/src aspects aspects/src/resources/META-INF build cluster connector connector/src/main/org/jboss/resource connector/src/main/org/jboss/resource/deployers connector/src/main/org/jboss/resource/metadata connector/src/resources connector/src/resources/deployers connector/src/resources/jca-sar console deployment ejb3 ejb3x hibernate-int iiop j2ee j2se j2se/src/main/org/jboss/mx/loading jbossas jbossas/jmx-remoting jbossas/remoting jmx jmx/src/main/org/jboss/mx/loading jmx/src/main/org/jboss/mx/server jmx-remoting management mbeans mbeans/src mbeans/src/main/org/jboss/mx mbeans/src/main/org/jboss/mx/mxbean mbeans/src/tests mbeans/src/tests/org mbeans/src/tests/org/jboss mbeans/src/tests/org/jboss/test mbeans/src/tests/org/jboss/test/mx mbeans/src/tests/org/jboss/test/mx/mxbean mbeans/src/tests/org/jboss/test/mx/mxbean/support mbeans/src/tests/org/jboss/test/mx/mxbean/test mess! aging messaging/src/etc/server/default/deploy naming server server/src/etc/conf/default server/src/etc/deploy server/src/resources/client-deployer server/src/resources/jmx-invoker-adaptor/META-INF server/src/resources/uuid-key-generator/META-INF spring-int system system/src/main/org/jboss system/src/main/org/jboss/deployers system/src/main/org/jboss/deployers/spi system/src/main/org/jboss/deployers/spi/management system/src/main/org/jboss/profileservice system/src/main/org/jboss/profileservice/spi system/src/main/org/jboss/system system/src/main/org/jboss/system/server system/src/main/org/jboss/system/server/profileservice system/src/resources system/src/resources/dtd system/src/resources/tests system/src/resources/tests/bootstrap/default system/src/tests/org/jboss/test system-jmx system-jmx/src system-jmx/src/etc system-jmx/src/main system-jmx/src/main/org system-jmx/src/main/org/jboss system-jmx/src/main/org/jboss/deployment system-jmx/src/main/org/jboss/deployment/scanne! r system-jmx/src/main/org/jboss/system system-jmx/src/main/org/jboss/system/deployers system-jmx/src/main/org/jboss/system/filterfactory system-jmx/src/main/org/jboss/system/metadata system-jmx/src/main/org/jboss/system/microcontainer system-jmx/src/main/org/jboss/system/pm system-jmx/src/main/org/jboss/system/server system-
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Sat Sep 23 17:02:40 EDT 2006
Author: scott.stark at jboss.org
Date: 2006-09-23 16:55:54 -0400 (Sat, 23 Sep 2006)
New Revision: 57108
Added:
trunk/connector/src/main/org/jboss/resource/deployers/
trunk/connector/src/main/org/jboss/resource/deployers/RARDeployer.java
trunk/connector/src/main/org/jboss/resource/deployers/RARDeployment.java
trunk/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java
trunk/connector/src/resources/deployers/
trunk/connector/src/resources/deployers/jca-deployers-beans.xml
trunk/j2se/src/main/org/jboss/mx/loading/LegacyDomainClassLoader.java
trunk/j2se/src/main/org/jboss/mx/loading/LoaderRepositoryDomain.java
trunk/jbossas/jmx-remoting/build.bat
trunk/jbossas/jmx-remoting/build.sh
trunk/jmx/src/main/org/jboss/mx/loading/ClassLoadingTaskDCL.java
trunk/jmx/src/main/org/jboss/mx/loading/DomainClassLoaderUCLImpl.java
trunk/jmx/src/main/org/jboss/mx/loading/LoadMgrDCL.java
trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepositoryDCL.java
trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepositoryDCLMBean.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java
trunk/mbeans/src/tests/
trunk/mbeans/src/tests/org/
trunk/mbeans/src/tests/org/jboss/
trunk/mbeans/src/tests/org/jboss/test/
trunk/mbeans/src/tests/org/jboss/test/mx/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java
trunk/server/src/etc/conf/default/deployer-beans.xml
trunk/system-jmx/
trunk/system-jmx/.classpath
trunk/system-jmx/.project
trunk/system-jmx/build-support-jars.xml
trunk/system-jmx/build-test.xml
trunk/system-jmx/build.bat
trunk/system-jmx/build.sh
trunk/system-jmx/build.xml
trunk/system-jmx/src/
trunk/system-jmx/src/etc/
trunk/system-jmx/src/etc/default.mf
trunk/system-jmx/src/etc/run.mf
trunk/system-jmx/src/main/
trunk/system-jmx/src/main/org/
trunk/system-jmx/src/main/org/jboss/
trunk/system-jmx/src/main/org/jboss/deployment/
trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java
trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/Deployer.java
trunk/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentException.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentState.java
trunk/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java
trunk/system-jmx/src/main/org/jboss/deployment/JARDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/MainDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java
trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SARDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java
trunk/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java
trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/package.html
trunk/system-jmx/src/main/org/jboss/deployment/scanner/
trunk/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/package.html
trunk/system-jmx/src/main/org/jboss/system/
trunk/system-jmx/src/main/org/jboss/system/BarrierController.java
trunk/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java
trunk/system-jmx/src/main/org/jboss/system/ConfigurationException.java
trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java
trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/MissingAttributeException.java
trunk/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/ServiceBinding.java
trunk/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java
trunk/system-jmx/src/main/org/jboss/system/ServiceContext.java
trunk/system-jmx/src/main/org/jboss/system/ServiceController.java
trunk/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java
trunk/system-jmx/src/main/org/jboss/system/ServiceCreator.java
trunk/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/ServiceFactory.java
trunk/system-jmx/src/main/org/jboss/system/ServiceInstance.java
trunk/system-jmx/src/main/org/jboss/system/ServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java
trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/deployers/
trunk/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java
trunk/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/
trunk/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java
trunk/system-jmx/src/main/org/jboss/system/metadata/
trunk/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java
trunk/system-jmx/src/main/org/jboss/system/pm/
trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java
trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java
trunk/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java
trunk/system-jmx/src/main/org/jboss/system/server/
trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerImpl.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/
trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java
trunk/system-jmx/src/resources/
trunk/system-jmx/src/resources/tests-support/
trunk/system-jmx/src/resources/tests-support/jar1/
trunk/system-jmx/src/resources/tests-support/jar1/resource1.xml
trunk/system-jmx/src/resources/tests-support/jar2/
trunk/system-jmx/src/resources/tests-support/jar2/resource1.xml
trunk/system-jmx/src/resources/tests/
trunk/system-jmx/src/resources/tests/org/
trunk/system-jmx/src/resources/tests/org/jboss/
trunk/system-jmx/src/resources/tests/org/jboss/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar1.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2CPjar1.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar3.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/system/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml
trunk/system-jmx/src/tests-support/
trunk/system-jmx/src/tests-support/org/
trunk/system-jmx/src/tests-support/org/jboss/
trunk/system-jmx/src/tests-support/org/jboss/test/
trunk/system-jmx/src/tests-support/org/jboss/test/support/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java
trunk/system-jmx/src/tests/
trunk/system-jmx/src/tests/org/
trunk/system-jmx/src/tests/org/jboss/
trunk/system-jmx/src/tests/org/jboss/test/
trunk/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java
trunk/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/classloading/
trunk/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/
trunk/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java
trunk/system/src/main/org/jboss/deployers/
trunk/system/src/main/org/jboss/deployers/spi/
trunk/system/src/main/org/jboss/deployers/spi/management/
trunk/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java
trunk/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java
trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java
trunk/system/src/main/org/jboss/profileservice/
trunk/system/src/main/org/jboss/profileservice/spi/
trunk/system/src/main/org/jboss/profileservice/spi/ArrayType.java
trunk/system/src/main/org/jboss/profileservice/spi/CompositeData.java
trunk/system/src/main/org/jboss/profileservice/spi/CompositeType.java
trunk/system/src/main/org/jboss/profileservice/spi/DeploymentTemplate.java
trunk/system/src/main/org/jboss/profileservice/spi/NoSuchDeploymentException.java
trunk/system/src/main/org/jboss/profileservice/spi/NoSuchProfileException.java
trunk/system/src/main/org/jboss/profileservice/spi/OpenType.java
trunk/system/src/main/org/jboss/profileservice/spi/Profile.java
trunk/system/src/main/org/jboss/profileservice/spi/ProfileConfiguration.java
trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java
trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java
trunk/system/src/main/org/jboss/profileservice/spi/PropertyInfo.java
trunk/system/src/main/org/jboss/profileservice/spi/SimpleType.java
trunk/system/src/main/org/jboss/system/server/BaseServerConfig.java
trunk/system/src/main/org/jboss/system/server/profileservice/
trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java
trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java
trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java
trunk/system/src/main/org/jboss/system/server/profileservice/SecurityActions.java
trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java
trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java
trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java
trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java
trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java
trunk/system/src/resources/dtd/jboss-service_5_0.dtd
Removed:
trunk/connector/src/main/org/jboss/resource/deployers/RARDeployer.java
trunk/connector/src/main/org/jboss/resource/deployers/RARDeployment.java
trunk/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java
trunk/connector/src/resources/deployers/jca-deployers-beans.xml
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java
trunk/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java
trunk/mbeans/src/tests/org/
trunk/mbeans/src/tests/org/jboss/
trunk/mbeans/src/tests/org/jboss/test/
trunk/mbeans/src/tests/org/jboss/test/mx/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java
trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java
trunk/system-jmx/.classpath
trunk/system-jmx/.project
trunk/system-jmx/build-support-jars.xml
trunk/system-jmx/build-test.xml
trunk/system-jmx/build.bat
trunk/system-jmx/build.sh
trunk/system-jmx/build.xml
trunk/system-jmx/src/
trunk/system-jmx/src/etc/
trunk/system-jmx/src/etc/default.mf
trunk/system-jmx/src/etc/run.mf
trunk/system-jmx/src/main/
trunk/system-jmx/src/main/org/
trunk/system-jmx/src/main/org/jboss/
trunk/system-jmx/src/main/org/jboss/deployment/
trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java
trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/Deployer.java
trunk/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentException.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/DeploymentState.java
trunk/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java
trunk/system-jmx/src/main/org/jboss/deployment/JARDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/MainDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java
trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SARDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java
trunk/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java
trunk/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java
trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java
trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/package.html
trunk/system-jmx/src/main/org/jboss/deployment/scanner/
trunk/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java
trunk/system-jmx/src/main/org/jboss/deployment/scanner/package.html
trunk/system-jmx/src/main/org/jboss/system/
trunk/system-jmx/src/main/org/jboss/system/BarrierController.java
trunk/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java
trunk/system-jmx/src/main/org/jboss/system/ConfigurationException.java
trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java
trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/MissingAttributeException.java
trunk/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/ServiceBinding.java
trunk/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java
trunk/system-jmx/src/main/org/jboss/system/ServiceContext.java
trunk/system-jmx/src/main/org/jboss/system/ServiceController.java
trunk/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java
trunk/system-jmx/src/main/org/jboss/system/ServiceCreator.java
trunk/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/ServiceFactory.java
trunk/system-jmx/src/main/org/jboss/system/ServiceInstance.java
trunk/system-jmx/src/main/org/jboss/system/ServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java
trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java
trunk/system-jmx/src/main/org/jboss/system/deployers/
trunk/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java
trunk/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java
trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/
trunk/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java
trunk/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java
trunk/system-jmx/src/main/org/jboss/system/metadata/
trunk/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java
trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java
trunk/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java
trunk/system-jmx/src/main/org/jboss/system/pm/
trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java
trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java
trunk/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java
trunk/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java
trunk/system-jmx/src/main/org/jboss/system/server/
trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerImpl.java
trunk/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/
trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
trunk/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java
trunk/system-jmx/src/resources/
trunk/system-jmx/src/resources/tests-support/
trunk/system-jmx/src/resources/tests-support/jar1/
trunk/system-jmx/src/resources/tests-support/jar1/resource1.xml
trunk/system-jmx/src/resources/tests-support/jar2/
trunk/system-jmx/src/resources/tests-support/jar2/resource1.xml
trunk/system-jmx/src/resources/tests/
trunk/system-jmx/src/resources/tests/org/
trunk/system-jmx/src/resources/tests/org/jboss/
trunk/system-jmx/src/resources/tests/org/jboss/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar1.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2CPjar1.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar3.jar
trunk/system-jmx/src/resources/tests/org/jboss/test/system/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/
trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml
trunk/system-jmx/src/tests-support/
trunk/system-jmx/src/tests-support/org/
trunk/system-jmx/src/tests-support/org/jboss/
trunk/system-jmx/src/tests-support/org/jboss/test/
trunk/system-jmx/src/tests-support/org/jboss/test/support/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/
trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java
trunk/system-jmx/src/tests/
trunk/system-jmx/src/tests/org/
trunk/system-jmx/src/tests/org/jboss/
trunk/system-jmx/src/tests/org/jboss/test/
trunk/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java
trunk/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/classloading/
trunk/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/
trunk/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java
trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/
trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/
trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java
trunk/system/.cvsignore
trunk/system/src/main/org/jboss/deployers/spi/
trunk/system/src/main/org/jboss/deployers/spi/management/
trunk/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java
trunk/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java
trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java
trunk/system/src/main/org/jboss/deployment/
trunk/system/src/main/org/jboss/system/BarrierController.java
trunk/system/src/main/org/jboss/system/BarrierControllerMBean.java
trunk/system/src/main/org/jboss/system/ConfigurationException.java
trunk/system/src/main/org/jboss/system/InterceptorServiceMBean.java
trunk/system/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java
trunk/system/src/main/org/jboss/system/InvalidAttributeException.java
trunk/system/src/main/org/jboss/system/ListenerServiceMBean.java
trunk/system/src/main/org/jboss/system/ListenerServiceMBeanSupport.java
trunk/system/src/main/org/jboss/system/MissingAttributeException.java
trunk/system/src/main/org/jboss/system/NotificationFilterFactory.java
trunk/system/src/main/org/jboss/system/ServiceBinding.java
trunk/system/src/main/org/jboss/system/ServiceConfigurator.java
trunk/system/src/main/org/jboss/system/ServiceContext.java
trunk/system/src/main/org/jboss/system/ServiceController.java
trunk/system/src/main/org/jboss/system/ServiceControllerMBean.java
trunk/system/src/main/org/jboss/system/ServiceCreator.java
trunk/system/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java
trunk/system/src/main/org/jboss/system/ServiceFactory.java
trunk/system/src/main/org/jboss/system/ServiceInstance.java
trunk/system/src/main/org/jboss/system/ServiceMBean.java
trunk/system/src/main/org/jboss/system/ServiceMBeanState.java
trunk/system/src/main/org/jboss/system/ServiceMBeanSupport.java
trunk/system/src/main/org/jboss/system/filterfactory/
trunk/system/src/main/org/jboss/system/metadata/
trunk/system/src/main/org/jboss/system/microcontainer/
trunk/system/src/main/org/jboss/system/pm/
trunk/system/src/main/org/jboss/system/server/ServerConfigImpl.java
trunk/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java
trunk/system/src/main/org/jboss/system/server/ServerConfigLocator.java
trunk/system/src/main/org/jboss/system/server/ServerImpl.java
trunk/system/src/main/org/jboss/system/server/ServerImplMBean.java
trunk/system/src/main/org/jboss/system/server/jmx/
trunk/system/src/resources/tests/org/
trunk/system/src/tests/org/jboss/test/AbstractSystemTest.java
trunk/system/src/tests/org/jboss/test/SystemAllTestSuite.java
trunk/system/src/tests/org/jboss/test/system/
Modified:
trunk/admin-console/.classpath
trunk/aop/.classpath
trunk/aop/build-retro.xml
trunk/aop/build-tests-jdk14.xml
trunk/aop/build-tests-jdk50.xml
trunk/aop/build.xml
trunk/aop/docs/reference/reference/en/modules/annotationcompiler.xml
trunk/aop/docs/reference/reference/en/modules/compiling.xml
trunk/aop/src/build.xml
trunk/aspects/.classpath
trunk/aspects/build-retro.xml
trunk/aspects/build-test.xml
trunk/aspects/build-test50.xml
trunk/aspects/build.xml
trunk/aspects/src/resources/META-INF/jboss-service.xml
trunk/build/build-distr.xml
trunk/build/build-thirdparty.xml
trunk/build/build.xml
trunk/cluster/.classpath
trunk/cluster/build.xml
trunk/connector/.classpath
trunk/connector/build.xml
trunk/connector/src/main/org/jboss/resource/metadata/ConnectorMetaData.java
trunk/connector/src/resources/jca-sar/jbossjca-service.xml
trunk/console/.classpath
trunk/console/build.xml
trunk/deployment/.classpath
trunk/deployment/build.xml
trunk/ejb3/.classpath
trunk/ejb3/build-test.xml
trunk/ejb3/build.xml
trunk/ejb3x/.classpath
trunk/ejb3x/build.xml
trunk/hibernate-int/.classpath
trunk/hibernate-int/build.sh
trunk/hibernate-int/build.xml
trunk/iiop/.classpath
trunk/iiop/build.xml
trunk/j2ee/.classpath
trunk/j2ee/build.xml
trunk/j2se/.classpath
trunk/j2se/build.xml
trunk/jbossas/.classpath
trunk/jbossas/jmx-remoting/build.xml
trunk/jbossas/remoting/build.xml
trunk/jmx-remoting/.classpath
trunk/jmx-remoting/build.xml
trunk/jmx/.classpath
trunk/jmx/build.xml
trunk/jmx/src/main/org/jboss/mx/loading/ClassLoaderUtils.java
trunk/jmx/src/main/org/jboss/mx/loading/ResourceInfo.java
trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepository3.java
trunk/jmx/src/main/org/jboss/mx/server/MBeanServerImpl.java
trunk/management/.classpath
trunk/management/build.xml
trunk/mbeans/.classpath
trunk/mbeans/build.xml
trunk/messaging/.classpath
trunk/messaging/build.xml
trunk/messaging/src/etc/server/default/deploy/hsqldb-jdbc2-service.xml
trunk/naming/.classpath
trunk/naming/build.xml
trunk/server/.classpath
trunk/server/build.xml
trunk/server/src/etc/conf/default/jboss-minimal.xml
trunk/server/src/etc/conf/default/jboss-service.xml
trunk/server/src/etc/deploy/bsh-deployer.xml
trunk/server/src/etc/deploy/ear-deployer.xml
trunk/server/src/etc/deploy/ejb-deployer.xml
trunk/server/src/resources/client-deployer/client-deployer-service.xml
trunk/server/src/resources/jmx-invoker-adaptor/META-INF/jboss-service.xml
trunk/server/src/resources/uuid-key-generator/META-INF/jboss-service.xml
trunk/spring-int/.classpath
trunk/spring-int/build.xml
trunk/system/.classpath
trunk/system/.project
trunk/system/build-test.xml
trunk/system/build.xml
trunk/system/src/main/org/jboss/Main.java
trunk/system/src/main/org/jboss/Version.java
trunk/system/src/main/org/jboss/system/server/Server.java
trunk/system/src/main/org/jboss/system/server/ServerConfigUtil.java
trunk/system/src/main/org/jboss/system/server/ServerInfo.java
trunk/system/src/main/org/jboss/system/server/ServerInfoMBean.java
trunk/system/src/main/org/jboss/system/server/ServerLoader.java
trunk/system/src/resources/log4j.properties
trunk/system/src/resources/tests/bootstrap/default/deployer-beans.xml
trunk/testsuite/.classpath
trunk/testsuite/build.xml
trunk/testsuite/imports/sections/aop.xml
trunk/testsuite/imports/sections/cache.xml
trunk/testsuite/imports/sections/cluster.xml
trunk/thirdparty/
trunk/tomcat/.classpath
trunk/tomcat/build.xml
trunk/tools/etc/buildmagic/modules.ent
trunk/transaction/.classpath
trunk/transaction/build.xml
trunk/varia/.classpath
trunk/varia/build.xml
trunk/varia/src/main/org/jboss/jmx/adaptor/snmp/system/MIB2SystemGroupService.java
trunk/varia/src/resources/kernel/META-INF/jboss-service.xml
Log:
Merged MC_VDF_WORK branch to head (r55121:57107)
Modified: trunk/admin-console/.classpath
===================================================================
--- trunk/admin-console/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/admin-console/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -4,42 +4,38 @@
<classpathentry kind="src" path="src/test"/>
<classpathentry kind="src" path="src/webtest"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="tmp_libs/dom4j.jar"/>
<classpathentry kind="lib" path="tmp_libs/webtest/commons-collections-3.1.jar"/>
<classpathentry kind="lib" path="tmp_libs/webtest/commons-httpclient-3.0.jar"/>
<classpathentry kind="lib" path="tmp_libs/webtest/commons-io-1.1.jar"/>
<classpathentry kind="lib" path="tmp_libs/webtest/htmlunit-1.8.jar"/>
<classpathentry kind="lib" path="tmp_libs/webtest/js-1.6R2.jar"/>
<classpathentry kind="lib" path="tmp_libs/webtest/nekohtml-0.9.5.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-codec/lib/commons-codec.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/lib/endorsed/xercesImpl.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/lib/concurrent.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/client/jnp-client.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-beanutils/lib/commons-beanutils.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-digester/lib/commons-digester-1.6.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-fileupload/lib/commons-fileupload.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-lang/lib/commons-lang-2.1.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/server/default/lib/commons-logging.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-pool/lib/commons-pool.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-validator/lib/commons-validator-1.1.3.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/cglib/lib/cglib.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/asm/lib/asm.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/server/default/deploy/jbossweb-tomcat6.sar/servlet-api.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/server/default/lib/hibernate3.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/lib/endorsed/xalan.jar"/>
- <classpathentry kind="var" path="JBOSS_HOME/lib/jboss-common.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/jaxen/lib/jaxen.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-struts/lib/struts-1.2.6.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/apache-log4j/lib/log4j.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/junit/lib/junit.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/easymock/lib/easymock-1.1.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/easymock/lib/easymockclassextension.jar"/>
- <classpathentry kind="var" path="JBOSS_HEAD/thirdparty/struts-test-case/lib/strutstest-2.1.3.jar"/>
- <classpathentry sourcepath="JBOSS_HEAD/hibernate-int/src/main" kind="var" path="JBOSS_HOME/server/default/lib/jboss-hibernate.jar"/>
- <classpathentry sourcepath="JBOSS_HEAD/deployment/src/main" kind="var" path="JBOSS_HOME/server/default/deploy/deployment-service.sar/deployment-service.jar"/>
- <classpathentry sourcepath="JBOSS_HEAD/system/src/main" kind="var" path="JBOSS_HOME/lib/jboss-system.jar"/>
- <classpathentry sourcepath="JBOSS_HEAD/j2se/src/main" kind="var" path="JBOSS_HOME/client/jboss-j2se.jar"/>
- <classpathentry sourcepath="JBOSS_HEAD/j2ee/src/main" kind="var" path="JBOSS_HOME/client/jboss-j2ee.jar"/>
- <classpathentry sourcepath="JBOSS_HEAD/messaging/src/main" kind="var" path="JBOSS_HOME/server/default/lib/jbossmq.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/aop"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/aspects"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/build"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/cluster"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/connector"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/console"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/deployment"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/ejb3"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/ejb3x"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/hibernate-int"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/iiop"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/j2ee"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/j2se"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/jbossas"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/jmx"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/jmx-remoting"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/management"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/mbeans"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/messaging"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/naming"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/server"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/spring-int"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/tomcat"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/transaction"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/varia"/>
<classpathentry kind="output" path="output/eclipse/classes"/>
</classpath>
Modified: trunk/aop/.classpath
===================================================================
--- trunk/aop/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -12,7 +12,9 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="docs"/>
<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry sourcepath="/javassist" kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
Modified: trunk/aop/build-retro.xml
===================================================================
--- trunk/aop/build-retro.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/build-retro.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -100,7 +100,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
</path>
<!-- ===== -->
Modified: trunk/aop/build-tests-jdk14.xml
===================================================================
--- trunk/aop/build-tests-jdk14.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/build-tests-jdk14.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -106,7 +106,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.test.classpath"/>
</path>
Modified: trunk/aop/build-tests-jdk50.xml
===================================================================
--- trunk/aop/build-tests-jdk50.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/build-tests-jdk50.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -101,7 +101,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.test.classpath"/>
</path>
Modified: trunk/aop/build.xml
===================================================================
--- trunk/aop/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -100,7 +100,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.test.classpath"/>
</path>
Modified: trunk/aop/docs/reference/reference/en/modules/annotationcompiler.xml
===================================================================
--- trunk/aop/docs/reference/reference/en/modules/annotationcompiler.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/docs/reference/reference/en/modules/annotationcompiler.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -239,7 +239,10 @@
<path id="concurrent.classpath">
<pathelement path="../../../concurrent.jar"/>
</path>
- <path id="jboss.common.classpath">
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<pathelement path="../../../jboss-common.jar"/>
</path>
<path id="jboss.aop.classpath">
@@ -252,7 +255,10 @@
<path refid="javassist.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="concurrent.classpath"/>
<path refid="qdox.classpath"/>
</path>]]></programlisting>
Modified: trunk/aop/docs/reference/reference/en/modules/compiling.xml
===================================================================
--- trunk/aop/docs/reference/reference/en/modules/compiling.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/docs/reference/reference/en/modules/compiling.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -63,7 +63,10 @@
<pathelement path="../../../concurrent.jar"/>
</path>
- <path id="jboss.common.classpath">
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<pathelement path="../../../jboss-common.jar"/>
</path>
@@ -71,7 +74,10 @@
<path refid="javassist.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="concurrent.classpath"/>
</path>]]>
</programlisting>
Modified: trunk/aop/src/build.xml
===================================================================
--- trunk/aop/src/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aop/src/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -15,7 +15,10 @@
<pathelement path="concurrent.jar"/>
</path>
- <path id="jboss.common.classpath">
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<pathelement path="jboss-common.jar"/>
</path>
@@ -35,7 +38,10 @@
<path refid="javassist.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="concurrent.classpath"/>
<path refid="qdox.classpath"/>
<path refid="junit.classpath"/>
Modified: trunk/aspects/.classpath
===================================================================
--- trunk/aspects/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aspects/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -7,7 +7,9 @@
<classpathentry kind="src" path="src/test50"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/aop"/>
<classpathentry kind="src" path="/cluster"/>
<classpathentry kind="src" path="/transaction"/>
@@ -29,5 +31,7 @@
<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/aspects/build-retro.xml
===================================================================
--- trunk/aspects/build-retro.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aspects/build-retro.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -76,11 +76,15 @@
<path refid="beanshell.beanshell.classpath"/>
<path refid="jboss.remoting.classpath"/>
<path refid="apache.xerces.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- Configure modules -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.jmx.classpath"/>
Modified: trunk/aspects/build-test.xml
===================================================================
--- trunk/aspects/build-test.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aspects/build-test.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -91,6 +91,7 @@
<path refid="apache.log4j.classpath"/>
<path refid="jboss.remoting.classpath"/>
<path refid="apache.xerces.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -101,7 +102,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.jmx.classpath"/>
Modified: trunk/aspects/build-test50.xml
===================================================================
--- trunk/aspects/build-test50.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aspects/build-test50.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -109,7 +109,10 @@
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.aop50.classpath"/>
<path refid="jboss.aspects50.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.system.classpath"/>
<path refid="jboss.jmx.classpath"/>
<path refid="jboss.naming.classpath"/>
Modified: trunk/aspects/build.xml
===================================================================
--- trunk/aspects/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aspects/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -76,15 +76,20 @@
<path refid="beanshell.beanshell.classpath"/>
<path refid="jboss.remoting.classpath"/>
<path refid="apache.xerces.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- Configure modules -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.jmx.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.security.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.system.classpath"/>
@@ -260,7 +265,7 @@
<fileset dir="${build.etc}">
<include name="org/jboss/**/*.xml"/>
</fileset>
- <zipfileset src="${jboss.common.lib}/jboss-archive-browsing.jar">
+ <zipfileset src="${jboss.common.core.lib}/jboss-common-core-2.0.0.jar">
<include name="org/jboss/util/file/ArchiveBrowser*.class"/>
<include name="org/jboss/util/file/ClassFileFilter.class"/>
<include name="org/jboss/util/file/DirectoryArchiveBrowser.class"/>
@@ -405,7 +410,7 @@
<fileset dir="${build.etc}">
<include name="org/jboss/**/*.xml"/>
</fileset>
- <zipfileset src="${jboss.common.lib}/jboss-archive-browsing.jar">
+ <zipfileset src="${jboss.common.core.lib}/jboss-common-core-2.0.0.jar">
<include name="org/jboss/util/file/ArchiveBrowser*.class"/>
<include name="org/jboss/util/file/ClassFileFilter.class"/>
<include name="org/jboss/util/file/DirectoryArchiveBrowser.class"/>
Modified: trunk/aspects/src/resources/META-INF/jboss-service.xml
===================================================================
--- trunk/aspects/src/resources/META-INF/jboss-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/aspects/src/resources/META-INF/jboss-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -46,6 +46,7 @@
<mbean code="org.jboss.aop.deployment.AspectDeployer"
name="jboss.aop:service=AspectDeployer">
+ <depends>jboss.system:service=MainDeployer</depends>
</mbean>
</server>
Modified: trunk/build/build-distr.xml
===================================================================
--- trunk/build/build-distr.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/build/build-distr.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -409,7 +409,20 @@
</fileset>
</copy>
</target>
-
+ <target name="_module-system-jmx-most">
+ <property name="_module.name" value="system-jmx" override="true"/>
+ <property name="_module.output" override="true"
+ value="${project.root}/${_module.name}/output"/>
+
+ <copy todir="${install.lib}" filtering="no">
+ <fileset dir="${_module.output}/lib">
+ <include name="jboss-system-jmx.jar"/>
+ </fileset>
+ </copy>
+ </target>
+ <target name="_module-system-jmx-all" depends="_module-system-jmx-most">
+ </target>
+
<!-- ====== -->
<!-- Naming -->
<!-- ====== -->
@@ -575,6 +588,12 @@
<property name="_module.output" override="true"
value="${project.root}/${_module.name}/output"/>
+ <mkdir dir="${install.server}/all/deployers"/>
+ <copy todir="${install.server}/all/deployers" filtering="no">
+ <fileset dir="${_module.output}/resources/deployers">
+ <include name="jca-deployers-beans.xml"/>
+ </fileset>
+ </copy>
<!-- Copy the generated deployment libraries -->
<mkdir dir="${install.server}/all/deploy"/>
@@ -1716,10 +1735,18 @@
<!-- Copy the generated libraries -->
<mkdir dir="${install.lib}"/>
<copy todir="${install.lib}" filtering="no">
- <fileset dir="${jboss.common.lib}">
- <include name="jboss-common.jar"/>
- <include name="namespace.jar"/>
+ <fileset dir="${jboss.common.core.lib}">
+ <exclude name="*-sources.jar"/>
</fileset>
+ <fileset dir="${jboss.common.logging.spi.lib}">
+ <exclude name="*-sources.jar"/>
+ </fileset>
+ <fileset dir="${jboss.common.logging.log4j.lib}">
+ <exclude name="*-sources.jar"/>
+ </fileset>
+ <fileset dir="${jboss.common.logging.jdk.lib}">
+ <exclude name="*-sources.jar"/>
+ </fileset>
<fileset dir="${jboss.jbossxb.lib}">
<include name="jboss-xml-binding.jar"/>
</fileset>
@@ -1727,16 +1754,25 @@
<include name="jboss-container.jar"/>
<include name="jboss-dependency.jar"/>
<include name="jboss-microcontainer.jar"/>
+ <include name="jboss-deployers.jar"/>
</fileset>
</copy>
<!-- Copy the generated client libraries -->
<mkdir dir="${install.client}"/>
<copy todir="${install.client}" filtering="no">
- <fileset dir="${jboss.common.lib}">
- <include name="jboss-common.jar"/>
- <include name="namespace.jar"/>
+ <fileset dir="${jboss.common.core.lib}">
+ <exclude name="*-sources.jar"/>
</fileset>
+ <fileset dir="${jboss.common.logging.spi.lib}">
+ <exclude name="*-sources.jar"/>
+ </fileset>
+ <fileset dir="${jboss.common.logging.log4j.lib}">
+ <exclude name="*-sources.jar"/>
+ </fileset>
+ <fileset dir="${jboss.common.logging.jdk.lib}">
+ <exclude name="*-sources.jar"/>
+ </fileset>
<fileset dir="${jboss.jbossxb.lib}">
<include name="jboss-xml-binding.jar"/>
</fileset>
@@ -1776,15 +1812,6 @@
</fileset>
</copy>
- <!-- Copy thirdparty code -->
- <copy todir="${install.lib}" filtering="no">
- <fileset dir="${apache.xerces.lib}">
- <include name="xml-apis.jar"/>
- <include name="xercesImpl.jar"/>
- <include name="resolver.jar"/>
- </fileset>
- </copy>
-
<!-- Copy thirdparty code to lib/endorsed -->
<mkdir dir="${install.lib}/endorsed"/>
<copy todir="${install.lib}/endorsed" filtering="no">
Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/build/build-thirdparty.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -90,7 +90,10 @@
<componentref name="jaxen" version="1.1beta4"/>
<componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
<componentref name="jboss/cache" version="snapshot"/>
- <componentref name="jboss/common" version="1.0.2"/>
+ <componentref name="jboss/common-core" version="2.0.0"/>
+ <componentref name="jboss/common-logging-log4j" version="2.0.0"/>
+ <componentref name="jboss/common-logging-jdk" version="2.0.0"/>
+ <componentref name="jboss/common-logging-spi" version="2.0.0"/>
<componentref name="jboss/jbossxb" version="1.0.0.CR6"/>
<componentref name="jboss/jbossretro" version="1.0.3.GA"/>
<componentref name="jboss/jbossws14" version="1.0.2.GA"/>
Modified: trunk/build/build.xml
===================================================================
--- trunk/build/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/build/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -105,6 +105,7 @@
<module name="server"/>
<module name="spring-int"/>
<module name="system"/>
+ <module name="system-jmx"/>
<module name="testsuite"/>
<module name="varia"/>
<module name="tomcat"/>
@@ -120,7 +121,7 @@
</group>
<group name="core">
- <include modules="j2se, mbeans, jmx, system, naming, aop"/>
+ <include modules="j2se, mbeans, jmx, system, system-jmx, naming, aop"/>
</group>
<group name="basic">
@@ -255,6 +256,7 @@
<property name="install.minimal" value="${install.server}/minimal"/>
<property name="install.minimal.lib" value="${install.minimal}/lib"/>
<property name="install.minimal.deploy" value="${install.minimal}/deploy"/>
+ <property name="install.minimal.deployers" value="${install.minimal}/deployers"/>
<property name="install.minimal.conf" value="${install.minimal}/conf"/>
<!-- Configuration for the nightly build and test job -->
@@ -421,7 +423,14 @@
<target name="_module-system-all" depends="_module-system-most">
<ant antfile="build-distr.xml" target="_module-system-all"/>
</target>
+ <target name="_module-system-jmx-most">
+ <ant antfile="build-distr.xml" target="_module-system-jmx-most"/>
+ </target>
+ <target name="_module-system-jmx-all" depends="_module-system-jmx-most">
+ <ant antfile="build-distr.xml" target="_module-system-jmx-all"/>
+ </target>
+
<!-- ====== -->
<!-- Naming -->
<!-- ====== -->
@@ -751,10 +760,12 @@
<!-- Build server/minimal manually -->
<mkdir dir="${install.minimal.deploy}"/>
+ <mkdir dir="${install.minimal.deployers}"/>
<copy todir="${install.minimal.conf}">
<fileset dir="${install.default.conf}">
<include name="jndi.properties" />
<include name="log4j.xml" />
+ <include name="deployer-beans.xml" />
</fileset>
</copy>
<copy file="${install.default.conf}/jboss-minimal.xml"
Modified: trunk/cluster/.classpath
===================================================================
--- trunk/cluster/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/cluster/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,7 +3,9 @@
<classpathentry excluding="org/jbossmx/" kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/server"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/transaction"/>
@@ -16,5 +18,7 @@
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="lib" path="/thirdparty/jboss/cache/lib/jboss-cache.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/cluster/build.xml
===================================================================
--- trunk/cluster/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/cluster/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -80,6 +80,7 @@
<path refid="jboss.cache.classpath"/>
<path refid="oswego.concurrent.classpath"/>
<path refid="jboss.remoting.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -89,8 +90,12 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.naming.classpath"/>
<path refid="jboss.mq.classpath"/>
<path refid="jboss.server.classpath"/>
Modified: trunk/connector/.classpath
===================================================================
--- trunk/connector/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -4,7 +4,9 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/system"/>
<classpathentry kind="src" path="/j2ee"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/server"/>
<classpathentry kind="src" path="/transaction"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
@@ -15,8 +17,11 @@
<classpathentry kind="lib" path="/thirdparty/quartz/lib/quartz-all-1.5.2.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/serialization/lib/jboss-serialization.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
- <classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar" sourcepath="C:/usr/local/Java/Jakarta/jakarta-log4j-1.2.8/src/java"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
+ <classpathentry sourcepath="/home/svn/JBossMC/jbossmc/container/src/main" kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-dependency.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/connector/build.xml
===================================================================
--- trunk/connector/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -79,6 +79,7 @@
<path refid="oswego.concurrent.classpath"/>
<path refid="sun.javamail.classpath"/>
<path refid="quartz.quartz.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -89,11 +90,15 @@
<!-- The combined depedant module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.security.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.transaction.classpath"/>
<path refid="jboss.serialization.classpath"/>
@@ -106,6 +111,8 @@
<!-- Where source files live -->
<property name="source.java" value="${module.source}/main"/>
+ <property name="javac.target" value="1.5"/>
+ <property name="javac.source" value="1.5"/>
<property name="source.etc" value="${module.source}/etc"/>
<property name="source.resources" value="${module.source}/resources"/>
Copied: trunk/connector/src/main/org/jboss/resource/deployers (from rev 57107, branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers)
Deleted: trunk/connector/src/main/org/jboss/resource/deployers/RARDeployer.java
===================================================================
--- branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers/RARDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/src/main/org/jboss/resource/deployers/RARDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,165 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.resource.deployers;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployers.plugins.deployers.helpers.AbstractSimpleRealDeployer;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext;
-import org.jboss.resource.metadata.ConnectorMetaData;
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceConstructorMetaData;
-import org.jboss.system.metadata.ServiceInjectionValueMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-
-/**
- * RARDeployer.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class RARDeployer extends AbstractSimpleRealDeployer<ConnectorMetaData>
-{
- /** The work manager name */
- private String workManagerName;
-
- /** The xa terminator name */
- private String xaTerminatorName;
-
- /**
- * Create a new RARDeployer.
- */
- public RARDeployer()
- {
- super(ConnectorMetaData.class);
- }
-
- public int getRelativeOrder()
- {
- return COMPONENT_DEPLOYER+1;
- }
-
- /**
- * Get the workManagerName.
- *
- * @return the workManagerName.
- */
- public String getWorkManagerName()
- {
- return workManagerName;
- }
-
- /**
- * Set the workManagerName.
- *
- * @param workManagerName the workManagerName.
- */
- public void setWorkManagerName(String workManagerName)
- {
- this.workManagerName = workManagerName;
- }
-
- /**
- * Get the XATerminatorName.
- *
- * @return the xaTerminatorName.
- */
- public String getXATerminatorName()
- {
- return xaTerminatorName;
- }
-
- /**
- * Set the XATerminatorName.
- *
- * @param xaTerminatorName the xaTerminatorName.
- */
- public void setXATerminatorName(String xaTerminatorName)
- {
- this.xaTerminatorName = xaTerminatorName;
- }
-
- protected String getObjectName(DeploymentUnit unit, ConnectorMetaData cmd)
- {
- // TODO this is a hack
- DeploymentContext ctx = unit.getDeploymentContext();
- String name = ctx.getRoot().getName();
- ctx = ctx.getParent();
- while (ctx != null)
- {
- name = ctx.getRoot().getName() + "#" + name;
- ctx = ctx.getParent();
- }
- return "jboss.jca:service=RARDeployment,name='" + name + "'";
- }
-
- public void deploy(DeploymentUnit unit, ConnectorMetaData cmd) throws DeploymentException
- {
- try
- {
- ServiceMetaData rarDeployment = new ServiceMetaData();
- String name = getObjectName(unit, cmd);
- ObjectName objectName = new ObjectName(name);
- rarDeployment.setObjectName(objectName);
- rarDeployment.setCode(RARDeployment.class.getName());
- ServiceConstructorMetaData constructor = new ServiceConstructorMetaData();
- constructor.setSignature(new String[] { ConnectorMetaData.class.getName() });
- constructor.setParameters(new Object[] { cmd });
- rarDeployment.setConstructor(constructor);
-
- List<ServiceAttributeMetaData> attributes = new ArrayList<ServiceAttributeMetaData>();
- ServiceAttributeMetaData attribute = null;
- if (workManagerName != null)
- {
- attribute = new ServiceAttributeMetaData();
- attribute.setName("WorkManager");
- attribute.setValue(new ServiceInjectionValueMetaData(workManagerName));
- attributes.add(attribute);
- }
- if (xaTerminatorName != null)
- {
- attribute = new ServiceAttributeMetaData();
- attribute.setName("XATerminator");
- attribute.setValue(new ServiceInjectionValueMetaData(xaTerminatorName, "XATerminator"));
- attributes.add(attribute);
- }
- if (attributes.isEmpty() == false)
- rarDeployment.setAttributes(attributes);
-
- // TODO component
- unit.addAttachment(ServiceMetaData.class, rarDeployment);
- }
- catch (Exception e)
- {
- throw DeploymentException.rethrowAsDeploymentException("Error creating rar deployment " + unit.getName(), e);
- }
- }
-
- public void undeploy(DeploymentUnit unit, ConnectorMetaData cmd)
- {
- }
-}
Copied: trunk/connector/src/main/org/jboss/resource/deployers/RARDeployer.java (from rev 57107, branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers/RARDeployer.java)
Deleted: trunk/connector/src/main/org/jboss/resource/deployers/RARDeployment.java
===================================================================
--- branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers/RARDeployment.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/src/main/org/jboss/resource/deployers/RARDeployment.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,352 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.resource.deployers;
-
-import java.net.URL;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.Timer;
-
-import javax.management.Attribute;
-import javax.management.AttributeNotFoundException;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanParameterInfo;
-import javax.management.ReflectionException;
-import javax.resource.spi.ActivationSpec;
-import javax.resource.spi.BootstrapContext;
-import javax.resource.spi.ResourceAdapter;
-import javax.resource.spi.UnavailableException;
-import javax.resource.spi.XATerminator;
-import javax.resource.spi.endpoint.MessageEndpointFactory;
-import javax.resource.spi.work.WorkManager;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.resource.deployment.ActivationSpecFactory;
-import org.jboss.resource.deployment.ResourceAdapterFactory;
-import org.jboss.resource.metadata.ConfigPropertyMetaData;
-import org.jboss.resource.metadata.ConnectorMetaData;
-import org.jboss.resource.metadata.DescriptionGroupMetaData;
-import org.jboss.resource.metadata.MessageListenerMetaData;
-import org.jboss.system.ServiceDynamicMBeanSupport;
-import org.jboss.system.server.ServerConfigUtil;
-
-/**
- * A resource adapter deployment
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 46109 $
- */
-public class RARDeployment extends ServiceDynamicMBeanSupport implements BootstrapContext
-{
- /** The RARDeploymentMetaData */
- /* TODO protected RARDeploymentMetaData rdmd; */
-
- /** The ConnectorMetaData */
- protected ConnectorMetaData cmd;
-
- /** The JBossRAMetaData */
- /* TODO protected JBossRAMetaData ramd; */
-
- /** The resource adapter */
- protected ResourceAdapter resourceAdapter;
-
- /** The work manager */
- private WorkManager workManager;
-
- /** The xa terminator */
- private XATerminator xaTerminator;
-
- /**
- * Create a new RAR deployment
- *
- * @param cmd the metadata
- */
- public RARDeployment(ConnectorMetaData cmd)
- {
- if (cmd == null)
- throw new IllegalArgumentException("Null metadata");
- this.cmd = cmd;
- /* TODO this.ramd = rdmd.getRaXmlMetaData(); */
-
- }
-
- public Timer createTimer() throws UnavailableException
- {
- return new Timer(true);
- }
-
- /**
- * Get the workManager.
- *
- * @return the workManager.
- */
- public WorkManager getWorkManager()
- {
- return workManager;
- }
-
- /**
- * Set the workManager.
- *
- * @param workManager the workManager.
- */
- public void setWorkManager(WorkManager workManager)
- {
- this.workManager = workManager;
- }
-
- /**
- * Get the XATerminator.
- *
- * @return the xaTerminator.
- */
- public XATerminator getXATerminator()
- {
- return xaTerminator;
- }
-
- /**
- * Set the xXATerminator.
- *
- * @param xaTerminator the XATerminator.
- */
- public void setXATerminator(XATerminator xaTerminator)
- {
- this.xaTerminator = xaTerminator;
- }
-
- protected void startService() throws Exception
- {
- URL url = cmd.getURL();
-
- if (cmd.getLicense().getRequired())
- {
- log.info ("Required license terms exist, view " + ServerConfigUtil.shortUrlFromServerHome(url.toString()));
- log.debug("License terms full URL: " + url);
- }
- resourceAdapter = ResourceAdapterFactory.createResourceAdapter(cmd);
- resourceAdapter.start(this);
- }
-
- protected void stopService() throws Exception
- {
- resourceAdapter.stop();
- }
-
- protected String getInternalDescription()
- {
- String description = null;
- DescriptionGroupMetaData dgmd = cmd.getDescription();
- if (dgmd != null)
- description = dgmd.getDescription();
- if (description == null)
- description = "RAR Deployment " + cmd.getURL();
- return description;
- }
-
- protected MBeanAttributeInfo[] getInternalAttributeInfo()
- {
- Collection properties = cmd.getProperties();
- MBeanAttributeInfo[] attrs = new MBeanAttributeInfo[13+properties.size()];
- attrs[0] = new MBeanAttributeInfo("MetaData", ConnectorMetaData.class.getName(), "The meta data", true, false, false);
- attrs[1] = new MBeanAttributeInfo("AuthenticationMechanism", String.class.getName(), "The authentication mechanism", true, false, false);
- attrs[2] = new MBeanAttributeInfo("EISType", String.class.getName(), "The EIS type", true, false, false);
- attrs[3] = new MBeanAttributeInfo("License", String.class.getName(), "The license", true, false, false);
- attrs[4] = new MBeanAttributeInfo("RAClass", String.class.getName(), "The resource adapter class", true, false, false);
- attrs[5] = new MBeanAttributeInfo("RAVersion", String.class.getName(), "The resource adapter version", true, false, false);
- attrs[6] = new MBeanAttributeInfo("TransactionSupport", String.class.getName(), "The transaction support", true, false, false);
- attrs[7] = new MBeanAttributeInfo("VendorName", String.class.getName(), "The vendor name", true, false, false);
- attrs[8] = new MBeanAttributeInfo("Version", String.class.getName(), "The spec version", true, false, false);
- attrs[9] = new MBeanAttributeInfo("ReauthenticationSupport", Boolean.TYPE.getName(), "Whether reauthentication support is supported", true, false, false);
- attrs[10] = new MBeanAttributeInfo("ResourceAdapter", ResourceAdapter.class.getName(), "The resource adapter instance", true, false, false);
- attrs[11] = new MBeanAttributeInfo("WorkManager", WorkManager.class.getName(), "The work manager", true, true, false);
- attrs[12] = new MBeanAttributeInfo("XATerminator", XATerminator.class.getName(), "The xa terminator", true, true, false);
- int n = 13;
- for (Iterator i = properties.iterator(); i.hasNext();)
- {
- ConfigPropertyMetaData cpmd = (ConfigPropertyMetaData) i.next();
- attrs[n++] = new MBeanAttributeInfo(cpmd.getName(), cpmd.getType(), cpmd.getDescription().getDescription(), true, false, false);
- }
- return attrs;
- }
-
- protected Object getInternalAttribute(String attribute)
- throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- if ("MetaData".equals(attribute))
- return cmd;
- else if ("AuthenticationMechanism".equals(attribute))
- return cmd.getAuthenticationMechanism().getAuthenticationMechansimType();
- else if ("EISType".equals(attribute))
- return cmd.getEISType();
- else if ("License".equals(attribute))
- return cmd.getLicense().getDescription().getDescription();
- else if ("RAClass".equals(attribute))
- return cmd.getRAClass();
- else if ("RAVersion".equals(attribute))
- return cmd.getRAVersion();
- else if ("TransactionSupport".equals(attribute))
- return cmd.getTransactionSupport();
- else if ("VendorName".equals(attribute))
- return cmd.getVendorName();
- else if ("Version".equals(attribute))
- return cmd.getVersion();
- else if ("ReauthenticationSupport".equals(attribute))
- return new Boolean(cmd.getReauthenticationSupport());
- else if ("ResourceAdapter".equals(attribute))
- return resourceAdapter;
- else if ("WorkManager".equals(attribute))
- return workManager;
- else if ("XATerminator".equals(attribute))
- return xaTerminator;
- Object property = cmd.getProperty(attribute);
- if (property != null)
- return property;
-
- return super.getInternalAttribute(attribute);
- }
-
- protected void setInternalAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- String name = attribute.getName();
- if ("WorkManager".equals(name))
- this.workManager = (WorkManager) attribute.getValue();
- else if ("XATerminator".equals(name))
- this.xaTerminator = (XATerminator) attribute.getValue();
- else
- super.setInternalAttribute(attribute);
- }
-
- protected MBeanOperationInfo[] getInternalOperationInfo()
- {
- MBeanOperationInfo[] ops = new MBeanOperationInfo[3];
-
- MBeanParameterInfo[] createActivationSpecParams = new MBeanParameterInfo[]
- {
- new MBeanParameterInfo("MessagingType", Class.class.getName(), "The type of the message listener"),
- new MBeanParameterInfo("ActivationConfig", Collection.class.getName(), "A collection of activation config properties")
- };
- ops[0] = new MBeanOperationInfo("createActivationSpec", "Create an activation spec",
- createActivationSpecParams, ActivationSpec.class.getName(), MBeanOperationInfo.ACTION);
-
- MBeanParameterInfo[] activationParams = new MBeanParameterInfo[]
- {
- new MBeanParameterInfo("MessageEndpointFactory", MessageEndpointFactory.class.getName(), "The message endpoint factory"),
- new MBeanParameterInfo("ActivationSpec", ActivationSpec.class.getName(), "The activation spec")
- };
- ops[1] = new MBeanOperationInfo("endpointActivation", "Active the endpoint",
- activationParams, Void.class.getName(), MBeanOperationInfo.ACTION);
- ops[2] = new MBeanOperationInfo("endpointDeactivation", "Deactive the endpoint",
- activationParams, Void.class.getName(), MBeanOperationInfo.ACTION);
-
- return ops;
- }
-
- protected Object internalInvoke(String actionName, Object[] params, String[] signature) throws MBeanException,
- ReflectionException
- {
- if ("createActivationSpec".equals(actionName))
- {
- if (params.length != 2)
- throw new IllegalArgumentException("Wrong number of parameters for " + actionName);
- Class messagingType = (Class) params[0];
- Collection activationConfig = (Collection) params[1];
- return createActivationSpec(messagingType, activationConfig);
- }
- else if ("endpointActivation".equals(actionName))
- {
- if (params.length != 2)
- throw new IllegalArgumentException("Wrong number of parameters for " + actionName);
- MessageEndpointFactory messageEndpointFactory = (MessageEndpointFactory) params[0];
- ActivationSpec activationSpec = (ActivationSpec) params[1];
- endpointActivation(messageEndpointFactory, activationSpec);
- return null;
- }
- else if ("endpointDeactivation".equals(actionName))
- {
- if (params.length != 2)
- throw new IllegalArgumentException("Wrong number of parameters for " + actionName);
- MessageEndpointFactory messageEndpointFactory = (MessageEndpointFactory) params[0];
- ActivationSpec activationSpec = (ActivationSpec) params[1];
- endpointDeactivation(messageEndpointFactory, activationSpec);
- return null;
- }
- return super.internalInvoke(actionName, params, signature);
- }
-
- protected ActivationSpec createActivationSpec(Class messagingType, Collection activationConfig) throws MBeanException
- {
- boolean trace = log.isTraceEnabled();
- if (trace)
- log.trace("CreateActivateSpec rar=" + getServiceName() + " messagingType=" + messagingType.getName() + " activationConfig=" + activationConfig);
-
- try
- {
- // Find the meta data
- MessageListenerMetaData mlmd = cmd.getMessageListener(messagingType.getName());
- if (mlmd == null)
- throw new DeploymentException("MessagingType '" + messagingType.getName() + "' not found in resource deployment " + getServiceName());
-
- return ActivationSpecFactory.createActivationSpec(getServiceName(), messagingType.getName(), activationConfig, mlmd);
- }
- catch (Exception e)
- {
- throw new MBeanException(e, "Error in create activation spec " + getServiceName());
- }
- }
-
- protected void endpointActivation(MessageEndpointFactory messageEndpointFactory, ActivationSpec activationSpec) throws MBeanException
- {
- boolean trace = log.isTraceEnabled();
- if (trace)
- log.trace("EndpointActivation rar=" + getServiceName() + " messagingEndpointFactory=" + messageEndpointFactory + " activationSpec=" + activationSpec);
-
- try
- {
- activationSpec.setResourceAdapter(resourceAdapter);
- resourceAdapter.endpointActivation(messageEndpointFactory, activationSpec);
- }
- catch (Exception e)
- {
- throw new MBeanException(e, "Error in endpoint activation " + getServiceName());
- }
- }
-
- protected void endpointDeactivation(MessageEndpointFactory messageEndpointFactory, ActivationSpec activationSpec) throws MBeanException
- {
- boolean trace = log.isTraceEnabled();
- if (trace)
- log.trace("EndpointDeactivation rar=" + getServiceName() + " messagingEndpointFactory=" + messageEndpointFactory + " activationSpec=" + activationSpec);
-
- try
- {
- resourceAdapter.endpointDeactivation(messageEndpointFactory, activationSpec);
- }
- catch (Exception e)
- {
- throw new MBeanException(e, "Error in endpoint deactivation " + getServiceName());
- }
- }
-}
Copied: trunk/connector/src/main/org/jboss/resource/deployers/RARDeployment.java (from rev 57107, branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers/RARDeployment.java)
Deleted: trunk/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java
===================================================================
--- branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,62 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.resource.deployers;
-
-import org.jboss.deployers.plugins.deployers.helpers.ObjectModelFactoryDeployer;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.resource.deployment.ResourceAdapterObjectModelFactory;
-import org.jboss.resource.metadata.ConnectorMetaData;
-import org.jboss.virtual.VirtualFile;
-import org.jboss.xb.binding.ObjectModelFactory;
-
-/**
- * RARParserDeployer.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class RARParserDeployer extends ObjectModelFactoryDeployer<ConnectorMetaData>
-{
- /**
- * Create a new RARParserDeployer.
- */
- public RARParserDeployer()
- {
- super(ConnectorMetaData.class);
- }
-
- protected ObjectModelFactory getObjectModelFactory()
- {
- return new ResourceAdapterObjectModelFactory();
- }
-
- public void deploy(DeploymentUnit unit) throws DeploymentException
- {
- createMetaData(unit, "ra.xml", null);
- }
-
- protected void init(DeploymentUnit unit, ConnectorMetaData cmd, VirtualFile file) throws Exception
- {
- cmd.setURL(file.toURL());
- }
-}
Copied: trunk/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java (from rev 57107, branches/MC_VDF_WORK/connector/src/main/org/jboss/resource/deployers/RARParserDeployer.java)
Modified: trunk/connector/src/main/org/jboss/resource/metadata/ConnectorMetaData.java
===================================================================
--- trunk/connector/src/main/org/jboss/resource/metadata/ConnectorMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/src/main/org/jboss/resource/metadata/ConnectorMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -21,6 +21,7 @@
*/
package org.jboss.resource.metadata;
+import java.net.URL;
import java.util.Collection;
import java.util.HashSet;
import java.util.Iterator;
@@ -38,6 +39,9 @@
{
private static final long serialVersionUID = -3049391010669865389L;
+ /** The url TODO move to RARDeploymentMetaData */
+ private URL url;
+
/** The version */
private String version = "1.0";
@@ -87,6 +91,26 @@
}
/**
+ * Get the url.
+ *
+ * @return the url.
+ */
+ public URL getURL()
+ {
+ return url;
+ }
+
+ /**
+ * Set the url.
+ *
+ * @param url the url.
+ */
+ public void setURL(URL url)
+ {
+ this.url = url;
+ }
+
+ /**
* Get the connector version
*
* @return the connector version
Copied: trunk/connector/src/resources/deployers (from rev 57107, branches/MC_VDF_WORK/connector/src/resources/deployers)
Deleted: trunk/connector/src/resources/deployers/jca-deployers-beans.xml
===================================================================
--- branches/MC_VDF_WORK/connector/src/resources/deployers/jca-deployers-beans.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/src/resources/deployers/jca-deployers-beans.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,40 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!--
- JCA Deployers
--->
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
-
- <!-- RAR Deployment -->
- <bean name="RARParserDeployer" class="org.jboss.resource.deployers.RARParserDeployer">
- <install bean="MainDeployer" method="addDeployer">
- <parameter><this/></parameter>
- </install>
- <uninstall bean="MainDeployer" method="removeDeployer">
- <parameter><this/></parameter>
- </uninstall>
- </bean>
- <bean name="RARDeployer" class="org.jboss.resource.deployers.RARDeployer">
- <property name="workManagerName">jboss.jca:service=WorkManager</property>
- <property name="XATerminatorName">jboss:service=TransactionManager</property>
- <install bean="MainDeployer" method="addDeployer">
- <parameter><this/></parameter>
- </install>
- <uninstall bean="MainDeployer" method="removeDeployer">
- <parameter><this/></parameter>
- </uninstall>
- </bean>
-
- <!-- ConnectionFactory Deployment -->
- <bean name="ConnectionFactoryDeployer" class="org.jboss.system.deployers.ServiceXSLDeployer">
- <property name="suffix">-ds.xml</property>
- <property name="XSLPath">stylesheets/ConnectionFactoryTemplate.xsl</property>
- <install bean="MainDeployer" method="addDeployer">
- <parameter><this/></parameter>
- </install>
- <uninstall bean="MainDeployer" method="removeDeployer">
- <parameter><this/></parameter>
- </uninstall>
- </bean>
-
-</deployment>
Copied: trunk/connector/src/resources/deployers/jca-deployers-beans.xml (from rev 57107, branches/MC_VDF_WORK/connector/src/resources/deployers/jca-deployers-beans.xml)
Modified: trunk/connector/src/resources/jca-sar/jbossjca-service.xml
===================================================================
--- trunk/connector/src/resources/jca-sar/jbossjca-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/connector/src/resources/jca-sar/jbossjca-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -38,18 +38,20 @@
<depends optional-attribute-name="XATerminatorName">jboss:service=TransactionManager</depends>
</mbean>
- <mbean code="org.jboss.resource.deployment.RARDeployer"
+ <!--mbean code="org.jboss.resource.deployment.RARDeployer"
name="jboss.jca:service=RARDeployer">
<depends optional-attribute-name="WorkManagerName">jboss.jca:service=WorkManager</depends>
<depends optional-attribute-name="XATerminatorName">jboss:service=TransactionManager</depends>
- </mbean>
+ <depends>jboss.system:service=MainDeployer</depends>
+ </mbean-->
- <mbean code="org.jboss.deployment.XSLSubDeployer" name="jboss.jca:service=ConnectionFactoryDeployer">
+ <!--mbean code="org.jboss.deployment.XSLSubDeployer" name="jboss.jca:service=ConnectionFactoryDeployer">
<attribute name="DdSuffix">-ds.xml</attribute>
<attribute name="EnhancedSuffixes">300:-ds.xml</attribute>
<attribute name="XslUrl">stylesheets/ConnectionFactoryTemplate.xsl</attribute>
<attribute name="ValidateDTDs">false</attribute>
- </mbean>
+ <depends>jboss.system:service=ServiceDeployer</depends>
+ </mbean-->
<!-- Experimental for new DsSubDeployer support
<mbean code="org.jboss.resource.deployment.ds.DsSubDeployer" name="jboss.jca:service=ConnectionFactoryDeployer">
Modified: trunk/console/.classpath
===================================================================
--- trunk/console/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/console/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,7 +3,9 @@
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/management"/>
<classpathentry kind="lib" path="/thirdparty/gnu-getopt/lib/getopt.jar"/>
<classpathentry kind="lib" path="/thirdparty/beanshell/lib/bsh-1.3.0.jar"/>
@@ -19,5 +21,6 @@
<classpathentry kind="src" path="/server"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/console/build.xml
===================================================================
--- trunk/console/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/console/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -89,13 +89,17 @@
&modules;
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.management.classpath"/>
<path refid="jboss.security.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.mq.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.varia.classpath"/>
<path refid="jboss.aop.classpath"/>
</path>
@@ -326,7 +330,7 @@
<include name="org/jboss/invocation/*"/>
<exclude name="META-INF/INDEX.LIST"/>
</zipfileset>
- <zipfileset src="${jboss.common.lib}/jboss-common-client.jar">
+ <zipfileset src="${jboss.common.core.lib}/jboss-common-core-2.0.0.jar">
<exclude name="META-INF/INDEX.LIST"/>
<exclude name="org/jboss/util/property/**"/>
<exclude name="org/jboss/util/propertyeditor/**"/>
Modified: trunk/deployment/.classpath
===================================================================
--- trunk/deployment/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/deployment/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src/main"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
- <classpathentry kind="src" path="/j2ee"/>
- <classpathentry kind="src" path="/system"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/j2ee"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/j2se"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system"/>
<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
- <classpathentry kind="src" path="/j2se"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/deployment/build.xml
===================================================================
--- trunk/deployment/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/deployment/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -69,6 +69,7 @@
<!-- The combined library classpath -->
<path id="library.classpath">
<path refid="dom4j.dom4j.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -79,10 +80,14 @@
<!-- The combined dependant module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
</path>
<!-- ===== -->
Modified: trunk/ejb3/.classpath
===================================================================
--- trunk/ejb3/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/ejb3/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -50,7 +50,9 @@
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/aop"/>
<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/system"/>
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
@@ -87,5 +89,7 @@
<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/ejb3/build-test.xml
===================================================================
--- trunk/ejb3/build-test.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/ejb3/build-test.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -168,7 +168,10 @@
<path refid="jboss.aop.classpath"/>
<path refid="jboss.aspects.classpath"/>
<path refid="jboss.ejb3x.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.cache.classpath"/>
<path refid="jboss.cluster.classpath"/>
<path refid="jboss.system.classpath"/>
@@ -2743,7 +2746,10 @@
<path refid="jboss.server.classpath"/>
<path refid="jboss.naming.classpath"/>
<path refid="trove.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.aop50.classpath"/>
<path refid="jboss.aspects.classpath"/>
<path refid="jboss.jbossxb.classpath"/>
Modified: trunk/ejb3/build.xml
===================================================================
--- trunk/ejb3/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/ejb3/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -117,9 +117,13 @@
<path refid="jboss.cache.classpath"/>
<path refid="jboss.aspects.classpath"/>
<path refid="jboss.ejb3x.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.cluster.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.naming.classpath"/>
<path refid="jboss.transaction.classpath"/>
<path refid="jboss.security.classpath"/>
@@ -456,7 +460,7 @@
<zipfileset src="${jboss.transaction.lib}/jboss-transaction.jar" />
<zipfileset src="${jboss.naming.lib}/jnpserver.jar" />
<zipfileset src="${jboss.j2ee.lib}/jboss-j2ee.jar" />
- <zipfileset src="${jboss.common.lib}/jboss-common.jar" />
+ <zipfileset src="${jboss.common.core.lib}/jboss-common-core-2.0.0.jar" />
<zipfileset src="${jboss.jbossxb.lib}/jboss-xml-binding.jar" />
<zipfileset src="${jboss.security.lib}/jbosssx.jar" />
<zipfileset src="${jboss.security.spi.lib}/jboss-security-spi.jar" />
@@ -553,7 +557,6 @@
</fileset>
</javadoc>
<property name="ejb3.version" value="jboss-EJB-3.0_RC2"/>
- <echo message="${jboss.common.lib}"/>
<zip zipfile="${ejb3.version}.zip">
<zipfileset dir="." prefix="${ejb3.version}">
<include name="INSTALL.html"/>
@@ -601,7 +604,6 @@
</fileset>
</javadoc>
<property name="ejb3.zip.version" value="jboss-EJB-3.0_Embeddable_ALPHA_8-patch2"/>
- <echo message="${jboss.common.lib}"/>
<zip zipfile="${ejb3.zip.version}.zip">
<zipfileset dir="." prefix="${ejb3.zip.version}">
<include name="RELEASE_NOTES.txt"/>
Modified: trunk/ejb3x/.classpath
===================================================================
--- trunk/ejb3x/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/ejb3x/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -4,7 +4,8 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="/thirdparty/sun-servlet/lib/servlet-api.jar"/>
<classpathentry kind="lib" path="/thirdparty/sun-jaf/lib/activation.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
<classpathentry kind="src" path="/j2ee"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/ejb3x/build.xml
===================================================================
--- trunk/ejb3x/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/ejb3x/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -85,8 +85,9 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
- <!-- this is for org.jboss.lang.Enum -->
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <!-- this is for org.jboss.lang.Enum -->
<path refid="jboss.aop.classpath"/>
<path refid="jboss.j2ee.classpath"/>
</path>
Modified: trunk/hibernate-int/.classpath
===================================================================
--- trunk/hibernate-int/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/hibernate-int/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -2,7 +2,9 @@
<classpath>
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/server"/>
<classpathentry kind="src" path="/transaction"/>
@@ -12,6 +14,8 @@
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="lib" path="/thirdparty/hibernate/lib/hibernate3.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/cache/lib/jboss-cache.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry combineaccessrules="false" kind="src" path="/system"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/hibernate-int/build.sh
===================================================================
--- trunk/hibernate-int/build.sh 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/hibernate-int/build.sh 2006-09-23 20:55:54 UTC (rev 57108)
@@ -159,9 +159,9 @@
# execute in debug mode, or simply execute
if [ "x$ANT_DEBUG" != "x" ]; then
- /bin/sh -x $ANT $ANT_OPTIONS "$@"
+ /bin/sh -x $ANT $ANT_OPTIONS "$@"
else
- exec $ANT $ANT_OPTIONS "$@"
+ exec $ANT $ANT_OPTIONS "$@"
fi
}
Modified: trunk/hibernate-int/build.xml
===================================================================
--- trunk/hibernate-int/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/hibernate-int/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -76,6 +76,7 @@
<path refid="hibernate3.classpath"/>
<path refid="odmg.classpath"/>
<path refid="cglib.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -86,11 +87,15 @@
<!-- Specify modules upon which this build depends -->
<path id="dependentmodule.classpath">
<path refid="jboss.cache.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.transaction.classpath"/>
</path>
Modified: trunk/iiop/.classpath
===================================================================
--- trunk/iiop/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/iiop/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -6,7 +6,6 @@
<classpathentry kind="lib" path="/thirdparty/jacorb/lib/jacorb.jar"/>
<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/naming"/>
<classpathentry kind="src" path="/server"/>
@@ -16,5 +15,10 @@
<classpathentry kind="lib" path="/thirdparty/apache-avalon/lib/avalon-framework.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/iiop/build.xml
===================================================================
--- trunk/iiop/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/iiop/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -79,6 +79,7 @@
<path refid="junit.junit.classpath"/>
<path refid="jacorb.jacorb.classpath"/>
<path refid="oswego.concurrent.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -89,8 +90,12 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.naming.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.j2se.classpath"/>
Modified: trunk/j2ee/.classpath
===================================================================
--- trunk/j2ee/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/j2ee/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -4,6 +4,8 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="lib" path="/thirdparty/sun-servlet/lib/servlet-api.jar"/>
<classpathentry kind="lib" path="/thirdparty/sun-jaf/lib/activation.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/j2ee/build.xml
===================================================================
--- trunk/j2ee/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/j2ee/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -87,7 +87,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
</path>
<!-- ===== -->
Modified: trunk/j2se/.classpath
===================================================================
--- trunk/j2se/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/j2se/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,9 +3,12 @@
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="src" path="src/tests"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+ <classpathentry sourcepath="/thirdparty/jboss/microcontainer/container-src" kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/j2se/build.xml
===================================================================
--- trunk/j2se/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/j2se/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -78,13 +78,18 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ===== -->
<!-- Tasks -->
<!-- ===== -->
-
+ <property name="javac.target" value="1.5"/>
+ <property name="javac.source" value="1.5"/>
<property name="source.java" value="${module.source}/main"/>
<property name="source.tests" value="${module.source}/tests"/>
<call target="_default:task-init"/>
Copied: trunk/j2se/src/main/org/jboss/mx/loading/LegacyDomainClassLoader.java (from rev 57107, branches/MC_VDF_WORK/j2se/src/main/org/jboss/mx/loading/LegacyDomainClassLoader.java)
Property changes on: trunk/j2se/src/main/org/jboss/mx/loading/LegacyDomainClassLoader.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/j2se/src/main/org/jboss/mx/loading/LoaderRepositoryDomain.java (from rev 57107, branches/MC_VDF_WORK/j2se/src/main/org/jboss/mx/loading/LoaderRepositoryDomain.java)
Property changes on: trunk/j2se/src/main/org/jboss/mx/loading/LoaderRepositoryDomain.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Modified: trunk/jbossas/.classpath
===================================================================
--- trunk/jbossas/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jbossas/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,15 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
- <classpathentry excluding="tests/" kind="src" path="remoting/src/main"/>
- <classpathentry kind="src" path="remoting/src/main/tests"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/aop"/>
<classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
<classpathentry combineaccessrules="false" kind="src" path="/server"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
- <classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
- <classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Copied: trunk/jbossas/jmx-remoting/build.bat (from rev 57107, branches/MC_VDF_WORK/jbossas/jmx-remoting/build.bat)
Property changes on: trunk/jbossas/jmx-remoting/build.bat
___________________________________________________________________
Name: svn:executable
+ *
Copied: trunk/jbossas/jmx-remoting/build.sh (from rev 57107, branches/MC_VDF_WORK/jbossas/jmx-remoting/build.sh)
Property changes on: trunk/jbossas/jmx-remoting/build.sh
___________________________________________________________________
Name: svn:executable
+ *
Modified: trunk/jbossas/jmx-remoting/build.xml
===================================================================
--- trunk/jbossas/jmx-remoting/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jbossas/jmx-remoting/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -81,7 +81,10 @@
&modules;
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.jmx-remoting.classpath"/>
</path>
Modified: trunk/jbossas/remoting/build.xml
===================================================================
--- trunk/jbossas/remoting/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jbossas/remoting/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -88,7 +88,10 @@
&modules;
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.aop.classpath"/>
<path refid="jboss.security.classpath"/>
Modified: trunk/jmx/.classpath
===================================================================
--- trunk/jmx/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -2,7 +2,9 @@
<classpath>
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="lib" path="/thirdparty/apache-bcel/lib/bcel.jar"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
@@ -10,5 +12,6 @@
<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="src" path="/mbeans"/>
+ <classpathentry sourcepath="/home/svn/JBossMC/jbossmc/container/src/main" kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/jmx/build.xml
===================================================================
--- trunk/jmx/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -73,10 +73,14 @@
<!-- Configure modules -->
<path id="dependentmodule.classpath">
<!-- Add dependent module classpath elements here. -->
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.mbeans.classpath"/>
<path refid="jboss.jmxcompliance.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- Configure thirdparty libraries -->
@@ -143,16 +147,8 @@
<property name="module.name" value="jbossmx"/>
<property name="module.Name" value="JBoss/JMX"/>
- <!-- xdoclet -->
- <path id="xdoclet.task.classpath">
- <path refid="javac.classpath"/>
- <fileset dir="${xdoclet.xdoclet.lib}">
- <include name="**/*.jar"/>
- </fileset>
- </path>
- <property name="xdoclet.task.classpath"
- refid="xdoclet.task.classpath"/>
-
+ <property name="javac.target" value="1.5"/>
+ <property name="javac.source" value="1.5"/>
<!-- Where build generated files will go -->
<property name="build.reports" value="${module.output}/reports"/>
<property name="build.classes" value="${module.output}/classes"/>
Modified: trunk/jmx/src/main/org/jboss/mx/loading/ClassLoaderUtils.java
===================================================================
--- trunk/jmx/src/main/org/jboss/mx/loading/ClassLoaderUtils.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx/src/main/org/jboss/mx/loading/ClassLoaderUtils.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -57,7 +57,7 @@
private static Logger log = Logger.getLogger(ClassLoaderUtils.class);
/** The singleton instance of repository classloader comparator */
- private static final Comparator repostiroyClassLoaderComparator = new RepositoryClassLoaderComparator();
+ private static final Comparator repositoryClassLoaderComparator = new RepositoryClassLoaderComparator();
/** Format a string buffer containing the Class, Interfaces, CodeSource,
and ClassLoader information for the given object clazz.
@@ -222,7 +222,7 @@
*/
public static Set newPackageSet()
{
- return new TreeSet(repostiroyClassLoaderComparator);
+ return new TreeSet(repositoryClassLoaderComparator);
}
/**
@@ -237,21 +237,6 @@
return (Set) original.clone();
}
- /** Given a UCL this method determine what packages
- it contains and create a mapping from the package names to the cl.
- * @param cl the UCL that loads from url
- * @param packagesMap the Map<cl, String[]> to update
- * @return the updated unique set of package names
- * @throws Exception
- */
- public static String[] updatePackageMap(RepositoryClassLoader cl, Map packagesMap)
- throws Exception
- {
- URL url = cl.getURL();
- ClassPathIterator cpi = new ClassPathIterator(url);
- HashSet pkgNameSet = new HashSet();
- return updatePackageMap(cl, packagesMap, cpi, pkgNameSet);
- }
/** Augment the package name associated with a UCL.
* @param cl the UCL that loads from url
* @param packagesMap the Map<cl, String[]> to update
@@ -260,35 +245,13 @@
* @return the updated unique set of package names
* @throws Exception
*/
- public static String[] updatePackageMap(RepositoryClassLoader cl, Map packagesMap,
- URL url, String[] prevPkgNames)
+ public static void updatePackageMap(URL url, PkgNameListener listener)
throws Exception
{
ClassPathIterator cpi = new ClassPathIterator(url);
- HashSet pkgNameSet = null;
- if (prevPkgNames == null)
- pkgNameSet = new HashSet();
- else
- pkgNameSet = new HashSet(Arrays.asList(prevPkgNames));
- return updatePackageMap(cl, packagesMap, cpi, pkgNameSet);
+ updatePackageMap(cpi, listener);
}
- /** Given a UCL this method determine what classes it contains
- and create a mapping from the class names to the cl.
- * @param cl the UCL that loads from url
- * @param classNamesMap the Map<cl, String[]> to update
- * @return the class names directly visible to the cl
- * @throws Exception
- */
- public static String[] updateClassNamesMap(RepositoryClassLoader cl,
- Map classNamesMap)
- throws Exception
- {
- URL url = cl.getURL();
- ClassPathIterator cpi = new ClassPathIterator(url);
- HashSet classNameSet = new HashSet();
- return updateClassNamesMap(cl, classNamesMap, cpi, classNameSet);
- }
/** Augment the class names associated with a UCL.
* @param cl the UCL that loads from url
* @param classNamesMap the Map<cl, String[]> to update
@@ -297,7 +260,7 @@
* @return the updated list of class names
* @throws Exception
*/
- public static String[] updateClassNamesMap(RepositoryClassLoader cl,
+ public static String[] updateClassNamesMap(Object cl,
Map classNamesMap, URL url, String[] prevClassNames)
throws Exception
{
@@ -310,11 +273,9 @@
return updateClassNamesMap(cl, classNamesMap, cpi, classNameSet);
}
- static String[] updatePackageMap(RepositoryClassLoader cl, Map packagesMap,
- ClassPathIterator cpi, HashSet pkgNameSet)
+ static void updatePackageMap(ClassPathIterator cpi, PkgNameListener listener)
throws Exception
{
- boolean trace = log.isTraceEnabled();
ClassPathEntry entry;
while( (entry = cpi.getNextEntry()) != null )
{
@@ -322,7 +283,7 @@
// First look for a META-INF/INDEX.LIST entry
if( name.equals("META-INF/INDEX.LIST") )
{
- readJarIndex(cl, cpi, packagesMap, pkgNameSet);
+ readJarIndex(cpi, listener);
// We are done
break;
}
@@ -332,17 +293,12 @@
continue;
String pkgName = entry.toPackageName();
- addPackage(pkgName, packagesMap, pkgNameSet, cl, trace);
+ listener.addPackage(pkgName);
}
cpi.close();
-
- // Return an array of the package names
- String[] pkgNames = new String[pkgNameSet.size()];
- pkgNameSet.toArray(pkgNames);
- return pkgNames;
}
- static String[] updateClassNamesMap(RepositoryClassLoader cl, Map classNamesMap,
+ static String[] updateClassNamesMap(Object cl, Map classNamesMap,
ClassPathIterator cpi, HashSet classNameSet)
throws Exception
{
@@ -372,8 +328,7 @@
/** Read the JDK 1.3+ META-INF/INDEX.LIST entry to obtain the package
names without having to iterate through all entries in the jar.
*/
- private static void readJarIndex(RepositoryClassLoader cl, ClassPathIterator cpi,
- Map packagesMap, Set pkgNameSet)
+ private static void readJarIndex(ClassPathIterator cpi, PkgNameListener listener)
throws Exception
{
boolean trace = log.isTraceEnabled();
@@ -396,38 +351,11 @@
if( line.length() == 0 )
break;
String pkgName = line.replace('/', '.');
- addPackage(pkgName, packagesMap, pkgNameSet, cl, trace);
+ listener.addPackage(pkgName);
}
br.close();
}
- private static void addPackage(String pkgName, Map packagesMap,
- Set pkgNameSet, RepositoryClassLoader cl, boolean trace)
- {
- // Skip the standard J2EE archive directories
- if( pkgName.startsWith("META-INF") || pkgName.startsWith("WEB-INF") )
- return;
-
- Set pkgSet = (Set) packagesMap.get(pkgName);
- if( pkgSet == null )
- {
- pkgSet = newPackageSet();
- packagesMap.put(pkgName, pkgSet);
- }
- if( pkgSet.contains(cl) == false )
- {
- pkgSet.add(cl);
- pkgNameSet.add(pkgName);
- // Anytime more than one class loader exists this may indicate a problem
- if( pkgSet.size() > 1 )
- {
- log.debug("Multiple class loaders found for pkg: "+pkgName);
- }
- if( trace )
- log.trace("Indexed pkg: "+pkgName+", UCL: "+cl);
- }
- }
-
/** Add a class name to the UCL map.
* @param jarClassName the class name in the jar (java/lang/String.class)
* @param classNamesMap the UCL class name mappings
@@ -435,7 +363,7 @@
* @param trace the logging trace level flag
*/
private static void addClass(String jarClassName, Map classNamesMap,
- RepositoryClassLoader cl, boolean trace)
+ Object cl, boolean trace)
{
LinkedList ucls = (LinkedList) classNamesMap.get(jarClassName);
if( ucls == null )
@@ -458,6 +386,11 @@
log.trace("Indexed class: "+jarClassName+", UCL: "+ucls.get(0));
}
+ public static interface PkgNameListener
+ {
+ public void addPackage(String name);
+ }
+
/**
*/
static class FileIterator
Copied: trunk/jmx/src/main/org/jboss/mx/loading/ClassLoadingTaskDCL.java (from rev 57107, branches/MC_VDF_WORK/jmx/src/main/org/jboss/mx/loading/ClassLoadingTaskDCL.java)
Property changes on: trunk/jmx/src/main/org/jboss/mx/loading/ClassLoadingTaskDCL.java
___________________________________________________________________
Name: svn:executable
+ *
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/jmx/src/main/org/jboss/mx/loading/DomainClassLoaderUCLImpl.java (from rev 57107, branches/MC_VDF_WORK/jmx/src/main/org/jboss/mx/loading/DomainClassLoaderUCLImpl.java)
Copied: trunk/jmx/src/main/org/jboss/mx/loading/LoadMgrDCL.java (from rev 57107, branches/MC_VDF_WORK/jmx/src/main/org/jboss/mx/loading/LoadMgrDCL.java)
Property changes on: trunk/jmx/src/main/org/jboss/mx/loading/LoadMgrDCL.java
___________________________________________________________________
Name: svn:executable
+ *
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Modified: trunk/jmx/src/main/org/jboss/mx/loading/ResourceInfo.java
===================================================================
--- trunk/jmx/src/main/org/jboss/mx/loading/ResourceInfo.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx/src/main/org/jboss/mx/loading/ResourceInfo.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -25,14 +25,15 @@
/**
*
- * @author starksm
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
*/
-class ResourceInfo
+class ResourceInfo<T>
{
URL url;
- ClassLoader cl;
+ T cl;
- ResourceInfo(URL url, ClassLoader cl)
+ ResourceInfo(URL url, T cl)
{
this.url = url;
this.cl = cl;
Modified: trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepository3.java
===================================================================
--- trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepository3.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepository3.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -32,6 +32,7 @@
import java.util.Enumeration;
import java.util.Map;
import java.util.Set;
+import java.util.TreeSet;
import java.io.IOException;
import javax.management.ListenerNotFoundException;
@@ -132,7 +133,7 @@
* they serve
* Access synchronized via this.packagesMap monitor.
*/
- private HashMap loaderToPackagesMap = new HashMap();
+ private HashMap<RepositoryClassLoader, List<String>> loaderToPackagesMap = new HashMap<RepositoryClassLoader, List<String>>();
/**
* The sequenceNumber used to number notifications.
@@ -781,8 +782,9 @@
{
try
{
- String[] pkgNames = ClassLoaderUtils.updatePackageMap(cl, packagesMap);
- loaderToPackagesMap.put(cl, pkgNames);
+ URL url = cl.getURL();
+ PackageMapper listener = new PackageMapper(cl);
+ ClassLoaderUtils.updatePackageMap(url, listener);
}
catch (Exception e)
{
@@ -800,9 +802,8 @@
{
try
{
- String[] prevPkgNames = (String[]) loaderToPackagesMap.get(cl);
- String[] pkgNames = ClassLoaderUtils.updatePackageMap(cl, packagesMap, url, prevPkgNames);
- loaderToPackagesMap.put(cl, pkgNames);
+ PackageMapper listener = new PackageMapper(cl);
+ ClassLoaderUtils.updatePackageMap(url, listener);
}
catch (Exception e)
{
@@ -892,17 +893,18 @@
// Clean up the package name to class loader mapping
if (dynamic == false)
{
- String[] pkgNames = (String[]) loaderToPackagesMap.remove(cl);
- int length = pkgNames != null ? pkgNames.length : 0;
- for (int p = 0; p < length; p++)
+ List<String> pkgNames = loaderToPackagesMap.remove(cl);
+ if( pkgNames != null )
{
- String pkgName = pkgNames[p];
- Set pkgSet = (Set) packagesMap.get(pkgName);
- if (pkgSet != null)
+ for(String pkgName : pkgNames)
{
- pkgSet.remove(cl);
- if (pkgSet.isEmpty())
- packagesMap.remove(pkgName);
+ Set pkgSet = (Set) packagesMap.get(pkgName);
+ if (pkgSet != null)
+ {
+ pkgSet.remove(cl);
+ if (pkgSet.isEmpty())
+ packagesMap.remove(pkgName);
+ }
}
}
}
@@ -1057,4 +1059,45 @@
return rcl;
}
}
+
+ private class PackageMapper implements ClassLoaderUtils.PkgNameListener
+ {
+ private RepositoryClassLoader loader;
+ PackageMapper(RepositoryClassLoader loader)
+ {
+ this.loader = loader;
+ }
+ public void addPackage(String pkgName)
+ {
+ // Skip the standard J2EE archive directories
+ if( pkgName.startsWith("META-INF") || pkgName.startsWith("WEB-INF") )
+ return;
+
+ Set<RepositoryClassLoader> pkgSet = (Set<RepositoryClassLoader>) packagesMap.get(pkgName);
+ if( pkgSet == null )
+ {
+ pkgSet = ClassLoaderUtils.newPackageSet();
+ packagesMap.put(pkgName, pkgSet);
+ }
+ if( pkgSet.contains(loader) == false )
+ {
+ pkgSet.add((RepositoryClassLoader)loader);
+ List<String> loaderPkgNames = loaderToPackagesMap.get(loader);
+ if( loaderPkgNames == null )
+ {
+ loaderPkgNames = new ArrayList<String>();
+ loaderToPackagesMap.put((RepositoryClassLoader)loader, loaderPkgNames);
+ }
+ loaderPkgNames.add(pkgName);
+
+ // Anytime more than one class loader exists this may indicate a problem
+ if( pkgSet.size() > 1 )
+ {
+ log.debug("Multiple class loaders found for pkg: "+pkgName);
+ }
+ if( log.isTraceEnabled() )
+ log.trace("Indexed pkg: "+pkgName+", UCL: "+loader);
+ }
+ }
+ }
}
Copied: trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepositoryDCL.java (from rev 57107, branches/MC_VDF_WORK/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepositoryDCL.java)
Copied: trunk/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepositoryDCLMBean.java (from rev 57107, branches/MC_VDF_WORK/jmx/src/main/org/jboss/mx/loading/UnifiedLoaderRepositoryDCLMBean.java)
Modified: trunk/jmx/src/main/org/jboss/mx/server/MBeanServerImpl.java
===================================================================
--- trunk/jmx/src/main/org/jboss/mx/server/MBeanServerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx/src/main/org/jboss/mx/server/MBeanServerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -745,7 +745,7 @@
{
MBeanEntry entry = registry.get(name);
if (NotificationBroadcaster.class.isInstance(entry.getResourceInstance()) == false)
- throw new RuntimeOperationsException(new IllegalArgumentException("The MBean named exists but does not implement the NotificationBroadcaster interface."));
+ throw new RuntimeOperationsException(new IllegalArgumentException("The MBean " + name + " exists but does not implement the NotificationBroadcaster interface."));
if (listener == null)
throw new RuntimeOperationsException(new IllegalArgumentException("Cannot add null listener"));
Modified: trunk/jmx-remoting/.classpath
===================================================================
--- trunk/jmx-remoting/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx-remoting/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -12,10 +12,9 @@
<attributes>
</attributes>
</classpathentry>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar">
- <attributes>
- </attributes>
- </classpathentry>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar">
<attributes>
</attributes>
Modified: trunk/jmx-remoting/build.xml
===================================================================
--- trunk/jmx-remoting/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/jmx-remoting/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -79,7 +79,10 @@
&modules;
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
</path>
Modified: trunk/management/.classpath
===================================================================
--- trunk/management/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/management/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,13 +3,15 @@
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="src" path="output/classes"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/server"/>
<classpathentry kind="src" path="/cluster"/>
<classpathentry kind="src" path="/connector"/>
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/management/build.xml
===================================================================
--- trunk/management/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/management/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -96,11 +96,15 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.cluster.classpath"/>
- <path refid="jboss.common.classpath"/>
<path refid="jboss.jca.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.j2ee.classpath"/>
</path>
Modified: trunk/mbeans/.classpath
===================================================================
--- trunk/mbeans/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src/main"/>
+ <classpathentry output="output/eclipse-test-classes" kind="src" path="src/tests"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="lib" path="/thirdparty/apache-bcel/lib/bcel.jar"/>
<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/mbeans/build.xml
===================================================================
--- trunk/mbeans/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -73,7 +73,10 @@
<!-- Configure modules -->
<path id="dependentmodule.classpath">
<!-- Add dependent module classpath elements here. -->
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.j2se.classpath"/>
</path>
@@ -137,7 +140,8 @@
<!-- Module name & version -->
<property name="module.name" value="jbossmbeans"/>
<property name="module.Name" value="JBoss/MBeans"/>
-
+ <property name="javac.target" value="1.5"/>
+ <property name="javac.source" value="1.5"/>
<!-- Where build generated files will go -->
<property name="build.reports" value="${module.output}/reports"/>
<property name="build.classes" value="${module.output}/classes"/>
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,115 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.lang.reflect.Type;
-
-import javax.management.openmbean.CompositeData;
-import javax.management.openmbean.InvalidKeyException;
-
-import org.jboss.util.UnreachableStatementException;
-
-/**
- * CompositeDataInvocationHandler.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataInvocationHandler implements InvocationHandler
-{
- /** The composite data */
- private CompositeData compositeData;
-
- /**
- * Create a new CompositeDataInvocationHandler.
- *
- * @param compositeData
- */
- public CompositeDataInvocationHandler(CompositeData compositeData)
- {
- if (compositeData == null)
- throw new IllegalArgumentException("Null compositeData");
- this.compositeData = compositeData;
- }
-
- /**
- * Get the compositeData.
- *
- * @return the compositeData.
- */
- public CompositeData getCompositeData()
- {
- return compositeData;
- }
-
- public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
- {
- if (Object.class.equals(method.getDeclaringClass()))
- return handleObjectInvocation(method.getName(), args);
-
- Object value = getValue(method);
-
- Type returnType = method.getGenericReturnType();
- return MXBeanUtils.reconstruct(returnType, value, method);
- }
-
- private Object getValue(Method method)
- {
- String key = MXBeanUtils.getCompositeDataKey(method);
- if (key == null)
- throw new IllegalArgumentException("Unsupported method '" + method + "'; it must be a property getter.");
- try
- {
- return compositeData.get(key);
- }
- catch (InvalidKeyException e)
- {
- throw new IllegalArgumentException("Unsupported method '" + method + "'; it must be a property getter for one of the item names of the composite data: " + compositeData, e);
- }
- }
-
- private Object handleObjectInvocation(String name, Object[] args) throws Throwable
- {
- if ("equals".equals(name))
- {
- Object object = args[0];
- if (object == null || object instanceof Proxy == false)
- return false;
- InvocationHandler handler = Proxy.getInvocationHandler(object);
- if (handler == this)
- return true;
- if (handler == null || handler instanceof CompositeDataInvocationHandler == false)
- return false;
-
- CompositeDataInvocationHandler other = (CompositeDataInvocationHandler) handler;
- return getCompositeData().equals(other.getCompositeData());
- }
- else if ("hashCode".equals(name))
- return getCompositeData().hashCode();
- else if ("toString".equals(name))
- return getCompositeData().toString();
- throw new UnreachableStatementException();
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataInvocationHandler.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,40 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import javax.management.openmbean.CompositeData;
-
-/**
- * CompositeDataView.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface CompositeDataView
-{
- /**
- * Convert this object to composite data
- *
- * @return the composite data
- */
- CompositeData toCompositeData();
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeDataView.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,198 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.Method;
-import java.lang.reflect.Type;
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.management.openmbean.CompositeType;
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-
-import org.jboss.util.UnexpectedThrowable;
-
-/**
- * CompositeTypeMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeTypeMetaData
-{
- /** The clazz */
- private Class<?> clazz;
-
- /** The composite type */
- private CompositeType compositeType;
-
- /** The items */
- private List<ItemMetaData> items = new ArrayList<ItemMetaData>();
-
- /**
- * Create a new CompositeTypeMetaData.
- *
- * @param clazz the class
- */
- public CompositeTypeMetaData(Class<?> clazz)
- {
- this.clazz = clazz;
- }
-
- /**
- * Get the composite type
- *
- * @return the composite type
- */
- public CompositeType getCompositeType()
- {
- if (compositeType == null)
- {
- String typeName = clazz.getName();
- if (items.size() == 0)
- return generateAnObject(typeName);
-
- String[] itemNames = new String[items.size()];
- OpenType[] itemTypes = new OpenType[items.size()];
- for (int i = 0; i < items.size(); ++i)
- {
- ItemMetaData item = items.get(i);
- itemNames[i] = item.getName();
- itemTypes[i] = item.getOpenType();
- }
- try
- {
- compositeType = new CompositeType(typeName, typeName, itemNames, itemNames, itemTypes);
- }
- catch (Throwable t)
- {
- throw new UnexpectedThrowable("Error creating composite type for: " + typeName, t);
- }
- }
- return compositeType;
- }
-
- /**
- * Generate the metadata
- */
- public void generate()
- {
- if (Object.class.equals(clazz))
- {
- compositeType = generateObject();
- return;
- }
- if (Class.class.equals(clazz))
- {
- compositeType = generateClass();
- return;
- }
- if (ClassLoader.class.equals(clazz))
- {
- compositeType = generateClassLoader();
- return;
- }
-
- Method[] methods = clazz.getMethods();
- for (Method method : methods)
- {
- Type returnType = method.getGenericReturnType();
- Class<?> declaring = method.getDeclaringClass();
- if (Object.class.equals(declaring) == false)
- {
- String key = MXBeanUtils.getCompositeDataKey(method);
- if (key != null)
- items.add(new ItemMetaData(key, returnType));
- }
- }
- }
-
- /**
- * Generate the composite data for an object
- *
- * @return the composite type
- */
- public static CompositeType generateObject()
- {
- return generateAnObject(Object.class.getName());
- }
-
- /**
- * Generate the composite data for an object
- *
- * @param name the class name
- * @return the composite type
- */
- private static CompositeType generateAnObject(String name)
- {
- String[] itemNames = { "class" };
- OpenType[] openTypes = { generateClass() };
- return safeCreateCompositeType(name, itemNames, openTypes);
- }
-
- /**
- * Generate the composite data for a class
- *
- * @return the composite type
- */
- public static CompositeType generateClass()
- {
- String name = Object.class.getName();
- String[] itemNames = { "name" };
- OpenType[] openTypes = { SimpleType.STRING };
- return safeCreateCompositeType(name, itemNames, openTypes);
- }
-
- /**
- * Generate the composite data for a classloader
- *
- * @return the composite type
- */
- public static CompositeType generateClassLoader()
- {
- String name = Object.class.getName();
- String[] itemNames = { "name" };
- OpenType[] openTypes = { SimpleType.STRING };
- return safeCreateCompositeType(name, itemNames, openTypes);
- }
-
- /**
- * Safely create a composite type
- *
- * @param name the name
- * @param itemNames the item names
- * @param openTypes the open types
- * @return the composite type
- */
- private static CompositeType safeCreateCompositeType(String name, String[] itemNames, OpenType[] openTypes)
- {
- try
- {
- return new CompositeType(name, name, itemNames, itemNames, openTypes);
- }
- catch (Exception e)
- {
- throw new UnexpectedThrowable(e);
- }
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaData.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,79 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import javax.management.openmbean.CompositeType;
-
-import org.jboss.util.collection.WeakClassCache;
-
-/**
- * CompositeTypeMetaDataFactory.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeTypeMetaDataFactory extends WeakClassCache
-{
- /** The singleton */
- private static final CompositeTypeMetaDataFactory SINGLETON = new CompositeTypeMetaDataFactory();
-
- /**
- * Get the composite type for a class
- *
- * @param clazz the class
- * @return the composite type
- */
- public static CompositeType getCompositeType(Class<?> clazz)
- {
- CompositeTypeMetaData metaData = getCompositeTypeMetaData(clazz);
- return metaData.getCompositeType();
- }
-
- /**
- * Get the composite type meta data
- *
- * @param clazz the class
- * @return the meta data
- */
- public static CompositeTypeMetaData getCompositeTypeMetaData(Class<?> clazz)
- {
- return (CompositeTypeMetaData) SINGLETON.get(clazz);
- }
-
- /**
- * Singleton
- */
- private CompositeTypeMetaDataFactory()
- {
- }
-
- protected Object instantiate(Class clazz)
- {
- return new CompositeTypeMetaData(clazz);
- }
-
- protected void generate(Class clazz, Object object)
- {
- CompositeTypeMetaData metaData = (CompositeTypeMetaData) object;
- metaData.generate();
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/CompositeTypeMetaDataFactory.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,43 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * GetterNames.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
- at Documented
- at Target(ElementType.CONSTRUCTOR)
- at Retention(RetentionPolicy.RUNTIME)
-public @interface GetterNames
-{
- /** The getter names */
- String[] value();
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/GetterNames.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,73 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.Type;
-
-import javax.management.openmbean.OpenType;
-
-/**
- * ItemMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ItemMetaData
-{
- /** The name */
- private String name;
-
- /** The open type */
- private SkeletonOpenType openType;
-
- /**
- * Create a new ItemMetaData.
- *
- * @param name the name
- * @param type the type
- */
- public ItemMetaData(String name, Type type)
- {
- this.name = name;
- openType = new SkeletonOpenType(type);
- }
-
- /**
- * Get the name.
- *
- * @return the name.
- */
- public String getName()
- {
- return name;
- }
-
- /**
- * Get the openType.
- *
- * @return the openType.
- */
- public OpenType getOpenType()
- {
- return openType.getOpenType();
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/ItemMetaData.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,43 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * MXBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
- at Documented
- at Target(ElementType.TYPE)
- at Retention(RetentionPolicy.RUNTIME)
-public @interface MXBean
-{
- /** Whether this is an MXBean */
- boolean value() default true;
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBean.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,510 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.Method;
-import java.lang.reflect.Type;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.JMException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.NotCompliantMBeanException;
-import javax.management.NotificationBroadcasterSupport;
-import javax.management.NotificationEmitter;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-import javax.management.openmbean.OpenMBeanAttributeInfo;
-import javax.management.openmbean.OpenMBeanInfo;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ExceptionHandler;
-
-/**
- * MXBeanDelegate.
- *
- * FIXME: Reflection madness
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanDelegate extends NotificationBroadcasterSupport implements DynamicMBean, MBeanRegistration, NotificationEmitter
-{
- /** The logger */
- private static final Logger log = Logger.getLogger(MXBeanDelegate.class);
-
- /** The implementation object */
- private Object implementation;
-
- /** The management interface */
- private Class mbeanInterface;
-
- /** The cached mbeaninfo */
- private OpenMBeanInfo cachedMBeanInfo;
-
- /** The attribute mapping */
- private Map<String, OpenMBeanAttributeInfo> attributeMapping;
-
- /** The getters */
- private Map<String, Method> getters;
-
- /** The setters */
- private Map<String, Method> setters;
-
- /** The operatinns */
- private Map<String, Method> operations;
-
- /**
- * Construct a DynamicMBean from the given implementation object
- * and the passed management interface class.
- *
- * @param implementation the object implementing the mbean
- * @param mbeanInterface the management interface of the mbean
- * @exception IllegalArgumentException for a null implementation
- * @exception NotCompliantMBeanException if the management interface
- * does not follow the JMX design patterns or the implementation
- * does not implement the interface
- */
- public MXBeanDelegate(Object implementation, Class mbeanInterface) throws NotCompliantMBeanException
- {
- this.implementation = implementation;
- this.mbeanInterface = mbeanInterface;
- }
-
- /**
- * Construct a DynamicMBean from this object
- * and the passed management interface class.<p>
- *
- * Used in subclassing
- *
- * @param mbeanInterface the management interface of the mbean
- * @exception NotCompliantMBeanException if the management interface
- * does not follow the JMX design patterns or this
- * does not implement the interface
- */
- protected MXBeanDelegate(Class mbeanInterface) throws NotCompliantMBeanException
- {
- this.implementation = this;
- this.mbeanInterface = mbeanInterface;
- }
-
- /**
- * Retrieve the implementation object
- *
- * @return the implementation
- */
- public Object getImplementation()
- {
- return implementation;
- }
-
- /**
- * Replace the implementation object
- *
- * @todo make this work after the mbean is registered
- * @param implementation the new implementation
- * @exception IllegalArgumentException for a null parameter
- * @exception NotCompliantMBeanException if the new implementation
- * does not implement the interface supplied at
- * construction
- */
- public void setImplementation(Object implementation) throws NotCompliantMBeanException
- {
- if (implementation == null)
- throw new IllegalArgumentException("Null implementation");
- this.implementation = implementation;
- }
-
- /**
- * Retrieve the implementation class
- *
- * @return the class of the implementation
- */
- public Class getImplementationClass()
- {
- return implementation.getClass();
- }
-
- /**
- * Retrieve the management interface
- *
- * @return the management interface
- */
- public final Class getMBeanInterface()
- {
- return mbeanInterface;
- }
-
- public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- try
- {
- OpenMBeanAttributeInfo attributeInfo = attributeMapping.get(attribute);
- if (attributeInfo == null)
- throw new AttributeNotFoundException(attribute);
- MBeanAttributeInfo mbeanAttributeInfo = (MBeanAttributeInfo) attributeInfo;
- if (mbeanAttributeInfo.isReadable() == false)
- throw new AttributeNotFoundException("Attribute is not readable: " + attribute);
-
- Method method = getters.get(attribute);
- if (method == null)
- throw new NoSuchMethodException("No method to get attribute: " + attribute);
-
- Object result = method.invoke(implementation, new Object[0]);
-
- return MXBeanUtils.construct(attributeInfo.getOpenType(), result, "Get attribute: " + attribute);
- }
- catch (Exception e)
- {
- JMException result = ExceptionHandler.handleException(e);
- if (result instanceof AttributeNotFoundException)
- throw (AttributeNotFoundException)result;
- if (result instanceof MBeanException)
- throw (MBeanException)result;
- if (result instanceof ReflectionException)
- throw (ReflectionException)result;
- throw new MBeanException(e, "Cannot get attribute: " + attribute);
- }
- }
-
- public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- try
- {
- String attributeName = attribute.getName();
- OpenMBeanAttributeInfo attributeInfo = attributeMapping.get(attributeName);
- if (attributeInfo == null)
- throw new AttributeNotFoundException(attributeName);
- MBeanAttributeInfo mbeanAttributeInfo = (MBeanAttributeInfo) attributeInfo;
- if (mbeanAttributeInfo.isWritable() == false)
- throw new AttributeNotFoundException("Attribute is not writable: " + attributeName);
-
- Method method = setters.get(attributeName);
- if (method == null)
- throw new NoSuchMethodException("No method to set attribute: " + attribute);
-
- Object value = MXBeanUtils.reconstruct(method.getGenericParameterTypes()[0], attribute.getValue(), method);
-
- method.invoke(implementation, new Object[] { value });
- }
- catch (Exception e)
- {
- JMException result = ExceptionHandler.handleException(e);
- if (result instanceof AttributeNotFoundException)
- throw (AttributeNotFoundException)result;
- if (result instanceof InvalidAttributeValueException)
- throw (InvalidAttributeValueException)result;
- if (result instanceof MBeanException)
- throw (MBeanException)result;
- if (result instanceof ReflectionException)
- throw (ReflectionException)result;
- throw new MBeanException(e, "Cannot set attribute: " + attribute);
- }
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- try
- {
- AttributeList attrList = new AttributeList(attributes.length);
- for (int i = 0; i < attributes.length; i++)
- {
- String name = attributes[i];
- Object value = getAttribute(name);
- attrList.add(new Attribute(name, value));
- }
- return attrList;
- }
- catch (Exception e)
- {
- JMException result = ExceptionHandler.handleException(e);
- // Why is this not throwing the same exceptions as getAttribute(String)
- throw new RuntimeException("Cannot get attributes", result);
- }
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- AttributeList result = new AttributeList(attributes.size());
- for (int i = 0; i < attributes.size(); ++i)
- {
- Attribute attr = (Attribute) attributes.get(i);
- String name = attr.getName();
- try
- {
- setAttribute(attr);
- result.add(new Attribute(name, attr.getValue()));
- }
- catch (Throwable t)
- {
- JMException e = ExceptionHandler.handleException(t);
- result.add(new Attribute(name, e));
- }
- }
- return result;
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException
- {
- try
- {
- String signatureString = getSignatureString(actionName, signature);
- Method method = operations.get(signatureString);
- if (method == null)
- throw new NoSuchMethodException("Cannot find method for operation: " + signatureString);
-
- Object[] parameters = params;
- if (params.length > 0)
- {
- parameters = new Object[params.length];
- Type[] parameterTypes = method.getGenericParameterTypes();
- for (int i = 0; i < parameters.length; ++i)
- parameters[i] = MXBeanUtils.reconstruct(parameterTypes[i], params[i], method);
- }
-
- Object result = method.invoke(implementation, parameters);
-
- if (result == null)
- return null;
- Type returnType = method.getGenericReturnType();
- return MXBeanUtils.construct(returnType, result, method);
- }
- catch (Exception e)
- {
- JMException result = ExceptionHandler.handleException(e);
- if (result instanceof MBeanException)
- throw (MBeanException)result;
- if (result instanceof ReflectionException)
- throw (ReflectionException)result;
- throw new MBeanException(e, "Cannot invoke: " + actionName);
- }
- }
-
- public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
- {
- return name;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- }
-
- public void preDeregister() throws Exception
- {
- }
-
- public void postDeregister()
- {
- }
-
- public MBeanInfo getMBeanInfo()
- {
- OpenMBeanInfo info = getCachedMBeanInfo();
- if (info == null)
- {
- try
- {
- info = buildMBeanInfo();
- cacheMBeanInfo(info);
- }
- catch (NotCompliantMBeanException e)
- {
- log.error("Unexcepted exception", e);
- throw new IllegalStateException("Unexcepted exception " + e.toString());
- }
-
- }
- return (MBeanInfo) info;
- }
-
- /**
- * Retrieve the cached mbean info
- *
- * @return the cached mbean info
- */
- public OpenMBeanInfo getCachedMBeanInfo()
- {
- return cachedMBeanInfo;
- }
-
- /**
- * Sets the cached mbean info
- *
- * @param info the mbeaninfo to cache, can be null to erase the cache
- */
- public void cacheMBeanInfo(OpenMBeanInfo info)
- {
- cachedMBeanInfo = info;
- Map<String, OpenMBeanAttributeInfo> attributeMapping = new HashMap<String, OpenMBeanAttributeInfo>();
- MBeanAttributeInfo[] attributes = info.getAttributes();
- for (int i = 0; i < attributes.length; ++i)
- {
- OpenMBeanAttributeInfo attribute = (OpenMBeanAttributeInfo) attributes[i];
- attributeMapping.put(attribute.getName(), attribute);
- }
- this.attributeMapping = attributeMapping;
-
- try
- {
- HashMap<String, Method> getters = new HashMap<String, Method>();
- HashMap<String, Method> setters = new HashMap<String, Method>();
-
- HashMap<String, Method> operations = new HashMap<String, Method>();
-
- Method[] methods = implementation.getClass().getMethods();
- for (Method method : methods)
- {
- String methodName = method.getName();
- Type[] signature = method.getGenericParameterTypes();
- Type returnType = method.getGenericReturnType();
-
- if (methodName.startsWith("set") &&
- methodName.length() > 3 &&
- signature.length == 1 &&
- returnType == Void.TYPE)
- {
- String key = methodName.substring(3, methodName.length());
- Method setter = setters.get(key);
- if (setter != null && setter.getGenericParameterTypes()[0].equals(signature[0]) == false)
- throw new RuntimeException("overloaded type for attribute set: " + key);
- setters.put(key, method);
- }
- else if (methodName.startsWith("get") &&
- methodName.length() > 3 &&
- signature.length == 0 &&
- returnType != Void.TYPE)
- {
- String key = methodName.substring(3, methodName.length());
- Method getter = getters.get(key);
- if (getter != null && getter.getName().startsWith("is"))
- throw new RuntimeException("mixed use of get/is for attribute " + key);
- getters.put(key, method);
- }
- else if (methodName.startsWith("is") &&
- methodName.length() > 2 &&
- signature.length == 0 &&
- returnType == Boolean.TYPE)
- {
- String key = methodName.substring(2, methodName.length());
- Method getter = getters.get(key);
- if (getter != null && getter.getName().startsWith("get"))
- throw new RuntimeException("mixed use of get/is for attribute " + key);
- getters.put(key, method);
- }
- else
- {
- operations.put(getSignatureString(method), method);
- }
- }
- this.getters = getters;
- this.setters = setters;
- this.operations = operations;
- }
- catch (RuntimeException e)
- {
- log.error("Error: ", e);
- throw e;
- }
- catch (Error e)
- {
- log.error("Error: ", e);
- throw e;
- }
- }
-
- /**
- * Builds a default MBeanInfo for this MBean, using the Management Interface specified for this MBean.
- *
- * While building the MBeanInfo, this method calls the customization hooks that make it possible for subclasses to
- * supply their custom descriptions, parameter names, etc...
- *
- * @return the mbean info
- * @throws NotCompliantMBeanException when not a valid mbean
- */
- public OpenMBeanInfo buildMBeanInfo() throws NotCompliantMBeanException
- {
- if (implementation == null)
- throw new IllegalArgumentException("Null implementation");
-
- MXBeanMetaData metadata = new MXBeanMetaData(implementation, mbeanInterface);
- return (OpenMBeanInfo) metadata.build();
- }
-
- /**
- * Get a signature string for a method
- *
- * @param method the method
- * @return the signature
- */
- private String getSignatureString(Method method)
- {
- String name = method.getName();
- Class[] signature = method.getParameterTypes();
- StringBuilder buffer = new StringBuilder(512);
- buffer.append(name);
- buffer.append("(");
- if (signature != null)
- {
- for (int i = 0; i < signature.length; i++)
- {
- buffer.append(signature[i].getName());
- if (i < signature.length-1)
- buffer.append(",");
- }
- }
- buffer.append(")");
- return buffer.toString();
- }
-
- /**
- * Get a signature string for a method
- *
- * @param operation the operation
- * @param signature the signature
- * @return the signature
- */
- private String getSignatureString(String operation, String[] signature)
- {
- StringBuilder buffer = new StringBuilder(512);
- buffer.append(operation);
- buffer.append("(");
- if (signature != null)
- {
- for (int i = 0; i < signature.length; i++)
- {
- buffer.append(signature[i]);
- if (i < signature.length-1)
- buffer.append(",");
- }
- }
- buffer.append(")");
- return buffer.toString();
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanDelegate.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,77 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.Proxy;
-
-import javax.management.DynamicMBean;
-import javax.management.MBeanServerConnection;
-import javax.management.ObjectName;
-
-/**
- * MXBeanFactory.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanFactory
-{
- /**
- * Create a proxy
- *
- * @param <T> the interface type
- * @param mbeanServerConnection the connection
- * @param objectName the object name
- * @param mxbeanInterface the interface
- * @return the proxy
- */
- public static <T> T makeProxy(MBeanServerConnection mbeanServerConnection, ObjectName objectName, Class<T> mxbeanInterface)
- {
- MXBeanInvocationHandler handler = new MXBeanInvocationHandler(mbeanServerConnection, mxbeanInterface, objectName);
- Object object = Proxy.newProxyInstance(mxbeanInterface.getClassLoader(), new Class[] { mxbeanInterface }, handler);
- return mxbeanInterface.cast(object);
- }
-
- /**
- * Create a new MXBean
- *
- * @param resource the resource
- * @return the MXBean
- */
- public static DynamicMBean newMXBean(Object resource)
- {
- return MXBeanUtils.createMXBean(resource, null);
- }
-
- /**
- * Create a new MXBean
- *
- * @param <T> the interface type
- * @param resource the resource
- * @param mxbeanInterface the interface
- * @return the MXBean
- */
- public static <T> DynamicMBean newMXBean(T resource, Class<T> mxbeanInterface)
- {
- return MXBeanUtils.createMXBean(resource, mxbeanInterface);
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanFactory.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,497 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.io.Serializable;
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.lang.reflect.Type;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.management.Attribute;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanParameterInfo;
-import javax.management.MBeanServerConnection;
-import javax.management.NotificationBroadcaster;
-import javax.management.NotificationEmitter;
-import javax.management.NotificationFilter;
-import javax.management.NotificationListener;
-import javax.management.ObjectName;
-import javax.management.openmbean.OpenMBeanAttributeInfo;
-import javax.management.openmbean.OpenMBeanInfo;
-import javax.management.openmbean.OpenMBeanOperationInfo;
-import javax.management.openmbean.OpenMBeanParameterInfo;
-import javax.management.openmbean.OpenType;
-
-import org.jboss.mx.util.JMXExceptionDecoder;
-
-/**
- * MXBeanInvocationHandler.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanInvocationHandler implements InvocationHandler, Serializable
-{
- /** The serialVersionUID */
- private static final long serialVersionUID = -2872014223541692039L;
-
- private static final Class[] LISTENER = new Class[] { NotificationListener.class };
- private static final Class[] TRIPLET = new Class[] { NotificationListener.class, NotificationFilter.class, Object.class };
-
- private static final Method EQUALS;
- private static final Method HASH_CODE;
- private static final Method TO_STRING;
-
- private static final Method ADD_NOTIFICATION_LISTENER;
- private static final Method GET_NOTIFICATION_INFO;
- private static final Method REMOVE_NOTIFICATION_LISTENER;
- private static final Method REMOVE_NOTIFICATION_LISTENER_TRIPLET;
-
- /** The connection */
- private MBeanServerConnection mbeanServerConnection;
-
- /** The interface */
- private Class<?> mxbeanInterface;
-
- /** The object name */
- private ObjectName objectName;
-
- /** The method mappings */
- private transient Map<Method, Action> mappings;
-
- /** The MBean Info */
- private transient OpenMBeanInfo mbeanInfo;
-
- static
- {
- try
- {
- ADD_NOTIFICATION_LISTENER = NotificationBroadcaster.class.getDeclaredMethod("addNotificationListener", TRIPLET);
- GET_NOTIFICATION_INFO = NotificationBroadcaster.class.getDeclaredMethod("getNotificationInfo", new Class[0]);
- REMOVE_NOTIFICATION_LISTENER = NotificationBroadcaster.class.getDeclaredMethod("removeNotificationListener", LISTENER);
- REMOVE_NOTIFICATION_LISTENER_TRIPLET = NotificationEmitter.class.getDeclaredMethod("removeNotificationListener", TRIPLET);
- EQUALS = Object.class.getDeclaredMethod("equals", new Class[] { Object.class });
- HASH_CODE = Object.class.getDeclaredMethod("hashCode", new Class[0]);
- TO_STRING = Object.class.getDeclaredMethod("toString", new Class[0]);
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Create a new MXBeanInvocationHandler.
- *
- * @param mbeanServerConnection the connection
- * @param mxbeanInterface the interface
- * @param objectName the object name
- */
- public MXBeanInvocationHandler(MBeanServerConnection mbeanServerConnection, Class<?> mxbeanInterface, ObjectName objectName)
- {
- if (mbeanServerConnection == null)
- throw new IllegalArgumentException("Null mbeanServerConnection");
- if (mxbeanInterface == null)
- throw new IllegalArgumentException("Null mxmbeanInterface");
- if (objectName == null)
- throw new IllegalArgumentException("Null objectName");
-
- this.mbeanServerConnection = mbeanServerConnection;
- this.mxbeanInterface = mxbeanInterface;
- this.objectName = objectName;
- }
-
- /**
- * Get the mbeanServerConnection.
- *
- * @return the mbeanServerConnection.
- */
- public MBeanServerConnection getMBeanServerConnection()
- {
- return mbeanServerConnection;
- }
-
- /**
- * Get the mxbeanInterface.
- *
- * @return the mxbeanInterface.
- */
- public Class<?> getMXBeanInterface()
- {
- return mxbeanInterface;
- }
-
- /**
- * Get the objectName.
- *
- * @return the objectName.
- */
- public ObjectName getObjectName()
- {
- return objectName;
- }
-
- public Object invoke(Object proxy, Method method, Object[] args) throws Throwable
- {
- try
- {
- return getAction(proxy, method).perform(args);
- }
- catch (Throwable t)
- {
- throw JMXExceptionDecoder.decode(t);
- }
- }
-
- /**
- * Get the actions for this method
- * @param proxy the proxy
- * @param method the method
- * @return the action
- * @throws Throwable for any error
- */
- private Action getAction(Object proxy, Method method) throws Throwable
- {
- // Doesn't really matter if the mappings are
- // setup twice by two different threads, they are the same.
- if (mappings == null)
- mappings = getMappings(proxy);
-
- // Check the action
- Action result = mappings.get(method);
- if (result == null)
- throw new UnsupportedOperationException("Unknown method: " + method);
-
- // Return the result
- return result;
- }
-
- /**
- * Set up the mappings
- *
- * @param proxy the proxy
- * @return the mapping
- * @throws Throwable for any error
- */
- private Map<Method, Action> getMappings(Object proxy) throws Throwable
- {
- mbeanInfo = (OpenMBeanInfo) mbeanServerConnection.getMBeanInfo(objectName);
- Map<String, OpenMBeanAttributeInfo> attributesMap = new HashMap<String, OpenMBeanAttributeInfo>();
- MBeanAttributeInfo[] attributes = mbeanInfo.getAttributes();
- for (int i = 0; i < attributes.length; ++i)
- {
- OpenMBeanAttributeInfo openAttribute = (OpenMBeanAttributeInfo) attributes[i];
- attributesMap.put(openAttribute.getName(), openAttribute);
- }
- MBeanOperationInfo[] operations = mbeanInfo.getOperations();
-
- Map<Method, Action> result = new HashMap<Method, Action>();
-
- Class[] interfaces = proxy.getClass().getInterfaces();
- for (int i = 0; i < interfaces.length; ++i)
- {
- if (NotificationBroadcaster.class.isAssignableFrom(interfaces[i]))
- {
- result.put(ADD_NOTIFICATION_LISTENER, new AddNotificationListenerAction());
- result.put(GET_NOTIFICATION_INFO, new GetNotificationInfoAction());
- result.put(REMOVE_NOTIFICATION_LISTENER, new RemoveNotificationListenerAction());
- result.put(REMOVE_NOTIFICATION_LISTENER_TRIPLET, new RemoveNotificationListenerTripletAction());
- }
- else
- {
- Method[] methods = interfaces[i].getMethods();
- for (Method method : methods)
- {
- String methodName = method.getName();
- Class returnType = method.getReturnType();
- Class[] parameterTypes = method.getParameterTypes();
-
- // Getter
- if (methodName.startsWith("get") &&
- methodName.length() > 3 &&
- Void.TYPE.equals(returnType) == false &&
- parameterTypes.length == 0)
- {
- String name = methodName.substring(3);
- OpenMBeanAttributeInfo attribute = attributesMap.get(name);
- if (attribute != null)
- {
- Type type = method.getGenericReturnType();
- result.put(method, new GetAction(attribute, type));
- continue;
- }
- }
- // Getter (is)
- else if(methodName.startsWith("is") &&
- methodName.length() > 2 &&
- Boolean.TYPE.equals(returnType) &&
- parameterTypes.length == 0)
- {
- String name = methodName.substring(2);
- OpenMBeanAttributeInfo attribute = attributesMap.get(name);
- if (attribute != null)
- {
- Type type = method.getGenericReturnType();
- result.put(method, new GetAction(attribute, type));
- continue;
- }
- }
- // Setter
- else if(methodName.startsWith("set") &&
- methodName.length() > 3 &&
- Void.TYPE.equals(returnType) &&
- parameterTypes.length == 1)
- {
- String name = methodName.substring(3);
- OpenMBeanAttributeInfo attribute = attributesMap.get(name);
- if (attribute != null)
- {
- result.put(method, new SetAction(attribute));
- continue;
- }
- }
- // Invoker
- OpenMBeanOperationInfo operation = findOperation(methodName, method.getGenericParameterTypes(), operations);
- if (operation != null)
- {
- String[] signature = getSignature(method);
- Type type = method.getGenericReturnType();
- result.put(method, new InvokeAction(operation, signature, type));
- }
- else
- {
- result.put(method, new InvalidAction(method));
- }
- }
- }
- }
-
- // Add the Object mappings
- result.put(EQUALS, new EqualsAction());
- result.put(HASH_CODE, new HashCodeAction());
- result.put(TO_STRING, new ToStringAction());
-
- return result;
- }
-
- private static OpenMBeanOperationInfo findOperation(String name, Type[] parameterTypes, MBeanOperationInfo[] operations)
- {
- OpenType[] signature = getSignature(parameterTypes);
- for (int i = 0; i < operations.length; ++i)
- {
- if (operations[i].getName().equals(name) == false)
- continue;
- MBeanParameterInfo[] parameters = operations[i].getSignature();
- boolean match = true;
- for (int p = 0; p < parameters.length && match; ++p)
- {
- OpenMBeanParameterInfo openMBeanParameterInfo = (OpenMBeanParameterInfo) parameters[p];
- if (signature[p].equals(openMBeanParameterInfo.getOpenType()) == false)
- match = false;
- }
- if (match)
- return (OpenMBeanOperationInfo) operations[i];
- }
- return null;
- }
-
- private static String[] getSignature(final Method method)
- {
- Class[] parameterTypes = method.getParameterTypes();
- String[] signature = new String[parameterTypes.length];
- for (int p = 0; p < parameterTypes.length; ++p)
- signature[p] = parameterTypes[p].getName();
- return signature;
- }
-
- private static OpenType[] getSignature(final Type[] parameterTypes)
- {
- OpenType[] signature = new OpenType[parameterTypes.length];
- for (int p = 0; p < parameterTypes.length; ++p)
- signature[p] = MXBeanUtils.getOpenType(parameterTypes[p]);
- return signature;
- }
-
- private interface Action
- {
- public Object perform(Object[] args) throws Throwable;
- }
-
- private class GetAction implements Action
- {
- private OpenMBeanAttributeInfo attribute;
- private Type type;
-
- public GetAction(OpenMBeanAttributeInfo attribute, Type type)
- {
- this.attribute = attribute;
- this.type = type;
- }
-
- public Object perform(Object[] args) throws Throwable
- {
- Object result = mbeanServerConnection.getAttribute(objectName, attribute.getName());
-
- return MXBeanUtils.reconstruct(attribute.getOpenType(), type, result, "Get attribute: " + attribute.getName());
- }
- }
-
- private class SetAction implements Action
- {
- private OpenMBeanAttributeInfo attribute;
-
- public SetAction(OpenMBeanAttributeInfo attribute)
- {
- this.attribute = attribute;
- }
-
- public Object perform(Object[] args) throws Throwable
- {
- Object value = MXBeanUtils.construct(attribute.getOpenType(), args[0], "Set attribute: " + attribute.getName());
-
- Attribute attr = new Attribute(attribute.getName(), value);
- mbeanServerConnection.setAttribute(objectName, attr);
- return null;
- }
- }
-
- private class InvokeAction implements Action
- {
- private OpenMBeanOperationInfo operation;
- private String[] signature;
- private Type type;
-
- public InvokeAction(OpenMBeanOperationInfo operation, String[] signature, Type type)
- {
- this.operation = operation;
- this.signature = signature;
- this.type = type;
- }
-
- public Object perform(Object[] args) throws Throwable
- {
- MBeanParameterInfo[] parameters = operation.getSignature();
- Object[] arguments = new Object[args.length];
- for (int i = 0; i < parameters.length; ++i)
- {
- OpenMBeanParameterInfo parameter = (OpenMBeanParameterInfo) parameters[i];
- arguments[i] = MXBeanUtils.construct(parameter.getOpenType(), args[i], operation.getName());
- }
-
- Object result = mbeanServerConnection.invoke(objectName, operation.getName(), arguments, signature);
-
- return MXBeanUtils.reconstruct(operation.getReturnOpenType(), type, result, operation.getName());
- }
- }
-
- private class InvalidAction implements Action
- {
- private Method method;
-
- public InvalidAction(Method method)
- {
- this.method = method;
- }
-
- public Object perform(Object[] args) throws Throwable
- {
- throw new UnsupportedOperationException(method + " is not mapped to the MBeanInfo operations for " + objectName);
- }
- }
-
- private class EqualsAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- Object object = args[0];
- if (object == null || object instanceof Proxy == false)
- return false;
- InvocationHandler handler = Proxy.getInvocationHandler(object);
- if (handler instanceof MXBeanInvocationHandler == false)
- return false;
- MXBeanInvocationHandler other = (MXBeanInvocationHandler) handler;
- return mbeanServerConnection.equals(other.mbeanServerConnection) && objectName.equals(other.objectName);
- }
- }
-
- private class HashCodeAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- return objectName.hashCode();
- }
- }
-
- private class ToStringAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- return "MXBeanInvocationHandler(" + objectName + ")";
- }
- }
-
- private class AddNotificationListenerAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- NotificationListener listener = (NotificationListener) args[0];
- NotificationFilter filter = (NotificationFilter) args[1];
- Object handback = args[2];
- mbeanServerConnection.addNotificationListener(objectName, listener, filter, handback);
- return null;
- }
- }
-
- private class GetNotificationInfoAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- return mbeanServerConnection.getMBeanInfo(objectName).getNotifications();
- }
- }
-
- private class RemoveNotificationListenerAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- NotificationListener listener = (NotificationListener) args[0];
- mbeanServerConnection.removeNotificationListener(objectName, listener);
- return null;
- }
- }
-
- private class RemoveNotificationListenerTripletAction implements Action
- {
- public Object perform(Object[] args) throws Throwable
- {
- NotificationListener listener = (NotificationListener) args[0];
- NotificationFilter filter = (NotificationFilter) args[1];
- Object handback = args[2];
- mbeanServerConnection.removeNotificationListener(objectName, listener, filter, handback);
- return null;
- }
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanInvocationHandler.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,417 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.Constructor;
-import java.lang.reflect.Method;
-import java.lang.reflect.Type;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.List;
-
-import javax.management.IntrospectionException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.NotCompliantMBeanException;
-import javax.management.NotificationBroadcaster;
-import javax.management.openmbean.OpenMBeanAttributeInfo;
-import javax.management.openmbean.OpenMBeanAttributeInfoSupport;
-import javax.management.openmbean.OpenMBeanConstructorInfo;
-import javax.management.openmbean.OpenMBeanConstructorInfoSupport;
-import javax.management.openmbean.OpenMBeanInfoSupport;
-import javax.management.openmbean.OpenMBeanOperationInfo;
-import javax.management.openmbean.OpenMBeanOperationInfoSupport;
-import javax.management.openmbean.OpenMBeanParameterInfo;
-import javax.management.openmbean.OpenMBeanParameterInfoSupport;
-import javax.management.openmbean.OpenType;
-
-import org.jboss.mx.metadata.AbstractBuilder;
-
-/**
- * MXBeanMetaData
- *
- * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>.
- * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>.
- * @author <a href="mailto:thomas.diesler at jboss.com">Thomas Diesler</a>.
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>.
- */
-public class MXBeanMetaData extends AbstractBuilder
-{
- /** The MBean */
- private Object mbeanInstance;
-
- /** The class */
- private Class<?> mbeanClass;
-
- /** The interface */
- private Class<?> mbeanInterface;
-
- /**
- * Find the MXBean interface for a class
- *
- * @param mbeanClass the mbean class
- * @return the interface
- */
- public static Class<?> findMXBeanInterface(Class<?> mbeanClass)
- {
- Class<?> concrete = mbeanClass;
- while (null != concrete)
- {
- Class result = findMXBeanInterface(concrete, concrete.getInterfaces());
- if (null != result)
- return result;
- concrete = concrete.getSuperclass();
- }
- return null;
- }
-
- /**
- * Find the MXBean interface for a class
- *
- * @param concrete the mbean class
- * @param interfaces the interfaces to consider
- * @return the interface
- */
- private static Class<?> findMXBeanInterface(Class<?> concrete, Class<?>[] interfaces)
- {
- String mxName = concrete.getName() + "MXBean";
- String stdName = concrete.getName() + "MBean";
-
- for (Class<?> intf : interfaces)
- {
- String name = intf.getName();
- if (mxName.equals(name) || stdName.equals(name))
- return intf;
-
- MXBean mxBean = intf.getAnnotation(MXBean.class);
- if (mxBean != null && mxBean.value())
- return intf;
- }
- return null;
- }
-
- /**
- * Create a new MXBeanMetaData.
- *
- * @param mbeanInstance the mbean instance
- * @throws NotCompliantMBeanException for any error
- */
- public MXBeanMetaData(Object mbeanInstance) throws NotCompliantMBeanException
- {
- this(mbeanInstance.getClass());
- this.mbeanInstance = mbeanInstance;
- }
-
- /**
- * Create a new MXBeanMetaData.
- *
- * @param mbeanClass the class
- * @throws NotCompliantMBeanException for any error
- */
- public MXBeanMetaData(Class<?> mbeanClass) throws NotCompliantMBeanException
- {
- this.mbeanClass = mbeanClass;
- this.mbeanInterface = findMXBeanInterface(mbeanClass);
- if (this.mbeanInterface == null)
- throw new NotCompliantMBeanException("Cannot obtain MXBean interface for: " + mbeanClass);
- }
-
- /**
- * Create a new MXBeanMetaData.
- *
- * @param mbeanInstance the mbean instance
- * @param mbeanInterface the mbean interface
- * @throws NotCompliantMBeanException for any error
- */
- public MXBeanMetaData(Object mbeanInstance, Class<?> mbeanInterface) throws NotCompliantMBeanException
- {
- this.mbeanInstance = mbeanInstance;
- this.mbeanClass = mbeanInstance.getClass();
- this.mbeanInterface = mbeanInterface;
- if (this.mbeanInterface == null)
- this.mbeanInterface = MXBeanMetaData.findMXBeanInterface(mbeanClass);
- if (this.mbeanInterface == null)
- throw new NotCompliantMBeanException("Cannot obtain mxbean interface for: " + mbeanClass);
- if (this.mbeanInterface.isInterface() == false)
- throw new NotCompliantMBeanException("Management interface is not an interface: " + mbeanInterface);
- }
-
- /**
- * Retrieve the management interface
- *
- * @return the interface
- */
- public Class<?> getMBeanInterface()
- {
- return mbeanInterface;
- }
-
- public MBeanInfo build() throws NotCompliantMBeanException
- {
- try
- {
- // First check the mbean instance implements the interface
- if (mbeanInterface == null)
- throw new NotCompliantMBeanException("The mbean does not implement a management interface");
- if (mbeanInstance != null && mbeanInterface.isInstance(mbeanInstance) == false)
- throw new NotCompliantMBeanException("The mbean does not implement its management interface " + mbeanInterface.getName());
-
- OpenMBeanConstructorInfo[] constructorInfo = buildConstructors();
-
- HashMap<String, Method> getters = new HashMap<String, Method>();
- HashMap<String, Method> setters = new HashMap<String, Method>();
-
- HashMap<String, OpenMBeanOperationInfo> operInfo = new HashMap<String, OpenMBeanOperationInfo>();
- List<OpenMBeanAttributeInfo> attrInfo = new ArrayList<OpenMBeanAttributeInfo>();
-
- Method[] methods = mbeanInterface.getMethods();
- for (Method method : methods)
- {
- String methodName = method.getName();
- Type[] signature = method.getGenericParameterTypes();
- Type returnType = method.getGenericReturnType();
-
- if (methodName.startsWith("set") &&
- methodName.length() > 3 &&
- signature.length == 1 &&
- returnType == Void.TYPE)
- {
- String key = methodName.substring(3, methodName.length());
- Method setter = setters.get(key);
- if (setter != null && setter.getGenericParameterTypes()[0].equals(signature[0]) == false)
- throw new IntrospectionException("overloaded type for attribute set: " + key);
- setters.put(key, method);
- }
- else if (methodName.startsWith("get") &&
- methodName.length() > 3 &&
- signature.length == 0 &&
- returnType != Void.TYPE)
- {
- String key = methodName.substring(3, methodName.length());
- Method getter = getters.get(key);
- if (getter != null && getter.getName().startsWith("is"))
- throw new IntrospectionException("mixed use of get/is for attribute " + key);
- getters.put(key, method);
- }
- else if (methodName.startsWith("is") &&
- methodName.length() > 2 &&
- signature.length == 0 &&
- isBooleanReturn(returnType))
- {
- String key = methodName.substring(2, methodName.length());
- Method getter = getters.get(key);
- if (getter != null && getter.getName().startsWith("get"))
- throw new IntrospectionException("mixed use of get/is for attribute " + key);
- getters.put(key, method);
- }
- else
- {
- OpenMBeanOperationInfo info = buildOperation(method);
- operInfo.put(getSignatureString(method), info);
- }
- }
-
- String[] keys = getters.keySet().toArray(new String[getters.size()]);
- for (String key : keys)
- {
- Method getter = getters.remove(key);
- Method setter = setters.remove(key);
- OpenMBeanAttributeInfo info = buildAttribute(key, getter, setter);
- attrInfo.add(info);
- }
-
- for (String key : setters.keySet())
- {
- Method setter = setters.remove(key);
- OpenMBeanAttributeInfo info = buildAttribute(key, null, setter);
- attrInfo.add(info);
- }
-
- OpenMBeanAttributeInfo[] attributeInfo = attrInfo.toArray(new OpenMBeanAttributeInfo[attrInfo.size()]);
- Collection<OpenMBeanOperationInfo> operations = operInfo.values();
- OpenMBeanOperationInfo[] operationInfo = operations.toArray(new OpenMBeanOperationInfo[operations.size()]);
-
- MBeanNotificationInfo[] notifications = null;
- if (mbeanInstance instanceof NotificationBroadcaster)
- notifications = ((NotificationBroadcaster) mbeanInstance).getNotificationInfo();
- else
- notifications = new MBeanNotificationInfo[0];
-
- return buildMBeanInfo(attributeInfo, constructorInfo, operationInfo, notifications);
-
- }
- catch (Throwable t)
- {
- NotCompliantMBeanException e = new NotCompliantMBeanException("Error generating OpenMBeanInfo.");
- e.initCause(t);
- throw e;
- }
- }
-
- /**
- * Build the constructors
- *
- * @return the info
- * @throws Exception for any error
- */
- private OpenMBeanConstructorInfo[] buildConstructors() throws Exception
- {
- Constructor<?>[] constructors = mbeanClass.getConstructors();
- OpenMBeanConstructorInfo[] constructorInfo = new OpenMBeanConstructorInfo[constructors.length];
- for (int i = 0; i < constructors.length; ++i)
- constructorInfo[i] = buildConstructor(constructors[i]);
- return constructorInfo;
- }
-
- /**
- * Build a constructor
- *
- * @param constructor the constructor
- * @return the info
- * @throws Exception for any error
- */
- private OpenMBeanConstructorInfo buildConstructor(Constructor<?> constructor) throws Exception
- {
- Type[] parameterTypes = constructor.getGenericParameterTypes();
- OpenMBeanParameterInfo[] parameterInfo = new OpenMBeanParameterInfo[parameterTypes.length];
- for (int i = 0; i < parameterTypes.length; ++i)
- parameterInfo[i] = buildParameter(i, parameterTypes[i]);
- return new OpenMBeanConstructorInfoSupport("MBean Constructor.", "MBean Constructor.", parameterInfo);
- }
-
- /**
- * Build a parameter
- *
- * @param i the index of the parameter
- * @param parameterType the parameter type
- * @return the info
- * @throws Exception for any error
- */
- private OpenMBeanParameterInfo buildParameter(int i, Type parameterType) throws Exception
- {
- OpenType openType = MXBeanUtils.getOpenType(parameterType);
- return new OpenMBeanParameterInfoSupport("arg" + i, "MBean Parameter.", openType);
- }
-
- /**
- * Build an attribute
- *
- * @param attrName the attribute name
- * @param getter the getter
- * @param setter the setter
- * @return the info
- * @throws Exception for any error
- */
- private OpenMBeanAttributeInfo buildAttribute(String attrName, Method getter, Method setter) throws Exception
- {
- boolean isReadable = (getter != null);
- boolean isWritable = (setter != null);
- boolean isIs = false;
-
- OpenType openType = null;
- if (getter != null)
- {
- openType = MXBeanUtils.getOpenType(getter.getGenericReturnType());
- if (getter.getName().startsWith("is"))
- isIs = true;
- }
- else
- {
- openType = MXBeanUtils.getOpenType(setter.getGenericParameterTypes()[0]);
- }
-
- return new OpenMBeanAttributeInfoSupport(attrName, attrName, openType, isReadable, isWritable, isIs);
- }
-
- /**
- * Build the operation info
- *
- * @param method the method
- * @return the info
- * @throws Exception for any error
- */
- private OpenMBeanOperationInfo buildOperation(Method method) throws Exception
- {
- Type[] parameterTypes = method.getGenericParameterTypes();
- OpenMBeanParameterInfo[] parameterInfo = new OpenMBeanParameterInfo[parameterTypes.length];
- for (int i = 0; i < parameterTypes.length; ++i)
- parameterInfo[i] = buildParameter(i, parameterTypes[i]);
- OpenType openType = MXBeanUtils.getOpenType(method.getGenericReturnType());
- return new OpenMBeanOperationInfoSupport(method.getName(), method.getName(), parameterInfo, openType, MBeanOperationInfo.ACTION);
- }
-
- /**
- * Build the mbean info
- *
- * @param attributes the attributes
- * @param constructors the constructors
- * @param operations the operations
- * @param notifications the notifications
- * @return the info
- * @throws Exception for any error
- */
- private OpenMBeanInfoSupport buildMBeanInfo(OpenMBeanAttributeInfo[] attributes, OpenMBeanConstructorInfo[] constructors, OpenMBeanOperationInfo[] operations, MBeanNotificationInfo[] notifications) throws Exception
- {
- return new OpenMBeanInfoSupport(mbeanClass.getName(), mbeanClass.getName(), attributes, constructors, operations, notifications);
- }
-
- /**
- * JMX standard specifies that only "boolean isX()" style methods
- * represent attributes. "Boolean isX()" methods map to operations.
- *
- * @param returnType the return type
- * @return true when boolean
- */
- private boolean isBooleanReturn(Type returnType)
- {
- return returnType == Boolean.TYPE;
- }
-
- /**
- * Get a signature string for a method
- *
- * @param method the method
- * @return the signature
- */
- private String getSignatureString(Method method)
- {
- String name = method.getName();
- Class[] signature = method.getParameterTypes();
- StringBuffer buffer = new StringBuffer(512);
- buffer.append(name);
- buffer.append("(");
- if (signature != null)
- {
- for (int i = 0; i < signature.length; i++)
- {
- buffer.append(signature[i].getName());
- if (i < signature.length-1)
- buffer.append(",");
- }
- }
- buffer.append(")");
- return buffer.toString();
- }
-}
-
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanMetaData.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,161 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.NotificationEmitter;
-import javax.management.NotificationFilter;
-import javax.management.NotificationListener;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-
-/**
- * MXBeanSupport.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanSupport implements DynamicMBean, MBeanRegistration, NotificationEmitter
-{
- /** No notifications */
- private static final MBeanNotificationInfo[] NO_NOTIFICATIONS = new MBeanNotificationInfo[0];
-
- /** The delegate */
- private DynamicMBean delegate;
-
- /** The mbean registration delegate */
- private MBeanRegistration registration;
-
- /** The emitter delegate */
- private NotificationEmitter emitter;
-
- /**
- * Create a new MXBeanSupport.
- */
- protected MXBeanSupport()
- {
- init(MXBeanUtils.createMXBean(this, null));
- }
-
- /**
- * Create a new MXBeanSupport.
- *
- * @param mxbeanInterface the interface
- */
- protected MXBeanSupport(Class<?> mxbeanInterface)
- {
- init(MXBeanUtils.createMXBean(this, mxbeanInterface));
- }
-
- public MBeanInfo getMBeanInfo()
- {
- return delegate.getMBeanInfo();
- }
-
- public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- return delegate.getAttribute(attribute);
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- return delegate.getAttributes(attributes);
- }
-
- public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- delegate.setAttribute(attribute);
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- return delegate.setAttributes(attributes);
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException
- {
- return delegate.invoke(actionName, params, signature);
- }
-
- public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
- {
- return registration.preRegister(server, name);
- }
-
- public void postRegister(Boolean registrationDone)
- {
- registration.postDeregister();
- }
-
- public void preDeregister() throws Exception
- {
- registration.preDeregister();
- }
-
- public void postDeregister()
- {
- registration.postDeregister();
- }
-
- public MBeanNotificationInfo[] getNotificationInfo()
- {
- return NO_NOTIFICATIONS;
- }
-
- public void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback) throws IllegalArgumentException
- {
- emitter.addNotificationListener(listener, filter, handback);
-
- }
-
- public void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException
- {
- emitter.removeNotificationListener(listener);
- }
-
- public void removeNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback) throws ListenerNotFoundException
- {
- emitter.removeNotificationListener(listener, filter, handback);
- }
-
- /**
- * Initialise the delegates
- *
- * @param delegate the delegate
- */
- private void init(DynamicMBean delegate)
- {
- this.delegate = delegate;
- this.registration = (MBeanRegistration) delegate;
- this.emitter = (NotificationEmitter) delegate;
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanSupport.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,1041 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.Array;
-import java.lang.reflect.GenericArrayType;
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.ParameterizedType;
-import java.lang.reflect.Proxy;
-import java.lang.reflect.Type;
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-import java.util.WeakHashMap;
-
-import javax.management.DynamicMBean;
-import javax.management.ObjectName;
-import javax.management.openmbean.ArrayType;
-import javax.management.openmbean.CompositeData;
-import javax.management.openmbean.CompositeDataSupport;
-import javax.management.openmbean.CompositeType;
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-import javax.management.openmbean.TabularData;
-import javax.management.openmbean.TabularDataSupport;
-import javax.management.openmbean.TabularType;
-
-import org.jboss.util.collection.WeakValueHashMap;
-
-/**
- * Utils.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanUtils
-{
- /** A cache of methods to keys */
- private static final Map<Method, String> compositeDataKeyCache = Collections.synchronizedMap(new WeakHashMap<Method, String>());
-
- /** A cache of classes to key to getters */
- private static final Map<Class, Map<String, Method>> compositeDataMethodCache = Collections.synchronizedMap(new WeakHashMap<Class, Map<String, Method>>());
-
- /** The map key */
- public static final String MAP_KEY = "key";
-
- /** The map value */
- public static final String MAP_VALUE = "value";
-
- /** Map index names */
- public static final String[] MAP_INDEX_NAMES = { MAP_KEY };
-
- /** Map item names */
- public static final String[] MAP_ITEM_NAMES = { MAP_KEY, MAP_VALUE };
-
- /**
- * Get the OpenType for a class
- *
- * @param type the type
- * @return the open type
- */
- public static OpenType getOpenType(Type type)
- {
- if (type == null)
- throw new IllegalArgumentException("Null type");
-
- OpenType result = checkType(type);
- if (result != null)
- return result;
- Class clazz = (Class) type;
- return CompositeTypeMetaDataFactory.getCompositeType(clazz);
- }
-
- /**
- * Get the SimpleType for a class
- *
- * @param type the type
- * @return the open type
- * @throws Exception for any error
- */
- public static SimpleType getSimpleType(Class type) throws Exception
- {
- SimpleType simpleType = checkSimpleType(type);
- if (simpleType == null)
- throw new IllegalArgumentException("Not a SimpleType: " + type.getName());
- return simpleType;
- }
-
- /**
- * Get the for a class that is not composite
- *
- * @param type the type
- * @return the open type or null if composite
- */
- public static OpenType checkType(Type type)
- {
- OpenType result = checkSimpleType(type);
- if (result != null)
- return result;
- result = checkEnum(type);
- if (result != null)
- return result;
- result = checkArray(type);
- if (result != null)
- return result;
- result = checkCollection(type);
- if (result != null)
- return result;
- return checkMap(type);
- }
-
- /**
- * Create a composite data proxy
- *
- * @param <T> the interface type
- * @param intf the interface type
- * @param compositeData the composite data
- * @return the proxy
- */
- public static <T> T createCompositeDataProxy(Class<T> intf, CompositeData compositeData)
- {
- if (intf == null)
- throw new IllegalArgumentException("Null interface");
- InvocationHandler handler = new CompositeDataInvocationHandler(compositeData);
- Object object = Proxy.newProxyInstance(intf.getClassLoader(), new Class[] { intf }, handler);
- return intf.cast(object);
- }
-
- /**
- * Construct some open data
- *
- * @param type the type
- * @param value the value
- * @param context the context
- * @return the open data
- * @throws Exception for any error
- */
- public static Object construct(Type type, Object value, Object context) throws Exception
- {
- OpenType openType = getOpenType(type);
- return construct(openType, value, context);
- }
-
- /**
- * Construct some open data
- *
- * @param openType the open type
- * @param value the value
- * @param context the context
- * @return the open data
- * @throws Exception for any error
- */
- public static Object construct(OpenType openType, Object value, Object context) throws Exception
- {
- if (openType instanceof SimpleType)
- return constructSimpleData(value);
- if (openType.isArray())
- return constructArrayData(openType, value, context);
- if (openType instanceof TabularType)
- return constructTabularData(openType, value, context);
- return constructCompositeData(openType, value, context);
- }
-
- /**
- * Reconstruct a type from an object
- *
- * @param type the type
- * @param value the value
- * @param context for error reporting
- * @return the object
- * @throws Exception for any error
- */
- public static Object reconstruct(Type type, Object value, Object context) throws Exception
- {
- OpenType openType = MXBeanUtils.getOpenType(type);
- return reconstruct(openType, type, value, context);
- }
-
- /**
- * Reconstruct a type from an object
- *
- * @param openType the open type
- * @param type the type
- * @param value the value
- * @param context for error reporting
- * @return the object
- * @throws Exception for any error
- */
- public static Object reconstruct(OpenType openType, Type type, Object value, Object context) throws Exception
- {
- if (openType instanceof SimpleType)
- return reconstructSimpleData(type, value, context);
- if (openType.isArray())
- return reconstructArrayData(openType, type, value, context);
- if (openType instanceof TabularType)
- return reconstructTabularData(openType, type, value, context);
- return reconstructCompositeData(openType, type, value, context);
- }
-
- /**
- * Get the SimpleType for a class
- *
- * @param type the type
- * @return the simple type or null if not a simple type
- */
- public static SimpleType checkSimpleType(Type type)
- {
- if (BigDecimal.class.equals(type))
- return SimpleType.BIGDECIMAL;
- if (BigInteger.class.equals(type))
- return SimpleType.BIGINTEGER;
- if (Boolean.class.equals(type))
- return SimpleType.BOOLEAN;
- if (Boolean.TYPE.equals(type))
- return SimpleType.BOOLEAN;
- if (Byte.class.equals(type))
- return SimpleType.BYTE;
- if (Byte.TYPE.equals(type))
- return SimpleType.BYTE;
- if (Character.class.equals(type))
- return SimpleType.CHARACTER;
- if (Character.TYPE.equals(type))
- return SimpleType.CHARACTER;
- if (Date.class.equals(type))
- return SimpleType.DATE;
- if (Double.class.equals(type))
- return SimpleType.DOUBLE;
- if (Double.TYPE.equals(type))
- return SimpleType.DOUBLE;
- if (Float.class.equals(type))
- return SimpleType.FLOAT;
- if (Float.TYPE.equals(type))
- return SimpleType.FLOAT;
- if (Integer.class.equals(type))
- return SimpleType.INTEGER;
- if (Integer.TYPE.equals(type))
- return SimpleType.INTEGER;
- if (Long.class.equals(type))
- return SimpleType.LONG;
- if (Long.TYPE.equals(type))
- return SimpleType.LONG;
- if (ObjectName.class.equals(type))
- return SimpleType.OBJECTNAME;
- if (Short.class.equals(type))
- return SimpleType.SHORT;
- if (Short.TYPE.equals(type))
- return SimpleType.SHORT;
- if (String.class.equals(type))
- return SimpleType.STRING;
- if (Void.class.equals(type))
- return SimpleType.VOID;
- return null;
- }
-
- /**
- * Get the simple type for an enum
- *
- * @param type the type
- * @return return the enum type or null if it is not an enum
- */
- public static SimpleType checkEnum(Type type)
- {
- if (type instanceof Class == false)
- return null;
- Class clazz = (Class) type;
- if (clazz.isEnum() || Enum.class.equals(clazz))
- return SimpleType.STRING;
- return null;
- }
-
- /**
- * Construct a simple type open data
- *
- * @param value the value
- * @return the simple type
- */
- public static Object constructSimpleData(Object value)
- {
- if (value != null && value instanceof Enum)
- {
- Enum enumeration = (Enum) value;
- return enumeration.name();
- }
- return value;
- }
-
- /**
- * Reconstruct a simple type open data
- *
- * @param type the type
- * @param value the value
- * @param context the context
- * @return the simple type
- */
- @SuppressWarnings("unchecked")
- private static Object reconstructSimpleData(Type type, Object value, Object context)
- {
- if (type instanceof Class)
- {
- if (value != null)
- {
- Class clazz = (Class) type;
- if (clazz.isEnum() || Enum.class.equals(clazz))
- {
- String string = (String) value;
- return Enum.valueOf(clazz, string);
- }
- }
- else
- {
- Class clazz = (Class) type;
- if (clazz.isPrimitive())
- throw new IllegalArgumentException("Attempt to use null as a primitive for: " + context);
- return null;
- }
- }
- return value;
- }
-
- /**
- * Get the array type for a class
- *
- * @param type the type
- * @return return the array type or null if it is not an array
- */
- public static ArrayType checkArray(Type type)
- {
- if (type instanceof Class)
- {
- Class clazz = (Class) type;
- if (clazz.isArray() == false)
- return null;
- int dimension = 1;
- Class componentType = clazz.getComponentType();
- while (componentType.isArray())
- {
- ++dimension;
- componentType = componentType.getComponentType();
- }
- OpenType componentOpenType = getOpenType(componentType);
- try
- {
- return new ArrayType(dimension, componentOpenType);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
- if (type instanceof GenericArrayType)
- {
- GenericArrayType arrayType = (GenericArrayType) type;
- int dimension = 1;
- Type componentType = arrayType.getGenericComponentType();
- while (componentType instanceof GenericArrayType)
- {
- ++dimension;
- arrayType = (GenericArrayType) componentType;
- componentType = arrayType.getGenericComponentType();
- }
- OpenType componentOpenType = getOpenType(componentType);
- try
- {
- return new ArrayType(dimension, componentOpenType);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
- return null;
- }
-
- /**
- * Get the collection type for a class
- *
- * @param type the type
- * @return return the array type or null if it is not a collection
- */
- public static ArrayType checkCollection(Type type)
- {
- if (type instanceof ParameterizedType == false)
- {
- if (type instanceof Class)
- return checkCollectionClass((Class) type);
- else
- return null;
- }
- ParameterizedType parameterizedType = (ParameterizedType) type;
- Type rawType = parameterizedType.getRawType();
- if (rawType instanceof Class == false)
- return null;
- Class rawClass = (Class) rawType;
- if (Collection.class.isAssignableFrom(rawClass) == false)
- return null;
- Type componentType = parameterizedType.getActualTypeArguments()[0];
- OpenType componentOpenType = getOpenType(componentType);
- try
- {
- return new ArrayType(1, componentOpenType);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Get the collection type for a class
- *
- * @param clazz the class
- * @return return the array type or null if it is not a collection
- */
- public static ArrayType checkCollectionClass(Class clazz)
- {
- if (Collection.class.isAssignableFrom(clazz) == false)
- return null;
- OpenType componentOpenType = getOpenType(Object.class);
- try
- {
- return new ArrayType(1, componentOpenType);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Construct an array type open data
- *
- * @param openType the open type
- * @param value the value
- * @param context the context
- * @return the open data
- * @throws Exception for any error
- */
- public static Object constructArrayData(OpenType openType, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- ArrayType arrayType = (ArrayType) openType;
- OpenType elementType = arrayType.getElementOpenType();
- int dimension = arrayType.getDimension();
-
- Class clazz = value.getClass();
- if (clazz.isArray())
- {
- Object[] oldArray = (Object[]) value;
- Class<?> componentType = Class.forName(arrayType.getClassName());
- return constructArray(elementType, componentType.getComponentType(), dimension, oldArray, context);
- }
- if (value instanceof Collection)
- {
- Collection c = (Collection) value;
- Object[] oldArray = c.toArray();
- Class<?> componentType = Class.forName(arrayType.getClassName());
- return constructArray(elementType, componentType.getComponentType(), dimension, oldArray, context);
- }
- throw new UnsupportedOperationException("Cannot construct array for: " + value);
- }
-
- /**
- * Construct an array of open data
- *
- * @param elementType the element type
- * @param componentType the componentType
- * @param dimension the dimension
- * @param oldArray the old array
- * @param context the context
- * @return the array
- * @throws Exception for any error
- */
- private static Object[] constructArray(OpenType elementType, Class<?> componentType, int dimension, Object[] oldArray, Object context) throws Exception
- {
- if (oldArray == null)
- return null;
-
- Object[] newArray = (Object[]) Array.newInstance(componentType, oldArray.length);
- if (dimension > 1)
- {
- for (int i = 0; i < oldArray.length; ++i)
- {
- Object[] nestedOld = (Object[]) oldArray[i];
- newArray[i] = constructArray(elementType, componentType.getComponentType(), dimension-1, nestedOld, context);
- }
- }
- else
- {
- if (Object.class.equals(componentType))
- {
- for (int i = 0; i < oldArray.length; ++i)
- newArray[i] = oldArray[i];
- }
- else
- {
- for (int i = 0; i < oldArray.length; ++i)
- newArray[i] = construct(elementType, oldArray[i], context);
- }
- }
-
- return newArray;
- }
-
- /**
- * Reconstruct an array type
- *
- * @param openType the open type
- * @param type the type
- * @param value the value
- * @param context the context
- * @return the value
- * @throws Exception for any error
- */
- public static Object reconstructArrayData(OpenType openType, Type type, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- ArrayType arrayType = (ArrayType) getOpenType(type);
- OpenType elementType = arrayType.getElementOpenType();
- int dimension = arrayType.getDimension();
- Object[] oldArray = (Object[]) value;
- if (type instanceof Class)
- {
- Class clazz = (Class) type;
- if (clazz.isArray())
- return reconstructArray(elementType, clazz.getComponentType(), dimension, oldArray, context);
- // TODO FIXME
- // else if (Set.class.isAssignableFrom(clazz))
- // return createSet(oldArray);
- // else if (Collection.class.isAssignableFrom(clazz))
- // return createCollection(oldArray);
- }
- else if (type instanceof ParameterizedType)
- {
- ParameterizedType parameterizedType = (ParameterizedType) type;
- Type rawType = parameterizedType.getRawType();
- if (rawType instanceof Class)
- {
- Class raw = (Class) rawType;
- if (Set.class.isAssignableFrom(raw))
- return createSet(oldArray);
- else if (Collection.class.isAssignableFrom(raw))
- return createCollection(oldArray);
- }
- }
- throw new UnsupportedOperationException("Cannot convert array type: " + type);
- }
-
- /**
- * Reconstruct an array
- *
- * @param elementType the element type
- * @param componentType the componentType
- * @param dimension the dimension
- * @param oldArray the old array of open data
- * @param context the context
- * @return the array
- * @throws Exception for any error
- */
- private static Object[] reconstructArray(OpenType elementType, Class componentType, int dimension, Object[] oldArray, Object context) throws Exception
- {
- if (oldArray == null)
- return null;
-
- Object[] newArray = (Object[]) Array.newInstance(componentType, oldArray.length);
- if (dimension > 1)
- {
- for (int i = 0; i < oldArray.length; ++i)
- {
- Object[] nestedOld = (Object[]) oldArray[i];
- newArray[i] = reconstructArray(elementType, componentType.getComponentType(), dimension-1, nestedOld, context);
- }
- }
- else
- {
- for (int i = 0; i < oldArray.length; ++i)
- newArray[i] = reconstruct(elementType, componentType, oldArray[i], context);
- }
-
- return newArray;
- }
-
- /**
- * Create a collection
- *
- * @param array the array
- * @return the collection
- */
- private static Collection createCollection(Object[] array)
- {
- return Arrays.asList(array);
- }
-
- /**
- * Create a set
- *
- * @param array the array
- * @return the set
- */
- @SuppressWarnings("unchecked")
- private static Set createSet(Object[] array)
- {
- HashSet result = new HashSet(array.length);
- for (int i = 0; i < array.length; ++i)
- result.add(array[i]);
- return result;
- }
-
- /**
- * Get the map type for a class
- *
- * @param type the type
- * @return return the tabular type or null if it is not a collection
- */
- public static TabularType checkMap(Type type)
- {
- if (type instanceof ParameterizedType == false)
- {
- if (type instanceof Class)
- return checkMapClass((Class) type);
- else
- return null;
- }
- ParameterizedType parameterizedType = (ParameterizedType) type;
- Type rawType = parameterizedType.getRawType();
- if (rawType instanceof Class == false)
- return null;
- Class rawClass = (Class) rawType;
- if (Map.class.isAssignableFrom(rawClass) == false)
- return null;
- Type[] args = parameterizedType.getActualTypeArguments();
- Type keyType = args[0];
- Type valueType = args[1];
- return createMapType(keyType, valueType);
- }
-
- /**
- * Get the map type for a class
- *
- * @param clazz the class
- * @return return the tabular type or null if it is not a collection
- */
- public static TabularType checkMapClass(Class clazz)
- {
- if (Map.class.isAssignableFrom(clazz) == false)
- return null;
- return createMapType(Object.class, Object.class);
- }
-
- /**
- * Create a map type
- *
- * @param keyType the key type
- * @param valueType the value type
- * @return the map type
- */
- public static TabularType createMapType(Type keyType, Type valueType)
- {
- String name = Map.class.getName();
- OpenType[] itemTypes = { getOpenType(keyType), getOpenType(valueType) };
- try
- {
- CompositeType entryType = createMapEntryType(itemTypes);
- return new TabularType(name, name, entryType, MAP_INDEX_NAMES);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Create a map type
- *
- * @param itemTypes the item types
- * @return the map entry type
- */
- private static CompositeType createMapEntryType(OpenType[] itemTypes)
- {
- String entryName = Map.Entry.class.getName();
- try
- {
- return new CompositeType(entryName, entryName, MAP_ITEM_NAMES, MAP_ITEM_NAMES, itemTypes);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
-
- /**
- * Construct a tabular type open data
- *
- * @param openType the open type
- * @param value the value
- * @param context the context
- * @return the open data
- * @throws Exception for any error
- */
- @SuppressWarnings("unchecked")
- public static Object constructTabularData(OpenType openType, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- TabularType tabularType = (TabularType) openType;
-
- if (value instanceof Map)
- {
- TabularDataSupport table = new TabularDataSupport(tabularType);
- CompositeType entryType = tabularType.getRowType();
- OpenType keyType = entryType.getType(MAP_KEY);
- OpenType valueType = entryType.getType(MAP_VALUE);
-
- Map<Object, Object> m = (Map<Object, Object>) value;
- for (Iterator<Map.Entry<Object, Object>> i = m.entrySet().iterator(); i.hasNext();)
- {
- Map.Entry<Object, Object> entry = i.next();
- Object key = construct(keyType, entry.getKey(), context);
- Object val = construct(valueType, entry.getValue(), context);
- CompositeDataSupport data = new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { key, val });
- table.put(data);
- }
- return table;
- }
- throw new UnsupportedOperationException("Cannot construct map for: " + value);
- }
-
- /**
- * Reconstruct a tabular type
- *
- * @param openType the open type
- * @param type the type
- * @param value the value
- * @param context the context
- * @return the value
- * @throws Exception for any error
- */
- public static Object reconstructTabularData(OpenType openType, Type type, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- TabularType tabularType = (TabularType) getOpenType(type);
- if (type instanceof Class)
- {
- // TODO FIXME
- // Class clazz = (Class) type;
- // if (Map.class.isAssignableFrom(clazz))
- // return createMap(tabularType, Object.class, Object.class, value, context);
- }
- else if (type instanceof ParameterizedType)
- {
- ParameterizedType parameterizedType = (ParameterizedType) type;
- Type rawType = parameterizedType.getRawType();
- if (rawType instanceof Class)
- {
- Class raw = (Class) rawType;
- if (Map.class.isAssignableFrom(raw))
- {
- Type keyType = parameterizedType.getActualTypeArguments()[0];
- Type valueType = parameterizedType.getActualTypeArguments()[1];
- return createMap(tabularType, keyType, valueType, value, context);
- }
- }
- }
- throw new UnsupportedOperationException("Cannot convert array type: " + type);
- }
-
- /**
- * Create a map
- *
- * @param openType the open type
- * @param keyType the key type
- * @param valueType the value type
- * @param value the value
- * @param context the context
- * @return the map
- * @throws Exception for any problem
- */
- @SuppressWarnings("unchecked")
- private static Map createMap(TabularType openType, Type keyType, Type valueType, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- Map<Object, Object> result = new HashMap<Object, Object>();
-
- TabularData table = (TabularData) value;
- Collection<CompositeData> values = table.values();
- for (CompositeData entry : values)
- {
- Object key = reconstruct(keyType, entry.get(MAP_KEY), context);
- Object val = reconstruct(valueType, entry.get(MAP_VALUE), context);
- result.put(key, val);
- }
-
- return result;
- }
-
- /**
- * Construct composite type open data
- *
- * @param openType the open type
- * @param value the value
- * @param context the context
- * @return the open data
- * @throws Exception for any error
- */
- @SuppressWarnings("unchecked")
- public static Object constructCompositeData(OpenType openType, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- Class clazz = value.getClass();
-
- CompositeType compositeType = (CompositeType) openType;
- Set<String> nameSet = compositeType.keySet();
- String[] names = nameSet.toArray(new String[nameSet.size()]);
-
- Object[] values = new Object[names.length];
-
- for (int i = 0 ; i < names.length; ++i)
- {
- String name = names[i];
- OpenType itemType = compositeType.getType(name);
- Method method = getCompositeDataMethod(clazz, name, itemType == SimpleType.BOOLEAN);
- Object itemValue = method.invoke(value, null);
- values[i] = construct(itemType, itemValue, context);
- }
- return new CompositeDataSupport(compositeType, names, values);
- }
-
- /**
- * Reconstruct a composite type
- *
- * @param openType the open type
- * @param type the type
- * @param value the value
- * @param context the context
- * @return the value
- * @throws Exception for any error
- */
- public static Object reconstructCompositeData(OpenType openType, Type type, Object value, Object context) throws Exception
- {
- if (value == null)
- return null;
-
- CompositeData compositeData = (CompositeData) value;
- CompositeDataInvocationHandler handler = new CompositeDataInvocationHandler(compositeData);
- Class clazz = (Class) type;
- Class[] interfaces = null;
- if (clazz.isInterface())
- interfaces = new Class[] { clazz };
- else
- interfaces = clazz.getInterfaces();
- return Proxy.newProxyInstance(clazz.getClassLoader(), interfaces, handler);
- }
-
- /**
- * Get the key for a composite data getter method
- *
- * @param method the method
- * @return the key
- */
- public static String getCompositeDataKey(Method method)
- {
- String key = compositeDataKeyCache.get(method);
- if (key != null)
- return key;
-
- StringBuilder fieldName = null;
-
- Class returnType = method.getReturnType();
- Class[] paramTypes = method.getParameterTypes();
- if (Void.TYPE.equals(returnType) == false && paramTypes.length == 0)
- {
- String name = method.getName();
- if (name.startsWith("is") && name.length() > 2)
- {
- if (Boolean.TYPE.equals(returnType))
- {
- fieldName = new StringBuilder();
- fieldName.append(Character.toLowerCase(name.charAt(2)));
- if (name.length() > 3)
- fieldName.append(name.substring(3));
- }
- }
- else if (name.startsWith("get") && name.length() > 3)
- {
- fieldName = new StringBuilder();
- fieldName.append(Character.toLowerCase(name.charAt(3)));
- if (name.length() > 4)
- fieldName.append(name.substring(4));
- }
- }
-
- if (fieldName == null)
- return null;
-
- String result = fieldName.toString();
- compositeDataKeyCache.put(method, result);
- return result;
- }
-
- /**
- * Get the key for a composite data getter method
- *
- * @param clazz the class
- * @param key the key
- * @param isBoolean whether it is boolean
- * @return the method
- * @throws Exception for any error
- */
- @SuppressWarnings("unchecked")
- public static Method getCompositeDataMethod(Class clazz, String key, boolean isBoolean) throws Exception
- {
- Map<String, Method> cache = compositeDataMethodCache.get(clazz);
- if (cache != null)
- {
- Method method = cache.get(key);
- if (method != null)
- return method;
- }
-
- StringBuilder name = new StringBuilder();
- name.append(Character.toUpperCase(key.charAt(0)));
- if (key.length() > 1)
- name.append(key.substring(1));
- Method method = null;
- try
- {
- method = clazz.getMethod("get" + name, null);
- }
- catch (NoSuchMethodException e)
- {
- if (isBoolean)
- {
- try
- {
- method = clazz.getMethod("is" + name, null);
- }
- catch (NoSuchMethodException ignored)
- {
- throw e;
- }
- }
- else
- {
- throw e;
- }
- }
-
- if (cache == null)
- {
- cache = new WeakValueHashMap();
- compositeDataMethodCache.put(clazz, cache);
- }
- cache.put(key, method);
- return method;
- }
-
- /**
- * Create a new MXBean
- *
- * @param resource the resource
- * @param mxbeanInterface the interface
- * @return the MXBean
- */
- public static DynamicMBean createMXBean(Object resource, Class<?> mxbeanInterface)
- {
- try
- {
- return new MXBeanDelegate(resource, mxbeanInterface);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw new RuntimeException("Error creating MXBean", e);
- }
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/MXBeanUtils.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Inherited;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * NotificationType.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
- at Documented
- at Inherited
- at Target(ElementType.TYPE)
- at Retention(RetentionPolicy.RUNTIME)
-public @interface NotificationType
-{
- /** The notification type */
- String value();
-
- /** The user data class */
- Class userDataClass() default void.class;
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/NotificationType.java)
Deleted: trunk/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,85 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.mx.mxbean;
-
-import java.lang.reflect.ParameterizedType;
-import java.lang.reflect.Type;
-
-import javax.management.openmbean.OpenType;
-
-import org.jboss.util.UnreachableStatementException;
-
-/**
- * SkeletonOpenType.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SkeletonOpenType
-{
- /** The open type */
- private OpenType openType;
-
- /** The composite type meta data */
- private CompositeTypeMetaData composite;
-
- /**
- * Create a new SkeletonOpenType.
- *
- * @param type the type
- */
- public SkeletonOpenType(Type type)
- {
- openType = MXBeanUtils.checkType(type);
- if (openType != null)
- return;
- Class clazz = null;
- if (type instanceof ParameterizedType)
- {
- ParameterizedType parameterizedType = (ParameterizedType) type;
- clazz = (Class) parameterizedType.getRawType();
- }
- else if (type instanceof Class)
- {
- clazz = (Class) type;
- }
- else
- {
- throw new UnsupportedOperationException("Unable to create open type for " + type);
- }
- composite = CompositeTypeMetaDataFactory.getCompositeTypeMetaData(clazz);
- }
-
- /**
- * Get the openType.
- *
- * @return the openType.
- */
- public OpenType getOpenType()
- {
- if (openType != null)
- return openType;
- if (composite != null)
- return composite.getCompositeType();
- throw new UnreachableStatementException();
- }
-}
Copied: trunk/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/main/org/jboss/mx/mxbean/SkeletonOpenType.java)
Copied: trunk/mbeans/src/tests (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests)
Copied: trunk/mbeans/src/tests/org (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org)
Copied: trunk/mbeans/src/tests/org/jboss (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss)
Copied: trunk/mbeans/src/tests/org/jboss/test (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test)
Copied: trunk/mbeans/src/tests/org/jboss/test/mx (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx)
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean)
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,98 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.util.Collection;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.management.openmbean.ArrayType;
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-
-import org.jboss.mx.mxbean.MXBeanUtils;
-
-/**
- * CollectionsInterface.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface CollectionsInterface
-{
- String ARRAY = "array";
- String COLLECTION = "collection";
- String SET = "set";
- String LIST = "list";
- String MAP = "map";
- String ENUM = "enum";
-
- String[] KEYS =
- {
- ARRAY,
- COLLECTION,
- SET,
- LIST,
- MAP,
- ENUM
- };
-
- OpenType[] TYPES = Initializer._TYPES;
-
- String[] getArray();
-
- Collection<String> getCollection();
-
- Set<String> getSet();
-
- List<String> getList();
-
- Map<String, Integer> getMap();
-
- TestEnum getEnum();
-
- public static class Initializer
- {
- static OpenType[] _TYPES;
-
- static
- {
- try
- {
- _TYPES = new OpenType[]
- {
- new ArrayType(1, SimpleType.STRING),
- new ArrayType(1, SimpleType.STRING),
- new ArrayType(1, SimpleType.STRING),
- new ArrayType(1, SimpleType.STRING),
- MXBeanUtils.createMapType(String.class, Integer.class),
- SimpleType.STRING
- };
- }
- catch (Exception e)
- {
- throw new RuntimeException(e);
- }
- }
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsInterface.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,129 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-import java.util.Set;
-
-import org.jboss.mx.mxbean.MXBeanSupport;
-
-/**
- * CollectionsMXBeanSupport.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CollectionsMXBeanSupport extends MXBeanSupport implements CollectionsMXBeanSupportMXBean
-{
- String[] array;
- Collection<String> collection;
- Set<String> set;
- List<String> list;
- Map<String, Integer> map;
- TestEnum enumeration;
-
- public CollectionsMXBeanSupport()
- {
- }
-
- public CollectionsMXBeanSupport(String[] array, Collection<String> collection, Set<String> set, List<String> list, Map<String, Integer> map, TestEnum enumeration)
- {
- this.array = array;
- this.collection = collection;
- this.set = set;
- this.list = list;
- this.map = map;
- this.enumeration = enumeration;
- }
-
- public String[] getArray()
- {
- return array;
- }
-
- public Collection<String> getCollection()
- {
- return collection;
- }
-
- public List<String> getList()
- {
- return list;
- }
-
- public Set<String> getSet()
- {
- return set;
- }
-
- public Map<String, Integer> getMap()
- {
- return map;
- }
-
- public TestEnum getEnum()
- {
- return enumeration;
- }
-
- public void setEnum(TestEnum enumeration)
- {
- this.enumeration = enumeration;
- }
-
- public void setArray(String[] array)
- {
- this.array = array;
- }
-
- public void setCollection(Collection<String> collection)
- {
- this.collection = collection;
- }
-
- public void setList(List<String> list)
- {
- this.list = list;
- }
-
- public void setMap(Map<String, Integer> map)
- {
- this.map = map;
- }
-
- public void setSet(Set<String> set)
- {
- this.set = set;
- }
-
- public List<String> echoReverse(List<String> list)
- {
- ArrayList<String> result = new ArrayList<String>(list.size());
- for (ListIterator<String> i = list.listIterator(list.size()); i.hasPrevious();)
- result.add(i.previous());
- return result;
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupport.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,57 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.util.Collection;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * CollectionsMXBeanSupportMXBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface CollectionsMXBeanSupportMXBean extends CollectionsInterface
-{
- /** The Object name */
- ObjectName REGISTERED_OBJECT_NAME = ObjectNameFactory.create("test:test=CollectionsMXBeanSupport");
-
- void setEnum(TestEnum enumeration);
-
- void setArray(String[] array);
-
- void setCollection(Collection<String> collection);
-
- void setList(List<String> list);
-
- void setMap(Map<String, Integer> map);
-
- void setSet(Set<String> set);
-
- List<String> echoReverse(List<String> list);
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CollectionsMXBeanSupportMXBean.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-
-import org.jboss.mx.mxbean.CompositeTypeMetaDataFactory;
-
-/**
- * CompositeInterface.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface CompositeInterface
-{
- String SIMPLE = "simple";
- String COMPOSITE = "composite";
-
- String[] KEYS =
- {
- SIMPLE,
- COMPOSITE
- };
-
- OpenType[] TYPES =
- {
- SimpleType.STRING,
- CompositeTypeMetaDataFactory.getCompositeType(SimpleInterface.class)
- };
-
- String getSimple();
-
- SimpleInterface getComposite();
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeInterface.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,71 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import org.jboss.mx.mxbean.MXBeanSupport;
-
-/**
- * SimpleMXBeanSupport.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeMXBeanSupport extends MXBeanSupport implements CompositeMXBeanSupportMXBean
-{
- private String simple;
- private SimpleInterface composite;
-
- public String getSimple()
- {
- return simple;
- }
-
- public CompositeMXBeanSupport(String simple, SimpleInterface composite)
- {
- this.simple = simple;
- this.composite = composite;
- }
-
- public SimpleInterface getComposite()
- {
- return composite;
- }
-
- public void setComposite(SimpleInterface composite)
- {
- this.composite = composite;
- }
-
- public void setSimple(String simple)
- {
- this.simple = simple;
- }
-
- public SimpleInterface echoReverse(SimpleInterface composite)
- {
- SimpleObject result = new SimpleObject();
- StringBuilder builder = new StringBuilder(composite.getString());
- builder.reverse();
- result.setString(builder.toString());
- return result;
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupport.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * CompositeMXBeanSupportMXBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface CompositeMXBeanSupportMXBean extends CompositeInterface
-{
- /** The Object name */
- ObjectName REGISTERED_OBJECT_NAME = ObjectNameFactory.create("test:test=CompositeMXBeanSupport");
-
- void setComposite(SimpleInterface composite);
-
- void setSimple(String simple);
-
- SimpleInterface echoReverse(SimpleInterface composite);
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/CompositeMXBeanSupportMXBean.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,38 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-/**
- * SimpleInterface.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface InvalidInterface
-{
- Object getInvalid();
- void notAGetter();
- void getString();
- String isString();
- String getString(Object parameter);
- Boolean isBoolean();
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/InvalidInterface.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,142 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-/**
- * NullSimpleObject.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class NullSimpleObject implements SimpleInterface
-{
- public BigDecimal getBigDecimal()
- {
- return null;
- }
-
- public BigInteger getBigInteger()
- {
- return null;
- }
-
- public Boolean getBoolean()
- {
- return null;
- }
-
- public Byte getByte()
- {
- return null;
- }
-
- public Character getCharacter()
- {
- return null;
- }
-
- public Date getDate()
- {
- return null;
- }
-
- public Double getDouble()
- {
- return null;
- }
-
- public Float getFloat()
- {
- return null;
- }
-
- public Integer getInteger()
- {
- return null;
- }
-
- public Long getLong()
- {
- return null;
- }
-
- public ObjectName getObjectName()
- {
- return null;
- }
-
- public byte getPrimitiveByte()
- {
- return primitiveByteValue;
- }
-
- public char getPrimitiveChar()
- {
- return primitiveCharValue;
- }
-
- public double getPrimitiveDouble()
- {
- return primitiveDoubleValue;
- }
-
- public float getPrimitiveFloat()
- {
- return primitiveFloatValue;
- }
-
- public int getPrimitiveInt()
- {
- return primitiveIntValue;
- }
-
- public long getPrimitiveLong()
- {
- return primitiveLongValue;
- }
-
- public short getPrimitiveShort()
- {
- return primitiveShortValue;
- }
-
- public Short getShort()
- {
- return null;
- }
-
- public String getString()
- {
- return null;
- }
-
- public boolean isPrimitiveBoolean()
- {
- return primitiveBooleanValue;
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/NullSimpleObject.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,337 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.mx.mxbean.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.mx.mxbean.test.AbstractMXBeanTest;
-
-/**
- * SimpleInterface.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface SimpleInterface
-{
- String BIG_DECIMAL = "bigDecimal";
-
- BigDecimal bigDecimalValue = new BigDecimal("12e4");
- BigDecimal bigDecimalChangedValue = new BigDecimal("12e5");
-
- String BIG_INTEGER = "bigInteger";
-
- BigInteger bigIntegerValue = new BigInteger("123456");
- BigInteger bigIntegerChangedValue = new BigInteger("123457");
-
- String BOOLEAN = "boolean";
-
- Boolean booleanValue = Boolean.TRUE;
- Boolean booleanChangedValue = Boolean.FALSE;
-
- String BOOLEAN_PRIMITIVE = "primitiveBoolean";
-
- boolean primitiveBooleanValue = booleanValue.booleanValue();
- boolean primitiveBooleanChangedValue = booleanChangedValue.booleanValue();
-
- String BYTE = "byte";
-
- Byte byteValue = new Byte("12");
- Byte byteChangedValue = new Byte("13");
-
- String BYTE_PRIMITIVE = "primitiveByte";
-
- byte primitiveByteValue = byteValue.byteValue();
- byte primitiveByteChangedValue = byteChangedValue.byteValue();
-
- String CHARACTER = "character";
-
- Character characterValue = new Character('a');
- Character characterChangedValue = new Character('b');
-
- String CHAR_PRIMITIVE = "primitiveChar";
-
- char primitiveCharValue = characterValue.charValue();
- char primitiveCharChangedValue = characterChangedValue.charValue();
-
- String DATE = "date";
-
- Date dateValue = AbstractMXBeanTest.createDate(2001, 1, 1);
- Date dateChangedValue = AbstractMXBeanTest.createDate(2002, 2, 2);
-
- String DOUBLE = "double";
-
- Double doubleValue = new Double("3.14e12");
- Double doubleChangedValue = new Double("3.14e13");
-
- String DOUBLE_PRIMITIVE = "primitiveDouble";
-
- double primitiveDoubleValue = doubleValue.doubleValue();
- double primitiveDoubleChangedValue = doubleChangedValue.doubleValue();
-
- String FLOAT = "float";
-
- Float floatValue = new Float("3.14");
- Float floatChangedValue = new Float("3.15");
-
- String FLOAT_PRIMITIVE = "primitiveFloat";
-
- float primitiveFloatValue = floatValue.floatValue();
- float primitiveFloatChangedValue = floatChangedValue.floatValue();
-
- String INTEGER = "integer";
-
- Integer integerValue = new Integer("1234");
- Integer integerChangedValue = new Integer("1235");
-
- String INT_PRIMITIVE = "primitiveInt";
-
- int primitiveIntValue = integerValue.intValue();
- int primitiveIntChangedValue = integerChangedValue.intValue();
-
- String LONG = "long";
-
- Long longValue = new Long("12345");
- Long longChangedValue = new Long("12346");
-
- String LONG_PRIMITIVE = "primitiveLong";
-
- long primitiveLongValue = longValue.longValue();
- long primitiveLongChangedValue = longChangedValue.longValue();
-
- String OBJECT_NAME = "objectName";
-
- ObjectName objectNameValue = ObjectNameFactory.create("domain:key=property");
- ObjectName objectNameChangedValue = ObjectNameFactory.create("domain:key=property2");
-
- String SHORT = "short";
-
- Short shortValue = new Short("123");
- Short shortChangedValue = new Short("124");
-
- String SHORT_PRIMITIVE = "primitiveShort";
-
- short primitiveShortValue = shortValue.shortValue();
- short primitiveShortChangedValue = shortChangedValue.shortValue();
-
- String STRING = "string";
-
- String stringValue = new String("StringValue");
- String stringChangedValue = new String("ChangedValue");
-
- String[] KEYS =
- {
- BIG_DECIMAL,
- BIG_INTEGER,
- BOOLEAN,
- BOOLEAN_PRIMITIVE,
- BYTE,
- BYTE_PRIMITIVE,
- CHARACTER,
- CHAR_PRIMITIVE,
- DATE,
- DOUBLE,
- DOUBLE_PRIMITIVE,
- FLOAT,
- FLOAT_PRIMITIVE,
- INTEGER,
- INT_PRIMITIVE,
- LONG,
- LONG_PRIMITIVE,
- OBJECT_NAME,
- SHORT,
- SHORT_PRIMITIVE,
- STRING
- };
-
- Object[] VALUES =
- {
- bigDecimalValue,
- bigIntegerValue,
- booleanValue,
- primitiveBooleanValue,
- byteValue,
- primitiveByteValue,
- characterValue,
- primitiveCharValue,
- dateValue,
- doubleValue,
- primitiveDoubleValue,
- floatValue,
- primitiveFloatValue,
- integerValue,
- primitiveIntValue,
- longValue,
- primitiveLongValue,
- objectNameValue,
- shortValue,
- primitiveShortValue,
- stringValue
- };
-
- Object[] CHANGED_VALUES =
- {
- bigDecimalChangedValue,
- bigIntegerChangedValue,
- booleanChangedValue,
- primitiveBooleanChangedValue,
- byteChangedValue,
- primitiveByteChangedValue,
- characterChangedValue,
- primitiveCharChangedValue,
- dateChangedValue,
- doubleChangedValue,
- primitiveDoubleChangedValue,
- floatChangedValue,
- primitiveFloatChangedValue,
- integerChangedValue,
- primitiveIntChangedValue,
- longChangedValue,
- primitiveLongChangedValue,
- objectNameChangedValue,
- shortChangedValue,
- primitiveShortChangedValue,
- stringChangedValue
- };
-
- Class[] TYPES =
- {
- BigDecimal.class,
- BigInteger.class,
- Boolean.class,
- Boolean.TYPE,
- Byte.class,
- Byte.TYPE,
- Character.class,
- Character.TYPE,
- Date.class,
- Double.class,
- Double.TYPE,
- Float.class,
- Float.TYPE,
- Integer.class,
- Integer.TYPE,
- Long.class,
- Long.TYPE,
- ObjectName.class,
- Short.class,
- Short.TYPE,
- String.class
- };
-
- Object[] NULL_VALUES =
- {
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null,
- null
- };
-
- Object[] LEGAL_NULL_VALUES =
- {
- null,
- null,
- null,
- primitiveBooleanValue,
- null,
- primitiveByteValue,
- null,
- primitiveCharValue,
- null,
- null,
- primitiveDoubleValue,
- null,
- primitiveFloatValue,
- null,
- primitiveIntValue,
- null,
- primitiveLongValue,
- null,
- null,
- primitiveShortValue,
- null,
- };
-
- BigDecimal getBigDecimal();
-
- BigInteger getBigInteger();
-
- boolean isPrimitiveBoolean();
-
- Boolean getBoolean();
-
- byte getPrimitiveByte();
-
- Byte getByte();
-
- char getPrimitiveChar();
-
- Character getCharacter();
-
- Date getDate();
-
- double getPrimitiveDouble();
-
- Double getDouble();
-
- float getPrimitiveFloat();
-
- Float getFloat();
-
- int getPrimitiveInt();
-
- Integer getInteger();
-
- long getPrimitiveLong();
-
- Long getLong();
-
- ObjectName getObjectName();
-
- short getPrimitiveShort();
-
- Short getShort();
-
- String getString();
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleInterface.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,278 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.mxbean.MXBeanSupport;
-
-/**
- * SimpleMXBeanSupport.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SimpleMXBeanSupport extends MXBeanSupport implements SimpleMXBeanSupportMXBean
-{
- private BigDecimal bigDecimal = bigDecimalValue;
- private BigInteger bigInteger = bigIntegerValue;
- private Boolean booleanV = booleanValue;
- private Byte byteV = byteValue;
- private Character characterV = characterValue;
- private Date date = dateValue;
- private Double doubleV = doubleValue;
- private Float floatV = floatValue;
- private Integer integer = integerValue;
- private Long longV = longValue;
- private ObjectName objectName = objectNameValue;
- private boolean primitiveBoolean = primitiveBooleanValue;
- private byte primitiveByte = primitiveByteValue;
- private char primitiveChar = primitiveCharValue;
- private double primitiveDouble = primitiveDoubleValue;
- private float primitiveFloat = primitiveFloatValue;
- private int primitiveInt = primitiveIntValue;
- private long primitiveLong = primitiveLongValue;
- private Short shortV = shortValue;
- private short primitiveShort = primitiveShortValue;
- private String string = stringValue;
-
- public BigDecimal getBigDecimal()
- {
- return bigDecimal;
- }
-
- public BigInteger getBigInteger()
- {
- return bigInteger;
- }
-
- public Boolean getBoolean()
- {
- return booleanV;
- }
-
- public Byte getByte()
- {
- return byteV;
- }
-
- public Character getCharacter()
- {
- return characterV;
- }
-
- public Date getDate()
- {
- return date;
- }
-
- public Double getDouble()
- {
- return doubleV;
- }
-
- public Float getFloat()
- {
- return floatV;
- }
-
- public Integer getInteger()
- {
- return integer;
- }
-
- public Long getLong()
- {
- return longV;
- }
-
- public ObjectName getObjectName()
- {
- return objectName;
- }
-
- public byte getPrimitiveByte()
- {
- return primitiveByte;
- }
-
- public char getPrimitiveChar()
- {
- return primitiveChar;
- }
-
- public double getPrimitiveDouble()
- {
- return primitiveDouble;
- }
-
- public float getPrimitiveFloat()
- {
- return primitiveFloat;
- }
-
- public int getPrimitiveInt()
- {
- return primitiveInt;
- }
-
- public long getPrimitiveLong()
- {
- return primitiveLong;
- }
-
- public short getPrimitiveShort()
- {
- return primitiveShort;
- }
-
- public Short getShort()
- {
- return shortV;
- }
-
- public String getString()
- {
- return string;
- }
-
- public boolean isPrimitiveBoolean()
- {
- return primitiveBoolean;
- }
-
- public void setBoolean(Boolean booleanV)
- {
- this.booleanV = booleanV;
- }
-
- public void setByte(Byte byteV)
- {
- this.byteV = byteV;
- }
-
- public void setCharacter(Character characterV)
- {
- this.characterV = characterV;
- }
-
- public void setDouble(Double doubleV)
- {
- this.doubleV = doubleV;
- }
-
- public void setFloat(Float floatV)
- {
- this.floatV = floatV;
- }
-
- public void setLong(Long longV)
- {
- this.longV = longV;
- }
-
- public void setShort(Short shortV)
- {
- this.shortV = shortV;
- }
-
- public void setBigDecimal(BigDecimal bigDecimal)
- {
- this.bigDecimal = bigDecimal;
- }
-
- public void setBigInteger(BigInteger bigInteger)
- {
- this.bigInteger = bigInteger;
- }
-
- public void setDate(Date date)
- {
- this.date = date;
- }
-
- public void setInteger(Integer integer)
- {
- this.integer = integer;
- }
-
- public void setObjectName(ObjectName objectName)
- {
- this.objectName = objectName;
- }
-
- public void setPrimitiveBoolean(boolean primitiveBoolean)
- {
- this.primitiveBoolean = primitiveBoolean;
- }
-
- public void setPrimitiveByte(byte primitiveByte)
- {
- this.primitiveByte = primitiveByte;
- }
-
- public void setPrimitiveChar(char primitiveChar)
- {
- this.primitiveChar = primitiveChar;
- }
-
- public void setPrimitiveDouble(double primitiveDouble)
- {
- this.primitiveDouble = primitiveDouble;
- }
-
- public void setPrimitiveFloat(float primitiveFloat)
- {
- this.primitiveFloat = primitiveFloat;
- }
-
- public void setPrimitiveInt(int primitiveInt)
- {
- this.primitiveInt = primitiveInt;
- }
-
- public void setPrimitiveLong(long primitiveLong)
- {
- this.primitiveLong = primitiveLong;
- }
-
- public void setPrimitiveShort(short primitiveShort)
- {
- this.primitiveShort = primitiveShort;
- }
-
- public void setString(String string)
- {
- this.string = string;
- }
-
- public String echoReverse(String string)
- {
- StringBuilder builder = new StringBuilder(string);
- builder.reverse();
- return builder.toString();
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupport.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,86 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * SimpleMXBeanSupportMXBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface SimpleMXBeanSupportMXBean extends SimpleInterface
-{
- /** The Object name */
- ObjectName REGISTERED_OBJECT_NAME = ObjectNameFactory.create("test:test=SimpleMXBeanSupport");
-
- void setBoolean(Boolean booleanV);
-
- void setByte(Byte byteV);
-
- void setCharacter(Character characterV);
-
- void setDouble(Double doubleV);
-
- void setFloat(Float floatV);
-
- void setLong(Long longV);
-
- void setShort(Short shortV);
-
- void setBigDecimal(BigDecimal bigDecimal);
-
- void setBigInteger(BigInteger bigInteger);
-
- void setDate(Date date);
-
- void setInteger(Integer integer);
-
- void setObjectName(ObjectName objectName);
-
- void setPrimitiveBoolean(boolean primitiveBoolean);
-
- void setPrimitiveByte(byte primitiveByte);
-
- void setPrimitiveChar(char primitiveChar);
-
- void setPrimitiveDouble(double primitiveDouble);
-
- void setPrimitiveFloat(float primitiveFloat);
-
- void setPrimitiveInt(int primitiveInt);
-
- void setPrimitiveLong(long primitiveLong);
-
- void setPrimitiveShort(short primitiveShort);
-
- void setString(String string);
-
- String echoReverse(String string);
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleMXBeanSupportMXBean.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,269 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-/**
- * SimpleObject.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SimpleObject implements SimpleInterface
-{
- private BigDecimal bigDecimal = bigDecimalValue;
- private BigInteger bigInteger = bigIntegerValue;
- private Boolean booleanV = booleanValue;
- private Byte byteV = byteValue;
- private Character characterV = characterValue;
- private Date date = dateValue;
- private Double doubleV = doubleValue;
- private Float floatV = floatValue;
- private Integer integer = integerValue;
- private Long longV = longValue;
- private ObjectName objectName = objectNameValue;
- private boolean primitiveBoolean = primitiveBooleanValue;
- private byte primitiveByte = primitiveByteValue;
- private char primitiveChar = primitiveCharValue;
- private double primitiveDouble = primitiveDoubleValue;
- private float primitiveFloat = primitiveFloatValue;
- private int primitiveInt = primitiveIntValue;
- private long primitiveLong = primitiveLongValue;
- private Short shortV = shortValue;
- private short primitiveShort = primitiveShortValue;
- private String string = stringValue;
-
- public BigDecimal getBigDecimal()
- {
- return bigDecimal;
- }
-
- public BigInteger getBigInteger()
- {
- return bigInteger;
- }
-
- public Boolean getBoolean()
- {
- return booleanV;
- }
-
- public Byte getByte()
- {
- return byteV;
- }
-
- public Character getCharacter()
- {
- return characterV;
- }
-
- public Date getDate()
- {
- return date;
- }
-
- public Double getDouble()
- {
- return doubleV;
- }
-
- public Float getFloat()
- {
- return floatV;
- }
-
- public Integer getInteger()
- {
- return integer;
- }
-
- public Long getLong()
- {
- return longV;
- }
-
- public ObjectName getObjectName()
- {
- return objectName;
- }
-
- public byte getPrimitiveByte()
- {
- return primitiveByte;
- }
-
- public char getPrimitiveChar()
- {
- return primitiveChar;
- }
-
- public double getPrimitiveDouble()
- {
- return primitiveDouble;
- }
-
- public float getPrimitiveFloat()
- {
- return primitiveFloat;
- }
-
- public int getPrimitiveInt()
- {
- return primitiveInt;
- }
-
- public long getPrimitiveLong()
- {
- return primitiveLong;
- }
-
- public short getPrimitiveShort()
- {
- return primitiveShort;
- }
-
- public Short getShort()
- {
- return shortV;
- }
-
- public String getString()
- {
- return string;
- }
-
- public boolean isPrimitiveBoolean()
- {
- return primitiveBoolean;
- }
-
- public void setBoolean(Boolean booleanV)
- {
- this.booleanV = booleanV;
- }
-
- public void setByte(Byte byteV)
- {
- this.byteV = byteV;
- }
-
- public void setCharacter(Character characterV)
- {
- this.characterV = characterV;
- }
-
- public void setDouble(Double doubleV)
- {
- this.doubleV = doubleV;
- }
-
- public void setFloat(Float floatV)
- {
- this.floatV = floatV;
- }
-
- public void setLong(Long longV)
- {
- this.longV = longV;
- }
-
- public void setShort(Short shortV)
- {
- this.shortV = shortV;
- }
-
- public void setBigDecimal(BigDecimal bigDecimal)
- {
- this.bigDecimal = bigDecimal;
- }
-
- public void setBigInteger(BigInteger bigInteger)
- {
- this.bigInteger = bigInteger;
- }
-
- public void setDate(Date date)
- {
- this.date = date;
- }
-
- public void setInteger(Integer integer)
- {
- this.integer = integer;
- }
-
- public void setObjectName(ObjectName objectName)
- {
- this.objectName = objectName;
- }
-
- public void setPrimitiveBoolean(boolean primitiveBoolean)
- {
- this.primitiveBoolean = primitiveBoolean;
- }
-
- public void setPrimitiveByte(byte primitiveByte)
- {
- this.primitiveByte = primitiveByte;
- }
-
- public void setPrimitiveChar(char primitiveChar)
- {
- this.primitiveChar = primitiveChar;
- }
-
- public void setPrimitiveDouble(double primitiveDouble)
- {
- this.primitiveDouble = primitiveDouble;
- }
-
- public void setPrimitiveFloat(float primitiveFloat)
- {
- this.primitiveFloat = primitiveFloat;
- }
-
- public void setPrimitiveInt(int primitiveInt)
- {
- this.primitiveInt = primitiveInt;
- }
-
- public void setPrimitiveLong(long primitiveLong)
- {
- this.primitiveLong = primitiveLong;
- }
-
- public void setPrimitiveShort(short primitiveShort)
- {
- this.primitiveShort = primitiveShort;
- }
-
- public void setString(String string)
- {
- this.string = string;
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/SimpleObject.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,33 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-/**
- * TestEnum.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public enum TestEnum
-{
- FIRST, SECOND
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestEnum.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,66 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.support;
-
-import java.lang.reflect.ParameterizedType;
-import java.lang.reflect.Type;
-
-import org.jboss.util.NotImplementedException;
-
-/**
- * TestParameterizedType.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class TestParameterizedType implements ParameterizedType
-{
- private Type raw;
- private Type[] args;
-
- /**
- * Create a new TestParameterizedType.
- *
- * @param raw the raw type
- * @param args the args the type args
- */
- public TestParameterizedType(Type raw, Type[] args)
- {
- this.raw = raw;
- this.args = args;
- }
-
- public Type[] getActualTypeArguments()
- {
- return args;
- }
-
- public Type getRawType()
- {
- return raw;
- }
-
- public Type getOwnerType()
- {
- throw new NotImplementedException();
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/support/TestParameterizedType.java)
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,309 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.util.Arrays;
-import java.util.Calendar;
-import java.util.Date;
-import java.util.Set;
-
-import javax.management.MBeanServer;
-import javax.management.MBeanServerFactory;
-import javax.management.openmbean.CompositeData;
-import javax.management.openmbean.CompositeDataSupport;
-import javax.management.openmbean.CompositeType;
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-
-import junit.framework.AssertionFailedError;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.mxbean.CompositeDataInvocationHandler;
-import org.jboss.mx.mxbean.MXBeanUtils;
-import org.jboss.test.BaseTestCase;
-import org.jboss.test.mx.mxbean.support.InvalidInterface;
-import org.jboss.test.mx.mxbean.support.SimpleInterface;
-import org.jboss.util.UnexpectedThrowable;
-
-/**
- * AbstractMXBeanTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class AbstractMXBeanTest extends BaseTestCase
-{
- private static Logger staticLog = Logger.getLogger(AbstractMXBeanTest.class);
-
- public AbstractMXBeanTest(String name)
- {
- super(name);
- }
-
- // @fixme move to AbstractTestCase
- public static void checkThrowableDeep(Class<? extends Throwable> wrapperExpected, Class<? extends Throwable> deepExpected, Throwable throwable) throws Exception
- {
- assertNotNull(deepExpected);
- assertNotNull(throwable);
-
- Throwable original = throwable;
-
- if (wrapperExpected != null)
- {
- if (wrapperExpected.isInstance(original) == false)
- {
- if (original instanceof Exception)
- throw (Exception) original;
- else if (original instanceof Error)
- throw (Error) original;
- else
- throw new UnexpectedThrowable("UnexpectedThrowable", original);
- }
- staticLog.debug("Got expected " + wrapperExpected.getName() + "(" + original + ")");
- }
-
- while (throwable.getCause() != null)
- throwable = throwable.getCause();
-
- if (deepExpected.isInstance(throwable) == false)
- {
- if (original instanceof Exception)
- throw (Exception) original;
- else if (original instanceof Error)
- throw (Error) original;
- else
- throw new UnexpectedThrowable("UnexpectedThrowable", original);
- }
- else
- {
- staticLog.debug("Got expected " + deepExpected.getName() + "(" + throwable + ")");
- }
- }
-
- // @fixme move to AbstractTestCase
- public static void checkThrowableDeep(Class<? extends Throwable> expected, Throwable throwable) throws Exception
- {
- checkThrowableDeep(null, expected, throwable);
- }
-
- // @fixme move to AbstractTestCase
- public static <T> T assertInstanceOf(Class<T> expected, Object object) throws Exception
- {
- if (object == null)
- return null;
- assertTrue(object.getClass(). getName() + " is not an instance of " + expected.getName(), expected.isInstance(object));
- return expected.cast(object);
- }
-
- public static void checkArrayEquals(Object expected, Object actual)
- {
- Object[] a1 = (Object[]) expected;
- Object[] a2 = (Object[]) actual;
- if (Arrays.deepEquals(a1, a2) == false)
- throw new AssertionFailedError("Expected: " + a1 + "=" + Arrays.deepToString(a1) + " got " + a2 + "=" + Arrays.deepToString(a2));
- }
-
- @SuppressWarnings("unchecked")
- public static void checkCompositeDataHandlerEquals(Object expected, Object actual)
- {
- if (expected == null)
- {
- assertEquals(expected, actual);
- return;
- }
-
- CompositeDataInvocationHandler handler = (CompositeDataInvocationHandler) Proxy.getInvocationHandler(actual);
- CompositeData data = handler.getCompositeData();
- CompositeType type = data.getCompositeType();
- Set<String> names = type.keySet();
- Class clazz = expected.getClass();
- for (String name : names)
- {
- OpenType itemType = type.getType(name);
- try
- {
- Method method = MXBeanUtils.getCompositeDataMethod(clazz, name, itemType == SimpleType.BOOLEAN);
- Object expectedValue = method.invoke(expected, null);
- Object actualValue = handler.invoke(actual, method, null);
- assertEquals(expectedValue, actualValue);
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Error e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- throw new RuntimeException(t);
- }
- }
- }
-
- public static void checkValueEquals(Object expected, Object actual)
- {
- if (actual == null)
- assertEquals(expected, actual);
- else if (actual instanceof Proxy)
- checkCompositeDataHandlerEquals(expected, actual);
- else if (actual.getClass().isArray())
- checkArrayEquals(expected, actual);
- else
- assertEquals(expected, actual);
- }
-
- protected CompositeData createCompositeData(String name, String[] keys, Object[] values) throws Exception
- {
- assertNotNullArray("values", values);
-
- Class[] types = new Class[values.length];
- for (int i = 0; i < values.length; ++i)
- types[i] = values[i].getClass();
-
- return createCompositeData(name, keys, types, values);
- }
-
- protected CompositeData createCompositeData(String name, String[] keys, Class[] types, Object[] values) throws Exception
- {
- CompositeType compositeType = createCompositeType(name, keys, types);
- return new CompositeDataSupport(compositeType, keys, values);
- }
-
- protected CompositeData createCompositeData(String name, String[] keys, OpenType[] openTypes, Object[] values) throws Exception
- {
- CompositeType compositeType = createCompositeType(name, keys, openTypes);
- return new CompositeDataSupport(compositeType, keys, values);
- }
-
- protected CompositeType createCompositeType(String name, String[] keys, Class[] types) throws Exception
- {
- assertNotNull(name);
- assertNotNullArray("keys", keys);
- assertNotNullArray("types", types);
- assertEquals(keys.length, types.length);
-
- OpenType[] openTypes = new OpenType[types.length];
- for (int i = 0; i < types.length; ++i)
- openTypes[i] = MXBeanUtils.getOpenType(types[i]);
-
- return new CompositeType(name, name, keys, keys, openTypes);
- }
-
- protected CompositeType createCompositeType(String name, String[] keys, OpenType[] openTypes) throws Exception
- {
- assertNotNull(name);
- assertNotNullArray("keys", keys);
- assertNotNullArray("types", openTypes);
- assertEquals(keys.length, openTypes.length);
-
- return new CompositeType(name, name, keys, keys, openTypes);
- }
-
- protected <T> T createCompositeDataProxy(Class<T> intf, String[] keys, Object[] values) throws Exception
- {
- assertNotNull(intf);
- return createCompositeDataProxy(intf, intf.getName(), keys, values);
- }
-
- protected <T> T createCompositeDataProxy(Class<T> intf, String name, String[] keys, Object[] values) throws Exception
- {
- CompositeData compositeData = createCompositeData(name, keys, values);
- return createCompositeDataProxy(intf, compositeData);
- }
-
- protected <T> T createCompositeDataProxy(Class<T> intf, String[] keys, Class[] types, Object[] values) throws Exception
- {
- assertNotNull(intf);
- return createCompositeDataProxy(intf, intf.getName(), keys, types, values);
- }
-
- protected <T> T createCompositeDataProxy(Class<T> intf, String name, String[] keys, Class[] types, Object[] values) throws Exception
- {
- CompositeData compositeData = createCompositeData(name, keys, types, values);
- return createCompositeDataProxy(intf, compositeData);
- }
-
- protected <T> T createCompositeDataProxy(Class<T> intf, String name, String[] keys, OpenType[] openTypes, Object[] values) throws Exception
- {
- CompositeData compositeData = createCompositeData(name, keys, openTypes, values);
- return createCompositeDataProxy(intf, compositeData);
- }
-
- protected <T> T createCompositeDataProxy(Class<T> intf, CompositeData compositeData)
- {
- return MXBeanUtils.createCompositeDataProxy(intf, compositeData);
- }
-
- protected CompositeData createTestCompositeData() throws Exception
- {
- return createCompositeData("Test", SimpleInterface.KEYS, SimpleInterface.VALUES);
- }
-
- protected SimpleInterface createTestCompositeDataProxy() throws Exception
- {
- return createCompositeDataProxy(SimpleInterface.class, SimpleInterface.KEYS, SimpleInterface.VALUES);
- }
-
- protected SimpleInterface createNullCompositeDataProxy() throws Exception
- {
- return createCompositeDataProxy(SimpleInterface.class, SimpleInterface.KEYS, SimpleInterface.TYPES, SimpleInterface.NULL_VALUES);
- }
-
- protected InvalidInterface createInvalidCompositeDataProxy() throws Exception
- {
- return createCompositeDataProxy(InvalidInterface.class, SimpleInterface.KEYS, SimpleInterface.VALUES);
- }
-
- protected SimpleInterface createTestCompositeDataProxy(String name) throws Exception
- {
- return createCompositeDataProxy(SimpleInterface.class, name, SimpleInterface.KEYS, SimpleInterface.VALUES);
- }
-
- protected MBeanServer createMBeanServer()
- {
- return MBeanServerFactory.newMBeanServer();
- }
-
- protected void assertNotNullArray(String context, Object[] array) throws Exception
- {
- assertNotNull(context + " is null ", array);
- for (int i = 0; i < array.length; ++i)
- assertNotNull(context + "[" + i + "] is null", array[i]);
- }
-
- public static Date createDate(int year, int month, int day)
- {
- Calendar calender = Calendar.getInstance();
- calender.clear();
- calender.set(year, month-1, day, 0, 0, 0);
- return calender.getTime();
- }
-
- public static String getUpperName(String name)
- {
- return Character.toUpperCase(name.charAt(0)) + name.substring(1);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/AbstractMXBeanTest.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,103 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import org.jboss.test.mx.mxbean.support.TestEnum;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataArrayUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataArrayUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataArrayUnitTestCase.class);
- }
-
- public CompositeDataArrayUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testArrayString() throws Exception
- {
- String[] array = { "one", "two", "three" };
- constructReconstructTest(array);
- }
-
- public void testMultiArrayString() throws Exception
- {
- String[][] array = { { "one", "two", "three" }, { "four", "five", "six" } };
- constructReconstructTest(array);
- }
-
- public void testArrayEnum() throws Exception
- {
- TestEnum[] array = { TestEnum.FIRST, TestEnum.SECOND };
- String[] openData = { TestEnum.FIRST.name(), TestEnum.SECOND.name() };
- constructReconstructTest(array, openData);
- }
-
- public void testMultiArrayEnum() throws Exception
- {
- TestEnum[][] array = { { TestEnum.FIRST, TestEnum.SECOND }, { TestEnum.SECOND } };
- String[][] openData = { { TestEnum.FIRST.name(), TestEnum.SECOND.name() }, { TestEnum.SECOND.name() } };
- constructReconstructTest(array, openData);
- }
-
- public void testArrayNull() throws Exception
- {
- constructReconstructTest(null, new String[0].getClass());
- }
-
- public void testArrayElementNull() throws Exception
- {
- TestEnum[] array = { TestEnum.FIRST, null };
- String[] openData = { TestEnum.FIRST.name(), null };
- constructReconstructTest(array, openData);
- }
-
- public void testMultiArrayElementNull() throws Exception
- {
- TestEnum[][] array = { { TestEnum.FIRST, null }, { TestEnum.SECOND } };
- String[][] openData = { { TestEnum.FIRST.name(), null }, { TestEnum.SECOND.name() } };
- constructReconstructTest(array, openData);
- }
-
- public void testMultiArrayNull() throws Exception
- {
- TestEnum[][] array = { { TestEnum.FIRST, TestEnum.SECOND }, null, { TestEnum.SECOND } };
- String[][] openData = { { TestEnum.FIRST.name(), TestEnum.SECOND.name() }, null, { TestEnum.SECOND.name() } };
- constructReconstructTest(array, openData);
- }
-
- public void checkEquals(Object expected, Object actual)
- {
- checkArrayEquals(expected, actual);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataArrayUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.math.BigDecimal;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataBigDecimalUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataBigDecimalUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataBigDecimalUnitTestCase.class);
- }
-
- public CompositeDataBigDecimalUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testBigDecimal() throws Exception
- {
- constructReconstructTest(new BigDecimal("12e4"));
- }
-
- public void testBigDecimalNull() throws Exception
- {
- constructReconstructTest(null, BigDecimal.class);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigDecimalUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.math.BigInteger;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataBigIntegerUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataBigIntegerUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataBigIntegerUnitTestCase.class);
- }
-
- public CompositeDataBigIntegerUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testBigInteger() throws Exception
- {
- constructReconstructTest(new BigInteger("123456"));
- }
-
- public void testBigIntegerNull() throws Exception
- {
- constructReconstructTest(null, BigInteger.class);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBigIntegerUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,74 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataBooleanUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataBooleanUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataBooleanUnitTestCase.class);
- }
-
- public CompositeDataBooleanUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testBooleanTrue() throws Exception
- {
- constructReconstructTest(new Boolean(true));
- }
-
- public void testBooleanFalse() throws Exception
- {
- constructReconstructTest(new Boolean(false));
- }
-
- public void testBooleanNull() throws Exception
- {
- constructReconstructTest(null, Boolean.class);
- }
-
- public void testBooleanTruePrimitive() throws Exception
- {
- constructReconstructTest(new Boolean(true), Boolean.TYPE);
- }
-
- public void testBooleanFalsePrimitive() throws Exception
- {
- constructReconstructTest(new Boolean(false), Boolean.TYPE);
- }
-
- public void testBooleanNullPrimitive() throws Exception
- {
- assertNullFailure(Boolean.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataBooleanUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataByteUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataByteUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataByteUnitTestCase.class);
- }
-
- public CompositeDataByteUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testByte() throws Exception
- {
- constructReconstructTest(new Byte(Byte.MAX_VALUE));
- }
-
- public void testByteNull() throws Exception
- {
- constructReconstructTest(null, Byte.class);
- }
-
- public void testBytePrimitive() throws Exception
- {
- constructReconstructTest(Byte.MAX_VALUE, Byte.TYPE);
- }
-
- public void testByteNullPrimitive() throws Exception
- {
- assertNullFailure(Byte.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataByteUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataCharacterUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataCharacterUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataCharacterUnitTestCase.class);
- }
-
- public CompositeDataCharacterUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testCharacter() throws Exception
- {
- constructReconstructTest(new Character(Character.MAX_VALUE));
- }
-
- public void testCharacterNull() throws Exception
- {
- constructReconstructTest(null, Character.class);
- }
-
- public void testCharacterPrimitive() throws Exception
- {
- constructReconstructTest(Character.MAX_VALUE, Character.TYPE);
- }
-
- public void testCharacterNullPrimitive() throws Exception
- {
- assertNullFailure(Character.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCharacterUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,137 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.lang.reflect.Type;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.LinkedHashSet;
-import java.util.List;
-import java.util.Set;
-
-import org.jboss.test.mx.mxbean.support.TestParameterizedType;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataCollectionUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataCollectionUnitTestCase extends CompositeDataTest
-{
- private static final TestParameterizedType COLLECTION_OF_STRINGS = new TestParameterizedType(Collection.class, new Type[] { String.class });
- private static final TestParameterizedType LIST_OF_STRINGS = new TestParameterizedType(List.class, new Type[] { String.class });
- private static final TestParameterizedType SET_OF_STRINGS = new TestParameterizedType(Set.class, new Type[] { String.class });
-
- public static Test suite()
- {
- return new TestSuite(CompositeDataCollectionUnitTestCase.class);
- }
-
- public CompositeDataCollectionUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testCollection() throws Exception
- {
- Collection<String> c = new ArrayList<String>();
- c.add("one");
- c.add("two");
- c.add("three");
- String[] openData = { "one", "two", "three" };
- constructReconstructTest(c, COLLECTION_OF_STRINGS, openData);
- }
-
- public void testCollectionNull() throws Exception
- {
- constructReconstructTest(null, COLLECTION_OF_STRINGS);
- }
-
- public void testCollectionContainsNull() throws Exception
- {
- Collection<String> c = new ArrayList<String>();
- c.add("one");
- c.add(null);
- c.add("three");
- String[] openData = { "one", null, "three" };
- constructReconstructTest(c, COLLECTION_OF_STRINGS, openData);
- }
-
- public void testList() throws Exception
- {
- ArrayList<String> c = new ArrayList<String>();
- c.add("one");
- c.add("two");
- c.add("three");
- String[] openData = { "one", "two", "three" };
- constructReconstructTest(c, LIST_OF_STRINGS, openData);
- }
-
- public void testListNull() throws Exception
- {
- constructReconstructTest(null, LIST_OF_STRINGS);
- }
-
- public void testListContainsNull() throws Exception
- {
- ArrayList<String> c = new ArrayList<String>();
- c.add("one");
- c.add(null);
- c.add("three");
- String[] openData = { "one", null, "three" };
- constructReconstructTest(c, LIST_OF_STRINGS, openData);
- }
-
- public void testSet() throws Exception
- {
- LinkedHashSet<String> c = new LinkedHashSet<String>();
- c.add("one");
- c.add("two");
- c.add("three");
- String[] openData = { "one", "two", "three" };
- constructReconstructTest(c, SET_OF_STRINGS, openData);
- }
-
- public void testSetNull() throws Exception
- {
- constructReconstructTest(null, SET_OF_STRINGS);
- }
-
- public void testSetContainsNull() throws Exception
- {
- LinkedHashSet<String> c = new LinkedHashSet<String>();
- c.add("one");
- c.add(null);
- c.add("three");
- String[] openData = { "one", null, "three" };
- constructReconstructTest(c, SET_OF_STRINGS, openData);
- }
-
- protected void checkOpenDataEquals(Object expected, Object actual)
- {
- checkArrayEquals(expected, actual);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCollectionUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,74 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import javax.management.openmbean.CompositeData;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.jboss.test.mx.mxbean.support.NullSimpleObject;
-import org.jboss.test.mx.mxbean.support.SimpleInterface;
-import org.jboss.test.mx.mxbean.support.SimpleObject;
-
-/**
- * CompositeDataCompositeUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataCompositeUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataCompositeUnitTestCase.class);
- }
-
- public CompositeDataCompositeUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testComposite() throws Exception
- {
- SimpleObject simple = new SimpleObject();
- CompositeData openData = createCompositeData(simple.getClass().getName(), SimpleInterface.KEYS, SimpleInterface.VALUES);
- constructReconstructTest(simple, openData);
- }
-
- public void testCompositeNull() throws Exception
- {
- constructReconstructTest(null, SimpleObject.class);
- }
-
- public void testCompositeContainsNull() throws Exception
- {
- NullSimpleObject simple = new NullSimpleObject();
- CompositeData openData = createCompositeData(simple.getClass().getName(), SimpleInterface.KEYS, SimpleInterface.TYPES, SimpleInterface.LEGAL_NULL_VALUES);
- constructReconstructTest(simple, openData);
- }
-
- protected void checkFinalEquals(Object expected, Object actual)
- {
- checkCompositeDataHandlerEquals(expected, actual);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataCompositeUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.util.Date;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataDateUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataDateUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataDateUnitTestCase.class);
- }
-
- public CompositeDataDateUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDate() throws Exception
- {
- constructReconstructTest(createDate(2001, 1, 1));
- }
-
- public void testDateNull() throws Exception
- {
- constructReconstructTest(null, Date.class);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDateUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataDoubleUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataDoubleUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataDoubleUnitTestCase.class);
- }
-
- public CompositeDataDoubleUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDouble() throws Exception
- {
- constructReconstructTest(new Double(Double.MAX_VALUE));
- }
-
- public void testDoubleNull() throws Exception
- {
- constructReconstructTest(null, Double.class);
- }
-
- public void testDoublePrimitive() throws Exception
- {
- constructReconstructTest(Double.MAX_VALUE, Double.TYPE);
- }
-
- public void testDoubleNullPrimitive() throws Exception
- {
- assertNullFailure(Double.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataDoubleUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import org.jboss.test.mx.mxbean.support.TestEnum;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeTypeEnumUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataEnumUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataEnumUnitTestCase.class);
- }
-
- public CompositeDataEnumUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testEnum() throws Exception
- {
- constructReconstructTest(TestEnum.FIRST, TestEnum.FIRST.name());
- }
-
- public void testEnumNull() throws Exception
- {
- constructReconstructTest(null, TestEnum.class);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataEnumUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataFloatUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataFloatUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataFloatUnitTestCase.class);
- }
-
- public CompositeDataFloatUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testFloat() throws Exception
- {
- constructReconstructTest(new Float(Float.MAX_VALUE));
- }
-
- public void testFloatNull() throws Exception
- {
- constructReconstructTest(null, Float.class);
- }
-
- public void testFloatPrimitive() throws Exception
- {
- constructReconstructTest(Float.MAX_VALUE, Float.TYPE);
- }
-
- public void testFloatNullPrimitive() throws Exception
- {
- assertNullFailure(Float.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataFloatUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataIntegerUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataIntegerUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataIntegerUnitTestCase.class);
- }
-
- public CompositeDataIntegerUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testInteger() throws Exception
- {
- constructReconstructTest(new Integer(Integer.MAX_VALUE));
- }
-
- public void testIntegerNull() throws Exception
- {
- constructReconstructTest(null, Integer.class);
- }
-
- public void testIntegerPrimitive() throws Exception
- {
- constructReconstructTest(Integer.MAX_VALUE, Integer.TYPE);
- }
-
- public void testIntegerNullPrimitive() throws Exception
- {
- assertNullFailure(Integer.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataIntegerUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,361 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import javax.management.openmbean.CompositeData;
-import javax.management.openmbean.InvalidKeyException;
-
-import junit.framework.AssertionFailedError;
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.jboss.mx.mxbean.CompositeDataInvocationHandler;
-import org.jboss.test.mx.mxbean.support.InvalidInterface;
-import org.jboss.test.mx.mxbean.support.SimpleInterface;
-
-/**
- * CompositeDataInvocationHandlerUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataInvocationHandlerUnitTestCase extends AbstractMXBeanTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataInvocationHandlerUnitTestCase.class);
- }
-
- public CompositeDataInvocationHandlerUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testGetCompositeData() throws Exception
- {
- CompositeData compositeData = createTestCompositeData();
- CompositeDataInvocationHandler test = new CompositeDataInvocationHandler(compositeData);
- assertTrue(compositeData == test.getCompositeData());
- }
-
- public void testNullCompositeData() throws Exception
- {
- try
- {
- new CompositeDataInvocationHandler(null);
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowable(IllegalArgumentException.class, t);
- }
- }
-
- public void testToEquals() throws Exception
- {
- SimpleInterface test1 = createTestCompositeDataProxy("Test1");
-
- assertFalse(test1.equals(null));
- assertFalse(test1.equals(new Object()));
- assertTrue(test1.equals(test1));
-
- SimpleInterface test2 = createTestCompositeDataProxy("Test2");
-
- assertFalse(test1.equals(test2));
- }
-
- public void testHashCode() throws Exception
- {
- CompositeData compositeData = createTestCompositeData();
- SimpleInterface test = createCompositeDataProxy(SimpleInterface.class, compositeData);
-
- assertEquals(test.hashCode(), compositeData.hashCode());
- }
-
- public void testToString() throws Exception
- {
- CompositeData compositeData = createTestCompositeData();
- SimpleInterface test = createCompositeDataProxy(SimpleInterface.class, compositeData);
-
- assertEquals(test.toString(), compositeData.toString());
- }
-
- public void testGetSimpleTypes() throws Exception
- {
- SimpleInterface test = createTestCompositeDataProxy();
- assertEquals(SimpleInterface.bigDecimalValue, test.getBigDecimal());
- assertEquals(SimpleInterface.bigIntegerValue, test.getBigInteger());
- assertEquals(SimpleInterface.booleanValue, test.getBoolean());
- assertEquals(SimpleInterface.primitiveBooleanValue, test.isPrimitiveBoolean());
- assertEquals(SimpleInterface.byteValue, test.getByte());
- assertEquals(SimpleInterface.primitiveByteValue, test.getPrimitiveByte());
- assertEquals(SimpleInterface.characterValue, test.getCharacter());
- assertEquals(SimpleInterface.primitiveCharValue, test.getPrimitiveChar());
- assertEquals(SimpleInterface.dateValue, test.getDate());
- assertEquals(SimpleInterface.doubleValue, test.getDouble());
- assertEquals(SimpleInterface.primitiveDoubleValue, test.getPrimitiveDouble());
- assertEquals(SimpleInterface.floatValue, test.getFloat());
- assertEquals(SimpleInterface.primitiveFloatValue, test.getPrimitiveFloat());
- assertEquals(SimpleInterface.integerValue, test.getInteger());
- assertEquals(SimpleInterface.primitiveIntValue, test.getPrimitiveInt());
- assertEquals(SimpleInterface.longValue, test.getLong());
- assertEquals(SimpleInterface.primitiveLongValue, test.getPrimitiveLong());
- assertEquals(SimpleInterface.objectNameValue, test.getObjectName());
- assertEquals(SimpleInterface.shortValue, test.getShort());
- assertEquals(SimpleInterface.primitiveShortValue, test.getPrimitiveShort());
- assertEquals(SimpleInterface.stringValue, test.getString());
- }
-
- public void testNullPrimitives() throws Exception
- {
- SimpleInterface test = createNullCompositeDataProxy();
- assertNull(test.getBigDecimal());
- assertNull(test.getBigInteger());
- assertNull(test.getBoolean());
- try
- {
- test.isPrimitiveBoolean();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getByte());
- try
- {
- test.getPrimitiveByte();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getCharacter());
- try
- {
- test.getPrimitiveChar();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getDate());
- assertNull(test.getDouble());
- try
- {
- test.getPrimitiveDouble();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getFloat());
- try
- {
- test.getPrimitiveFloat();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getInteger());
- try
- {
- test.getPrimitiveInt();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getLong());
- try
- {
- test.getPrimitiveLong();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(test.getObjectName());
- assertNull(test.getShort());
- try
- {
- test.getPrimitiveShort();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- assertNull(SimpleInterface.stringValue, test.getString());
- }
-
- public void testGetInvalid() throws Exception
- {
- InvalidInterface test = createInvalidCompositeDataProxy();
- try
- {
- test.getInvalid();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, InvalidKeyException.class, t);
- }
- }
-
- public void testNotAGetter() throws Exception
- {
- InvalidInterface test = createInvalidCompositeDataProxy();
- try
- {
- test.notAGetter();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- }
-
- public void testGetNoReturnType() throws Exception
- {
- InvalidInterface test = createInvalidCompositeDataProxy();
- try
- {
- test.getString();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- }
-
- public void testGetWithParameters() throws Exception
- {
- InvalidInterface test = createInvalidCompositeDataProxy();
- try
- {
- test.getString(null);
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- }
-
- public void testIsNotBoolean() throws Exception
- {
- InvalidInterface test = createInvalidCompositeDataProxy();
- try
- {
- test.isString();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- }
-
- public void testIsBoolean() throws Exception
- {
- InvalidInterface test = createInvalidCompositeDataProxy();
- try
- {
- test.isBoolean();
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataInvocationHandlerUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataLongUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataLongUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataLongUnitTestCase.class);
- }
-
- public CompositeDataLongUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testLong() throws Exception
- {
- constructReconstructTest(new Long(Long.MAX_VALUE));
- }
-
- public void testLongNull() throws Exception
- {
- constructReconstructTest(null, Long.class);
- }
-
- public void testLongPrimitive() throws Exception
- {
- constructReconstructTest(Long.MAX_VALUE, Long.TYPE);
- }
-
- public void testLongNullPrimitive() throws Exception
- {
- assertNullFailure(Long.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataLongUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,106 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.lang.reflect.Type;
-import java.util.LinkedHashMap;
-import java.util.Map;
-
-import javax.management.openmbean.CompositeDataSupport;
-import javax.management.openmbean.CompositeType;
-import javax.management.openmbean.TabularDataSupport;
-import javax.management.openmbean.TabularType;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.jboss.mx.mxbean.MXBeanUtils;
-import org.jboss.test.mx.mxbean.support.TestParameterizedType;
-
-/**
- * CompositeDataMapUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataMapUnitTestCase extends CompositeDataTest
-{
- private static final TestParameterizedType MAP_OF_STRINGS_TO_INTEGERS = new TestParameterizedType(Map.class, new Type[] { String.class, Integer.class });
- private static final TabularType TABLE_STRING_TO_INTEGER = MXBeanUtils.createMapType(String.class, Integer.class);
-
- public static Test suite()
- {
- return new TestSuite(CompositeDataMapUnitTestCase.class);
- }
-
- public CompositeDataMapUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testMap() throws Exception
- {
- Map<String, Integer> c = new LinkedHashMap<String, Integer>();
- c.put("one", 1);
- c.put("two", 2);
- c.put("three", 3);
- TabularDataSupport openData = new TabularDataSupport(TABLE_STRING_TO_INTEGER);
- CompositeType entryType = TABLE_STRING_TO_INTEGER.getRowType();
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "one", 1 }));
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "two", 2 }));
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "three", 3 }));
- constructReconstructTest(c, MAP_OF_STRINGS_TO_INTEGERS, openData);
- }
-
- public void testMapNull() throws Exception
- {
- constructReconstructTest(null, MAP_OF_STRINGS_TO_INTEGERS);
- }
-
- public void testMapNullKey() throws Exception
- {
- Map<String, Integer> c = new LinkedHashMap<String, Integer>();
- c.put("one", 1);
- c.put(null, 2);
- c.put("three", 3);
- TabularDataSupport openData = new TabularDataSupport(TABLE_STRING_TO_INTEGER);
- CompositeType entryType = TABLE_STRING_TO_INTEGER.getRowType();
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "one", 1 }));
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { null, 2 }));
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "three", 3 }));
- constructReconstructTest(c, MAP_OF_STRINGS_TO_INTEGERS, openData);
- }
-
- public void testMapNullValue() throws Exception
- {
- Map<String, Integer> c = new LinkedHashMap<String, Integer>();
- c.put("one", 1);
- c.put("two", null);
- c.put("three", 3);
- TabularDataSupport openData = new TabularDataSupport(TABLE_STRING_TO_INTEGER);
- CompositeType entryType = TABLE_STRING_TO_INTEGER.getRowType();
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "one", 1 }));
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "two", null }));
- openData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "three", 3 }));
- constructReconstructTest(c, MAP_OF_STRINGS_TO_INTEGERS, openData);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataMapUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,58 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataObjectNameUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataObjectNameUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataObjectNameUnitTestCase.class);
- }
-
- public CompositeDataObjectNameUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testObjectName() throws Exception
- {
- constructReconstructTest(ObjectNameFactory.create("domain:key=property"));
- }
-
- public void testObjectNameNull() throws Exception
- {
- constructReconstructTest(null, ObjectName.class);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataObjectNameUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeDataShortUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataShortUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataShortUnitTestCase.class);
- }
-
- public CompositeDataShortUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testShort() throws Exception
- {
- constructReconstructTest(new Short(Short.MAX_VALUE));
- }
-
- public void testShortNull() throws Exception
- {
- constructReconstructTest(null, Short.class);
- }
-
- public void testShortPrimitive() throws Exception
- {
- constructReconstructTest(Short.MAX_VALUE, Short.TYPE);
- }
-
- public void testShortNullPrimitive() throws Exception
- {
- assertNullFailure(Short.TYPE);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataShortUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,59 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-/**
- * CompositeTypeStringUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeDataStringUnitTestCase extends CompositeDataTest
-{
- public static Test suite()
- {
- return new TestSuite(CompositeDataStringUnitTestCase.class);
- }
-
- public CompositeDataStringUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testString() throws Exception
- {
- constructReconstructTest("Hello");
- }
-
- public void testStringEmpty() throws Exception
- {
- constructReconstructTest("");
- }
-
- public void testStringNull() throws Exception
- {
- constructReconstructTest(null, String.class);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataStringUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,129 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.lang.reflect.Type;
-
-import javax.management.openmbean.OpenType;
-
-import junit.framework.AssertionFailedError;
-
-import org.jboss.mx.mxbean.MXBeanUtils;
-
-/**
- * CompositeDataTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class CompositeDataTest extends AbstractMXBeanTest
-{
- public CompositeDataTest(String name)
- {
- super(name);
- }
-
- protected void constructReconstructTest(Object initialValue) throws Exception
- {
- constructReconstructTest(initialValue, initialValue);
- }
-
- protected void constructReconstructTest(Object initialValue, Type type) throws Exception
- {
- constructReconstructTest(initialValue, type, initialValue);
- }
-
- protected void constructReconstructTest(Object initialValue, Type type, Object expectedOpenData) throws Exception
- {
- constructReconstructTest(initialValue, type, expectedOpenData, initialValue);
- }
-
- protected void assertNullFailure(Type type) throws Exception
- {
- try
- {
- constructReconstructTest(null, type);
- fail("Should not be here");
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- checkThrowable(IllegalArgumentException.class, t);
- }
- }
-
- protected void constructReconstructTest(Object initialValue, Object expectedOpenData) throws Exception
- {
- constructReconstructTest(initialValue, expectedOpenData, initialValue);
- }
-
- protected void constructReconstructTest(Object initialValue, Object expectedOpenData, Object expected) throws Exception
- {
- Type type = initialValue.getClass();
- constructReconstructTest(initialValue, type, expectedOpenData, expected);
- }
-
- protected void constructReconstructTest(Object initialValue, Type type, Object expectedOpenData, Object expected) throws Exception
- {
- OpenType openType = MXBeanUtils.getOpenType(type);
- constructReconstructTest(initialValue, type, openType, expectedOpenData, expected);
- }
-
- protected void constructReconstructTest(Object initialValue, Type type, OpenType openType, Object expectedOpenData, Object expected) throws Exception
- {
- Object openData = construct(openType, type, initialValue);
- checkOpenDataEquals(expectedOpenData, openData);
- if (initialValue != null)
- assertTrue(openData + " is not " + openType, openType.isValue(openData));
-
- Object finalValue = reconstruct(openType, type, openData);
- checkFinalEquals(expected, finalValue);
- }
-
- protected void checkOpenDataEquals(Object expected, Object actual)
- {
- checkEquals(expected, actual);
- }
-
- protected void checkFinalEquals(Object expected, Object actual)
- {
- checkEquals(expected, actual);
- }
-
- protected void checkEquals(Object expected, Object actual)
- {
- assertEquals(expected, actual);
- }
-
- protected Object construct(OpenType openType, Type type, Object value) throws Exception
- {
- return MXBeanUtils.construct(openType, value, getClass().getName() + "#" + getName());
- }
-
- protected Object reconstruct(OpenType openType, Type type, Object openData) throws Exception
- {
- return MXBeanUtils.reconstruct(openType, type, openData, getClass().getName() + "#" + getName());
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeDataTest.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,113 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import javax.management.openmbean.CompositeType;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.jboss.mx.mxbean.CompositeTypeMetaData;
-import org.jboss.mx.mxbean.CompositeTypeMetaDataFactory;
-import org.jboss.test.mx.mxbean.support.CollectionsInterface;
-import org.jboss.test.mx.mxbean.support.CompositeInterface;
-import org.jboss.test.mx.mxbean.support.SimpleInterface;
-import org.jboss.test.mx.mxbean.support.SimpleObject;
-
-/**
- * CompositeTypeMetaDataFactoryUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CompositeTypeMetaDataFactoryUnitTestCase extends AbstractMXBeanTest
-{
- private static final CompositeType OBJECT_TYPE = CompositeTypeMetaData.generateObject();
- private static final CompositeType CLASS_TYPE = CompositeTypeMetaData.generateClass();
- private static final CompositeType CLASSLOADER_TYPE = CompositeTypeMetaData.generateClassLoader();
-
- public static Test suite()
- {
- return new TestSuite(CompositeTypeMetaDataFactoryUnitTestCase.class);
- }
-
- public CompositeTypeMetaDataFactoryUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testGetCompositeDataObject() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(Object.class);
- assertNotNull(type);
- assertEquals(OBJECT_TYPE, type);
- }
-
- public void testGetCompositeDataClass() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(Class.class);
- assertNotNull(type);
- assertEquals(CLASS_TYPE, type);
- }
-
- public void testGetCompositeDataClassLoader() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(ClassLoader.class);
- assertNotNull(type);
- assertEquals(CLASSLOADER_TYPE, type);
- }
-
- public void testSimpleInterfaceCompositeType() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(SimpleInterface.class);
- assertNotNull(type);
- assertEquals(createSimpleCompositeType(SimpleInterface.class), type);
- }
-
- public void testSimpleObjectCompositeType() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(SimpleObject.class);
- assertNotNull(type);
- assertEquals(createSimpleCompositeType(SimpleObject.class), type);
- }
-
- public void testCompositeInterfaceType() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(CompositeInterface.class);
- assertNotNull(type);
- CompositeType expected = createCompositeType(CompositeInterface.class.getName(), CompositeInterface.KEYS, CompositeInterface.TYPES);
- assertEquals(expected, type);
- }
-
- public void testCollectionsInterfaceType() throws Exception
- {
- CompositeType type = CompositeTypeMetaDataFactory.getCompositeType(CollectionsInterface.class);
- assertNotNull(type);
- CompositeType expected = createCompositeType(CollectionsInterface.class.getName(), CollectionsInterface.KEYS, CollectionsInterface.TYPES);
- assertEquals(expected, type);
- }
-
- protected CompositeType createSimpleCompositeType(Class clazz) throws Exception
- {
- return createCompositeType(clazz.getName(), SimpleInterface.KEYS, SimpleInterface.TYPES);
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/CompositeTypeMetaDataFactoryUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,311 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.LinkedHashMap;
-import java.util.LinkedHashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.management.openmbean.OpenMBeanAttributeInfo;
-import javax.management.openmbean.OpenMBeanInfo;
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.jboss.mx.mxbean.MXBeanFactory;
-import org.jboss.mx.mxbean.MXBeanUtils;
-import org.jboss.test.mx.mxbean.support.CollectionsInterface;
-import org.jboss.test.mx.mxbean.support.CollectionsMXBeanSupport;
-import org.jboss.test.mx.mxbean.support.CollectionsMXBeanSupportMXBean;
-import org.jboss.test.mx.mxbean.support.CompositeInterface;
-import org.jboss.test.mx.mxbean.support.CompositeMXBeanSupport;
-import org.jboss.test.mx.mxbean.support.CompositeMXBeanSupportMXBean;
-import org.jboss.test.mx.mxbean.support.SimpleInterface;
-import org.jboss.test.mx.mxbean.support.SimpleMXBeanSupport;
-import org.jboss.test.mx.mxbean.support.SimpleMXBeanSupportMXBean;
-import org.jboss.test.mx.mxbean.support.SimpleObject;
-import org.jboss.test.mx.mxbean.support.TestEnum;
-
-/**
- * MXBeanInvocationHandlerUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanInvocationHandlerUnitTestCase extends AbstractMXBeanTest
-{
- public static Test suite()
- {
- return new TestSuite(MXBeanInvocationHandlerUnitTestCase.class);
- }
-
- public MXBeanInvocationHandlerUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testGetSimpleAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleMXBeanSupport support = new SimpleMXBeanSupport();
- ObjectName objectName = SimpleMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- SimpleMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, SimpleMXBeanSupportMXBean.class);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- OpenType[] types = new OpenType[SimpleInterface.TYPES.length];
- for (int i = 0; i < types.length; ++i)
- types[i] = MXBeanUtils.getOpenType(SimpleInterface.TYPES[i]);
- checkAttributes(SimpleMXBeanSupportMXBean.class, proxy, support, SimpleInterface.KEYS, types, SimpleInterface.VALUES, info);
- }
-
- public void testSetSimpleAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleMXBeanSupport support = new SimpleMXBeanSupport();
- ObjectName objectName = SimpleMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- SimpleMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, SimpleMXBeanSupportMXBean.class);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- OpenType[] types = new OpenType[SimpleInterface.TYPES.length];
- for (int i = 0; i < types.length; ++i)
- types[i] = MXBeanUtils.getOpenType(SimpleInterface.TYPES[i]);
- proxy.setBigDecimal(SimpleInterface.bigDecimalChangedValue);
- proxy.setBigInteger(SimpleInterface.bigIntegerChangedValue);
- proxy.setBoolean(SimpleInterface.booleanChangedValue);
- proxy.setByte(SimpleInterface.byteChangedValue);
- proxy.setCharacter(SimpleInterface.characterChangedValue);
- proxy.setDate(SimpleInterface.dateChangedValue);
- proxy.setDouble(SimpleInterface.doubleChangedValue);
- proxy.setFloat(SimpleInterface.floatChangedValue);
- proxy.setInteger(SimpleInterface.integerChangedValue);
- proxy.setLong(SimpleInterface.longChangedValue);
- proxy.setObjectName(SimpleInterface.objectNameChangedValue);
- proxy.setPrimitiveBoolean(SimpleInterface.primitiveBooleanChangedValue);
- proxy.setPrimitiveByte(SimpleInterface.primitiveByteChangedValue);
- proxy.setPrimitiveChar(SimpleInterface.primitiveCharChangedValue);
- proxy.setPrimitiveDouble(SimpleInterface.primitiveDoubleChangedValue);
- proxy.setPrimitiveFloat(SimpleInterface.primitiveFloatChangedValue);
- proxy.setPrimitiveInt(SimpleInterface.primitiveIntChangedValue);
- proxy.setPrimitiveLong(SimpleInterface.primitiveLongChangedValue);
- proxy.setPrimitiveShort(SimpleInterface.primitiveShortChangedValue);
- proxy.setShort(SimpleInterface.shortChangedValue);
- proxy.setString(SimpleInterface.stringChangedValue);
- checkAttributes(SimpleInterface.class, proxy, support, SimpleInterface.KEYS, types, SimpleInterface.CHANGED_VALUES, info);
- }
-
- public void testSimpleInvoke() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleMXBeanSupport support = new SimpleMXBeanSupport();
- ObjectName objectName = SimpleMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- SimpleMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, SimpleMXBeanSupportMXBean.class);
- assertEquals("olleH", proxy.echoReverse("Hello"));
- }
-
- public void testGetCompositeAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleObject composite = new SimpleObject();
- CompositeMXBeanSupport support = new CompositeMXBeanSupport("Simple", composite);
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- CompositeMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, CompositeMXBeanSupportMXBean.class);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- Object[] values = { "Simple", composite };
- checkAttributes(CompositeMXBeanSupportMXBean.class, proxy, support, CompositeInterface.KEYS, CompositeInterface.TYPES, values, info);
- }
-
- public void testSetCompositeAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleObject composite = new SimpleObject();
- CompositeMXBeanSupport support = new CompositeMXBeanSupport("Simple", composite);
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- CompositeMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, CompositeMXBeanSupportMXBean.class);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- SimpleObject changed = new SimpleObject();
- changed.setBigDecimal(SimpleInterface.bigDecimalChangedValue);
- changed.setBigInteger(SimpleInterface.bigIntegerChangedValue);
- changed.setBoolean(SimpleInterface.booleanChangedValue);
- changed.setByte(SimpleInterface.byteChangedValue);
- changed.setCharacter(SimpleInterface.characterChangedValue);
- changed.setDate(SimpleInterface.dateChangedValue);
- changed.setDouble(SimpleInterface.doubleChangedValue);
- changed.setFloat(SimpleInterface.floatChangedValue);
- changed.setInteger(SimpleInterface.integerChangedValue);
- changed.setLong(SimpleInterface.longChangedValue);
- changed.setObjectName(SimpleInterface.objectNameChangedValue);
- changed.setPrimitiveBoolean(SimpleInterface.primitiveBooleanChangedValue);
- changed.setPrimitiveByte(SimpleInterface.primitiveByteChangedValue);
- changed.setPrimitiveChar(SimpleInterface.primitiveCharChangedValue);
- changed.setPrimitiveDouble(SimpleInterface.primitiveDoubleChangedValue);
- changed.setPrimitiveFloat(SimpleInterface.primitiveFloatChangedValue);
- changed.setPrimitiveInt(SimpleInterface.primitiveIntChangedValue);
- changed.setPrimitiveLong(SimpleInterface.primitiveLongChangedValue);
- changed.setPrimitiveShort(SimpleInterface.primitiveShortChangedValue);
- changed.setShort(SimpleInterface.shortChangedValue);
- changed.setString(SimpleInterface.stringChangedValue);
- proxy.setSimple("Changed");
- proxy.setComposite(changed);
- Object[] values = new Object[] { "Changed", changed };
- checkAttributes(CompositeMXBeanSupportMXBean.class, proxy, support, CompositeInterface.KEYS, CompositeInterface.TYPES, values, info);
- }
-
- public void testCompositeInvoke() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleObject composite = new SimpleObject();
- CompositeMXBeanSupport support = new CompositeMXBeanSupport("Simple", composite);
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- CompositeMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, CompositeMXBeanSupportMXBean.class);
- composite = new SimpleObject();
- composite.setString("hello");
- SimpleInterface result = proxy.echoReverse(composite);
- assertEquals("olleh", result.getString());
- }
-
- public void testGetCollectionAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- String[] array = { "array" };
- Collection<String> collection = new ArrayList<String>();
- collection.add("collection");
- Set<String> set = new HashSet<String>();
- set.add("set");
- List<String> list = new ArrayList<String>();
- list.add("list");
- Map<String, Integer> map = new HashMap<String, Integer>();
- map.put("map", 1);
- TestEnum enumeration = TestEnum.FIRST;
- CollectionsMXBeanSupport support = new CollectionsMXBeanSupport(array, collection, set, list, map, enumeration);
- ObjectName objectName = CollectionsMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- CollectionsMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, CollectionsMXBeanSupportMXBean.class);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- Object[] values = { array, collection, set, list, map, enumeration };
- checkAttributes(CollectionsMXBeanSupportMXBean.class, proxy, support, CollectionsInterface.KEYS, CollectionsInterface.TYPES, values, info);
- }
-
- public void testSetCollectionAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- String[] array = { "array" };
- Collection<String> collection = new ArrayList<String>();
- collection.add("collection");
- Set<String> set = new LinkedHashSet<String>();
- set.add("set");
- List<String> list = new ArrayList<String>();
- list.add("list");
- Map<String, Integer> map = new LinkedHashMap<String, Integer>();
- map.put("map", 1);
- TestEnum enumeration = TestEnum.FIRST;
- CollectionsMXBeanSupport support = new CollectionsMXBeanSupport(array, collection, set, list, map, enumeration);
- ObjectName objectName = CollectionsMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- CollectionsMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, CollectionsMXBeanSupportMXBean.class);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
-
- String[] changedArray = { "arrayChanged" };
- Collection<String> changedCollection = new ArrayList<String>();
- changedCollection.add("collectionChanged");
- Set<String> changedSet = new LinkedHashSet<String>();
- changedSet.add("setChanged");
- List<String> changedList = new ArrayList<String>();
- changedList.add("listChanged");
- Map<String, Integer> changedMap = new LinkedHashMap<String, Integer>();
- changedMap.put("mapChanged", 2);
- TestEnum changedEnumeration = TestEnum.SECOND;
-
- proxy.setArray(changedArray);
- proxy.setCollection(changedCollection);
- proxy.setEnum(changedEnumeration);
- proxy.setList(changedList);
- proxy.setMap(changedMap);
- proxy.setSet(changedSet);
- Object[] changedValues = { changedArray, changedCollection, changedSet, changedList, changedMap, changedEnumeration };
- checkAttributes(CollectionsMXBeanSupportMXBean.class, proxy, support, CollectionsInterface.KEYS, CollectionsInterface.TYPES, changedValues, info);
- }
-
- public void testCollectionInvoke() throws Exception
- {
- MBeanServer server = createMBeanServer();
- CollectionsMXBeanSupport support = new CollectionsMXBeanSupport();
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- CollectionsMXBeanSupportMXBean proxy = MXBeanFactory.makeProxy(server, objectName, CollectionsMXBeanSupportMXBean.class);
- List<String> list = new ArrayList<String>();
- list.add("one");
- list.add("two");
- list.add("three");
- List<String> expected = new ArrayList<String>();
- expected.add("three");
- expected.add("two");
- expected.add("one");
- List<String> result = proxy.echoReverse(list);
- assertEquals(expected, result);
- }
-
- protected void checkAttributes(Class intf, Object proxy, Object mxbean, String[] keys, OpenType[] types, Object[] values, OpenMBeanInfo info) throws Exception
- {
- MBeanAttributeInfo[] attributes = info.getAttributes();
-
- assertEquals(keys.length, values.length);
- assertEquals(keys.length, types.length);
- assertEquals(keys.length, attributes.length);
-
- Map<String, OpenMBeanAttributeInfo> mapping = new HashMap<String, OpenMBeanAttributeInfo>(attributes.length);
- for (int i = 0; i < attributes.length; ++i)
- {
- OpenMBeanAttributeInfo attribute = (OpenMBeanAttributeInfo) attributes[i];
- String name = attribute.getName();
- mapping.put(name, attribute);
- }
-
- for (int i = 0; i < keys.length; ++i)
- {
- String name = getUpperName(keys[i]);
- OpenMBeanAttributeInfo attribute = mapping.get(name);
- assertNotNull("Could not find key " + name + " in " + mapping.keySet(), attribute);
- Method method = MXBeanUtils.getCompositeDataMethod(intf, keys[i], types[i] == SimpleType.BOOLEAN);
- Object value = method.invoke(proxy, null);
- checkValueEquals(values[i], value);
- value = method.invoke(mxbean, null);
- checkValueEquals(values[i], value);
- assertEquals(types[i], attribute.getOpenType());
- }
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanInvocationHandlerUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,371 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.LinkedHashMap;
-import java.util.LinkedHashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.management.openmbean.CompositeData;
-import javax.management.openmbean.CompositeDataSupport;
-import javax.management.openmbean.CompositeType;
-import javax.management.openmbean.OpenMBeanAttributeInfo;
-import javax.management.openmbean.OpenMBeanInfo;
-import javax.management.openmbean.OpenType;
-import javax.management.openmbean.SimpleType;
-import javax.management.openmbean.TabularDataSupport;
-import javax.management.openmbean.TabularType;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
-import org.jboss.mx.mxbean.MXBeanUtils;
-import org.jboss.test.mx.mxbean.support.CollectionsInterface;
-import org.jboss.test.mx.mxbean.support.CollectionsMXBeanSupport;
-import org.jboss.test.mx.mxbean.support.CollectionsMXBeanSupportMXBean;
-import org.jboss.test.mx.mxbean.support.CompositeInterface;
-import org.jboss.test.mx.mxbean.support.CompositeMXBeanSupport;
-import org.jboss.test.mx.mxbean.support.CompositeMXBeanSupportMXBean;
-import org.jboss.test.mx.mxbean.support.SimpleInterface;
-import org.jboss.test.mx.mxbean.support.SimpleMXBeanSupport;
-import org.jboss.test.mx.mxbean.support.SimpleMXBeanSupportMXBean;
-import org.jboss.test.mx.mxbean.support.SimpleObject;
-import org.jboss.test.mx.mxbean.support.TestEnum;
-
-/**
- * MXBeanSupportUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MXBeanSupportUnitTestCase extends AbstractMXBeanTest
-{
- private static final TabularType TABLE_STRING_TO_INTEGER = MXBeanUtils.createMapType(String.class, Integer.class);
-
- public static Test suite()
- {
- return new TestSuite(MXBeanSupportUnitTestCase.class);
- }
-
- public MXBeanSupportUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testGetSimpleAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleMXBeanSupport support = new SimpleMXBeanSupport();
- ObjectName objectName = SimpleMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- OpenType[] types = new OpenType[SimpleInterface.TYPES.length];
- for (int i = 0; i < types.length; ++i)
- types[i] = MXBeanUtils.getOpenType(SimpleInterface.TYPES[i]);
- checkAttributes(server, objectName, SimpleMXBeanSupportMXBean.class, support, SimpleInterface.KEYS, types, SimpleInterface.VALUES, SimpleInterface.VALUES, info);
- }
-
- public void testSetSimpleAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleMXBeanSupport support = new SimpleMXBeanSupport();
- ObjectName objectName = SimpleMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- String[] keys = SimpleInterface.KEYS;
- Object[] values = SimpleInterface.VALUES;
- Object[] changedValues = SimpleInterface.CHANGED_VALUES;
- AttributeList list = new AttributeList(keys.length);
- OpenType[] types = new OpenType[SimpleInterface.TYPES.length];
- for (int i = 0; i < types.length; ++i)
- {
- types[i] = MXBeanUtils.getOpenType(SimpleInterface.TYPES[i]);
- String name = getUpperName(keys[i]);
- server.setAttribute(objectName, new Attribute(name, changedValues[i]));
- Attribute attribute = new Attribute(name, values[i]);
- list.add(attribute);
- }
- checkAttributes(server, objectName, SimpleMXBeanSupportMXBean.class, support, keys, types, SimpleInterface.CHANGED_VALUES, SimpleInterface.CHANGED_VALUES, info);
-
- setAttributes(server, objectName, list);
- checkAttributes(server, objectName, SimpleMXBeanSupportMXBean.class, support, keys, types, SimpleInterface.VALUES, SimpleInterface.VALUES, info);
- }
-
- public void testSimpleInvoke() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleMXBeanSupport support = new SimpleMXBeanSupport();
- ObjectName objectName = SimpleMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- assertEquals("olleH", server.invoke(objectName, "echoReverse", new Object[] { "Hello" }, new String[] { String.class.getName() }));
- }
-
- public void testGetCompositeAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleObject composite = new SimpleObject();
- CompositeMXBeanSupport support = new CompositeMXBeanSupport("Simple", composite);
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- CompositeData data = createCompositeData(SimpleInterface.class.getName(), SimpleInterface.KEYS, SimpleInterface.VALUES);
- Object[] values = { "Simple", data };
- Object[] realValues = { "Simple", composite };
- checkAttributes(server, objectName, CompositeMXBeanSupportMXBean.class, support, CompositeInterface.KEYS, CompositeInterface.TYPES, values, realValues, info);
- }
-
- public void testSetCompositeAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleObject composite = new SimpleObject();
- CompositeMXBeanSupport support = new CompositeMXBeanSupport("Simple", composite);
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- String[] keys = CompositeInterface.KEYS;
- CompositeData data = createCompositeData(SimpleInterface.class.getName(), SimpleInterface.KEYS, SimpleInterface.VALUES);
- Object[] values = { "Simple", data };
- data = createCompositeData(SimpleInterface.class.getName(), SimpleInterface.KEYS, SimpleInterface.CHANGED_VALUES);
- Object[] changedValues = { "Changed", data };
- AttributeList list = new AttributeList(keys.length);
- for (int i = 0; i < keys.length; ++i)
- {
- String name = getUpperName(keys[i]);
- server.setAttribute(objectName, new Attribute(name, changedValues[i]));
- Attribute attribute = new Attribute(name, values[i]);
- list.add(attribute);
- }
- SimpleObject changed = new SimpleObject();
- changed.setBigDecimal(SimpleInterface.bigDecimalChangedValue);
- changed.setBigInteger(SimpleInterface.bigIntegerChangedValue);
- changed.setBoolean(SimpleInterface.booleanChangedValue);
- changed.setByte(SimpleInterface.byteChangedValue);
- changed.setCharacter(SimpleInterface.characterChangedValue);
- changed.setDate(SimpleInterface.dateChangedValue);
- changed.setDouble(SimpleInterface.doubleChangedValue);
- changed.setFloat(SimpleInterface.floatChangedValue);
- changed.setInteger(SimpleInterface.integerChangedValue);
- changed.setLong(SimpleInterface.longChangedValue);
- changed.setObjectName(SimpleInterface.objectNameChangedValue);
- changed.setPrimitiveBoolean(SimpleInterface.primitiveBooleanChangedValue);
- changed.setPrimitiveByte(SimpleInterface.primitiveByteChangedValue);
- changed.setPrimitiveChar(SimpleInterface.primitiveCharChangedValue);
- changed.setPrimitiveDouble(SimpleInterface.primitiveDoubleChangedValue);
- changed.setPrimitiveFloat(SimpleInterface.primitiveFloatChangedValue);
- changed.setPrimitiveInt(SimpleInterface.primitiveIntChangedValue);
- changed.setPrimitiveLong(SimpleInterface.primitiveLongChangedValue);
- changed.setPrimitiveShort(SimpleInterface.primitiveShortChangedValue);
- changed.setShort(SimpleInterface.shortChangedValue);
- changed.setString(SimpleInterface.stringChangedValue);
- Object[] realChangedValues = { "Changed", changed };
- checkAttributes(server, objectName, CompositeMXBeanSupportMXBean.class, support, CompositeInterface.KEYS, CompositeInterface.TYPES, changedValues, realChangedValues, info);
-
- setAttributes(server, objectName, list);
- Object[] realValues = { "Simple", composite };
- checkAttributes(server, objectName, CompositeMXBeanSupportMXBean.class, support, keys, CompositeInterface.TYPES, values, realValues, info);
- }
-
- public void testCompositeInvoke() throws Exception
- {
- MBeanServer server = createMBeanServer();
- SimpleObject composite = new SimpleObject();
- CompositeMXBeanSupport support = new CompositeMXBeanSupport("Simple", composite);
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- composite = new SimpleObject();
- composite.setString("hello");
- CompositeData data = (CompositeData) MXBeanUtils.construct(MXBeanUtils.getOpenType(SimpleInterface.class), composite, getName());
- Object actual = server.invoke(objectName, "echoReverse", new Object[] { data }, new String[] { SimpleInterface.class.getName() });
- composite = new SimpleObject();
- composite.setString("olleh");
- CompositeData expected = (CompositeData) MXBeanUtils.construct(MXBeanUtils.getOpenType(SimpleInterface.class), composite, getName());
- checkValueEquals(expected, actual);
- }
-
- public void testGetCollectionAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- String[] array = { "array" };
- Collection<String> collection = new ArrayList<String>();
- collection.add("collection");
- Set<String> set = new LinkedHashSet<String>();
- set.add("set");
- List<String> list = new ArrayList<String>();
- list.add("list");
- Map<String, Integer> map = new LinkedHashMap<String, Integer>();
- map.put("map", 1);
- TestEnum enumeration = TestEnum.FIRST;
- CollectionsMXBeanSupport support = new CollectionsMXBeanSupport(array, collection, set, list, map, enumeration);
- ObjectName objectName = CollectionsMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
- String[] collectionArray = collection.toArray(new String[collection.size()]);
- String[] setArray = set.toArray(new String[set.size()]);
- String[] listArray = list.toArray(new String[list.size()]);
- TabularDataSupport mapData = new TabularDataSupport(TABLE_STRING_TO_INTEGER);
- CompositeType entryType = TABLE_STRING_TO_INTEGER.getRowType();
- mapData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "map", 1 }));
-
- Object[] values = { array, collectionArray, setArray, listArray, mapData, TestEnum.FIRST.name() };
- Object[] realValues = { array, collection, set, list, map, enumeration };
- checkAttributes(server, objectName, CollectionsMXBeanSupportMXBean.class, support, CollectionsInterface.KEYS, CollectionsInterface.TYPES, values, realValues, info);
- }
-
- public void testSetCollectionAttributes() throws Exception
- {
- MBeanServer server = createMBeanServer();
- String[] array = { "array" };
- Collection<String> collection = new ArrayList<String>();
- collection.add("collection");
- Set<String> set = new LinkedHashSet<String>();
- set.add("set");
- List<String> list = new ArrayList<String>();
- list.add("list");
- Map<String, Integer> map = new LinkedHashMap<String, Integer>();
- map.put("map", 1);
- TestEnum enumeration = TestEnum.FIRST;
- CollectionsMXBeanSupport support = new CollectionsMXBeanSupport(array, collection, set, list, map, enumeration);
- ObjectName objectName = CollectionsMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- OpenMBeanInfo info = (OpenMBeanInfo) server.getMBeanInfo(objectName);
-
- String[] keys = CollectionsInterface.KEYS;
- String[] collectionArray = collection.toArray(new String[collection.size()]);
- String[] setArray = set.toArray(new String[set.size()]);
- String[] listArray = list.toArray(new String[list.size()]);
- TabularDataSupport mapData = new TabularDataSupport(TABLE_STRING_TO_INTEGER);
- CompositeType entryType = TABLE_STRING_TO_INTEGER.getRowType();
- mapData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "map", 1 }));
- Object[] values = { array, collectionArray, setArray, listArray, mapData, TestEnum.FIRST.name() };
-
- String[] changedArray = { "arrayChanged" };
- Collection<String> changedCollection = new ArrayList<String>();
- changedCollection.add("collectionChanged");
- Set<String> changedSet = new LinkedHashSet<String>();
- changedSet.add("setChanged");
- List<String> changedList = new ArrayList<String>();
- changedList.add("listChanged");
-
- String[] changedCollectionArray = changedCollection.toArray(new String[changedCollection.size()]);
- String[] changedSetArray = changedSet.toArray(new String[changedSet.size()]);
- String[] changedListArray = changedList.toArray(new String[changedList.size()]);
- TabularDataSupport changedMapData = new TabularDataSupport(TABLE_STRING_TO_INTEGER);
- changedMapData.put(new CompositeDataSupport(entryType, MXBeanUtils.MAP_ITEM_NAMES, new Object[] { "mapChanged", 2 }));
- Object[] changedValues = { changedArray, changedCollectionArray, changedSetArray, changedListArray, changedMapData, TestEnum.SECOND.name() };
-
- AttributeList attributeList = new AttributeList(keys.length);
- for (int i = 0; i < keys.length; ++i)
- {
- String name = getUpperName(keys[i]);
- server.setAttribute(objectName, new Attribute(name, changedValues[i]));
- Attribute attribute = new Attribute(name, values[i]);
- attributeList.add(attribute);
- }
- Map<String, Integer> changedMap = new LinkedHashMap<String, Integer>();
- changedMap.put("mapChanged", 2);
- Object[] realChangedValues = { changedArray, changedCollection, changedSet, changedList, changedMap, TestEnum.SECOND };
- checkAttributes(server, objectName, CollectionsMXBeanSupportMXBean.class, support, keys, CollectionsInterface.TYPES, changedValues, realChangedValues, info);
-
- setAttributes(server, objectName, attributeList);
- Object[] realValues = { array, collection, set, list, map, enumeration };
- checkAttributes(server, objectName, CollectionsMXBeanSupportMXBean.class, support, keys, CollectionsInterface.TYPES, values, realValues, info);
- }
-
- public void testCollectionInvoke() throws Exception
- {
- MBeanServer server = createMBeanServer();
- CollectionsMXBeanSupport support = new CollectionsMXBeanSupport();
- ObjectName objectName = CompositeMXBeanSupportMXBean.REGISTERED_OBJECT_NAME;
- server.registerMBean(support, objectName);
- String[] list = { "one", "two", "three" };
- String[] expected = { "three", "two", "one" };
- Object result = server.invoke(objectName, "echoReverse", new Object[] { list }, new String[] { List.class.getName() });
- checkArrayEquals(expected, result);
- }
-
- private void checkAttributes(MBeanServer server, ObjectName objectName, Class intf, Object mxbean, String[] keys, OpenType[] types, Object[] values, Object[] realValues, OpenMBeanInfo info) throws Exception
- {
- MBeanAttributeInfo[] attributes = info.getAttributes();
-
- assertEquals(keys.length, values.length);
- assertEquals(keys.length, types.length);
- assertEquals(keys.length, attributes.length);
-
- Map<String, OpenMBeanAttributeInfo> mapping = new HashMap<String, OpenMBeanAttributeInfo>(attributes.length);
- for (int i = 0; i < attributes.length; ++i)
- {
- OpenMBeanAttributeInfo attribute = (OpenMBeanAttributeInfo) attributes[i];
- String name = attribute.getName();
- mapping.put(name, attribute);
- }
-
- String[] attributeNames = new String[keys.length];
-
- for (int i = 0; i < keys.length; ++i)
- {
- String name = getUpperName(keys[i]);
- OpenMBeanAttributeInfo attribute = mapping.get(name);
- assertNotNull("Could not find key " + name + " in " + mapping.keySet(), attribute);
- Object value = server.getAttribute(objectName, name);
- checkValueEquals(values[i], value);
- Method method = MXBeanUtils.getCompositeDataMethod(intf, keys[i], types[i] == SimpleType.BOOLEAN);
- value = method.invoke(mxbean, null);
- checkValueEquals(realValues[i], value);
- assertEquals(types[i], attribute.getOpenType());
- attributeNames[i] = name;
- }
-
- AttributeList list = server.getAttributes(objectName, attributeNames);
- for (int i = 0; i < keys.length; ++i)
- {
- String name = attributeNames[i];
- OpenMBeanAttributeInfo attribute = mapping.get(name);
- Attribute attr = (Attribute) list.get(i);
- checkValueEquals(values[i], attr.getValue());
- assertEquals(types[i], attribute.getOpenType());
- }
- }
-
- private void setAttributes(MBeanServer server, ObjectName objectName, AttributeList list) throws Exception
- {
- AttributeList result = server.setAttributes(objectName, list);
- for (int i = 0; i < list.size(); ++i)
- {
- Attribute attribute = (Attribute) list.get(i);
- Object expected = attribute.getValue();
- attribute = (Attribute) result.get(i);
- Object actual = attribute.getValue();
- checkValueEquals(expected, actual);
- }
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanSupportUnitTestCase.java)
Deleted: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.mx.mxbean.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * MXBean Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 37459 $
- */
-public class MXBeanTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("MXBean Tests");
-
- suite.addTest(CompositeDataInvocationHandlerUnitTestCase.suite());
- suite.addTest(CompositeTypeMetaDataFactoryUnitTestCase.suite());
- suite.addTest(CompositeDataBigDecimalUnitTestCase.suite());
- suite.addTest(CompositeDataBigIntegerUnitTestCase.suite());
- suite.addTest(CompositeDataBooleanUnitTestCase.suite());
- suite.addTest(CompositeDataByteUnitTestCase.suite());
- suite.addTest(CompositeDataCharacterUnitTestCase.suite());
- suite.addTest(CompositeDataDateUnitTestCase.suite());
- suite.addTest(CompositeDataDoubleUnitTestCase.suite());
- suite.addTest(CompositeDataFloatUnitTestCase.suite());
- suite.addTest(CompositeDataIntegerUnitTestCase.suite());
- suite.addTest(CompositeDataLongUnitTestCase.suite());
- suite.addTest(CompositeDataObjectNameUnitTestCase.suite());
- suite.addTest(CompositeDataShortUnitTestCase.suite());
- suite.addTest(CompositeDataStringUnitTestCase.suite());
- suite.addTest(CompositeDataEnumUnitTestCase.suite());
- suite.addTest(CompositeDataArrayUnitTestCase.suite());
- suite.addTest(CompositeDataCollectionUnitTestCase.suite());
- suite.addTest(CompositeDataMapUnitTestCase.suite());
- suite.addTest(CompositeDataCompositeUnitTestCase.suite());
- suite.addTest(MXBeanSupportUnitTestCase.suite());
- suite.addTest(MXBeanInvocationHandlerUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java (from rev 57107, branches/MC_VDF_WORK/mbeans/src/tests/org/jboss/test/mx/mxbean/test/MXBeanTestSuite.java)
Modified: trunk/messaging/.classpath
===================================================================
--- trunk/messaging/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/messaging/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -5,7 +5,9 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/server"/>
<classpathentry kind="src" path="/transaction"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
@@ -13,5 +15,6 @@
<classpathentry kind="src" path="/j2se"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/messaging/build.xml
===================================================================
--- trunk/messaging/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/messaging/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -78,8 +78,12 @@
<!-- The combined depedant module classpath -->
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.naming.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.j2se.classpath"/>
Modified: trunk/messaging/src/etc/server/default/deploy/hsqldb-jdbc2-service.xml
===================================================================
--- trunk/messaging/src/etc/server/default/deploy/hsqldb-jdbc2-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/messaging/src/etc/server/default/deploy/hsqldb-jdbc2-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -33,7 +33,7 @@
name="jboss.mq:service=MessageCache">
<attribute name="HighMemoryMark">50</attribute>
<attribute name="MaxMemoryMark">60</attribute>
- <attribute name="CacheStore">jboss.mq:service=PersistenceManager</attribute>
+ <depends optional-attribute-name="CacheStore">jboss.mq:service=PersistenceManager</depends>
</mbean>
<!--
Modified: trunk/naming/.classpath
===================================================================
--- trunk/naming/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/naming/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,7 +3,9 @@
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="src" path="output/gen-src"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
Modified: trunk/naming/build.xml
===================================================================
--- trunk/naming/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/naming/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -87,7 +87,10 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
</path>
<!-- ===== -->
Modified: trunk/server/.classpath
===================================================================
--- trunk/server/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -4,11 +4,12 @@
<classpathentry kind="src" path="output/gen-src"/>
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/system"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/naming"/>
- <classpathentry kind="src" path="/transaction"/>
<classpathentry kind="lib" path="/thirdparty/apache-bcel/lib/bcel.jar"/>
<classpathentry kind="lib" path="/thirdparty/gjt-jpl-util/lib/jpl-pattern.jar"/>
<classpathentry kind="lib" path="/thirdparty/gjt-jpl-util/lib/jpl-util.jar"/>
@@ -26,5 +27,8 @@
<classpathentry kind="lib" path="/thirdparty/hibernate-entitymanager/lib/ejb3-persistence.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/transaction"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/server/build.xml
===================================================================
--- trunk/server/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -86,6 +86,7 @@
<path refid="sun.servlet.classpath"/>
<path refid="jboss.remoting.classpath"/>
<path refid="jboss.jbossxb.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -97,8 +98,12 @@
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
<path refid="ejb3-persistence.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.mbeans.classpath"/>
<path refid="jboss.naming.classpath"/>
Copied: trunk/server/src/etc/conf/default/deployer-beans.xml (from rev 57107, branches/MC_VDF_WORK/server/src/etc/conf/default/deployer-beans.xml)
Modified: trunk/server/src/etc/conf/default/jboss-minimal.xml
===================================================================
--- trunk/server/src/etc/conf/default/jboss-minimal.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/etc/conf/default/jboss-minimal.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -73,56 +73,4 @@
proxy-type="attribute">jboss.system:service=ThreadPool</depends>
</mbean>
- <!-- ==================================================================== -->
- <!-- Deployment Scanning -->
- <!-- ==================================================================== -->
-
- <!-- An mbean for hot deployment/undeployment of archives.
- -->
- <mbean code="org.jboss.deployment.scanner.URLDeploymentScanner"
- name="jboss.deployment:type=DeploymentScanner,flavor=URL">
-
- <depends optional-attribute-name="Deployer">jboss.system:service=MainDeployer</depends>
-
- <!-- The URLComparator can be used to specify a deployment ordering
- for deployments found in a scanned directory. The class specified
- must be an implementation of java.util.Comparator, it must be able
- to compare two URL objects, and it must have a no-arg constructor.
- Two deployment comparators are shipped with JBoss:
- - org.jboss.deployment.DeploymentSorter
- Sorts by file extension, as follows:
- "sar", "service.xml", "rar", "jar", "war", "wsr", "ear", "zip",
- "*"
- - org.jboss.deployment.scanner.PrefixDeploymentSorter
- If the name portion of the url begins with 1 or more digits, those
- digits are converted to an int (ignoring leading zeroes), and
- files are deployed in that order. Files that do not start with
- any digits will be deployed last, and they will be sorted by
- extension as above with DeploymentSorter.
- -->
- <attribute name="URLComparator">org.jboss.deployment.DeploymentSorter</attribute>
- <!-- The Filter specifies a java.io.FileFilter for scanned
- directories. Any file not accepted by this filter will not be
- deployed. The org.jboss.deployment.scanner.DeploymentFilter
- rejects the following patterns:
- "#*", "%*", ",*", ".*", "_$*", "*#", "*$", "*%", "*.BAK",
- "*.old", "*.orig", "*.rej", "*.bak", "*,v", "*~", ".make.state",
- ".nse_depinfo", "CVS", "CVS.admin", "RCS", "RCSLOG", "SCCS",
- "TAGS", "core", "tags"
- -->
- <attribute name="Filter">org.jboss.deployment.scanner.DeploymentFilter</attribute>
-
- <attribute name="ScanPeriod">5000</attribute>
-
- <!-- URLs are comma seperated and unprefixed arguments are considered
- file URLs and resolve relative to server home(JBOSS_DIST/server/default)
- unless the given path is absolute. Any referenced directories cannot
- be unpackaged archives, use the parent directory of the unpacked
- archive.
- -->
- <attribute name="URLs">
- deploy/
- </attribute>
- </mbean>
-
</server>
Modified: trunk/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- trunk/server/src/etc/conf/default/jboss-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/etc/conf/default/jboss-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -15,6 +15,21 @@
<classpath codebase="${jboss.server.lib.url:lib}" archives="*"/>
<!-- ==================================================================== -->
+ <!-- Main Deployer -->
+ <!-- ==================================================================== -->
+ <mbean code="org.jboss.deployment.MainDeployer"
+ name="jboss.system:service=MainDeployer">
+ </mbean>
+
+ <!-- ==================================================================== -->
+ <!-- SAR Deployer -->
+ <!-- ==================================================================== -->
+ <mbean code="org.jboss.deployment.SARDeployer"
+ name="jboss.system:service=ServiceDeployer">
+ <depends>jboss.system:service=MainDeployer</depends>
+ </mbean>
+
+ <!-- ==================================================================== -->
<!-- JSR-77 Single JBoss Server Management Domain -->
<!-- ==================================================================== -->
<mbean code="org.jboss.management.j2ee.LocalJBossServerDomain"
@@ -33,6 +48,7 @@
<attribute name="JTAService">jboss:service=TransactionManager</attribute>
<attribute name="UserTransactionService">jboss:service=DistributedTransactionManager</attribute>
<attribute name="RMI_IIOPService">jboss:service=CorbaORB</attribute>
+ <depends>jboss.system:service=MainDeployer</depends>
</mbean>
<!-- ==================================================================== -->
@@ -261,6 +277,7 @@
<mbean code="org.jboss.security.plugins.SecurityConfig"
name="jboss.security:service=SecurityConfig">
<attribute name="LoginConfig">jboss.security:service=XMLLoginConfig</attribute>
+ <depends>jboss.security:service=XMLLoginConfig</depends>
</mbean>
<mbean code="org.jboss.security.auth.login.XMLLoginConfig"
name="jboss.security:service=XMLLoginConfig">
@@ -599,101 +616,4 @@
<mbean code="org.jboss.ejb.plugins.cmp.jdbc.metadata.MetaDataLibrary"
name="jboss.jdbc:service=metadata"/>
- <!-- ==================================================================== -->
- <!-- Deployment Scanning -->
- <!-- ==================================================================== -->
-
- <!-- An mbean for hot deployment/undeployment of archives.
- -->
- <mbean code="org.jboss.deployment.scanner.URLDeploymentScanner"
- name="jboss.deployment:type=DeploymentScanner,flavor=URL">
-
- <!-- Uncomment (and comment/remove version below) to enable usage of the
- DeploymentCache
- <depends optional-attribute-name="Deployer">jboss.deployment:type=DeploymentCache</depends>
- -->
- <depends optional-attribute-name="Deployer">jboss.system:service=MainDeployer</depends>
-
- <!-- The URLComparator can be used to specify a deployment ordering
- for deployments found in a scanned directory. The class specified
- must be an implementation of java.util.Comparator, it must be able
- to compare two URL objects, and it must have a no-arg constructor.
- Two deployment comparators are shipped with JBoss:
- - org.jboss.deployment.DeploymentSorter
- Sorts by file extension, as follows:
- "sar", "service.xml", "rar", "jar", "war", "wsr", "ear", "zip",
- "*"
- - org.jboss.deployment.scanner.PrefixDeploymentSorter
- If the name portion of the url begins with 1 or more digits, those
- digits are converted to an int (ignoring leading zeroes), and
- files are deployed in that order. Files that do not start with
- any digits will be deployed first, and they will be sorted by
- extension as above with DeploymentSorter.
- -->
- <attribute name="URLComparator">org.jboss.deployment.DeploymentSorter</attribute>
- <!--
- <attribute name="URLComparator">org.jboss.deployment.scanner.PrefixDeploymentSorter</attribute>
- -->
-
- <!-- The FilterInstance specifies a URLLister.URLFilter for scanned
- directories. This DeploymentFilter is initialized with the given
- prefixes, suffixes and matches that define which URLs should be
- ignored.
- -->
- <attribute name="FilterInstance"
- attributeClass="org.jboss.deployment.scanner.DeploymentFilter"
- serialDataType="javaBean">
- <!-- Files starting with theses strings are ignored -->
- <property name="prefixes">#,%,\,,.,_$</property>
- <!-- Files ending with theses strings are ignored -->
- <property name="suffixes">#,$,%,~,\,v,.BAK,.bak,.old,.orig,.tmp,.rej,.sh</property>
- <!-- Files matching with theses strings are ignored -->
- <property name="matches">.make.state,.nse_depinfo,CVS,CVS.admin,RCS,RCSLOG,SCCS,TAGS,core,tags</property>
- </attribute>
-
- <!-- Frequency in milliseconds to rescan the URLs for changes -->
- <attribute name="ScanPeriod">5000</attribute>
- <!-- A flag to disable the scans -->
- <attribute name="ScanEnabled">true</attribute>
-
- <!-- URLs are comma separated and resolve relative to the server home URL
- unless the given path is absolute. If the URL ends in "/" it is
- considered a collection and scanned, otherwise it is simply deployed;
- this follows RFC2518 convention and allows discrimination between
- collections and directories that are simply unpacked archives.
-
- URLs may be local (file:) or remote (http:). Scanning is supported
- for remote URLs but unpacked deployment units are not.
-
- Example URLs:
- deploy/
- scans ${jboss.server.url}/deploy/, which is local or remote
- depending on the URL used to boot the server
- ${jboss.server.home}/deploy/
- scans ${jboss.server.home)/deploy, which is always local
- file:/var/opt/myapp.ear
- deploy myapp.ear from a local location
- file:/var/opt/apps/
- scans the specified directory
- http://www.test.com/netboot/myapp.ear
- deploys myapp.ear from a remote location
- http://www.test.com/netboot/apps/
- scans the specified WebDAV location
- -->
- <attribute name="URLs">
- deploy/
- </attribute>
-
- <!-- Indicates if the scanner should recursively scan directories that
- contain no "." in their names. This can be used to group applications
- and services that must be deployed and that have the same
- logical function in the same directory i.e.
- deploy/JMX/
- deploy/JMS/
- ...
- -->
- <attribute name="RecursiveSearch">True</attribute>
-
- </mbean>
-
</server>
Modified: trunk/server/src/etc/deploy/bsh-deployer.xml
===================================================================
--- trunk/server/src/etc/deploy/bsh-deployer.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/etc/deploy/bsh-deployer.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -8,5 +8,6 @@
-->
<mbean code="org.jboss.varia.deployment.BeanShellSubDeployer"
name="jboss.deployer:service=BSHDeployer">
+ <depends>jboss.system:service=MainDeployer</depends>
</mbean>
</server>
Modified: trunk/server/src/etc/deploy/ear-deployer.xml
===================================================================
--- trunk/server/src/etc/deploy/ear-deployer.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/etc/deploy/ear-deployer.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -15,5 +15,6 @@
optimization disabled.
-->
<attribute name="CallByValue">false</attribute>
+ <depends>jboss.system:service=MainDeployer</depends>
</mbean>
</server>
Modified: trunk/server/src/etc/deploy/ejb-deployer.xml
===================================================================
--- trunk/server/src/etc/deploy/ejb-deployer.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/etc/deploy/ejb-deployer.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -293,6 +293,7 @@
<depends optional-attribute-name="TransactionManagerServiceName">jboss:service=TransactionManager</depends>
<!-- The dynamic class loading simple web server -->
<depends optional-attribute-name="WebServiceName">jboss:service=WebService</depends>
+ <depends>jboss.system:service=MainDeployer</depends>
</mbean>
Modified: trunk/server/src/resources/client-deployer/client-deployer-service.xml
===================================================================
--- trunk/server/src/resources/client-deployer/client-deployer-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/resources/client-deployer/client-deployer-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -5,7 +5,8 @@
<server>
<mbean code="org.jboss.deployment.ClientDeployer"
name="jboss.j2ee:service=ClientDeployer"
- xmbean-dd="client-deployer-xmbean.xml" />
+ xmbean-dd="client-deployer-xmbean.xml">
+ <depends>jboss.system:service=MainDeployer</depends>
<!--
<xmbean>
<description>The J2EE Application Client Deployer</description>
@@ -41,7 +42,7 @@
<name>destroy</name>
</operation>
</xmbean>
+ -->
</mbean>
- -->
</server>
Modified: trunk/server/src/resources/jmx-invoker-adaptor/META-INF/jboss-service.xml
===================================================================
--- trunk/server/src/resources/jmx-invoker-adaptor/META-INF/jboss-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/resources/jmx-invoker-adaptor/META-INF/jboss-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -38,6 +38,7 @@
<mbean code="org.jboss.naming.NamingAlias" name="jboss.jmx:alias=jmx/rmi/RMIAdaptor">
<attribute name="FromName">jmx/rmi/RMIAdaptor</attribute>
<attribute name="ToName">jmx/invoker/RMIAdaptor</attribute>
+ <depends>jboss:service=Naming</depends>
</mbean>
<!-- This is the service that handles the RMIAdaptor invocations by routing
Modified: trunk/server/src/resources/uuid-key-generator/META-INF/jboss-service.xml
===================================================================
--- trunk/server/src/resources/uuid-key-generator/META-INF/jboss-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/server/src/resources/uuid-key-generator/META-INF/jboss-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -11,6 +11,7 @@
<!-- UUIDKeyGeneratorFactoryService -->
<mbean code="org.jboss.ejb.plugins.keygenerator.uuid.UUIDKeyGeneratorFactoryService"
name="jboss:service=KeyGeneratorFactory,type=UUID">
+ <depends>jboss:service=Naming</depends>
</mbean>
<!-- HiLoKeyGeneratorFactory -->
Modified: trunk/spring-int/.classpath
===================================================================
--- trunk/spring-int/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/spring-int/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -5,7 +5,9 @@
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry combineaccessrules="false" kind="src" path="/system"/>
<classpathentry combineaccessrules="false" kind="src" path="/j2se"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry combineaccessrules="false" kind="src" path="/server"/>
<classpathentry kind="lib" path="/thirdparty/spring/lib/spring-beans.jar"/>
<classpathentry kind="lib" path="/thirdparty/spring/lib/spring-core.jar"/>
@@ -22,5 +24,7 @@
<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-microcontainer.jar"/>
<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/spring-int/build.xml
===================================================================
--- trunk/spring-int/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/spring-int/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -98,6 +98,7 @@
<path refid="jboss.kernel.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
</path>
<!-- Where source files live -->
Modified: trunk/system/.classpath
===================================================================
--- trunk/system/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -5,18 +5,20 @@
<classpathentry output="output/eclipse-test-classes" kind="src" path="src/tests-support"/>
<classpathentry kind="lib" path="src/resources/tests"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
<classpathentry kind="lib" path="/thirdparty/gnu-getopt/lib/getopt.jar"/>
<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
- <classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
- <classpathentry kind="src" path="/j2se"/>
- <classpathentry kind="src" path="/mbeans"/>
<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-dependency.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-microcontainer.jar"/>
<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-jdk/lib/jboss-logging-jdk-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/xercesImpl.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Deleted: trunk/system/.cvsignore
===================================================================
--- trunk/system/.cvsignore 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/.cvsignore 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,2 +0,0 @@
-output
-build.log
Modified: trunk/system/.project
===================================================================
--- trunk/system/.project 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/.project 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,8 +3,6 @@
<name>system</name>
<comment></comment>
<projects>
- <project>common</project>
- <project>jmx</project>
<project>test</project>
</projects>
<buildSpec>
Modified: trunk/system/build-test.xml
===================================================================
--- trunk/system/build-test.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/build-test.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -85,7 +85,10 @@
<path refid="apache.log4j.classpath" />
<path refid="oswego.concurrent.classpath" />
<path refid="jboss.jbossxb.classpath" />
- <path refid="jboss.common.classpath" />
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.profiler.jvmti.classpath" />
</path>
Modified: trunk/system/build.xml
===================================================================
--- trunk/system/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -2,7 +2,6 @@
<!DOCTYPE project [
<!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
<!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
- <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
<!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
]>
@@ -70,25 +69,16 @@
<path refid="junit.junit.classpath"/>
<path refid="gnu.getopt.classpath"/>
<path refid="apache.xerces.classpath"/>
- <path refid="apache.log4j.classpath"/>
- <path refid="apache.commons.classpath"/>
<path refid="oswego.concurrent.classpath"/>
<path refid="dom4j.dom4j.classpath"/>
<path refid="jboss.jbossxb.classpath"/>
<path refid="jboss.microcontainer.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
</path>
- <!-- ======= -->
- <!-- Modules -->
- <!-- ======= -->
-
- &modules;
-
<!-- The combined dependant module classpath -->
<path id="dependentmodule.classpath">
- <path refid="jboss.common.classpath"/>
- <path refid="jboss.j2se.classpath"/>
- <path refid="jboss.mbeans.classpath"/>
</path>
<!-- ===== -->
@@ -143,9 +133,6 @@
| Build all jar files.
-->
<target name="module-jars" >
-
- <!-- Server and client jars -->
- <call target="_default:server-client-jars"/>
<!--
| Build log4j-boot.jar This is a minimal subset of the log4j
@@ -171,6 +158,10 @@
<include name="dtd/**"/>
</fileset>
</jar>
+
+ <jar jarfile="${build.lib}/${jar.client.name}" manifest="${build.etc}/default.mf">
+ <fileset dir="${build.classes}" includes="${jar.client.includes}"/>
+ </jar>
<!-- Build jboss-boot.jar -->
<jar jarfile="${build.lib}/jboss-boot.jar" manifest="${build.etc}/default.mf">
Modified: trunk/system/src/main/org/jboss/Main.java
===================================================================
--- trunk/system/src/main/org/jboss/Main.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/Main.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -50,6 +50,7 @@
* <pre>
* ./run.sh -Dlog4j.configuration=log4j-debug.properties
* </pre>
+ * TODO: Should jdk logging be the default
*
* @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
* @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
@@ -59,9 +60,6 @@
*/
public class Main
{
- /** The JMX library to use. */
- private String jmxLibs = "jboss-j2se.jar,jboss-mbeans.jar,jboss-jmx.jar,dom4j.jar,jaxen.jar";
-
/** EDU.oswego.cs.dl.util.concurrent */
private String concurrentLib = "concurrent.jar";
@@ -184,7 +182,7 @@
loader.addEndorsedJars();
// Add jmx libs
- loader.addLibraries(jmxLibs);
+ //loader.addLibraries(jmxLibs);
// jmx UnifiedLoaderRepository needs a concurrent class...
loader.addLibrary(concurrentLib);
Modified: trunk/system/src/main/org/jboss/Version.java
===================================================================
--- trunk/system/src/main/org/jboss/Version.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/Version.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -270,9 +270,11 @@
{
InputStream in =
Version.class.getResourceAsStream("/org/jboss/version.properties");
-
- props.load(in);
- in.close();
+ if( in != null )
+ {
+ props.load(in);
+ in.close();
+ }
}
catch (IOException e)
{
Copied: trunk/system/src/main/org/jboss/deployers (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/deployers)
Copied: trunk/system/src/main/org/jboss/deployers/spi (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi)
Copied: trunk/system/src/main/org/jboss/deployers/spi/management (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management)
Deleted: trunk/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java
===================================================================
--- branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,68 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployers.spi.management;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.jboss.profileservice.spi.PropertyInfo;
-
-/**
- * A collection of the properties making up a deployment managed object
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class ManagedObject
- implements Serializable
-{
- private static final long serialVersionUID = 1;
-
- private ArrayList<PropertyInfo> properties = new ArrayList<PropertyInfo>();
-
- public ManagedObject()
- {
- }
-
- public List<PropertyInfo> getProperties()
- {
- return properties;
- }
-
- public boolean addPropertyRef(PropertyInfo ref)
- {
- return properties.add(ref);
- }
- public boolean removePropertyRef(PropertyInfo ref)
- {
- return properties.remove(ref);
- }
- public int getSize()
- {
- return properties.size();
- }
- public void clear()
- {
- properties.clear();
- }
-}
Copied: trunk/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management/ManagedObject.java)
Deleted: trunk/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java
===================================================================
--- branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,120 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployers.spi.management;
-
-/**
- * A management view wrapper of a bean property.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class ManagedPropertyRef
-{
- /**
- * A namespace context that maps the managed property onto a managed view
- * context (e.g., /, /DataSource, /DataSource/Pool).
- */
- private String context;
- /**
- * The DeploymentBean name which sources the property
- * @return
- */
- private String beanName;
- /**
- * The DeploymentBean property name
- */
- private String propertyName;
- /**
- * An option management view description of the property
- */
- private String description;
-
- /**
- * Create a managed property ref for the indicated bean property.
- * @param context
- * @param beanName
- * @param propertyName
- * @param description
- */
- public ManagedPropertyRef(String context, String beanName,
- String propertyName, String description)
- {
- this.context = context;
- this.beanName = beanName;
- this.propertyName = propertyName;
- this.description = description;
- }
-
- /**
- * @return Returns the beanName.
- */
- public String getBeanName()
- {
- return this.beanName;
- }
-
- /**
- * @return Returns the context.
- */
- public String getContext()
- {
- return this.context;
- }
-
- /**
- * @return Returns the description.
- */
- public String getDescription()
- {
- return this.description;
- }
-
- /**
- * @return Returns the propertyName.
- */
- public String getPropertyName()
- {
- return this.propertyName;
- }
-
- /**
- * Equality based on beanName + propertyName
- */
- public boolean equals(Object obj)
- {
- ManagedPropertyRef ref = (ManagedPropertyRef) obj;
- boolean equals = beanName.equals(ref.beanName);
- if( equals )
- {
- equals = propertyName.equals(ref.propertyName);
- }
- return equals;
- }
-
- /**
- * Hash based on beanName + propertyName
- */
- public int hashCode()
- {
- return beanName.hashCode() + propertyName.hashCode();
- }
-}
Copied: trunk/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management/ManagedPropertyRef.java)
Deleted: trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java
===================================================================
--- branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management/ManagementView.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,52 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-
-package org.jboss.deployers.spi.management;
-
-import org.jboss.profileservice.spi.NoSuchDeploymentException;
-import org.jboss.profileservice.spi.ProfileKey;
-import org.jboss.profileservice.spi.NoSuchProfileException;
-
-/**
- * The management view plugin spi for querying profiles for the
- * deployemnt management object interface roots.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public interface ManagementView
-{
- /**
- * Obtain the top-level management view for a deployment. This is
- * done by identifying all DeploymentBeans annotated with
- * @link{org.jboss.annotation.management.ManagedObject}
- *
- * @param key - the profile containing the deployment
- * @param deploymentName - the name of deployment
- * @return the root management view
- * @throws NoSuchProfileException
- * @throws NoSuchDeploymentException
- */
- public ManagedObject getView(ProfileKey key, String deploymentName)
- throws NoSuchProfileException, NoSuchDeploymentException;
-
-}
Copied: trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/deployers/spi/management/ManagementView.java)
Added: trunk/system/src/main/org/jboss/profileservice/spi/ArrayType.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ArrayType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ArrayType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,56 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+
+public class ArrayType<T>
+ extends OpenType<T>
+{
+ private int dimension;
+ private OpenType<?> elementType;
+
+ public ArrayType(int dimension, OpenType<?> elementType)
+ {
+ super(elementType.getClassName(), elementType.getClassName(),
+ "Array of: "+elementType.getClassName());
+ this.dimension = dimension;
+ this.elementType = elementType;
+ }
+
+ public int getDimension()
+ {
+ return dimension;
+ }
+ public OpenType<?> getElementOpenType()
+ {
+ return elementType;
+ }
+ public boolean isValue(Object value)
+ {
+ return false;
+ }
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/CompositeData.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/CompositeData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/CompositeData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+import java.util.Collection;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+
+public interface CompositeData
+{
+ public CompositeType getCompositeType();
+ public Object get(String key);
+ public Object[] getAll(String[] keys);
+ public boolean containsKey(String key);
+ public boolean containsValue(Object value);
+ public Collection<?> values();
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/CompositeType.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/CompositeType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/CompositeType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+import java.util.Set;
+import java.util.HashSet;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+
+public class CompositeType<T>
+ extends OpenType<T>
+{
+ public CompositeType(String typeName, String description,
+ String[] itemNames, String[] itemDescriptions, OpenType<T>[] itemTypes)
+ {
+ super(CompositeData.class.getName(), typeName, description);
+ }
+ public String getDescription(String itemName)
+ {
+ return null;
+ }
+ public boolean containsKey(String itemName)
+ {
+ return false;
+ }
+ public OpenType<?> getType(String itemName)
+ {
+ return null;
+ }
+ public Set<String> keySet()
+ {
+ return new HashSet<String>();
+ }
+ public boolean isValue(Object obj)
+ {
+ return false;
+ }
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/DeploymentTemplate.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/DeploymentTemplate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/DeploymentTemplate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+import java.util.Set;
+
+import org.jboss.deployers.spi.structure.DeploymentContext;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+
+public interface DeploymentTemplate
+{
+ String getName();
+ Set<PropertyInfo> getProperties();
+ DeploymentContext expand(Set<PropertyInfo> values);
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/NoSuchDeploymentException.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/NoSuchDeploymentException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/NoSuchDeploymentException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,48 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.profileservice.spi;
+
+/**
+ * An exception thrown when there is no matching deployment.
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class NoSuchDeploymentException extends Exception
+{
+ private static final long serialVersionUID = 1;
+
+ public NoSuchDeploymentException()
+ {
+ }
+
+ public NoSuchDeploymentException(String msg)
+ {
+ super(msg);
+ }
+
+ public NoSuchDeploymentException(String msg, Throwable cause)
+ {
+ super(msg, cause);
+ }
+
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/NoSuchProfileException.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/NoSuchProfileException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/NoSuchProfileException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+/**
+ * Exception thrown when a profile query failes to find a match.
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class NoSuchProfileException extends Exception
+{
+ /** The serialVersionUID */
+ private static final long serialVersionUID = 461561859030090797L;
+
+ public NoSuchProfileException(String message)
+ {
+ super(message);
+ }
+
+ public NoSuchProfileException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
+ public NoSuchProfileException(Throwable cause)
+ {
+ super(cause);
+ }
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/OpenType.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/OpenType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/OpenType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,56 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+
+public abstract class OpenType<T>
+{
+ private String className;
+ private String typeName;
+ private String description;
+ protected OpenType(String className, String typeName, String description)
+ {
+ this.className = className;
+ this.typeName = typeName;
+ this.description = description;
+ }
+
+ public String getClassName()
+ {
+ return className;
+ }
+ public String getTypeName()
+ {
+ return typeName;
+ }
+ public String getDescription()
+ {
+ return description;
+ }
+
+ public abstract boolean isValue(Object value);
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/Profile.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/Profile.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/Profile.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,149 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.profileservice.spi;
+
+import java.util.Collection;
+import java.util.Map;
+
+import org.jboss.deployers.spi.structure.DeploymentContext;
+
+/**
+ * A profile represents a named collection of deployments on a server
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public interface Profile
+{
+ /**
+ * The x.y.z version of the profile
+ *
+ * @return the version
+ */
+ String getVersion();
+
+ /**
+ * Get a deployment template.
+ *
+ * @param name - the deployment name to identify the template to retrieve
+ * @return the named DeploymentTemplate
+ * @throws NoSuchDeploymentException - if there is no such deployment
+ */
+ DeploymentTemplate getTemplate(String name) throws NoSuchDeploymentException;
+
+ /**
+ * Add a bootstrap
+ *
+ * @param d the bootstrap
+ */
+ void addBootstrap(DeploymentContext d);
+
+ /**
+ * Remove a bootstrap
+ *
+ * @param name the name
+ */
+ void removeBootstrap(String name);
+
+ /**
+ * Get a named bootstrap.
+ *
+ * @param name - the bootstrap name
+ * @return the named bootstrap
+ * @throws NoSuchDeploymentException - if there is no such bootstrap
+ */
+ DeploymentContext getBootstrap(String name) throws NoSuchDeploymentException;
+
+ /**
+ * Get all bootstraps defined in this profile
+ *
+ * @return the bootstrap instances in this profile.
+ */
+ Collection<DeploymentContext> getBootstraps();
+
+ /**
+ * Add a deployer
+ *
+ * @param d the deployer
+ */
+ void addDeployer(DeploymentContext d);
+
+ /**
+ * Remove a deployer
+ *
+ * @param name the name
+ */
+ void removeDeployer(String name);
+
+ /**
+ * Get a named deployer.
+ *
+ * @param name - the deployer name
+ * @return the named Deployer
+ * @throws NoSuchDeploymentException - if there is no such deployer
+ */
+ DeploymentContext getDeployer(String name) throws NoSuchDeploymentException;
+
+ /**
+ * Get all deployer defined in this profile
+ *
+ * @return the deployer instances in this profile.
+ */
+ Collection<DeploymentContext> getDeployers();
+
+ /**
+ * Add a deployment
+ *
+ * @param d the deployment
+ */
+ void addDeployment(DeploymentContext d);
+
+ /**
+ * Remove a deployment
+ *
+ * @param name the name
+ */
+ void removeDeployment(String name);
+
+ /**
+ * Get a named deployment.
+ *
+ * @param name - the deployment name
+ * @return the named Deployment
+ * @throws NoSuchDeploymentException - if there is no such deployment
+ */
+ DeploymentContext getDeployment(String name) throws NoSuchDeploymentException;
+
+ /**
+ * Get all deployments defined in this profile
+ *
+ * @return the deployment instances in this profile.
+ */
+ Collection<DeploymentContext> getDeployments();
+
+ /**
+ * Get the config
+ *
+ * @return the config
+ */
+ Map<String, Object> getConfig();
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/ProfileConfiguration.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ProfileConfiguration.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ProfileConfiguration.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+/**
+ * The configuration of the deployments that make up a profile
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public interface ProfileConfiguration
+{
+ public Profile getProfile();
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,85 @@
+package org.jboss.profileservice.spi;
+
+import java.io.Serializable;
+
+/**
+ * The key for a Profile. It consists fo the domain, server and name.
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class ProfileKey
+ implements Comparable, Serializable
+{
+ private static final long serialVersionUID = 1;
+ /** The DEFAULT value for domain, server, name */
+ public static final String DEFAULT = "default";
+
+ /** The profile domain/cluster */
+ private String domain;
+ /** The server/node */
+ private String server;
+ /** The profile name */
+ private String name;
+
+ /**
+ * Calls this this(DEFAULT, DEFAULT, name)
+ * @param name - the profile name
+ */
+ public ProfileKey(String name)
+ {
+ this(DEFAULT, DEFAULT, name);
+ }
+
+ /**
+ * Build a profile key from the domain, server and name. If any parameter
+ * is null it defaulted to "default".
+ *
+ * @param domain - the admin domain
+ * @param server - the server instance name
+ * @param name - the profile name
+ */
+ public ProfileKey(String domain, String server, String name)
+ {
+ if( domain == null )
+ domain = DEFAULT;
+ this.domain = domain;
+ if( server == null )
+ server = DEFAULT;
+ this.server = server;
+ if( name == null )
+ name = DEFAULT;
+ this.name = name;
+ }
+
+ /**
+ * Compare based on domain, then server and finally name.
+ *
+ * @param o - the ProfileKey instance to compare to
+ * @return < 0, 0, > 0 based on whether this is less than, equal to
+ * or greater than o.
+ */
+ public int compareTo(Object o)
+ {
+ ProfileKey pk = (ProfileKey) o;
+ int compareTo = domain.compareTo(pk.domain);
+ if( compareTo == 0 )
+ {
+ compareTo = server.compareTo(pk.server);
+ if( compareTo == 0 )
+ {
+ compareTo = name.compareTo(pk.name);
+ }
+ }
+ return compareTo;
+ }
+ public boolean equals(Object o)
+ {
+ return compareTo(o) == 0;
+ }
+ public int hashCode()
+ {
+ int hash = domain.hashCode() + server.hashCode() + name.hashCode();
+ return hash;
+ }
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,81 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+import org.jboss.deployers.spi.management.ManagementView;
+
+/**
+ * The entry point service for accessing/administiring server profiles
+ *
+ * @todo this should be broken up into different feature plugin services
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public interface ProfileService
+{
+ // Querying profiles
+
+ /**
+ * Get the unique domains for which profiles exist
+ * @return array of profile domains
+ */
+ public String[] getDomains();
+
+ /**
+ * Get the keys for all known profiles
+ * @return keys for all known profiles
+ */
+ public ProfileKey[] getProfileKeys();
+
+ /**
+ * Obtain the profile for the key.
+ *
+ * @param key - the key for the profile
+ * @return the matching profile.
+ * @throws NoSuchProfileException
+ */
+ public Profile getProfile(ProfileKey key)
+ throws NoSuchProfileException;
+
+ /**
+ * Get a list of the deployment names associated with a profile.
+ * @param key - the key for the profile
+ * @return the list of deployment names.
+ * @throws NoSuchProfileException
+ */
+ public String[] getProfileDeploymentNames(ProfileKey key)
+ throws NoSuchProfileException;
+
+ /**
+ * Obtain the ManagementView plugin
+ * @return the ManagementView plugin if supported
+ */
+ public ManagementView getViewManager();
+
+ // Admin of profiles @todo could be an option plugin
+ public Profile newProfile(ProfileKey key);
+ public void removeProfile(ProfileKey key)
+ throws NoSuchProfileException;
+
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/PropertyInfo.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/PropertyInfo.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/PropertyInfo.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+import java.util.Set;
+
+/**
+ * Modelled after the JMX OpenMBeanParameterInfo
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public interface PropertyInfo
+{
+ public String getName();
+ public String getDescription();
+ public Set<?> getLegalValues();
+ public Comparable<?> getMinValue();
+ public Comparable<?> getMaxValue();
+ public boolean isValue(Object obj);
+ public OpenType<?> getOpenType();
+ public Object getFieldValue(String fieldName);
+ public void setFields(String[] fieldNames, Object[] fieldValues);
+
+ /**
+ * Get the current property value. Must interact with the
+ * Policy somehow.
+ * @return current property value.
+ */
+ public Object getValue();
+
+ /**
+ * Set the current property value. Must interact with the
+ * Policy somehow.
+ * @param value - current property value.
+ */
+ public void setValue(Object value);
+}
Added: trunk/system/src/main/org/jboss/profileservice/spi/SimpleType.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/SimpleType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/profileservice/spi/SimpleType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,47 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.profileservice.spi;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+
+public final class SimpleType<T>
+ extends OpenType<T>
+{
+ public static final SimpleType<Void> VOID = new SimpleType<Void>(Void.class);
+
+ public static final SimpleType<String> STRING = new SimpleType<String>(String.class);
+
+ public static final SimpleType<Boolean> BOOLEAN = new SimpleType<Boolean>(Boolean.class);
+
+ private SimpleType(Class<T> valueClass)
+ {
+ super(valueClass.getName(), valueClass.getName(), valueClass.getName());
+ }
+ public boolean isValue(Object obj)
+ {
+ return false;
+ }
+}
Deleted: trunk/system/src/main/org/jboss/system/BarrierController.java
===================================================================
--- trunk/system/src/main/org/jboss/system/BarrierController.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/BarrierController.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,396 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.Notification;
-import javax.management.ObjectName;
-
-/**
- * BarrierController service.
- *
- * A service that controls the lifecycle of a secondary mbean
- * (the BarrierMbean) that can be used as a dependency for other
- * services.
- *
- * Starting and stopping the barrier mbean (and as a result
- * all services depending on it) is performed by listening
- * for any kind of JMX notification. In particular we use
- * the handback object of a notification subscription to
- * qualify the start and stop signals.
- *
- * Manual control of the barrier is also supported through
- * startBarrier()/stopBarrier() methods.
- *
- * You may subclass BarrierController and override enableOnStartup()
- * to apply complex logic in deciding whether to initially start
- * the barrier (e.g. query some other mbean).
- *
- * @jmx:mbean
- * extends="org.jboss.system.ListenerServiceMBean"
- * name="jboss:service=BarrierController"
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class BarrierController extends ListenerServiceMBeanSupport
- implements BarrierControllerMBean
-{
- // Private Data --------------------------------------------------
-
- /** The ObjectName of the Barrier MBean */
- private ObjectName barrierName;
-
- /** The initial state of the barrier */
- private Boolean enableOnStartup;
-
- /** The notification subscription handback string that starts the barrier */
- private String startHandback;
-
- /** The notification subscription handback string that stops the barrier */
- private String stopHandback;
-
- /** The dynamic subscriptions flag */
- private Boolean dynamicSubscriptions;
-
- // Protected Data ------------------------------------------------
-
- /** The controlled Barrier */
- protected Barrier barrier;
-
- // Constructors --------------------------------------------------
-
- /**
- * Default CTOR
- */
- public BarrierController()
- {
- // empty
- }
-
- // Attributes ----------------------------------------------------
-
- /**
- * The controlled barrier StateString.
- *
- * @jmx.managed-attribute
- */
- public String getBarrierStateString()
- {
- return (barrier != null) ? barrier.getStateString() : null;
- }
-
- /**
- * The controlled barrier ObjectName.
- *
- * @jmx.managed-attribute
- */
- public void setBarrierObjectName(ObjectName barrierName)
- {
- // set once
- if (this.barrierName == null)
- {
- this.barrierName = barrierName;
- }
- }
-
- /**
- * The controlled barrier ObjectName.
- *
- * @jmx.managed-attribute
- */
- public ObjectName getBarrierObjectName()
- {
- return barrierName;
- }
-
-
- /**
- * The initial state of the barrier.
- *
- * If set, it overrides the internal call to enableOnStartup()
- * which will never get called.
- *
- * @jmx.managed-attribute
- */
- public void setBarrierEnabledOnStartup(Boolean enableOnStartup)
- {
- // set once
- if (this.enableOnStartup == null)
- {
- this.enableOnStartup = enableOnStartup;
- }
- }
-
- /**
- * The initial state of the barrier.
- *
- * Use the value set through setBarrierEnabledOnStartup()
- * otherwise call the internal enableOnStartup() override
- * to make a decision.
- *
- * @jmx.managed-attribute
- */
- public Boolean getBarrierEnabledOnStartup()
- {
- if (enableOnStartup == null)
- {
- // setBarrierEnabledOnStartup() not called
- // initialize through enableOnStartup()
- enableOnStartup = enableOnStartup();
- }
- return enableOnStartup;
- }
-
- /**
- * The notification subscription handback string that starts the barrier.
- *
- * @jmx.managed-attribute
- */
- public void setStartBarrierHandback(String startHandback)
- {
- // set once
- if (this.startHandback == null)
- {
- this.startHandback = startHandback;
- }
- }
-
- /**
- * The notification subscription handback string that starts the barrier.
- *
- * @jmx.managed-attribute
- */
- public String getStartBarrierHandback()
- {
- return startHandback;
- }
-
- /**
- * The notification subscription handback string that stops the barrier.
- *
- * @jmx.managed-attribute
- */
- public void setStopBarrierHandback(String stopHandback)
- {
- // set once
- if (this.stopHandback == null)
- {
- this.stopHandback = stopHandback;
- }
- }
-
- /**
- * The notification subscription handback string that stops the barrier.
- *
- * @jmx.managed-attribute
- */
- public String getStopBarrierHandback()
- {
- return stopHandback;
- }
-
- /**
- * The ability to dynamically subscribe for notifications.
- *
- * @jmx.managed-attribute
- */
- public void setDynamicSubscriptions(Boolean dynamicSubscriptions)
- {
- // set once
- if (this.dynamicSubscriptions == null)
- {
- this.dynamicSubscriptions = dynamicSubscriptions;
- }
- }
-
- /**
- * The ability to dynamically subscribe for notifications.
- *
- * @jmx.managed-attribute
- */
- public Boolean getDynamicSubscriptions()
- {
- if (dynamicSubscriptions == null)
- {
- dynamicSubscriptions = Boolean.TRUE;
- }
- return dynamicSubscriptions;
- }
-
- // Override ------------------------------------------------------
-
- /**
- * Override this method to apply complex logic whether
- * to start the Barrier service upon startup or not.
- *
- * This method will be only called once and only if
- * setBarrierEnabledOnStartup(Boolean) has not been called.
- *
- * The default implementation is to return false.
- */
- protected Boolean enableOnStartup()
- {
- return Boolean.FALSE;
- }
-
- // Lifecycle -----------------------------------------------------
-
- protected void createService() throws Exception
- {
- // create the Barrier
- barrier = new Barrier(getServiceName());
-
- // register with the MBeanServer
- getServer().registerMBean(barrier, barrierName);
-
- // implicitly call the ServiceController
- barrier.create();
-
- // conditionally start the barrier
- if (getBarrierEnabledOnStartup().booleanValue())
- {
- startBarrier();
- }
- // subscribe for notifications
- subscribe(getDynamicSubscriptions().booleanValue());
- }
-
- protected void destroyService()
- {
- // unsubscribe for notifications
- unsubscribe();
-
- try
- {
- // implicitly call the ServiceController
- barrier.destroy();
-
- // remove from MBeanServer
- getServer().unregisterMBean(barrierName);
- }
- catch (Throwable e)
- {
- log.debug("Unexpected error during destroy", e);
- }
-
- // cleanup
- barrier = null;
- }
-
- // ListenerServiceMBeanSupport -----------------------------------
-
- /**
- * Base on the handback object the decision
- * for starting/stopping the barrier
- */
- public void handleNotification2(Notification n, Object handback)
- {
- log.debug("Got notification: " + n);
-
- if (startHandback != null && startHandback.equals(handback))
- {
- log.debug("Saw '" + handback + "' handback, starting barrier");
- startBarrier();
- }
- else if (stopHandback != null && stopHandback.equals(handback))
- {
- log.debug("Saw '" + handback + "' handback, stopping barrier");
- stopBarrier();
- }
- }
-
- // Operations ----------------------------------------------------
-
- /**
- * Manually start the controlled barrier
- *
- * @jmx:managed-operation
- */
- public void startBarrier()
- {
- try
- {
- // implicitly call the ServiceController
- barrier.start();
- }
- catch (Throwable e)
- {
- log.warn("Failed to start barrier: " + barrierName, e);
- }
- }
-
- /**
- * Manually stop the controlled barrier
- *
- * @jmx:managed-operation
- */
- public void stopBarrier()
- {
- try
- {
- // implicitly call the ServiceController
- barrier.stop();
- }
- catch (Throwable e)
- {
- log.warn("Failed to stop barrier: " + barrierName, e);
- }
- }
-
- // Inner Class ---------------------------------------------------
-
- /**
- * The controlled barrier MBean interface
- */
- public static interface BarrierMBean
- {
- /** We just want to expose those attributes */
- ObjectName getBarrierController();
- String getStateString();
- int getState();
-
- /** Hook up with the ServiceController */
- void jbossInternalLifecycle(String method) throws Exception;
- }
-
- /**
- * The controlled barrier MBean class
- */
- public static class Barrier extends ServiceMBeanSupport implements BarrierMBean
- {
- /** The parent Controller */
- private ObjectName barrierController;
-
- /** CTOR */
- public Barrier(ObjectName barrierController)
- {
- this.barrierController = barrierController;
- }
-
- /** Accessor */
- public ObjectName getBarrierController()
- {
- return barrierController;
- }
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/BarrierControllerMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/BarrierControllerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/BarrierControllerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,67 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.ObjectName;
-
-/**
- * BarrierController service interface
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public interface BarrierControllerMBean extends ListenerServiceMBean
-{
- // Attributes ----------------------------------------------------
-
- /** The controlled barrier StateString */
- String getBarrierStateString();
-
- /** The controlled barrier ObjectName */
- void setBarrierObjectName(ObjectName barrierName);
- ObjectName getBarrierObjectName();
-
- /** The initial state of the barrier */
- void setBarrierEnabledOnStartup(Boolean enableOnStartup);
- Boolean getBarrierEnabledOnStartup();
-
- /** The notification subscription handback string that starts the barrier */
- void setStartBarrierHandback(String startHandback);
- String getStartBarrierHandback();
-
- /** The notification subscription handback string that stops the barrier */
- void setStopBarrierHandback(String stopHandback);
- String getStopBarrierHandback();
-
- /** The ability to dynamically subscribe for notifications */
- void setDynamicSubscriptions(Boolean dynamicSubscriptions);
- Boolean getDynamicSubscriptions();
-
- // Operations ----------------------------------------------------
-
- /** Manually start the controlled barrier */
- void startBarrier();
-
- /** Manually stop the controlled barrier */
- void stopBarrier();
-}
Deleted: trunk/system/src/main/org/jboss/system/ConfigurationException.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ConfigurationException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ConfigurationException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,74 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import org.jboss.util.NestedException;
-
-/**
- * Thrown to indicate a non-fatal configuration related problem.
- *
- * @see ConfigurationService
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version <tt>$Revision$</tt>
- */
-public class ConfigurationException
- extends NestedException
-{
- /**
- * Construct a <tt>ConfigurationException</tt> with the specified detail
- * message.
- *
- * @param msg Detail message.
- */
- public ConfigurationException(String msg) {
- super(msg);
- }
-
- /**
- * Construct a <tt>ConfigurationException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param msg Detail message.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public ConfigurationException(String msg, Throwable nested) {
- super(msg, nested);
- }
-
- /**
- * Construct a <tt>ConfigurationException</tt> with the specified
- * nested <tt>Throwable</tt>.
- *
- * @param nested Nested <tt>Throwable</tt>.
- */
- public ConfigurationException(Throwable nested) {
- super(nested);
- }
-
- /**
- * Construct a <tt>ConfigurationException</tt> with no detail.
- */
- public ConfigurationException() {
- super();
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/InterceptorServiceMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/InterceptorServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/InterceptorServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,47 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.List;
-
-/**
- * MBean interface for services that dynamically attach an
- * interceptor to a set of target Interceptable (X)MBeans.
- *
- * @see InterceptorServiceMBeanSupport
- * @see org.jboss.mx.server.Interceptable
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public interface InterceptorServiceMBean extends ServiceMBean
-{
- // Attributes ----------------------------------------------------
-
- /**
- * The ObjectNames of the MBeans implementing the operations
- * in the org.jboss.mx.server.Interceptable interface
- */
- void setInterceptables(List interceptables);
- List getInterceptables();
-
-}
Deleted: trunk/system/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java
===================================================================
--- trunk/system/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,275 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.interceptor.AbstractInterceptor;
-import org.jboss.mx.interceptor.DynamicInterceptor;
-import org.jboss.mx.interceptor.Interceptor;
-import org.jboss.mx.server.Invocation;
-
-/**
- * Helper class that can be used for writing MBean Services
- * that dynamically hook-up an Interceptor to other (X)MBeans
- * that have been configured as Interceptable.
- *
- * In a nutshell, call attach()/detach() from your
- * createService()/destroyService() or startService()/stopService()
- * pair methods to attach/detach an interceptor to the target mbean(s),
- * then override invoke() to do something with the invocations.
- *
- * You may also provide your own Interceptor, in which case
- * you should call attach(Interceptor).
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public abstract class InterceptorServiceMBeanSupport extends ServiceMBeanSupport
- implements InterceptorServiceMBean
-{
- // Private Data --------------------------------------------------
-
- /** The Interceptables to attach to */
- private List interceptables;
-
- /** The attached interceptor */
- private Interceptor interceptor;
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- */
- public InterceptorServiceMBeanSupport()
- {
- super();
- }
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param type The class type to determine Logger name from.
- */
- public InterceptorServiceMBeanSupport(final Class type)
- {
- super(type);
- }
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param category The logger category name.
- */
- public InterceptorServiceMBeanSupport(final String category)
- {
- super(category);
- }
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param log The logger to use.
- */
- public InterceptorServiceMBeanSupport(final Logger log)
- {
- super(log);
- }
-
- // InterceptorServiceMBean ---------------------------------------
-
- public void setInterceptables(List interceptables)
- {
- // copy
- if (interceptables != null)
- {
- this.interceptables = new ArrayList(interceptables);
- }
- }
-
- public List getInterceptables()
- {
- // return a copy
- if (interceptables != null)
- {
- return new ArrayList(interceptables);
- }
- return null;
- }
-
- // Protected API -------------------------------------------------
-
- /**
- * Add our interceptor to the target Interceptables.
- *
- * Override invoke(Invocation) to handle the calls.
- *
- * @throws Exception thrown on any interceptor registration error
- */
- protected void attach() throws Exception
- {
- if (interceptor == null)
- {
- attach(new XMBeanInterceptor());
- }
- }
-
- /**
- * Add the provided interceptor to the target Interceptables.
- *
- * @param interceptor the interceptor to add
- * @throws Exception thrown on any interceptor registration error
- */
- protected void attach(Interceptor interceptor) throws Exception
- {
- if (interceptor == null)
- {
- throw new IllegalArgumentException("Null interceptor");
- }
-
- // check we haven't attached already
- if (this.interceptor != null)
- {
- throw new IllegalStateException("Interceptor already attached");
- }
-
- log.debug("Attaching interceptor: " + interceptor.getName());
-
- // remember the interceptor
- this.interceptor = interceptor;
-
- // add the interceptor to the Interceptables; an exception
- // will be thrown if any of them is not Interceptable,
- // in which case detach() should be called.
- if (interceptables != null)
- {
- Object[] params = new Object[] { interceptor };
- String[] signature = new String[] { Interceptor.class.getName() };
-
- for (Iterator i = interceptables.iterator(); i.hasNext(); )
- {
- ObjectName target = (ObjectName)i.next();
- super.server.invoke(target,
- DynamicInterceptor.ADD_INTERCEPTOR,
- params,
- signature);
-
- log.debug("Interceptor attached to: '" + target + "'");
- }
- }
- }
-
- /**
- * Remove the interceptor from the target Interceptables
- */
- protected void detach()
- {
- if (interceptor != null)
- {
- log.debug("Detaching interceptor: " + interceptor.getName());
- if (interceptables != null)
- {
- Object[] params = new Object[] { interceptor };
- String[] signature = new String[] { Interceptor.class.getName() };
-
- for (Iterator i = interceptables.iterator(); i.hasNext(); )
- {
- ObjectName target = (ObjectName)i.next();
- try
- {
- super.server.invoke(target,
- DynamicInterceptor.REMOVE_INTERCEPTOR,
- params,
- signature);
-
- log.debug("Interceptor detached from: '" + target + "'");
- }
- catch (Exception e)
- {
- log.debug("Caught exception while removing interceptor from '" +
- target + "'", e);
- }
- }
- }
- interceptor = null;
- }
- }
-
- /**
- * Use this to forward the call
- */
- protected Object invokeNext(Invocation invocation) throws Throwable
- {
- // call the next in the interceptor chain,
- // if nobody follows dispatch the call
- Interceptor next = invocation.nextInterceptor();
- if (next != null)
- {
- return next.invoke(invocation);
- }
- else
- {
- return invocation.dispatch();
- }
- }
-
- // Override ------------------------------------------------------
-
- /**
- * Override
- */
- protected Object invoke(Invocation invocation) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- // Private Inner Class -------------------------------------------
-
- /**
- * Simple Interceptor delegating to
- * the invoke(Invocation) callback
- */
- private class XMBeanInterceptor extends AbstractInterceptor
- {
- public XMBeanInterceptor()
- {
- super("XMBeanInterceptor('" + InterceptorServiceMBeanSupport.this.getServiceName() + "')");
- }
-
- public Object invoke(Invocation invocation) throws Throwable
- {
- // delegate
- return InterceptorServiceMBeanSupport.this.invoke(invocation);
- }
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/InvalidAttributeException.java
===================================================================
--- trunk/system/src/main/org/jboss/system/InvalidAttributeException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/InvalidAttributeException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * Thrown to indicate that a given attribute value is not valid.
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version <tt>$Revision$</tt>
- */
-public class InvalidAttributeException
- extends ConfigurationException
-{
- /**
- * Construct a <tt>InvalidAttributeException</tt> with the
- * specified detail message.
- *
- * @param name The attribute name.
- * @param msg The detail message.
- */
- public InvalidAttributeException(final String name, final String msg) {
- super(makeMessage(name, msg));
- }
-
- /**
- * Construct a <tt>InvalidAttributeException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param name The attribute name.
- * @param msg The detail message.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public InvalidAttributeException(final String name, final String msg, final Throwable nested)
- {
- super(makeMessage(name, msg), nested);
- }
-
- /**
- * Make a execption message for the attribute name and detail message.
- */
- private static String makeMessage(final String name, final String msg) {
- return "Invalid value for attribute '" + name + "': " + msg;
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/ListenerServiceMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ListenerServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ListenerServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,123 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * An extension of the ServiceMBean interface that provides for
- * declarative JMX notification subscription handling.
- * <p>
- * The SubscriptionList attribute is used to specify the list
- * of MBeans/notifications that the listener service instance
- * will subscribe for.
- * <p>
- * The abstract class ListenerServiceMBeanSupport implements
- * this interface.
- *
- * @see ServiceMBean
- * @see ListenerServiceMBeanSupport
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public interface ListenerServiceMBean
- extends ServiceMBean
-{
- // Constants -----------------------------------------------------
-
- /** The XML subscription-list elements and attributes */
- public static final String SL_ROOT_ELEMENT = "subscription-list";
- public static final String SL_MBEAN_ELEMENT = "mbean";
- public static final String SL_FILTER_ELEMENT = "filter";
- public static final String SL_NOTIFICATION_ELEMENT = "notification";
- public static final String SL_MBEAN_NAME_ATTRIBUTE = "name";
- public static final String SL_MBEAN_HANDBACK_ATTRIBUTE = "handback";
- public static final String SL_FILTER_FACTORY_ATTRIBUTE = "factory";
- public static final String SL_NOTIFICATION_TYPE_ATTRIBUTE = "type";
-
- // Public --------------------------------------------------------
-
- /**
- * Used to configure at start-up the JMX notification subscriptions.
- *
- * The configuration is done inline in the mbean descriptor. For example:
- *
- * <code>
- * ...
- * <attribute name="SubscriptionList">
- * <subscription-list>
- * <mbean name="jboss.system:*">
- * <notification type="org.jboss.system.ServiceMBean.start"/>
- * <notification type="org.jboss.system.ServiceMBean.stop"/>
- * </mbean>
- * </subscription-list>
- * </attribute>
- * ...
- * </code>
- *
- * The filter mechanism has been extended to support specification
- * of arbitrary filters, using filter factory plugins:
- *
- * <code>
- * ...
- * <attribute name="SubscriptionList">
- * <subscription-list>
- * <mbean name="jboss.system:*">
- * <filter factory="NotificationFilterSupportFactory">
- * <enable type="org.jboss.system.ServiceMBean.start"/>
- * <enable type="org.jboss.system.ServiceMBean.stop"/>
- * </filter>
- * </mbean>
- * <mbean name="jboss.monitor:service=MemoryMonitor">
- * <filter factory="AttributeChangeNotificationFilterFactory">
- * <enable attribute-name="State"/>
- * </filter>
- * </mbean>
- * <mbean name="JMImplementation:type=MBeanServerDelegate">
- * <filter factory="MBeanServerNotificationFilterFactory">
- * <enable type="JMX.mbean"/>
- * <enable object-name="jboss:type=Service,name=SystemProperties"/>
- * </filter>
- * </mbean>
- * </subscription-list>
- * </attribute>
- * ...
- * </code>
- *
- * 'factory' is the full class name of a class that implements the
- * org.jboss.system.NotificationFilterFactory interface. If the
- * class cannot be loaded, a second attempt is made to load the
- * class from within the org.jboss.system.filterfactory package.
- *
- * Three NotificationFilterFactories corresponding to the three
- * "standard" jmx notification filters, have been pre-packaged.
- *
- * Those are:
- *
- * @see org.jboss.system.filterfactory.AttributeChangeNotificationFilterFactory
- * @see org.jboss.system.filterfactory.MBeanServerNotificationFilterFactory
- * @see org.jboss.system.filterfactory.NotificationFilterSupportFactory
- *
- * See also jboss-subscription.dtd
- **/
- public void setSubscriptionList(org.w3c.dom.Element list);
-
-}
Deleted: trunk/system/src/main/org/jboss/system/ListenerServiceMBeanSupport.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ListenerServiceMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ListenerServiceMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,809 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import javax.management.InstanceNotFoundException;
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanServer;
-import javax.management.MBeanServerNotification;
-import javax.management.MalformedObjectNameException;
-import javax.management.Notification;
-import javax.management.NotificationFilter;
-import javax.management.NotificationFilterSupport;
-import javax.management.NotificationListener;
-import javax.management.ObjectName;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * An abstract base class that provides for declarative JMX notification
- * subscription handling.
- * <p>
- * A JBoss service that is in addition a NotificationListener can
- * subclass ListenerServiceMBeanSupport instead of ServiceMBeanSupport
- * and specify at run-time, inline in the MBean descriptor using the
- * SubscriptionList attribute, the set of MBeans/notifications the
- * service wants to subscribe/receive.
- * <p>
- * Call subscribe(boolean dynamicSubscriptions) at anytime to register to
- * those MBeans and for those notifications that match the specified criteria.
- * Call unsubscribe() to unsubscribe for Notifications.
- * <p>
- * If true is passed to subscribe() the baseclass will monitor for
- * registration events from the MBeanServer and automatically subscribe
- * to new instances of MBeans that match the subscription criteria.
- * Monitoring for unsubscribe events in not necessary, since the MBeanServer
- * automatically removes subscriptions to unregistering MBeans.
- * <p>
- * An alternative subscribe(boolean dynamicSubscription, ObjectName listener)
- * can be used to specify a different MBean as the receiver of the
- * subscribed notifications. The specified MBean must be a NotificationListener.
- * <p>
- * To handle the incoming notifications override the handleNotification2()
- * method. The usual handleNotification() method should not be overriden,
- * since it is used to monitor the incoming notifications for registration
- * events coming from the MBeanServer, before delegating to
- * handleNotification2(), in order to implement dynamic subscriptions.
- *
- * @see ListenerServiceMBean
- * @see NotificationFilterFactory
- *
- * REVISIONS
- * =========
- * 14/03/05, dimitris
- * The filter mechanism has been extended to support specification
- * of arbitrary filters, using dynamic filter factory plugins
- * implementing the NotificationFilterFactory interface.
- * Three filter factories corresponding to the "standard" jmx
- * notification filters are supplied by default in package
- * org.jboss.system.filterfactory.
- *
- * 19/10/04, dimitris
- * renamed inner class MBeanInfo to SubscriptionInfo and made public,
- * using NotificationFilter instead of NotificationFilterSupport and added new
- * subscribe(List subscriptionList, boolean dynamicSubscriptions, ObjectName listener)
- * to allow external programmatic specification of the subscription list.
- *
- * 28/02/04, dimitris
- * explicit subscribe()/unsubscribe() replaced implicit start()/stop();
- * dynamic subscription behaviour can be enabled/disabled, plus it is
- * now possible to specify an external MBean as notification listener.
- *
- * 02/02/04, dimitris
- * Initial version, that resulted by generalizing the notification
- * subscription mechanism of the snmp adapter.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- *
- * @version $Revision$
-**/
-public abstract class ListenerServiceMBeanSupport
- extends ServiceMBeanSupport
- implements ListenerServiceMBean, NotificationListener
-{
- // Private Data --------------------------------------------------
-
- /** The mbean subscription specification list */
- private List sublist; // if null, subscriptions not made
-
- /** The mbean subscription config in XML form */
- private Element xmllist; // set through SubscriptionList attribute
-
- /** monitoring and registering to new MBeans, as they appear */
- private boolean dynamicSubscriptions;
-
- /** the receiver of the notifications */
- private ObjectName listener;
-
- /** Handback to identify our own MBeanServerDelegate subscription */
- private Object myHandback;
-
- /** Filter to receive only registration events */
- private NotificationFilterSupport myFilter;
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- **/
- public ListenerServiceMBeanSupport()
- {
- super();
- init();
- }
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param type The class type to determine Logger name from.
- **/
- public ListenerServiceMBeanSupport(final Class type)
- {
- super(type);
- init();
- }
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param category The logger category name.
- **/
- public ListenerServiceMBeanSupport(final String category)
- {
- super(category);
- init();
- }
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param log The logger to use.
- **/
- public ListenerServiceMBeanSupport(final Logger log)
- {
- super(log);
- init();
- }
-
- // ListenerServiceMBean Implementation ---------------------------
-
- /**
- * Used to configure the JMX notification subscriptions.
- *
- * The configuration is done inline in the mbean descriptor.
- *
- * See jboss-subscription.dtd
- **/
- public void setSubscriptionList(Element list)
- {
- // deep copy the provided Element for later use
- // not sure if really necessary - play it safe
- this.xmllist = (Element)list.cloneNode(true);
- }
-
- // Public API ----------------------------------------------------
-
- /**
- * Subscribes this MBean for JMX notifications.
- *
- * @param dynamicSubscriptions indicates whether to monitor and subscribe
- * to new MBeans that match the specification.
- **/
- public void subscribe(boolean dynamicSubscriptions)
- throws Exception
- {
- subscribe(dynamicSubscriptions, this.getServiceName());
- }
-
- /**
- * Subscribes a listener MBean for JMX notifications.
- *
- * @param dynamicSubscriptions indicates whether to monitor and subscribe
- * to new MBeans that match the specification.
- * @param listener the receiver of the notifications.
- **/
- public void subscribe(boolean dynamicSubscriptions, ObjectName listener)
- throws Exception
- {
- // we need an xml subscription specification
- if (this.xmllist != null)
- {
- // Parse the XML spec
- log.debug("Parsing subscription specification");
- List subscriptionList = parseXMLSubscriptionSpec(this.xmllist);
-
- subscribe(subscriptionList, dynamicSubscriptions, listener);
- }
- else
- log.debug("Subscription specification not provided");
- }
-
- /**
- * Subscribes a listener MBean for JMX notifications.
- *
- * @param subscriptionList the list containing SubscriptionInfo data.
- * @param dynamicSubscriptions indicates whether to monitor and subscribe
- * to new MBeans that match the specification.
- * @param listener the receiver of the notifications.
- **/
- public void subscribe(List subscriptionList, boolean dynamicSubscriptions, ObjectName listener)
- throws Exception
- {
- // return if already subscribed
- if (this.sublist != null)
- return;
-
- // we need an subscription specification
- if (subscriptionList != null)
- {
- // store input
- this.sublist = subscriptionList;
- this.dynamicSubscriptions = dynamicSubscriptions;
- this.listener = listener;
-
- log.debug(this.sublist);
-
- log.debug("Subscribing for JMX notifications" +
- ", dynamic=" + dynamicSubscriptions +
- (this.getServiceName().equals(listener) ? "" :
- ", listener='" + listener + "'"));
-
- bulkRegister();
-
- if (dynamicSubscriptions == true)
- {
- // Subscribe to MBeanServerDelegate MBean for registrations
- getServer().addNotificationListener(
- new ObjectName(ServerConstants.MBEAN_SERVER_DELEGATE),
- this.getServiceName(),
- this.myFilter,
- this.myHandback
- );
-
- log.debug("Subscribed to MBeanServerDelegate, too");
- }
- }
- else
- log.debug("Subscription list not provided");
- }
-
- /**
- * Unsubscribes for JMX notifications
- **/
- public void unsubscribe()
- {
- // return if not subscribed
- if (this.sublist == null)
- return;
-
- log.debug("Removing all JMX notification subscriptions");
- bulkUnregister();
-
- if (this.dynamicSubscriptions == true)
- {
- // Unbscribe from MBeanServerDelegate MBean for registrations
- try {
- getServer().removeNotificationListener(
- new ObjectName(ServerConstants.MBEAN_SERVER_DELEGATE),
- this.getServiceName(),
- this.myFilter,
- this.myHandback
- );
-
- log.debug("Unsubscribed from MBeanServerDelegate, too");
- }
- catch (MalformedObjectNameException e)
- {
- // shouldn't happen!
- log.warn("Could not convert '" + ServerConstants.MBEAN_SERVER_DELEGATE
- + "' to ObjectName", e);
- }
- catch (InstanceNotFoundException e)
- {
- // shouldn't happen
- log.warn("Could not unsubscribe from non-existent MBeanServerDelegate!", e);
- }
- catch (ListenerNotFoundException e)
- {
- // shouldn't happend
- log.warn("Could not unsubscribe from MBeanServerDelegate", e);
- }
- }
- // use sublist to indicate we've unsubscribed
- this.sublist = null;
- }
-
- // NotificationListener -----------------------------------------
-
- /**
- * DO NOT OVERRIDE THIS!
- *
- * Handles dynamic subscriptions before delegating to
- * handleNotification2()
- **/
- public void handleNotification(Notification notification, Object handback)
- {
- // check if the notification is for me!
- if (this.dynamicSubscriptions == true && handback == this.myHandback)
- {
- if (log.isTraceEnabled())
- log.trace("It's for me: " + notification + ", handback:" + handback);
-
- String type = notification.getType();
- ObjectName target = null;
- try {
- target = ((MBeanServerNotification)notification).getMBeanName();
- }
- catch (ClassCastException e) {
- log.warn("MBeanServer sent unknown notification class type: " +
- notification.getClass().getName());
- return;
- }
-
- if (type.equals(MBeanServerNotification.REGISTRATION_NOTIFICATION))
- {
- // iterate over the subscription specification
- Iterator i = this.sublist.iterator();
-
- while (i.hasNext())
- {
- SubscriptionInfo mbeanInfo = (SubscriptionInfo)i.next();
-
- ObjectName objectName = mbeanInfo.getObjectName();
-
- try
- {
- if(objectName.apply(target))
- {
- log.debug("ObjectName: '" + target + "' matched '" + objectName + "'");
-
- // go for it!
- singleRegister(
- this.getServer(),
- target,
- this.listener,
- mbeanInfo.getFilter(),
- mbeanInfo.getHandback()
- );
- }
- }
- catch (Exception e)
- {
- // catch exceptions from apply()
- // shouldn't happen
- log.warn("Caught exception from ObjectName.apply("
- + target + ")", e);
- }
- }
- }
- else
- {
- log.warn("Got unknown notification type from MBeanServerDelegate: "
- + type);
- }
- }
- else // delegate to subclass
- handleNotification2(notification, handback);
- }
-
- /**
- * Override to add notification handling!
- **/
- public void handleNotification2(Notification notification, Object handback)
- {
- // empty!
- }
-
- // Private Methods -----------------------------------------------
-
- /**
- * Initialises myself
- **/
- private void init()
- {
- // just pickup a unique object
- this.myHandback = new Integer(Integer.MAX_VALUE);
-
- // allow only registration events
- this.myFilter = new NotificationFilterSupport();
- this.myFilter.enableType(MBeanServerNotification.REGISTRATION_NOTIFICATION);
- }
-
- /**
- * Subscribes for notifications to a single MBean
- **/
- private void singleRegister(
- MBeanServer server, ObjectName target, ObjectName listener,
- NotificationFilter filter, Object handback)
- {
- try
- {
- server.addNotificationListener(target, listener, filter, handback);
-
- logSubscription(target, listener, handback, filter);
- }
- catch (InstanceNotFoundException e)
- {
- // ignore - mbean might not be registered
- log.debug("Could not subscribe to: '" + target
- + "', target or listener MBean not registered");
- }
- catch (RuntimeException e)
- {
- log.warn("Failed to subscribe to: '" + target
- + "', maybe not a notification broadcaster or: '" + listener
- + "', maybe not a notification listener");
- }
- }
-
- /**
- * Unsubscribes for notifications from a single MBean
- **/
- private void singleUnregister(
- MBeanServer server, ObjectName target, ObjectName listener,
- NotificationFilter filter, Object handback)
- {
- try
- {
- // remove the matching subscription
- server.removeNotificationListener(target, listener, filter, handback);
-
- log.debug("Unsubscribed from: '" + target + "'");
- }
- catch (InstanceNotFoundException e)
- {
- // ignore - target mbean not present
- log.debug("Could not unsubscribe from non-existent: '"
- + target + "'");
- }
- catch (ListenerNotFoundException e)
- {
- // May happen if target is not a notification broadcaster
- // and so we hadn't registered in the first place
- log.debug("Could not unsubscribe from: '" + target + "'");
- }
- catch (RuntimeException e)
- {
- // whatever
- log.debug("Could not unsubscribe from: '" + target + "'");
- }
- }
-
- /**
- * Performs the notification subscriptions
- **/
- private void bulkRegister()
- {
- // iterate over the subscription specification
- Iterator i = this.sublist.iterator();
-
- // find out my server
- MBeanServer server = this.getServer();
-
- while (i.hasNext())
- {
- SubscriptionInfo mbeanInfo = (SubscriptionInfo)i.next();
-
- ObjectName objectName = mbeanInfo.getObjectName();
- Object handback = mbeanInfo.getHandback();
- NotificationFilter filter = mbeanInfo.getFilter();
-
- if (objectName.isPattern())
- {
- Set mset = server.queryNames(objectName, null);
-
- log.debug("ObjectName: '" + objectName + "' matched " + mset.size() + " MBean(s)");
-
- Iterator j = mset.iterator();
- while (j.hasNext())
- singleRegister(server, (ObjectName)j.next(), this.listener,
- filter, handback);
- }
- else
- singleRegister(server, objectName, this.listener, filter, handback);
- }
- }
-
- /**
- * Performs bulk unregistration
- **/
- private void bulkUnregister()
- {
- // iterate over the subscription specification
- Iterator i = this.sublist.iterator();
-
- // find out my server
- MBeanServer server = this.getServer();
-
- while (i.hasNext())
- {
- SubscriptionInfo mbeanInfo = (SubscriptionInfo)i.next();
-
- ObjectName objectName = mbeanInfo.getObjectName();
- Object handback = mbeanInfo.getHandback();
- NotificationFilter filter = mbeanInfo.getFilter();
-
- if (objectName.isPattern())
- {
- Set mset = server.queryNames(objectName, null);
-
- log.debug("ObjectName: '" + objectName + "' matched " + mset.size() + " MBean(s)");
-
- Iterator j = mset.iterator();
- while (j.hasNext())
- singleUnregister(server, (ObjectName)j.next(), this.listener,
- filter, handback);
- }
- else
- singleUnregister(server, objectName, this.listener, filter, handback);
- }
- }
-
- /**
- * Logs subscription info
- **/
- private void logSubscription(
- ObjectName objectName, ObjectName listener,
- Object handback, NotificationFilter filter)
- {
- StringBuffer sbuf = new StringBuffer(100);
-
- sbuf.append("Subscribed to: { objectName='").append(objectName);
- sbuf.append("', listener='").append(listener);
- sbuf.append("', handback=").append(handback);
- sbuf.append(", filter=");
- sbuf.append(filter == null ? null : filter.toString());
- sbuf.append(" }");
-
- log.debug(sbuf.toString());
- }
-
- /**
- * Encapsulte the factory and filter creation logic
- */
- private NotificationFilter createNotificationFilter(String factoryClass, Element filterConfig)
- throws Exception
- {
- NotificationFilterFactory factory;
- try
- {
- // try to load the factory Class
- Class clazz = Thread.currentThread().getContextClassLoader().loadClass(factoryClass);
- factory = (NotificationFilterFactory)clazz.newInstance();
- }
- catch (Exception e) // ClassNotFoundException, IllegalAccessException, InstantiationException
- {
- // factory class not found. Make a second try using
- // the 'org.jboss.system.filterfactory.' package prefix
- // for the "standard" filter factories provided with jboss.
- // If that fails, too, rethrow the original exception.
- try
- {
- factoryClass = "org.jboss.system.filterfactory." + factoryClass;
- Class clazz = Thread.currentThread().getContextClassLoader().loadClass(factoryClass);
- factory = (NotificationFilterFactory)clazz.newInstance();
- }
- catch (Exception inner)
- {
- throw e;
- }
- }
- // delegate the filter creation/configuration to the factory
- return factory.createNotificationFilter(filterConfig);
- }
-
- /**
- * Parses the XML subscription specification
- **/
- private ArrayList parseXMLSubscriptionSpec(Element root)
- throws Exception
- {
- ArrayList slist = new ArrayList();
-
- // parse level 0 - subscription-list
- if (!root.getNodeName().equals(SL_ROOT_ELEMENT))
- {
- throw new Exception("Expected '" + SL_ROOT_ELEMENT + "' element, "
- + "got: " + "'" + root.getNodeName() + "'");
- }
- else
- {
- NodeList rootlist = root.getChildNodes();
-
- for (int i = 0; i < rootlist.getLength(); i++)
- {
- // Parse level 1 - look for mbeans
- Node mbean = rootlist.item(i);
-
- if (mbean.getNodeName().equals(SL_MBEAN_ELEMENT))
- {
- // mbean found look for name & handback attrs
- String name = null;
-
- if (((Element)mbean).hasAttribute(SL_MBEAN_NAME_ATTRIBUTE))
- {
- name = ((Element)mbean).getAttribute(SL_MBEAN_NAME_ATTRIBUTE);
- }
- else
- {
- throw new Exception("'" + SL_MBEAN_ELEMENT + "' element must have a '"
- + SL_MBEAN_NAME_ATTRIBUTE + "' attribute");
- }
-
- String handback = null;
- if (((Element)mbean).hasAttribute(SL_MBEAN_HANDBACK_ATTRIBUTE))
- {
- handback = ((Element)mbean).getAttribute(SL_MBEAN_HANDBACK_ATTRIBUTE);
- }
-
- // try to convert name to the correct data type
- // may throw MalformedObjectNameException
- ObjectName objectName = new ObjectName(name);
-
- // Parse level 2 - see if we have a filter for this subscription
- NotificationFilter filter = null;
-
- NodeList mbeanChildren = mbean.getChildNodes();
-
- // check for filter spec, as a single mbean child node
- for (int j = 0; j < mbeanChildren.getLength(); j++)
- {
- Node mbeanChildNode = mbeanChildren.item(j);
-
- // check if this is a 'filter' node
- if (mbeanChildNode.getNodeName().equals(SL_FILTER_ELEMENT))
- {
- // look for the 'factory' attribute
- String factory = null;
- if (((Element)mbeanChildNode).hasAttribute(SL_FILTER_FACTORY_ATTRIBUTE))
- {
- factory = ((Element)mbeanChildNode).getAttribute(SL_FILTER_FACTORY_ATTRIBUTE);
-
- // instantiate the factory and request the filter
- filter = createNotificationFilter(factory, (Element)mbeanChildNode);
- break;
- }
- else
- {
- throw new Exception("'" + SL_FILTER_ELEMENT + "' element must have a '"
- + SL_FILTER_FACTORY_ATTRIBUTE + "' attribute");
- }
- }
- }
-
- if (filter == null)
- {
- // if no filter has been set check for old-style
- // <notification type="..."/> construct that results
- // in a fixed NotificationFilterSupport filter
-
- // need to find out all notification types (if any)
- // in order to create the Notification filter
- ArrayList tmplist = new ArrayList(mbeanChildren.getLength());
-
- for (int j = 0; j < mbeanChildren.getLength(); j++)
- {
- Node mbeanChildNode = mbeanChildren.item(j);
-
- // check if this is a 'notification' element
- if (mbeanChildNode.getNodeName().equals(SL_NOTIFICATION_ELEMENT))
- {
- // look for 'type' attribute
- String type = null;
- if (((Element)mbeanChildNode).hasAttribute(SL_NOTIFICATION_TYPE_ATTRIBUTE))
- {
- type = ((Element)mbeanChildNode).getAttribute(SL_NOTIFICATION_TYPE_ATTRIBUTE);
- tmplist.add(type);
- }
- else
- {
- throw new Exception("'" + SL_NOTIFICATION_ELEMENT + "' element must have a '"
- + SL_NOTIFICATION_TYPE_ATTRIBUTE + "' attribute");
- }
- }
- }
- // create the filter (if needed)
- if (tmplist.size() > 0)
- {
- NotificationFilterSupport sfilter = new NotificationFilterSupport();
- for (int j = 0; j < tmplist.size(); j++)
- {
- sfilter.enableType((String)tmplist.get(j));
- }
- filter = sfilter;
- }
- }
- slist.add(new SubscriptionInfo(objectName, handback, filter));
- }
- }
- }
- return slist;
- }
-
- // Inner Class ---------------------------------------------------
-
- /**
- * Inner data holder class to store the parsed subscription specification.
- **/
- public static final class SubscriptionInfo
- {
- // Private Data -----------------------------------------------
-
- /** MBean notification broadcaster or pattern */
- private ObjectName objectName;
-
- /** Optional handback object to identify a subscription */
- private Object handback;
-
- /** Arbitrary NotificationFilter */
- private NotificationFilter filter;
-
- // Constructor ------------------------------------------------
-
- /**
- * Simple CTOR
- **/
- public SubscriptionInfo(ObjectName objectName, Object handback, NotificationFilter filter)
- {
- this.objectName = objectName;
- this.handback = handback;
- this.filter = filter;
- }
-
- // Accessors --------------------------------------------------
- /**
- * Gets objectname
- **/
- public ObjectName getObjectName()
- {
- return this.objectName;
- }
-
- /**
- * Gets handback object
- **/
- public Object getHandback()
- {
- return this.handback;
- }
-
- /**
- * Gets notification filter
- **/
- public NotificationFilter getFilter()
- {
- return this.filter;
- }
-
- /**
- * Pretty prints
- **/
- public String toString()
- {
- StringBuffer sbuf = new StringBuffer(100);
-
- sbuf.append("SubscriptionInfo { objectName='").append(this.objectName);
- sbuf.append("', handback=").append(this.handback);
- sbuf.append(", filter=");
- sbuf.append(this.filter == null ? null : this.filter.toString());
-
- sbuf.append(" }");
-
- return sbuf.toString();
- }
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/MissingAttributeException.java
===================================================================
--- trunk/system/src/main/org/jboss/system/MissingAttributeException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/MissingAttributeException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * Thrown to indicate that a required attribute has not been set.
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version <tt>$Revision$</tt>
- */
-public class MissingAttributeException
- extends ConfigurationException
-{
- /**
- * Construct a <tt>MissingAttributeException</tt> with the specified detail
- * message.
- *
- * @param name The attribute name.
- */
- public MissingAttributeException(final String name) {
- super(makeMessage(name));
- }
-
- /**
- * Construct a <tt>MissingAttributeException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param name The attribute name.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public MissingAttributeException(final String name, final Throwable nested) {
- super(makeMessage(name), nested);
- }
-
- /**
- * Make a execption message for the attribute name.
- */
- private static String makeMessage(final String name) {
- return "Missing attribute '" + name + "'";
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/NotificationFilterFactory.java
===================================================================
--- trunk/system/src/main/org/jboss/system/NotificationFilterFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/NotificationFilterFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.NotificationFilter;
-
-import org.w3c.dom.Element;
-
-/**
- * Abstracts NotificationFilter creation based on an arbritrary
- * xml element fragment. Used by ListenerServiceMBeanSupport
- * to enable NotificationFilterFactory plugins.
- *
- * @see ListenerServiceMBeanSupport
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public interface NotificationFilterFactory
-{
- /**
- * Create a notification filter implementation and initialize
- * it, using the passed xml element fragment.
- *
- * @param filterConfig the xml fragment to use for configuring the filter
- * @return an initialized NotificationFilter
- * @throws Exception in case the xml fragment cannot be parsed properly
- */
- public NotificationFilter createNotificationFilter(Element filterConfig)
- throws Exception;
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceBinding.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceBinding.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceBinding.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.ObjectName;
-
-/**
- * A policy used by ServiceController to allow the override
- * of MBean attribute values at configuration time.
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public interface ServiceBinding
-{
- /**
- * Possibly override the configuration of a service.
- *
- * @param serviceName the JMX ObjectName of the service
- * @exception Exception thrown on failure to override a configuration
- */
- void applyServiceConfig(ObjectName serviceName) throws Exception;
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceConfigurator.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceConfigurator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceConfigurator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,457 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.io.IOException;
-import java.io.StringWriter;
-import java.io.Writer;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.management.Attribute;
-import javax.management.InstanceNotFoundException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanInfo;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.system.metadata.ServiceValueContext;
-import org.jboss.util.xml.DOMWriter;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Service configuration helper.
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version <tt>$Revision$</tt>
- */
-public class ServiceConfigurator
-{
- /** The MBean server which this service is registered in. */
- private final MBeanServer server;
-
- /** The parent service controller */
- private final ServiceController serviceController;
-
- /** The ServiceCreator */
- private final ServiceCreator serviceCreator;
-
- /** The ServiceBinding plugin policy */
- private ServiceBinding serviceBinding;
-
- /** Instance logger. */
- private static final Logger log = Logger.getLogger(ServiceConfigurator.class);
-
- /**
- * Configure an MBean
- *
- * @param server the server
- * @param controller the service controller
- * @param objectName the object name
- * @param classLoaderName the classloader object name
- * @param attrs the attributes
- * @throws Exception for any error
- */
- public static void configure(MBeanServer server, ServiceController controller, ObjectName objectName, ObjectName classLoaderName, Collection<ServiceAttributeMetaData> attrs) throws Exception
- {
- server = checkMBeanServer(server, controller);
- ClassLoader cl = server.getClassLoader(classLoaderName);
- configure(server, controller, objectName, cl, attrs);
- }
-
- /**
- * Configure an MBean
- *
- * @param server the server
- * @param controller the service controller
- * @param objectName the object name
- * @param cl the classloader
- * @param attrs the attributes
- * @throws Exception for any error
- */
- public static void configure(MBeanServer server, ServiceController controller, ObjectName objectName, ClassLoader cl, Collection<ServiceAttributeMetaData> attrs) throws Exception
- {
- ServiceValueContext valueContext = new ServiceValueContext(server, controller, cl);
- server = checkMBeanServer(server, controller);
-
- HashMap<String, MBeanAttributeInfo> attributeMap = getAttributeMap(server, objectName);
-
- for (ServiceAttributeMetaData attribute : attrs)
- {
- String attributeName = attribute.getName();
- if (attributeName == null || attributeName.length() == 0)
- throw new DeploymentException("No or empty attribute name for " + objectName);
- MBeanAttributeInfo attributeInfo = attributeMap.get(attributeName);
- if (attributeInfo == null)
- throw new DeploymentException("No Attribute found with name: " + attributeName + " for " + objectName);
-
- valueContext.setAttributeInfo(attributeInfo);
- Object value = attribute.getValue(valueContext);
- try
- {
- log.debug(attributeName + " set to " + value + " in " + objectName);
- server.setAttribute(objectName, new Attribute(attributeName, value));
- }
- catch (Throwable t)
- {
- throw new DeploymentException("Exception setting attribute " + attributeName + " on mbean " + objectName, JMXExceptionDecoder.decode(t));
- }
- }
- }
-
- /**
- * Check the server/controller parameters
- *
- * @param server the server
- * @param controller the controller
- * @return the server
- */
- private static MBeanServer checkMBeanServer(MBeanServer server, ServiceController controller)
- {
- if (server != null)
- return server;
-
- if (controller != null)
- return controller.getMBeanServer();
-
- throw new IllegalArgumentException("Either the server or controller must be passed");
- }
-
- /**
- * Apply any service binding overrides
- *
- * @review why isn't the MBeanServer part of this api?
- * @param server the server
- * @param objectName the object name
- * @param serviceBinding the service binding
- * @throws Exception for any error
- */
- public static void applyServiceConfig(MBeanServer server, ObjectName objectName, ServiceBinding serviceBinding) throws Exception
- {
- try
- {
- serviceBinding.applyServiceConfig(objectName);
- }
- catch (Throwable e)
- {
- // serviceBinding is most probably a dynamic mbean proxy
- Throwable t = JMXExceptionDecoder.decode(e);
- log.warn("Failed to apply service binding override for " + objectName, t);
- }
- }
-
- /**
- * Get an attribute map for the MBean
- *
- * @param server the server
- * @param objectName the object name
- * @return a map of attribute name to attribute info
- * @throws Exception for any error
- */
- private static HashMap<String, MBeanAttributeInfo> getAttributeMap(MBeanServer server, ObjectName objectName) throws Exception
- {
- MBeanInfo info;
- try
- {
- info = server.getMBeanInfo(objectName);
- }
- catch (InstanceNotFoundException e)
- {
- // The MBean is no longer available
- throw new DeploymentException("Trying to configure nonexistent mbean: " + objectName);
- }
- catch (Exception e)
- {
- throw new DeploymentException("Could not get mbeanInfo", JMXExceptionDecoder.decode(e));
- }
- if (info == null)
- throw new DeploymentException("MBeanInfo is null for mbean: " + objectName);
- MBeanAttributeInfo[] attributes = info.getAttributes();
- HashMap<String, MBeanAttributeInfo> attributeMap = new HashMap<String, MBeanAttributeInfo>();
- for (int i = 0; i < attributes.length; i++)
- {
- MBeanAttributeInfo attr = attributes[i];
- attributeMap.put(attr.getName(), attr);
- }
-
- return attributeMap;
- }
-
- /**
- * Constructor
- *
- * @deprecated the service controller no longer uses the service configurator and vice-versa
- * @param server the mbean server
- * @param serviceController the servie controller
- * @param serviceCreator the service creator
- */
- public ServiceConfigurator(MBeanServer server, ServiceController serviceController, ServiceCreator serviceCreator)
- {
- if (server == null)
- throw new IllegalArgumentException("Null server");
- if (serviceCreator == null)
- throw new IllegalArgumentException("Null serverCreator");
-
- this.server = server;
- this.serviceController = serviceController;
- this.serviceCreator = serviceCreator;
- if (serviceController != null)
- this.serviceBinding = serviceController.getServiceBinding();
- }
-
- /**
- * Dynamically plug-in a ServiceBinding policy
- * to possibly override the configuration of a service.
- *
- * @param serviceBinding policy
- */
- public void setServiceBinding(ServiceBinding serviceBinding)
- {
- this.serviceBinding = serviceBinding;
- }
-
- /**
- * The <code>install</code> method iterates through the mbean tags in the
- * supplied xml configuration and creates and configures the mbeans shown.
- * The mbean configuration can be nested.
- *
- * @deprecated the service controller no longer uses the service configurator and vice-versa
- * @param config the xml <code>Element</code> containing the configuration of
- * the mbeans to create and configure.
- * @param loaderName the classloader's ObjectName
- * @return a <code>List</code> of ObjectNames of created mbeans.
- * @throws DeploymentException if an error occurs
- */
- public List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException
- {
- // Parse the xml
- ServiceMetaDataParser parser = new ServiceMetaDataParser(config);
- List<ServiceMetaData> metaDatas = parser.parse();
-
- // Track the registered object names
- List<ObjectName> result = new ArrayList<ObjectName>(metaDatas.size());
-
- // Go through each mbean in the passed xml
- for (ServiceMetaData metaData : metaDatas)
- {
- ObjectName objectName = metaData.getObjectName();
- Collection<ServiceAttributeMetaData> attrs = metaData.getAttributes();
- // Install and configure the mbean
- try
- {
- ServiceCreator.install(server, objectName, metaData, null);
- result.add(objectName);
- configure(server, null, objectName, loaderName, attrs);
- if (serviceBinding != null)
- applyServiceConfig(server, objectName, serviceBinding);
- }
- catch (Throwable t)
- {
- // Something went wrong
- for (ObjectName name : result)
- {
- try
- {
- serviceCreator.remove(name);
- }
- catch (Exception e)
- {
- log.error("Error removing mbean after failed deployment: " + name, e);
- }
- }
- DeploymentException.rethrowAsDeploymentException("Error during install", t);
- }
- }
- return result;
- }
-
- /**
- * Builds a string that consists of the configuration elements of the
- * currently running MBeans registered in the server.
- *
- * @todo replace with more sophisticated mbean persistence mechanism.
- * @param server the MBeanServer
- * @param serviceController the service controller
- * @param objectNames the object names to retrieve
- * @return the xml string
- * @throws Exception Failed to construct configuration.
- */
- public static String getConfiguration(MBeanServer server, ServiceController serviceController, ObjectName[] objectNames) throws Exception
- {
- Writer out = new StringWriter();
-
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- DocumentBuilder builder = factory.newDocumentBuilder();
- Document doc = builder.newDocument();
-
- Element serverElement = doc.createElement("server");
-
- // Store attributes as XML
- for (int j = 0; j < objectNames.length; j++)
- {
- Element mbeanElement = internalGetConfiguration(doc, server, serviceController, objectNames[j]);
- serverElement.appendChild(mbeanElement);
- }
-
- doc.appendChild(serverElement);
-
- // Write configuration
- new DOMWriter(out).setPrettyprint(true).print(doc);
-
- out.close();
-
- // Return configuration
- return out.toString();
- }
-
- private static Element internalGetConfiguration(Document doc, MBeanServer server, ServiceController serviceController, ObjectName name) throws Exception
- {
- Element mbeanElement = doc.createElement("mbean");
- mbeanElement.setAttribute("name", name.toString());
-
- MBeanInfo info = server.getMBeanInfo(name);
- mbeanElement.setAttribute("code", info.getClassName());
- MBeanAttributeInfo[] attributes = info.getAttributes();
- boolean trace = log.isTraceEnabled();
- for (int i = 0; i < attributes.length; i++)
- {
- if (trace)
- log.trace("considering attribute: " + attributes[i]);
- if (attributes[i].isReadable() && attributes[i].isWritable())
- {
- Element attributeElement = null;
- if (attributes[i].getType().equals("javax.management.ObjectName"))
- {
- attributeElement = doc.createElement("depends");
- attributeElement.setAttribute("optional-attribute-name", attributes[i].getName());
- }
- else
- {
- attributeElement = doc.createElement("attribute");
- attributeElement.setAttribute("name", attributes[i].getName());
- }
- Object value = server.getAttribute(name, attributes[i].getName());
-
- if (value != null)
- {
- if (value instanceof Element)
- {
- attributeElement.appendChild(doc.importNode((Element) value, true));
- }
- else
- {
- attributeElement.appendChild(doc.createTextNode(value.toString()));
- }
- }
- mbeanElement.appendChild(attributeElement);
- }
- }
-
- ServiceContext sc = serviceController.getServiceContext(name);
- for (Iterator i = sc.iDependOn.iterator(); i.hasNext();)
- {
- ServiceContext needs = (ServiceContext) i.next();
- Element dependsElement = doc.createElement("depends");
- dependsElement.appendChild(doc.createTextNode(needs.objectName.toString()));
- mbeanElement.appendChild(dependsElement);
- }
-
- return mbeanElement;
- }
-
- /**
- * Builds a string that consists of the configuration elements of the
- * currently running MBeans registered in the server.
- *
- * TODO replace with more sophisticated mbean persistence mechanism.
- * @param objectNames the object names
- * @return the xml string
- * @throws Exception Failed to construct configuration.
- */
- public String getConfiguration(ObjectName[] objectNames) throws Exception
- {
- return getConfiguration(server, serviceController, objectNames);
- }
-
- /**
- * A utility method that transforms the contents of the argument element into
- * a StringBuffer representation that can be reparsed.
- *
- * [FIXME] This is not a general DOMUtils method because of its funny contract. It does not
- * support multiple child elements neither can it deal with text content.
- *
- * @param element - the parent dom element whose contents are to be extracted as an xml document string.
- * @return the xml document string.
- * @throws IOException for an error during IO
- * @throws TransformerException for an erro during transformation
- */
- public static StringBuffer getElementContent(Element element) throws IOException, TransformerException
- {
- NodeList children = element.getChildNodes();
- Element content = null;
- for (int n = 0; n < children.getLength(); n++)
- {
- Node node = children.item(n);
- if (node.getNodeType() == Node.ELEMENT_NODE)
- {
- content = (Element)node;
- break;
- }
- }
- if (content == null)
- return null;
-
- // Get a parsable representation of this elements content
- DOMSource source = new DOMSource(content);
- TransformerFactory tFactory = TransformerFactory.newInstance();
- Transformer transformer = tFactory.newTransformer();
- StringWriter sw = new StringWriter();
- StreamResult result = new StreamResult(sw);
- transformer.transform(source, result);
- sw.close();
- return sw.getBuffer();
- }
-}
\ No newline at end of file
Deleted: trunk/system/src/main/org/jboss/system/ServiceContext.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceContext.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceContext.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,130 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import java.io.Serializable;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import javax.management.ObjectName;
-
-/**
- * ServiceContext holds information for the Service
- *
- * @see Service
- * @see ServiceMBeanSupport
- *
- * @author <a href="mailto:marc.fleury at jboss.org">marc fleury</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ServiceContext implements Serializable
-{
- /** @since 4.0.2 */
- private static final long serialVersionUID = 7461263042948325633L;
-
- /** The possible string-fied states */
- private static final String[] stateNames = {
- "INSTALLED",
- "CONFIGURED",
- "CREATED",
- "RUNNING",
- "FAILED",
- "STOPPED",
- "DESTROYED",
- "NOTYETINSTALLED"
- };
-
- /** Valid service states */
- public static final int INSTALLED = 0;
- public static final int CONFIGURED = 1;
- public static final int CREATED = 2;
- public static final int RUNNING = 3;
- public static final int FAILED = 4;
- public static final int STOPPED = 5;
- public static final int DESTROYED = 6;
- public static final int NOTYETINSTALLED = 7;
-
- /** The name of the service **/
- public ObjectName objectName;
-
- /** State of the service **/
- public int state = NOTYETINSTALLED;
-
- /** Dependent beans **/
- public List<ServiceContext> iDependOn = new LinkedList<ServiceContext>();
-
- /** Beans that depend on me **/
- public List<ServiceContext> dependsOnMe = new LinkedList<ServiceContext>();
-
- /** The fancy proxy to my service calls **/
- public transient Service proxy;
-
- /** Cause for failure */
- public Throwable problem;
-
- public String getStateString()
- {
- return getStateString(state);
- }
-
- public static String getStateString(int stateInt)
- {
- return stateNames[stateInt];
- }
-
- public String toString()
- {
- StringBuffer sbuf = new StringBuffer(512);
-
- sbuf.append("ObjectName: ").append(objectName);
- sbuf.append("\n State: ").append(stateNames[state]);
-
- if (state == FAILED && problem != null)
- {
- sbuf.append("\n Reason: ").append(problem.toString());
- }
- printList(sbuf, "\n I Depend On:", iDependOn);
- printList(sbuf, "\n Depends On Me:", dependsOnMe);
-
- // this magically makes *all* jmx-console outputs look better :)
- sbuf.append("\n");
-
- return sbuf.toString();
- }
-
- private void printList(StringBuffer sbuf, String msg, List ctxs)
- {
- if (ctxs.size() > 0)
- {
- // only out stuff, if there are indeed dependencies
- sbuf.append(msg);
- for (Iterator i = ctxs.iterator(); i.hasNext(); )
- {
- ServiceContext sc = (ServiceContext) i.next();
- sbuf.append("\n ");
- sbuf.append(sc.objectName);
- }
- }
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceController.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceController.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceController.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,713 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.CopyOnWriteArrayList;
-
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.Notification;
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.Controller;
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.dependency.spi.ControllerMode;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.dependency.spi.DependencyInfo;
-import org.jboss.dependency.spi.DependencyItem;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.DeploymentState;
-import org.jboss.kernel.Kernel;
-import org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap;
-import org.jboss.kernel.spi.dependency.KernelController;
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.system.microcontainer.LifecycleDependencyItem;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-import org.w3c.dom.Element;
-
-/**
- * This is the main Service Controller. A controller can deploy a service to a
- * jboss.system It installs by delegating, it configures by delegating<p>
- *
- * This class has been rewritten to delegate to the microcontainer's
- * generic controller. Like the original ServiceController, all state
- * transitions must be handled manually, e.g. driven by the deployer
- * invoking create, start, stop, etc.
- * That is with one exception; we register ourselves an automatic context.
- *
- * @see org.jboss.system.Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ServiceController extends JBossNotificationBroadcasterSupport
- implements ServiceControllerMBean, MBeanRegistration
-{
- /** The ObjectName of the default loader repository */
- public static final ObjectName DEFAULT_LOADER_REPOSITORY = ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
-
- /** The operation name for lifecycle */
- public static final String JBOSS_INTERNAL_LIFECYCLE = "jbossInternalLifecycle";
-
- /** The signature for lifecycle operations */
- public static final String[] JBOSS_INTERNAL_LIFECYCLE_SIG = new String[] { String.class.getName() };
-
- /** Class logger. */
- private static final Logger log = Logger.getLogger(ServiceController.class);
-
- /** The kernel */
- protected Kernel kernel;
-
- /** A callback to the JMX MBeanServer */
- protected MBeanServer server;
-
- /** The service binding */
- protected ServiceBinding serviceBinding;
-
- /** The contexts */
- protected Map<ObjectName, ServiceControllerContext> installed = new ConcurrentHashMap<ObjectName, ServiceControllerContext>();
-
- /** The contexts in installation order */
- protected CopyOnWriteArrayList<ServiceControllerContext> installedOrder = new CopyOnWriteArrayList<ServiceControllerContext>();
-
- /**
- * Get the MBeanServer
- *
- * @return the server
- */
- public MBeanServer getMBeanServer()
- {
- return server;
- }
-
- /**
- * Set the server.
- *
- * @param server the server.
- */
- public void setMBeanServer(MBeanServer server)
- {
- this.server = server;
- }
-
- /**
- * Get the kernel.
- *
- * @return the kernel.
- */
- public Kernel getKernel()
- {
- return kernel;
- }
-
- /**
- * Set the kernel.
- *
- * @param kernel the kernel.
- */
- public void setKernel(Kernel kernel)
- {
- this.kernel = kernel;
- }
-
- /**
- * Get the serviceBinding.
- *
- * @return the serviceBinding.
- */
- public ServiceBinding getServiceBinding()
- {
- return serviceBinding;
- }
-
- /**
- * Plugin a ServiceBinding policy
- *
- * @param serviceBinding policy
- */
- public void setServiceBinding(ServiceBinding serviceBinding)
- {
- this.serviceBinding = serviceBinding;
- }
-
- public List<ServiceContext> listDeployed()
- {
- // Retrieve the service context from all our installed contexts
- ArrayList<ServiceContext> result = new ArrayList<ServiceContext>(installedOrder.size());
- for (ServiceControllerContext context : installedOrder)
- result.add(context.getServiceContext());
- return result;
- }
-
- public List<ServiceContext> listIncompletelyDeployed()
- {
- // Retrieve the service contexts that are not deployed properly
- ArrayList<ServiceContext> result = new ArrayList<ServiceContext>();
- for (ServiceControllerContext context : installedOrder)
- {
- ServiceContext sc = context.getServiceContext();
- if (sc.state != ServiceContext.CREATED &&
- sc.state != ServiceContext.RUNNING &&
- sc.state != ServiceContext.STOPPED &&
- sc.state != ServiceContext.DESTROYED)
- {
- result.add(sc);
- }
- }
- return result;
- }
-
- public List<ObjectName> listDeployedNames()
- {
- // Get all the object names from our installed contexts
- ArrayList<ObjectName> result = new ArrayList<ObjectName>(installed.size());
- for (ObjectName name : installed.keySet())
- result.add(name);
- return result;
- }
-
- public String listConfiguration(ObjectName[] objectNames) throws Exception
- {
- return ServiceConfigurator.getConfiguration(server, this, objectNames);
- }
-
- public void validateDeploymentState(DeploymentInfo di, DeploymentState state)
- {
- ArrayList<ObjectName> mbeans = new ArrayList<ObjectName>(di.mbeans);
- if (di.deployedObject != null)
- mbeans.add(di.deployedObject);
- boolean mbeansStateIsValid = true;
- for (int m = 0; m < mbeans.size(); ++m)
- {
- ObjectName serviceName = mbeans.get(m);
- ServiceContext ctx = getServiceContext(serviceName);
- if (ctx != null && state == DeploymentState.STARTED)
- mbeansStateIsValid &= ctx.state == ServiceContext.RUNNING;
- }
- if (mbeansStateIsValid == true)
- di.state = state;
- }
-
- public List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException
- {
- KernelController controller = kernel.getController();
-
- // Parse the xml
- ServiceMetaDataParser parser = new ServiceMetaDataParser(config);
- List<ServiceMetaData> metaDatas = parser.parse();
-
- // Track the registered mbeans both for returning the result
- // and uninstalling in the event of an error
- List<ObjectName> result = new ArrayList<ObjectName>(metaDatas.size());
- List<ServiceControllerContext> contexts = new ArrayList<ServiceControllerContext>(metaDatas.size());
-
- // Go through each mbean in the passed xml
- for (ServiceMetaData metaData : metaDatas)
- {
- metaData.setClassLoaderName(loaderName);
-
- // Install the context to the configured level
- ServiceControllerContext context = new ServiceControllerContext(this, metaData);
- try
- {
- doInstall(controller, context);
- contexts.add(context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- result.add(context.getObjectName());
- }
- catch (Throwable t)
- {
- // Something went wrong
- for (ServiceControllerContext ctx : contexts)
- safelyRemoveAnyRegisteredContext(ctx);
-
- DeploymentException.rethrowAsDeploymentException("Error during install", t);
- }
- }
- return result;
- }
-
- /**
- * Install an MBean without any meta data
- *
- * @param name the object name
- * @param object the mbean object
- * @throws DeploymentException for any error
- */
- public void install(ObjectName name, Object object) throws DeploymentException
- {
- if (name == null)
- throw new IllegalArgumentException("Null name");
- if (object == null)
- throw new IllegalArgumentException("Null object");
-
- KernelController controller = kernel.getController();
-
- ServiceControllerContext context = new ServiceControllerContext(this, name, object);
- try
- {
- doInstall(controller, context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- }
- catch (Throwable t)
- {
- // Something went wrong
- safelyRemoveAnyRegisteredContext(context);
-
- DeploymentException.rethrowAsDeploymentException("Error during install", t);
- }
- }
-
- public void register(ObjectName serviceName) throws Exception
- {
- register(serviceName, null);
- }
-
- public void register(ObjectName serviceName, Collection<ObjectName> depends) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to register null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("Registering service " + serviceName);
-
- // This is an already registered mbean
- KernelController controller = kernel.getController();
- ServiceControllerContext context = new ServiceControllerContext(this, serviceName);
- if (depends != null)
- addDependencies(context, depends);
-
- // Install the context to the configured level
- try
- {
- doInstall(controller, context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- }
- catch (Throwable t)
- {
- // Something went wrong
- safelyRemoveAnyRegisteredContext(context);
-
- DeploymentException.rethrowAsDeploymentException("Error during register: " + serviceName, t);
- }
- }
-
- public void create(ObjectName serviceName) throws Exception
- {
- create(serviceName, null);
- }
-
- public void create(ObjectName serviceName, Collection<ObjectName> depends) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to create null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("Creating service " + serviceName);
-
- // Register if not already done so
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- register(serviceName, depends);
- context = installed.get(serviceName);
- }
- ServiceContext ctx = context.getServiceContext();
-
- // If we are already created (can happen in dependencies) or failed just return
- if (ctx.state == ServiceContext.CREATED
- || ctx.state == ServiceContext.RUNNING
- || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring create request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go to the created state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.CREATE, "create");
- }
- catch (Throwable t)
- {
- log.warn("Problem creating service " + serviceName, t);
- }
- }
-
- public void start(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to start null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("starting service " + serviceName);
-
- // Register if not already done so
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- register(serviceName, null);
- context = installed.get(serviceName);
- }
- ServiceContext ctx = context.getServiceContext();
-
- // If we are already started (can happen in dependencies) just return
- if (ctx.state == ServiceContext.RUNNING || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring start request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go to the fully installed state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.INSTALLED, "start");
- }
- catch (Throwable t)
- {
- log.warn("Problem starting service " + serviceName, t);
- }
- }
-
- public void restart(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to restart null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("restarting service " + serviceName);
- stop(serviceName);
- start(serviceName);
- }
-
- public void stop(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to stop null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("stopping service: " + serviceName);
-
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- log.warn("Ignoring request to stop nonexistent service: " + serviceName);
- return;
- }
-
- // If we are already stopped (can happen in dependencies) just return
- ServiceContext ctx = context.getServiceContext();
- if (ctx.state != ServiceContext.RUNNING)
- {
- log.debug("Ignoring stop request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go back to the created state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.CREATE, null);
- }
- catch (Throwable t)
- {
- log.warn("Problem stopping service " + serviceName, t);
- }
- }
-
- public void destroy(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to destroy null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("destroying service: " + serviceName);
-
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- log.warn("Ignoring request to destroy nonexistent service: " + serviceName);
- return;
- }
-
- // If we are already destroyed (can happen in dependencies) just return
- ServiceContext ctx = context.getServiceContext();
- if (ctx.state == ServiceContext.DESTROYED || ctx.state == ServiceContext.NOTYETINSTALLED || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring destroy request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go the configured state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.CONFIGURED, null);
- }
- catch (Throwable t)
- {
- log.warn("Problem stopping service " + serviceName, t);
- }
- }
-
- public void remove(ObjectName objectName) throws Exception
- {
- if (objectName == null)
- {
- log.warn("Ignoring request to remove null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- // Removal can be attempted twice, this is because ServiceMBeanSupport does a "double check"
- // to make sure the ServiceController is tidied up
- // However, if the tidyup is done correctly, it invokes this method recursively:
- // ServiceController::remove -> MBeanServer::unregisterMBean
- // ServiceMBeanSupport::postDeregister -> ServiceController::remove
- ServiceControllerContext context = installed.remove(objectName);
- if (context == null)
- {
- log.trace("Ignoring request to remove nonexistent service: " + objectName);
- return;
- }
- installedOrder.remove(context);
- log.debug("removing service: " + objectName);
-
- // Uninstall the context
- safelyRemoveAnyRegisteredContext(context);
- }
-
- public ServiceContext getServiceContext(ObjectName serviceName)
- {
- ServiceControllerContext context = installed.get(serviceName);
- if (context != null)
- return context.getServiceContext();
- return null;
- }
-
- public void shutdown()
- {
- log.debug("Stopping " + installedOrder.size() + " services");
-
- KernelController controller = kernel.getController();
-
- int serviceCounter = 0;
-
- // Uninstall all the contexts we know about
- ListIterator<ServiceControllerContext> iterator = installedOrder.listIterator(installedOrder.size());
- while (iterator.hasPrevious())
- {
- ServiceControllerContext context = iterator.previous();
- controller.uninstall(context.getName());
- ++serviceCounter;
- }
- log.debug("Stopped " + serviceCounter + " services");
- }
-
- public ObjectName preRegister(MBeanServer server, ObjectName name)
- throws Exception
- {
- this.server = server;
-
- if( kernel == null )
- {
- // Bootstrap the microcontainer.
- BasicBootstrap bootstrap = new BasicBootstrap();
- bootstrap.run();
- kernel = bootstrap.getKernel();
- }
-
- log.debug("Controller MBean online");
- return name == null ? OBJECT_NAME : name;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- if (registrationDone.booleanValue() == false)
- log.fatal("Registration of ServiceController failed");
- else
- {
- // Register the ServiceController as a running service
- KernelController controller = kernel.getController();
- ServiceControllerContext context = new ServiceControllerContext(this, ServiceControllerMBean.OBJECT_NAME);
- context.setMode(ControllerMode.AUTOMATIC);
- try
- {
- controller.install(context);
- }
- catch (Throwable t)
- {
- log.fatal("Error registering service controller", t);
- }
- }
- }
-
- public void preDeregister()
- throws Exception
- {
- }
-
- public void postDeregister()
- {
- installed.clear();
- installedOrder.clear();
- server = null;
- }
-
- /**
- * Install a context
- *
- * @param controller the controller
- * @param context the context
- * @throws Throwable for any error
- */
- private void doInstall(KernelController controller, ServiceControllerContext context) throws Throwable
- {
- controller.install(context);
- installed.put(context.getObjectName(), context);
- log.debug("installed service: "+context.getObjectName());
- installedOrder.add(context);
- }
-
- /**
- * Change a context
- *
- * @param controller the controller
- * @param context the context
- * @param requiredState the require state
- * @param logWait log the waiting dependencies
- * @throws Throwable for any error
- */
- private void doChange(KernelController controller, ServiceControllerContext context, ControllerState requiredState, String logWait) throws Throwable
- {
- if (ControllerMode.ON_DEMAND.equals(context.getMode()) == false)
- {
- controller.change(context, requiredState);
- ControllerState state = context.getState();
- if (logWait != null && requiredState.equals(state) == false && state != ControllerState.ERROR)
- log.debug("Waiting in " + logWait + " of " + context.getObjectName() + " on " + getUnresolvedDependencies(context, requiredState));
- }
- }
-
- /**
- * Sends outs controller notifications about service lifecycle events
- *
- * @param type the notification type
- * @param serviceName the service name
- */
- public void sendControllerNotification(String type, ObjectName serviceName)
- {
- Notification notification = new Notification(type, this, super.nextNotificationSequenceNumber());
- notification.setUserData(serviceName);
- sendNotification(notification);
- }
-
- /**
- * Add the passed lifecycle dependencies to the context
- *
- * @param context the context
- * @param depends the dependencies
- */
- private void addDependencies(ServiceControllerContext context, Collection<ObjectName> depends)
- {
- DependencyInfo info = context.getDependencyInfo();
- for (ObjectName other : depends)
- {
- info.addIDependOn(new LifecycleDependencyItem(context.getName(), other.getCanonicalName(), ControllerState.CREATE));
- info.addIDependOn(new LifecycleDependencyItem(context.getName(), other.getCanonicalName(), ControllerState.START));
- }
- }
-
- /**
- * Get the unresolved dependencies
- *
- * @param context the context
- * @param state the state we want to move to
- * @return the unresolved dependencies
- */
- private String getUnresolvedDependencies(ServiceControllerContext context, ControllerState state)
- {
- boolean first = true;
-
- StringBuilder builder = new StringBuilder();
- for (DependencyItem item : context.getDependencyInfo().getUnresolvedDependencies())
- {
- if (item.isResolved() == false && item.getWhenRequired() == state)
- {
- if (first)
- first = false;
- else
- builder.append(' ');
- builder.append(item.getIDependOn());
- }
- }
- return builder.toString();
- }
-
- /**
- * Safely remove any potentially registered context (usually after an error)
- *
- * @param ctx the context
- */
- private void safelyRemoveAnyRegisteredContext(ServiceControllerContext ctx)
- {
- // First the context must have a controller
- Controller controller = ctx.getController();
- if (controller != null)
- {
- // The name must be registered and it must be our context
- Object name = ctx.getName();
- ControllerContext registered = controller.getContext(name, null);
- if (registered == ctx)
- controller.uninstall(name);
- }
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceControllerMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceControllerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceControllerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,195 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.Collection;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.DeploymentState;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.w3c.dom.Element;
-
-/**
- * ServiceController MBean interface.
- *
- * @see org.jboss.system.Service
- */
-public interface ServiceControllerMBean
-{
- /** The default ObjectName */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:service=ServiceController");
-
- /**
- * Plugin a ServiceBinding policy
- *
- * @param serviceBinding policy
- */
- void setServiceBinding(ServiceBinding serviceBinding);
-
- /**
- * Lists the ServiceContexts of deployed mbeans
- *
- * @return the list of ServiceContexts for mbeans deployed through ServiceController.
- */
- List<ServiceContext> listDeployed();
-
- /**
- * The <code>listIncompletelyDeployed</code> method returns the
- * service contexts for the mbeans whose status is not CREATED,
- * RUNNING, STOPPED or DESTROYED. An MBean that has reached one
- * of the above states has its dependencies resolved.
- *
- * @return a List<ServiceContext>
- */
- List<ServiceContext> listIncompletelyDeployed();
-
- /**
- * lists ObjectNames of deployed mbeans deployed through
- * serviceController.
- *
- * @return a list of ObjectNames of deployed mbeans.
- */
- List<ObjectName> listDeployedNames();
-
- /**
- * Gets the Configuration attribute of the ServiceController object
- *
- * @param objectNames Description of Parameter
- * @return The Configuration value
- * @throws Exception Description of Exception
- */
- String listConfiguration(ObjectName[] objectNames) throws Exception;
-
- /**
- * Go through the mbeans of the DeploymentInfo and validate that
- * they are in a state at least equal to that of the argument state
- *
- * @param di the deployment info
- * @param state the deployment state
- */
- void validateDeploymentState(DeploymentInfo di, DeploymentState state);
-
- /**
- * Deploy the beans; deploy means "instantiate and configure" so the MBean
- * is created in the MBeanServer. You must call "create" and "start" separately
- * on the MBean to affect the service lifecycle deploy doesn't bother with service
- * lifecycle only MBean instanciation/registration/configuration.
- *
- * @param config
- * @param loaderName
- * @return Description of the Returned Value
- * @throws DeploymentException
- */
- List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException;
-
- /**
- * Register the mbean against the microkernel with no dependencies.
- *
- * @see #register(ObjectName, java.util.Collection)
- * @param serviceName the object name
- * @throws Exception for any error
- */
- void register(ObjectName serviceName) throws Exception;
-
- /**
- * Register the mbean against the microkernel with dependencies.
- *
- * @param serviceName the object name
- * @param depends the dependencies
- * @throws Exception for any error
- */
- void register(ObjectName serviceName, Collection<ObjectName> depends) throws Exception;
-
- /**
- * Create a service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void create(ObjectName serviceName) throws Exception;
-
- /**
- * Create a service with given dependencies
- *
- * @param serviceName Description of Parameter
- * @param depends the dependencies
- * @throws Exception Description of Exception
- */
- void create(ObjectName serviceName, Collection<ObjectName> depends) throws Exception;
-
- /**
- * Starts the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void start(ObjectName serviceName) throws Exception;
-
- /**
- * Stops and restarts the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void restart(ObjectName serviceName) throws Exception;
-
- /**
- * Stop the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void stop(ObjectName serviceName) throws Exception;
-
- /**
- * Destroy the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void destroy(ObjectName serviceName) throws Exception;
-
- /**
- * This MBean is going bye bye
- *
- * @param objectName Description of Parameter
- * @throws Exception Description of Exception
- */
- void remove(ObjectName objectName) throws Exception;
-
- /**
- * Describe <code>shutdown</code> method here.
- */
- void shutdown();
-
- /**
- * Lookup the ServiceContext for the given serviceName
- *
- * @param serviceName the service name
- * @return the service context
- */
- ServiceContext getServiceContext(ObjectName serviceName);
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceCreator.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceCreator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceCreator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,378 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.net.URL;
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-import javax.management.StandardMBean;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.server.registry.MBeanEntry;
-import org.jboss.mx.service.ServiceConstants;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.metadata.ServiceConstructorMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.util.UnreachableStatementException;
-import org.w3c.dom.Element;
-
-/**
- * A helper class for the controller.
- *
- * @see Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ServiceCreator
-{
- /** Instance logger. */
- private static final Logger log = Logger.getLogger(ServiceCreator.class);
-
- /** The MBean Registry Object Name */
- private static ObjectName MBEAN_REGISTRY = ObjectNameFactory.create(ServerConstants.MBEAN_REGISTRY);
-
- /** The server */
- private MBeanServer server;
-
- /**
- * Install an MBean
- *
- * @todo expand the meta data to include a pre-instantiated object
- * @param server the mbean server
- * @param objectName the object name
- * @param metaData the service metadata
- * @param mbean any mbean instance
- * @return the installed instance
- * @throws Exception for any error
- */
- public static ServiceInstance install(MBeanServer server, ObjectName objectName, ServiceMetaData metaData, Object mbean) throws Exception
- {
- if (server == null)
- throw new IllegalArgumentException("Null MBeanServer");
- if (objectName == null)
- throw new IllegalArgumentException("Null ObjectName");
- if (metaData == null && mbean == null)
- throw new IllegalArgumentException("Either metadata or an mbean object must be supplied");
-
- // Check for duplicate
- if (server.isRegistered(objectName))
- throw new DeploymentException("Trying to install an already registered mbean: " + objectName);
-
- try
- {
- ServiceInstance result = null;
-
- // No meta data just register directly
- if (metaData == null)
- {
- ObjectInstance instance = server.registerMBean(mbean, objectName);
- result = new ServiceInstance(instance, mbean);
- }
- else
- {
- String code = metaData.getCode();
- if (code == null || code.trim().length() == 0)
- throw new ConfigurationException("Missing or empty code for mbean " + objectName);
-
- String xmbeanDD = metaData.getXMBeanDD();
-
- // Not an XMBean
- if (xmbeanDD == null)
- {
- String interfaceName = metaData.getInterfaceName();
- if (interfaceName != null)
- result = installStandardMBean(server, objectName, metaData);
- else
- result = installPlainMBean(server, objectName, metaData);
- }
- // Embedded XMBean Descriptor
- else if (xmbeanDD.length() == 0)
- result = installEmbeddedXMBean(server, objectName, metaData);
- // Reference to external XMBean descriptor
- else
- result = installExternalXMBean(server, objectName, metaData);
- }
-
- log.debug("Created mbean: " + objectName);
- return result;
- }
- catch (Throwable e)
- {
- Throwable newE = JMXExceptionDecoder.decode(e);
-
- // didn't work, unregister in case the jmx agent is screwed.
- try
- {
- server.unregisterMBean(objectName);
- }
- catch (Throwable ignore)
- {
- }
-
- DeploymentException.rethrowAsDeploymentException("Unable to createMBean for " + objectName, newE);
- throw new UnreachableStatementException();
- }
- }
-
- /**
- * Install a StandardMBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installStandardMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
- String interfaceName = metaData.getInterfaceName();
-
- Class intf = loader.loadClass(interfaceName);
- log.debug("About to create bean resource: " + objectName + " with code: " + code + " and interface " + interfaceName);
- Object resource = server.instantiate(code,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
-
- log.debug("About to register StandardMBean : " + objectName);
- ObjectInstance instance = server.createMBean(StandardMBean.class.getName(),
- objectName,
- loaderName,
- new Object[] { resource, intf },
- new String[] { Object.class.getName() , Class.class.getName() });
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Install a plain MBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installPlainMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
-
- // This is a standard or dynamic mbean
- log.debug("About to create bean: " + objectName + " with code: " + code);
- ObjectInstance instance = server.createMBean(code,
- objectName,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
-
- MBeanEntry entry = (MBeanEntry) server.invoke(MBEAN_REGISTRY, "get", new Object[] { objectName }, new String[] { ObjectName.class.getName() });
- Object resource = entry.getResourceInstance();
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Install an embedded XMBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installEmbeddedXMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
-
- // This is an xmbean with an embedded mbean descriptor
- log.debug("About to create xmbean object: " + objectName + " with code: " + code + " with embedded descriptor");
- //xmbean: construct object first.
- Object resource = server.instantiate(code,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
-
- String xmbeanCode = metaData.getXMBeanCode();
- Element mbeanDescriptor = metaData.getXMBeanDescriptor();
- Object[] args = { resource, mbeanDescriptor, ServiceConstants.PUBLIC_JBOSSMX_XMBEAN_DTD_1_0 };
- String[] sig = { Object.class.getName(), Element.class.getName(), String.class.getName() };
- ObjectInstance instance = server.createMBean(xmbeanCode,
- objectName,
- loaderName,
- args,
- sig);
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Install an external XMBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installExternalXMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
- String xmbeanDD = metaData.getXMBeanDD();
-
- // This is an xmbean with an external descriptor
- log.debug("About to create xmbean object: " + objectName + " with code: " + code + " with descriptor: " + xmbeanDD);
- //xmbean: construct object first.
- Object resource = server.instantiate(code,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
- // Try to find the dd first as a resource then as a URL
- URL xmbeanddUrl = null;
- try
- {
- xmbeanddUrl = resource.getClass().getClassLoader().getResource(xmbeanDD);
- }
- catch (Exception e)
- {
- }
-
- if (xmbeanddUrl == null)
- xmbeanddUrl = new URL(xmbeanDD);
-
- String xmbeanCode = metaData.getXMBeanCode();
-
- //now create the mbean
- Object[] args = { resource, xmbeanddUrl };
- String[] sig = { Object.class.getName(), URL.class.getName() };
- ObjectInstance instance = server.createMBean(xmbeanCode,
- objectName,
- loaderName,
- args,
- sig);
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Uninstall an MBean
- *
- * @param server the mbean server
- * @param objectName the object name
- */
- public static void uninstall(MBeanServer server, ObjectName objectName)
- {
- if (server == null)
- throw new IllegalArgumentException("Null MBeanServer");
- if (objectName == null)
- throw new IllegalArgumentException("Null ObjectName");
- try
- {
- log.debug("Removing mbean from server: " + objectName);
- server.unregisterMBean(objectName);
- }
- catch (Throwable t)
- {
- log.debug("Error unregistering mbean " + objectName, t);
- }
- }
-
- /**
- * Create a new ServiceCreator
- *
- * @deprecated This is no longer used and will be going away
- * @param server the mbean server
- */
- public ServiceCreator(final MBeanServer server)
- {
- if (server == null)
- throw new IllegalArgumentException("Null MBeanServer");
- this.server = server;
- }
-
- /**
- * Clean shutdown
- */
- public void shutdown()
- {
- this.server = null;
- }
-
- /**
- * Parses the given configuration document and creates MBean
- * instances in the current MBean server.
- *
- * @deprecated This is no longer used and will be going away
- * @param mbeanName the object name
- * @param loaderName the classloader
- * @param mbeanElement the config
- * @return the created object instance
- * @throws Exception for any error
- */
- public ObjectInstance install(ObjectName mbeanName, ObjectName loaderName, Element mbeanElement) throws Exception
- {
- if (mbeanName == null)
- throw new IllegalArgumentException("Null mbeanName");
- if (mbeanElement == null)
- throw new IllegalArgumentException("Null mbean element");
-
- ServiceMetaDataParser parser = new ServiceMetaDataParser(mbeanElement);
- List<ServiceMetaData> metaDatas = parser.parse();
- if (metaDatas.isEmpty())
- throw new DeploymentException("No mbeans found in passed configuration for " + mbeanName);
- ServiceMetaData metaData = metaDatas.get(0);
- metaData.setClassLoaderName(loaderName);
- ServiceInstance instance = install(server, mbeanName, metaData, null);
- return instance.getObjectInstance();
- }
-
- /**
- * Remove the installed object
- *
- * @param name the object name
- * @throws Exception for any error
- */
- public void remove(ObjectName name) throws Exception
- {
- if (name == null)
- throw new IllegalArgumentException("Null name");
- uninstall(server, name);
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,354 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import java.util.List;
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanConstructorInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanParameterInfo;
-import javax.management.ReflectionException;
-
-import org.jboss.logging.Logger;
-
-/**
- * <description>
- *
- * @see <related>
- *
- * @author <a href="mailto:sacha.labourey at cogito-info.ch">Sacha Labourey</a>.
- * @version $Revision$
- *
- * <p><b>Revisions:</b>
- *
- * <p><b>6 janv. 2003 Sacha Labourey:</b>
- * <ul>
- * <li> First implementation </li>
- * </ul>
- */
-public class ServiceDynamicMBeanSupport
- extends ServiceMBeanSupport
- implements DynamicMBean
-{
-
- // Constants -----------------------------------------------------
-
- // Attributes ----------------------------------------------------
-
- // Static --------------------------------------------------------
-
- // Constructors --------------------------------------------------
-
- public ServiceDynamicMBeanSupport()
- {
- super();
- }
-
- public ServiceDynamicMBeanSupport(Class type)
- {
- super(type);
- }
-
- public ServiceDynamicMBeanSupport(String category)
- {
- super(category);
- }
-
- public ServiceDynamicMBeanSupport(Logger log)
- {
- super(log);
- }
-
- // Public --------------------------------------------------------
-
- // DynamicMBean implementation -----------------------------------
-
- public Object getAttribute(String attribute)
- throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- // locally managed attributes!
- //
- if("State".equals(attribute))
- {
- return new Integer(getState());
- }
- if("StateString".equals(attribute))
- {
- return getStateString();
- }
- if("Name".equals(attribute))
- {
- return getName();
- }
-
- // Wrapped attributes?
- //
- return getInternalAttribute (attribute);
-
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature)
- throws MBeanException, ReflectionException
- {
- try
- {
- if (ServiceController.JBOSS_INTERNAL_LIFECYCLE.equals(actionName))
- {
- jbossInternalLifecycle((String) params[0]);
- return null;
- }
- if (params == null || params.length == 0)
- {
- if ("create".equals(actionName))
- {
- create(); return null;
- }
- else if ("start".equals(actionName))
- {
- start(); return null;
- }
- else if ("stop".equals(actionName))
- {
- stop(); return null;
- }
- else if ("destroy".equals(actionName))
- {
- destroy(); return null;
- }
- }
- }
- catch (Exception e)
- {
- throw new MBeanException(e, "Exception in service lifecyle operation: " + actionName);
- }
-
- // If I am here, it means that the invocation has not been handled locally
- //
- try
- {
- return internalInvoke (actionName, params, signature);
- }
- catch (Exception e)
- {
- throw new MBeanException(e,
- "Exception invoking: " + actionName);
- }
- }
-
- public void setAttribute(Attribute attribute)
- throws
- AttributeNotFoundException,
- InvalidAttributeValueException,
- MBeanException,
- ReflectionException
- {
- setInternalAttribute (attribute);
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- AttributeList list = new AttributeList();
- if (attributes == null)
- return list;
- for (int i = 0; i < attributes.size(); ++i)
- {
- Attribute attribute = (Attribute) attributes.get(i);
- try
- {
- setAttribute(attribute);
- list.add(attribute);
- }
- catch (Throwable t)
- {
- log.debug("Error setting attribute " + attribute.getName(), t);
- }
- }
- return list;
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- AttributeList list = new AttributeList();
- if (attributes == null)
- return list;
- for (int i = 0; i < attributes.length; ++i)
- {
- try
- {
- Object value = getAttribute(attributes[i]);
- list.add(new Attribute(attributes[i], value));
- }
- catch (Throwable t)
- {
- log.debug("Error getting attribute " + attributes[i], t);
- }
- }
- return list;
- }
-
- public MBeanInfo getMBeanInfo()
- {
- MBeanParameterInfo[] noParams = new MBeanParameterInfo[] {};
-
- MBeanConstructorInfo[] ctorInfo = getInternalConstructorInfo();
-
- MBeanAttributeInfo[] attrs = getInternalAttributeInfo();
- MBeanAttributeInfo[] attrInfo = new MBeanAttributeInfo[3 + attrs.length];
- attrInfo[0] = new MBeanAttributeInfo("Name",
- "java.lang.String",
- "Return the service name",
- true,
- false,
- false);
- attrInfo[1] = new MBeanAttributeInfo("State",
- "int",
- "Return the service state",
- true,
- false,
- false);
- attrInfo[2] = new MBeanAttributeInfo("StateString",
- "java.lang.String",
- "Return the service's state as a String",
- true,
- false,
- false);
- System.arraycopy(attrs, 0, attrInfo, 3, attrs.length);
-
- MBeanParameterInfo[] jbossInternalLifecycleParms = new MBeanParameterInfo[1];
- jbossInternalLifecycleParms[0] = new MBeanParameterInfo("method", String.class.getName(), "The lifecycle method");
-
- MBeanOperationInfo[] ops = getInternalOperationInfo();
- MBeanOperationInfo[] opInfo = new MBeanOperationInfo[5 + ops.length];
- opInfo[0] = new MBeanOperationInfo("create",
- "create service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[1] = new MBeanOperationInfo("start",
- "start service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[2] = new MBeanOperationInfo("stop",
- "stop service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[3] = new MBeanOperationInfo("destroy",
- "destroy service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[4] = new MBeanOperationInfo(ServiceController.JBOSS_INTERNAL_LIFECYCLE,
- "Internal lifecycle (for internal use)",
- jbossInternalLifecycleParms,
- "void",
- MBeanOperationInfo.ACTION);
-
- System.arraycopy(ops, 0, opInfo, 5, ops.length);
-
- MBeanNotificationInfo[] notifyInfo = getInternalNotificationInfo();
- return new MBeanInfo(getClass().getName(),
- getInternalDescription(),
- attrInfo,
- ctorInfo,
- opInfo,
- notifyInfo);
- }
-
- // Y overrides ---------------------------------------------------
-
- // Package protected ---------------------------------------------
-
- // Protected -----------------------------------------------------
-
- protected String getInternalDescription()
- {
- return "DynamicMBean Service";
- }
-
- protected MBeanConstructorInfo[] getInternalConstructorInfo()
- {
- return new MBeanConstructorInfo[0];
- }
-
- protected MBeanAttributeInfo[] getInternalAttributeInfo()
- {
- return new MBeanAttributeInfo[0];
- }
-
- protected MBeanOperationInfo[] getInternalOperationInfo()
- {
- return new MBeanOperationInfo[0];
- }
-
- protected MBeanNotificationInfo[] getInternalNotificationInfo()
- {
- return new MBeanNotificationInfo[0];
- }
-
- protected Object getInternalAttribute(String attribute)
- throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- throw new AttributeNotFoundException ("Attribute not found " + attribute);
- }
-
- protected void setInternalAttribute(Attribute attribute)
- throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- throw new AttributeNotFoundException ("Attribute not found " + attribute);
- }
-
- protected Object internalInvoke(String actionName, Object[] params, String[] signature)
- throws MBeanException, ReflectionException
- {
- StringBuffer buffer = new StringBuffer();
- buffer.append(actionName);
- buffer.append('(');
- for (int i = 0; i < signature.length; ++i)
- {
- buffer.append(signature[i]);
- if (i < signature.length - 1)
- buffer.append(", ");
- }
- buffer.append(')');
- throw new MBeanException(new Exception("Operation not found " + buffer.toString()), "Operation not found " + actionName);
- }
-
-
- // Private -------------------------------------------------------
-
- // Inner classes -------------------------------------------------
-
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceFactory.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-/**
- * The ServiceFactory interface is used to obtain a Service
- * proxy instance for a named MBean.
- *
- * @author <a href="mailto:Scott_Stark at displayscape.com">Scott Stark</a>.
- * @version $Revision$
- */
-public interface ServiceFactory
-{
- /**
- * Create a Service proxy instance for the MBean given by name.
- *
- * @param server The MBeanServer instance
- * @param name The name of the MBean that wishes to be managed by
- * the JBoss ServiceControl service.
- */
- Service createService(MBeanServer server, ObjectName name);
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceInstance.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceInstance.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceInstance.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,78 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.ObjectInstance;
-
-/**
- * ServiceInstance.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceInstance
-{
- /** The object instance */
- private ObjectInstance objectInstance;
-
- /** The object */
- private Object resource;
-
- /**
- * Create a new ServiceInstance.
- */
- public ServiceInstance()
- {
- }
-
- /**
- * Create a new ServiceInstance.
- *
- * @param objectInstance the object instance
- * @param resource the object
- */
- public ServiceInstance(ObjectInstance objectInstance, Object resource)
- {
- this.objectInstance = objectInstance;
- this.resource = resource;
- }
-
- /**
- * Get the resource.
- *
- * @return the resource.
- */
- public Object getResource()
- {
- return resource;
- }
-
- /**
- * Get the objectInstance.
- *
- * @return the objectInstance.
- */
- public ObjectInstance getObjectInstance()
- {
- return objectInstance;
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,78 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * An interface describing a JBoss service MBean.
- *
- * @see Service
- * @see ServiceMBeanSupport
- *
- * @author <a href="mailto:rickard.oberg at telkel.com">Rickard Öberg</a>
- * @author <a href="mailto:andreas at jboss.org">Andreas Schaefer</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public interface ServiceMBean
- extends Service
-{
- // Constants -----------------------------------------------------
-
- /** ServiceController notification types corresponding to service lifecycle events */
- public static final String CREATE_EVENT = "org.jboss.system.ServiceMBean.create";
- public static final String START_EVENT = "org.jboss.system.ServiceMBean.start";
- public static final String STOP_EVENT = "org.jboss.system.ServiceMBean.stop";
- public static final String DESTROY_EVENT = "org.jboss.system.ServiceMBean.destroy";
-
- public static final String[] states = {
- "Stopped", "Stopping", "Starting", "Started", "Failed",
- "Destroyed", "Created", "Unregistered", "Registered"
- };
-
- /** The Service.stop has completed */
- public static final int STOPPED = 0;
- /** The Service.stop has been invoked */
- public static final int STOPPING = 1;
- /** The Service.start has been invoked */
- public static final int STARTING = 2;
- /** The Service.start has completed */
- public static final int STARTED = 3;
- /** There has been an error during some operation */
- public static final int FAILED = 4;
- /** The Service.destroy has completed */
- public static final int DESTROYED = 5;
- /** The Service.create has completed */
- public static final int CREATED = 6;
- /** The MBean has been created but has not completed MBeanRegistration.postRegister */
- public static final int UNREGISTERED = 7;
- /** The MBean has been created and has completed MBeanRegistration.postRegister */
- public static final int REGISTERED = 8;
-
- // Public --------------------------------------------------------
-
- String getName();
- int getState();
- String getStateString();
-
- /** Detyped lifecycle invocation */
- void jbossInternalLifecycle(String method) throws Exception;
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceMBeanState.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceMBeanState.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceMBeanState.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,141 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.jboss.util.state.State;
-import org.jboss.util.state.StateMachine;
-import org.jboss.util.state.Transition;
-
-/**
- * A final class that encapsulates the constants necessary
- * for creating StateMachines that follow the ServiceMBean
- * lifecycle model.
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public final class ServiceMBeanState
-{
- // ServiceMBean States
- public static final State STATE_UNREGISTERED = new State("Unregistered"); // Initial State
- public static final State STATE_REGISTERED = new State("Registered");
- public static final State STATE_CREATED = new State("Created");
- public static final State STATE_STARTING = new State("Starting");
- public static final State STATE_STARTED = new State("Started");
- public static final State STATE_STOPPING = new State("Stopping");
- public static final State STATE_STOPPED = new State("Stopped");
- public static final State STATE_DESTROYED = new State("Destroyed");
- public static final State STATE_FAILED = new State("Failed");
-
- // ServiceMBean State Transitions
- public static final Transition TRANS_REGISTER = new Transition("register", STATE_REGISTERED);
- public static final Transition TRANS_CREATE = new Transition("create", STATE_CREATED);
- public static final Transition TRANS_START_BEGIN = new Transition("startBegin", STATE_STARTING);
- public static final Transition TRANS_START_END = new Transition("startEnd", STATE_STARTED);
- public static final Transition TRANS_STOP_BEGIN = new Transition("stopBegin", STATE_STOPPING);
- public static final Transition TRANS_STOP_END = new Transition("stopEnd", STATE_STOPPED);
- public static final Transition TRANS_DESTROY = new Transition("destroy", STATE_DESTROYED);
- public static final Transition TRANS_UNREGISTER = new Transition("unregister", STATE_UNREGISTERED);
- public static final Transition TRANS_FAIL = new Transition("fail", STATE_FAILED);
-
- /** The possible set of States a ServiceMBean can be in */
- public static final Set STATES = new HashSet(
- Arrays.asList(new State[] {
- STATE_UNREGISTERED,
- STATE_REGISTERED,
- STATE_CREATED,
- STATE_STARTING,
- STATE_STARTED,
- STATE_STOPPING,
- STATE_STOPPED,
- STATE_DESTROYED,
- STATE_FAILED
- }));
-
- // Associate States with valid Transitions, or else, define explicitly
- // the ServiceMBean lifecycle that drives the StateMachine
- static
- {
- STATE_UNREGISTERED
- .addTransition(TRANS_REGISTER)
- .addTransition(TRANS_FAIL);
-
- STATE_REGISTERED
- .addTransition(TRANS_CREATE)
- .addTransition(TRANS_UNREGISTER)
- .addTransition(TRANS_FAIL);
-
- STATE_CREATED
- .addTransition(TRANS_START_BEGIN)
- .addTransition(TRANS_DESTROY)
- .addTransition(TRANS_FAIL);
-
- STATE_STARTING
- .addTransition(TRANS_START_END)
- .addTransition(TRANS_FAIL);
-
- STATE_STARTED
- .addTransition(TRANS_STOP_BEGIN)
- .addTransition(TRANS_FAIL);
-
- STATE_STOPPING
- .addTransition(TRANS_STOP_END)
- .addTransition(TRANS_FAIL);
-
- STATE_STOPPED
- .addTransition(TRANS_START_BEGIN)
- .addTransition(TRANS_DESTROY)
- .addTransition(TRANS_FAIL);
-
- STATE_DESTROYED
- .addTransition(TRANS_CREATE)
- .addTransition(TRANS_UNREGISTER)
- .addTransition(TRANS_FAIL);
-
- // STATE_FAILED - no transitions
- }
-
- /**
- * Create a new StateMachine that follows the ServiceMBean
- * lifecycle, initialized to the STATE_UNREGISTERED state.
- *
- * @param description A string description for this state machine, or null
- * @return the StateMachine
- */
- public static StateMachine createStateMachine(String description)
- {
- return new StateMachine(STATES, STATE_UNREGISTERED, description);
- }
-
- /**
- * Dissallow instances of this class
- */
- private ServiceMBeanState()
- {
- // empty
- }
-
-}
Deleted: trunk/system/src/main/org/jboss/system/ServiceMBeanSupport.java
===================================================================
--- trunk/system/src/main/org/jboss/system/ServiceMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/ServiceMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,510 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.AttributeChangeNotification;
-import javax.management.JMException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.SARDeployerMBean;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-
-/**
- * An abstract base class JBoss services can subclass to implement a
- * service that conforms to the ServiceMBean interface. Subclasses must
- * override {@link #getName} method and should override
- * {@link #startService}, and {@link #stopService} as approriate.
- *
- * @see ServiceMBean
- *
- * @author <a href="mailto:rickard.oberg at telkel.com">Rickard Ãberg</a>
- * @author Scott.Stark at jboss.org
- * @author <a href="mailto:andreas at jboss.org">Andreas Schaefer</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version $Revision$
- */
-public class ServiceMBeanSupport
- extends JBossNotificationBroadcasterSupport
- implements ServiceMBean, MBeanRegistration
-{
- /** The signature for service controller operations */
- public static final String[] SERVICE_CONTROLLER_SIG = new String[] { ObjectName.class.getName() };
-
- /**
- * The instance logger for the service. Not using a class logger
- * because we want to dynamically obtain the logger name from
- * concreate sub-classes.
- */
- protected Logger log;
-
- /** The MBeanServer which we have been register with. */
- protected MBeanServer server;
-
- /** The object name which we are registsred under. */
- protected ObjectName serviceName;
-
- /** The current state this service is in. */
- private int state = UNREGISTERED;
-
- /** For backwards compatibility */
- private boolean isJBossInternalLifecycleExposed = false;
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * <p>Sets up logging.
- */
- public ServiceMBeanSupport()
- {
- // can not call this(Class) because we need to call getClass()
- this.log = Logger.getLogger(getClass().getName());
- log.trace("Constructing");
- }
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * <p>Sets up logging.
- *
- * @param type The class type to determine category name from.
- */
- public ServiceMBeanSupport(final Class type)
- {
- this(type.getName());
- }
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * <p>Sets up logging.
- *
- * @param category The logger category name.
- */
- public ServiceMBeanSupport(final String category)
- {
- this(Logger.getLogger(category));
- }
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * @param log The logger to use.
- */
- public ServiceMBeanSupport(final Logger log)
- {
- this.log = log;
- log.trace("Constructing");
- }
-
- /**
- * Use the short class name as the default for the service name.
- */
- public String getName()
- {
- // TODO: Check if this gets called often, if so cache this or remove if not used
- // use the logger so we can better be used as a delegate instead of sub-class
- return org.jboss.util.Classes.stripPackageName(log.getName());
- }
-
- public ObjectName getServiceName()
- {
- return serviceName;
- }
-
- /**
- * Provide access to the service DeploymentInfo. This is only available
- * after the service has passed its create step.
- *
- * @return The service DeploymentInfo if found registered under the SARDeployer.
- * @throws JMException - thrown on failure to invoke
- * SARDeployer.getService(ObjectName)
- */
- public DeploymentInfo getDeploymentInfo()
- throws JMException
- {
- Object[] args = {serviceName};
- String[] sig = {serviceName.getClass().getName()};
- DeploymentInfo sdi = (DeploymentInfo) server.invoke(SARDeployerMBean.OBJECT_NAME,
- "getService", args, sig);
- return sdi;
- }
-
- public MBeanServer getServer()
- {
- return server;
- }
-
- public int getState()
- {
- return state;
- }
-
- public String getStateString()
- {
- return states[state];
- }
-
- public Logger getLog()
- {
- return log;
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // State Mutators //
- ///////////////////////////////////////////////////////////////////////////
-
- public void create() throws Exception
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "create", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalCreate();
- }
-
- public void start() throws Exception
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "start", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalStart();
- }
-
- public void stop()
- {
- try
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "stop", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalStop();
- }
- catch (Throwable t)
- {
- log.warn("Error in stop " + jbossInternalDescription(), t);
- }
- }
-
- public void destroy()
- {
- try
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "destroy", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalDestroy();
- }
- catch (Throwable t)
- {
- log.warn("Error in destroy " + jbossInternalDescription(), t);
- }
- }
-
- protected String jbossInternalDescription()
- {
- if (serviceName != null)
- return serviceName.toString();
- else
- return getName();
- }
-
- public void jbossInternalLifecycle(String method) throws Exception
- {
- if (method == null)
- throw new IllegalArgumentException("Null method name");
-
- if (method.equals("create"))
- jbossInternalCreate();
- else if (method.equals("start"))
- jbossInternalStart();
- else if (method.equals("stop"))
- jbossInternalStop();
- else if (method.equals("destroy"))
- jbossInternalDestroy();
- else
- throw new IllegalArgumentException("Unknown lifecyle method " + method);
- }
-
- protected void jbossInternalCreate() throws Exception
- {
- log.debug("Creating " + jbossInternalDescription());
-
- try
- {
- createService();
- state = CREATED;
- }
- catch (Exception e)
- {
- log.debug("Initialization failed " + jbossInternalDescription(), e);
- throw e;
- }
-
- log.debug("Created " + jbossInternalDescription());
- }
-
- protected void jbossInternalStart() throws Exception
- {
- if (state == STARTING || state == STARTED || state == STOPPING)
- return;
-
- if (state != CREATED && state != STOPPED && state != FAILED)
- {
- log.debug("Start requested before create, calling create now");
- create();
- }
-
- state = STARTING;
- sendStateChangeNotification(STOPPED, STARTING, getName() + " starting", null);
- log.debug("Starting " + jbossInternalDescription());
-
- try
- {
- startService();
- }
- catch (Exception e)
- {
- state = FAILED;
- sendStateChangeNotification(STARTING, FAILED, getName() + " failed", e);
- log.debug("Starting failed " + jbossInternalDescription(), e);
- throw e;
- }
-
- state = STARTED;
- sendStateChangeNotification(STARTING, STARTED, getName() + " started", null);
- log.debug("Started " + jbossInternalDescription());
- }
-
- protected void jbossInternalStop()
- {
- if (state != STARTED)
- return;
-
- state = STOPPING;
- sendStateChangeNotification(STARTED, STOPPING, getName() + " stopping", null);
- log.debug("Stopping " + jbossInternalDescription());
-
- try
- {
- stopService();
- }
- catch (Throwable e)
- {
- state = FAILED;
- sendStateChangeNotification(STOPPING, FAILED, getName() + " failed", e);
- log.warn("Stopping failed " + jbossInternalDescription(), e);
- return;
- }
-
- state = STOPPED;
- sendStateChangeNotification(STOPPING, STOPPED, getName() + " stopped", null);
- log.debug("Stopped " + jbossInternalDescription());
- }
-
- protected void jbossInternalDestroy()
- {
- if (state == DESTROYED)
- return;
-
- if (state == STARTED)
- {
- log.debug("Destroy requested before stop, calling stop now");
- stop();
- }
-
- log.debug("Destroying " + jbossInternalDescription());
-
- try
- {
- destroyService();
- }
- catch (Throwable t)
- {
- log.warn("Destroying failed " + jbossInternalDescription(), t);
- }
- state = DESTROYED;
- log.debug("Destroyed " + jbossInternalDescription());
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // JMX Hooks //
- ///////////////////////////////////////////////////////////////////////////
-
- /**
- * Callback method of {@link MBeanRegistration}
- * before the MBean is registered at the JMX Agent.
- *
- * <p>
- * <b>Attention</b>: Always call this method when you overwrite it in a subclass
- * because it saves the Object Name of the MBean.
- *
- * @param server Reference to the JMX Agent this MBean is registered on
- * @param name Name specified by the creator of the MBean. Note that you can
- * overwrite it when the given ObjectName is null otherwise the
- * change is discarded (maybe a bug in JMX-RI).
- */
- public ObjectName preRegister(MBeanServer server, ObjectName name)
- throws Exception
- {
- this.server = server;
-
- serviceName = getObjectName(server, name);
-
- return serviceName;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- if (!registrationDone.booleanValue())
- {
- log.info( "Registration is not done -> stop" );
- stop();
- }
- else
- {
- state = REGISTERED;
- // This is for backwards compatibility - see whether jbossInternalLifecycle is exposed
- try
- {
- MBeanInfo info = server.getMBeanInfo(serviceName);
- MBeanOperationInfo[] ops = info.getOperations();
- for (int i = 0; i < ops.length; ++i)
- {
- if (ops[i] != null && ServiceController.JBOSS_INTERNAL_LIFECYCLE.equals(ops[i].getName()))
- {
- isJBossInternalLifecycleExposed = true;
- break;
- }
- }
- }
- catch (Throwable t)
- {
- log.warn("Unexcepted error accessing MBeanInfo for " + serviceName, t);
- }
- }
- }
-
- public void preDeregister() throws Exception
- {
- }
-
- public void postDeregister()
- {
- server = null;
- serviceName = null;
- state = UNREGISTERED;
- }
-
- /**
- * The <code>getNextNotificationSequenceNumber</code> method returns
- * the next sequence number for use in notifications.
- *
- * @return a <code>long</code> value
- */
- protected long getNextNotificationSequenceNumber()
- {
- return nextNotificationSequenceNumber();
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // Concrete Service Overrides //
- ///////////////////////////////////////////////////////////////////////////
-
- /**
- * Sub-classes should override this method if they only need to set their
- * object name during MBean pre-registration.
- */
- protected ObjectName getObjectName(MBeanServer server, ObjectName name)
- throws MalformedObjectNameException
- {
- return name;
- }
-
- /**
- * Sub-classes should override this method to provide
- * custum 'create' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void createService() throws Exception {}
-
- /**
- * Sub-classes should override this method to provide
- * custum 'start' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void startService() throws Exception {}
-
- /**
- * Sub-classes should override this method to provide
- * custum 'stop' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void stopService() throws Exception {}
-
- /**
- * Sub-classes should override this method to provide
- * custum 'destroy' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void destroyService() throws Exception {}
-
- // Private -------------------------------------------------------
-
- /**
- * Helper for sending out state change notifications
- */
- private void sendStateChangeNotification(int oldState, int newState, String msg, Throwable t)
- {
- long now = System.currentTimeMillis();
-
- AttributeChangeNotification stateChangeNotification = new AttributeChangeNotification(
- this,
- getNextNotificationSequenceNumber(), now, msg,
- "State", "java.lang.Integer",
- new Integer(oldState), new Integer(newState)
- );
- stateChangeNotification.setUserData(t);
-
- sendNotification(stateChangeNotification);
- }
-}
Copied: trunk/system/src/main/org/jboss/system/server/BaseServerConfig.java (from rev 57107, branches/MC_VDF_WORK/system/src/main/org/jboss/system/server/BaseServerConfig.java)
Modified: trunk/system/src/main/org/jboss/system/server/Server.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/Server.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/Server.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -21,13 +21,16 @@
*/
package org.jboss.system.server;
+import java.util.Date;
import java.util.Properties;
/**
- * The interface of the basic JBoss server component.
+ * The interface of the server loaded by the ServerLoader
+ * @see ServerLoader
*
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
+ * @author Jason Dillon
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
*/
public interface Server
{
@@ -36,6 +39,36 @@
/** The JMX notification event type sent on begin of the server shutdown */
public final String STOP_NOTIFICATION_TYPE = "org.jboss.system.server.stopped";
+ /** The server start date */
+ Date getStartDate();
+
+ /** The server version */
+ String getVersion();
+
+ /** The server version code name */
+ String getVersionName();
+
+ /** The date the server was build (compiled) */
+ String getBuildNumber();
+
+ /** The JVM used to build the server */
+ String getBuildJVM();
+
+ /** The Operating System used to build the server */
+ String getBuildOS();
+
+ /** The build id */
+ String getBuildID();
+
+ /** The date the server was build */
+ String getBuildDate();
+
+ /** A flag indicating if shutdown has been called */
+ boolean isInShutdown();
+
+ // Operations ----------------------------------------------------
+
+
/**
* Initialize the Server instance.
*
@@ -88,6 +121,10 @@
* @param exitcode The exit code returned to the operating system.
*/
void exit(int exitcode);
+ /**
+ * Shutdown the server, the JVM and run shutdown hooks. Exits with code 1.
+ */
+ void exit();
/**
* Forcibly terminates the currently running Java virtual machine.
@@ -95,4 +132,8 @@
* @param exitcode The exit code returned to the operating system.
*/
void halt(int exitcode);
+ /**
+ * Forcibly terminates the currently running Java virtual machine. Exits with code 1.
+ */
+ void halt();
}
Deleted: trunk/system/src/main/org/jboss/system/server/ServerConfigImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerConfigImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerConfigImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,676 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.Properties;
-
-import org.jboss.util.NestedRuntimeException;
-import org.jboss.util.Null;
-import org.jboss.util.Primitives;
-import org.jboss.util.platform.Java;
-
-/**
- * A container for the basic configuration elements required to create
- * a Server instance.
- *
- * <p>MalformedURLException are rethrown as NestedRuntimeExceptions, so that
- * code that needs to access these values does not have to directly
- * worry about problems with lazy construction of final URL values.
- *
- * <p>Most values are determined durring first call to getter. All values
- * when determined will have equivilent system properties set.
- *
- * <p>Clients are not meant to use this class directly. Instead use
- * {@link ServerConfigLocator} to get an instance of {@link ServerConfig}
- * and then use it to get the server's configuration bits.
- *
- * @jmx:mbean name="jboss.system:type=ServerConfig"
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author Scott.Stark at jboss.org
- * @version <tt>$Revision$</tt>
- */
-public class ServerConfigImpl
- implements ServerConfig, ServerConfigImplMBean
-{
- /** The configuration properties to pull data from. */
- private Properties props;
-
- private File homeDir;
- private URL homeURL;
- private URL libraryURL;
-
- /**
- * The base URL where patch files will be loaded from. This is
- * typed as an Object to allow its value to contain Null.VALUE
- * or a URL. If value is Null.VALUE then we have determined
- * that there is no user configuration for this value and it will
- * be passed back as null to the requesting client.
- */
- private Object patchURL;
-
- private String serverName;
- private File serverBaseDir;
- private File serverHomeDir;
- private File serverLogDir;
- private File serverTempDir;
- private File serverDataDir;
- private URL serverBaseURL;
- private URL serverHomeURL;
- private URL serverLibraryURL;
- private URL serverConfigURL;
-
- /** Exit on shutdown flag. */
- private Boolean exitOnShutdown;
- private Boolean blockingShutdown;
- private Boolean requireJBossURLStreamHandlerFactory;
- private Boolean platformMBeanServer;
-
- private String rootDeployableFilename;
-
- /**
- * Construct a new <tt>ServerConfigImpl</tt> instance.
- *
- * @param props Configuration properties.
- *
- * @throws Exception Missing or invalid configuration.
- */
- public ServerConfigImpl(final Properties props) throws Exception
- {
- this.props = props;
-
- // Must have HOME_DIR
- homeDir = getFile(ServerConfig.HOME_DIR);
- if (homeDir == null)
- throw new Exception("Missing configuration value for: " + ServerConfig.HOME_DIR);
- System.setProperty(ServerConfig.HOME_DIR, homeDir.toString());
- // Setup the SERVER_HOME_DIR system property
- getServerHomeDir();
- }
-
- /** Breakout the initialization of URLs from the constructor as we need
- * the ServerConfig.HOME_DIR set for log setup, but we cannot create any
- * file URLs prior to the
- */
- public void initURLs()
- throws MalformedURLException
- {
- // If not set then default to homeDir
- homeURL = getURL(ServerConfig.HOME_URL);
- if (homeURL == null)
- homeURL = homeDir.toURL();
- System.setProperty(ServerConfig.HOME_URL, homeURL.toString());
- }
-
- /////////////////////////////////////////////////////////////////////////
- // Typed Access //
- /////////////////////////////////////////////////////////////////////////
-
- /**
- * Get the local home directory which the server is running from.
- *
- * @jmx:managed-attribute
- */
- public File getHomeDir()
- {
- return homeDir;
- }
-
- /**
- * Get the home URL which the server is running from.
- *
- * @jmx:managed-attribute
- */
- public URL getHomeURL()
- {
- return homeURL;
- }
-
- /**
- * Get the home URL which the server is running from.
- *
- * @jmx:managed-attribute
- */
- public URL getLibraryURL()
- {
- if (libraryURL == null)
- {
- try
- {
- libraryURL = getURL(ServerConfig.LIBRARY_URL);
- if (libraryURL == null)
- {
- libraryURL = new URL(homeURL, ServerConfig.LIBRARY_URL_SUFFIX);
- }
- System.setProperty(ServerConfig.LIBRARY_URL, libraryURL.toString());
- }
- catch (MalformedURLException e)
- {
- throw new NestedRuntimeException(e);
- }
- }
- return libraryURL;
- }
-
- /**
- * Get the patch URL for the server.
- *
- * @jmx:managed-attribute
- */
- public URL getPatchURL()
- {
- if (patchURL == null)
- {
- try
- {
- patchURL = getURL(ServerConfig.PATCH_URL);
- if (patchURL == null)
- {
- patchURL = Null.VALUE;
- }
- else
- {
- System.setProperty(ServerConfig.PATCH_URL, patchURL.toString());
- }
- }
- catch (MalformedURLException e)
- {
- throw new NestedRuntimeException(e);
- }
- }
-
- if (patchURL == Null.VALUE)
- return null;
-
- return (URL) patchURL;
- }
-
- /**
- * Get the name of the server.
- *
- * @jmx:managed-attribute
- */
- public String getServerName()
- {
- if (serverName == null)
- {
- serverName = props.getProperty(ServerConfig.SERVER_NAME, ServerConfig.DEFAULT_SERVER_NAME);
- System.setProperty(ServerConfig.SERVER_NAME, serverName);
- }
- return serverName;
- }
-
- /**
- * Get the base directory for calculating server home directories.
- *
- * @jmx:managed-attribute
- */
- public File getServerBaseDir()
- {
- if (serverBaseDir == null)
- {
- serverBaseDir = getFile(ServerConfig.SERVER_BASE_DIR);
- if (serverBaseDir == null)
- {
- serverBaseDir = new File(homeDir, ServerConfig.SERVER_BASE_DIR_SUFFIX);
- System.setProperty(ServerConfig.SERVER_BASE_DIR, serverBaseDir.toString());
- }
- }
- return serverBaseDir;
- }
-
- /**
- * Get the server home directory.
- *
- * @jmx:managed-attribute
- */
- public File getServerHomeDir()
- {
- if (serverHomeDir == null)
- {
- serverHomeDir = getFile(ServerConfig.SERVER_HOME_DIR);
- if (serverHomeDir == null)
- {
- serverHomeDir = new File(getServerBaseDir(), getServerName());
- System.setProperty(ServerConfig.SERVER_HOME_DIR, serverHomeDir.toString());
- }
- }
- return serverHomeDir;
- }
-
- /**
- * Get the directory where temporary files will be stored. The associated
- * ServerConfig.SERVER_LOG_DIR system property needs to be set before
- * the logging framework is used.
- *
- * @see ServerConfig.SERVER_LOG_DIR
- * @return the writable temp directory
- */
- public File getServerLogDir()
- {
- if (serverLogDir == null)
- {
- serverLogDir = getFile(ServerConfig.SERVER_LOG_DIR);
- if (serverLogDir == null)
- {
- serverLogDir = new File(getServerHomeDir(), ServerConfig.SERVER_LOG_DIR_SUFFIX);
- System.setProperty(ServerConfig.SERVER_LOG_DIR, serverLogDir.toString());
- }
- }
- return serverLogDir;
- }
-
- /**
- * Get the directory where temporary files will be stored.
- *
- * @jmx:managed-attribute
- * @return the writable temp directory
- */
- public File getServerTempDir()
- {
- if (serverTempDir == null)
- {
- serverTempDir = getFile(ServerConfig.SERVER_TEMP_DIR);
- if (serverTempDir == null)
- {
- serverTempDir = new File(getServerHomeDir(), ServerConfig.SERVER_TEMP_DIR_SUFFIX);
- System.setProperty(ServerConfig.SERVER_TEMP_DIR, serverTempDir.toString());
- }
- }
- return serverTempDir;
- }
-
- /**
- * Get the directory where local data will be stored.
- *
- * @jmx:managed-attribute
- * @return the data directory
- */
- public File getServerDataDir()
- {
- if (serverDataDir == null)
- {
- serverDataDir = getFile(ServerConfig.SERVER_DATA_DIR);
- if (serverDataDir == null)
- {
- serverDataDir = new File(getServerHomeDir(), ServerConfig.SERVER_DATA_DIR_SUFFIX);
- System.setProperty(ServerConfig.SERVER_DATA_DIR, serverDataDir.toString());
- }
- }
- return serverDataDir;
- }
-
- /**
- * Get the native dir for unpacking
- *
- * @jmx:managed-attribute
- * @return the directory
- */
- public File getServerNativeDir()
- {
- String fileName = System.getProperty(NATIVE_DIR_PROPERTY);
- if (fileName != null)
- return new File(fileName);
- return new File(getServerTempDir(), "native");
- }
-
- /**
- * Get the temporary deployment dir for unpacking
- *
- * @jmx:managed-attribute
- * @return the directory
- */
- public File getServerTempDeployDir()
- {
- return new File(getServerTempDir(), "deploy");
- }
-
- /**
- * Get the base directory for calculating server home URLs.
- *
- * @jmx:managed-attribute
- */
- public URL getServerBaseURL()
- {
- if (serverBaseURL == null)
- {
- try
- {
- serverBaseURL = getURL(ServerConfig.SERVER_BASE_URL);
- if (serverBaseURL == null)
- {
- serverBaseURL = new URL(homeURL, ServerConfig.SERVER_BASE_URL_SUFFIX);
- }
- System.setProperty(ServerConfig.SERVER_BASE_URL, serverBaseURL.toString());
- }
- catch (MalformedURLException e)
- {
- throw new NestedRuntimeException(e);
- }
- }
- return serverBaseURL;
- }
-
- /**
- * Get the server home URL.
- *
- * @jmx:managed-attribute
- */
- public URL getServerHomeURL()
- {
- if (serverHomeURL == null)
- {
- try
- {
- serverHomeURL = getURL(ServerConfig.SERVER_HOME_URL);
- if (serverHomeURL == null)
- {
- serverHomeURL = new URL(getServerBaseURL(), getServerName() + "/");
- }
- System.setProperty(ServerConfig.SERVER_HOME_URL, serverHomeURL.toString());
- }
- catch (MalformedURLException e)
- {
- throw new NestedRuntimeException(e);
- }
- }
- return serverHomeURL;
- }
-
- /**
- * Get the server library URL.
- *
- * @jmx:managed-attribute
- */
- public URL getServerLibraryURL()
- {
- if (serverLibraryURL == null)
- {
- try
- {
- serverLibraryURL = getURL(ServerConfig.SERVER_LIBRARY_URL);
- if (serverLibraryURL == null)
- {
- serverLibraryURL = new URL(getServerHomeURL(), ServerConfig.LIBRARY_URL_SUFFIX);
- }
- System.setProperty(ServerConfig.SERVER_LIBRARY_URL, serverLibraryURL.toString());
- }
- catch (MalformedURLException e)
- {
- throw new NestedRuntimeException(e);
- }
- }
- return serverLibraryURL;
- }
-
- /**
- * Get the server configuration URL.
- *
- * @jmx:managed-attribute
- */
- public URL getServerConfigURL()
- {
- if (serverConfigURL == null)
- {
- try
- {
- serverConfigURL = getURL(ServerConfig.SERVER_CONFIG_URL);
- if (serverConfigURL == null)
- {
- serverConfigURL = new URL(getServerHomeURL(), ServerConfig.SERVER_CONFIG_URL_SUFFIX);
- }
- System.setProperty(ServerConfig.SERVER_CONFIG_URL, serverConfigURL.toString());
- }
- catch (MalformedURLException e)
- {
- throw new NestedRuntimeException(e);
- }
- }
- return serverConfigURL;
- }
-
- /**
- * Get the current value of the flag that indicates if we are
- * using the platform MBeanServer as the main jboss server.
- * Both the {@link ServerConfig.PLATFORM_MBEANSERVER}
- * property must be set, and the jvm must be jdk1.5+
- *
- * @return true if jboss runs on the jvm platfrom MBeanServer
- *
- * @jmx:managed-attribute
- */
- public boolean getPlatformMBeanServer()
- {
- if (platformMBeanServer == null)
- {
- if (Java.isCompatible(Java.VERSION_1_5))
- {
- // get whatever the user has specified or the default
- String value = props.getProperty(ServerConfig.PLATFORM_MBEANSERVER,
- (new Boolean(ServerConfig.DEFAULT_PLATFORM_MBEANSERVER)).toString());
-
- // treat empty string as true
- value = "".equals(value) ? "true" : value;
-
- // true or false
- platformMBeanServer = new Boolean(value);
- }
- else
- {
- // negative :)
- platformMBeanServer = Boolean.FALSE;
- }
- }
- return platformMBeanServer.booleanValue();
- }
-
- /**
- * Enable or disable exiting the JVM when {@link Server#shutdown} is called.
- * If enabled, then shutdown calls {@link Server#exit}. If disabled, then
- * only the shutdown hook will be run.
- *
- * @param flag True to enable calling exit on shutdown.
- *
- * @jmx:managed-attribute
- */
- public void setExitOnShutdown(final boolean flag)
- {
- exitOnShutdown = Primitives.valueOf(flag);
- }
-
- /**
- * Get the current value of the exit on shutdown flag.
- *
- * @return The current value of the exit on shutdown flag.
- *
- * @jmx:managed-attribute
- */
- public boolean getExitOnShutdown()
- {
- if (exitOnShutdown == null)
- {
- String value = props.getProperty(ServerConfig.EXIT_ON_SHUTDOWN, null);
- if (value == null)
- {
- exitOnShutdown = Primitives.valueOf(ServerConfig.DEFAULT_EXIT_ON_SHUTDOWN);
- }
- else
- {
- exitOnShutdown = new Boolean(value);
- }
- }
- return exitOnShutdown.booleanValue();
- }
-
- /**
- * Enable or disable blocking when {@link Server#shutdown} is
- * called. If enabled, then shutdown will be called in the current
- * thread. If disabled, then the shutdown hook will be run
- * ansynchronously in a separate thread.
- *
- * @param flag True to enable blocking shutdown.
- *
- * @jmx:managed-attribute
- */
- public void setBlockingShutdown(final boolean flag)
- {
- blockingShutdown = Primitives.valueOf(flag);
- }
-
- /**
- * Get the current value of the blocking shutdown flag.
- *
- * @return The current value of the blocking shutdown flag.
- *
- * @jmx:managed-attribute
- */
- public boolean getBlockingShutdown()
- {
- if (blockingShutdown == null)
- {
- String value = props.getProperty(ServerConfig.BLOCKING_SHUTDOWN, null);
- if (value == null)
- {
- blockingShutdown = Primitives.valueOf(ServerConfig.DEFAULT_BLOCKING_SHUTDOWN);
- }
- else
- {
- blockingShutdown = new Boolean(value);
- }
- }
- return blockingShutdown.booleanValue();
- }
-
-
- /**
- * Set the RequireJBossURLStreamHandlerFactory flag. if false,
- * exceptions when setting the URLStreamHandlerFactory will be
- * logged and ignored.
- *
- * @param flag True to enable blocking shutdown.
- *
- * @jmx:managed-attribute
- */
- public void setRequireJBossURLStreamHandlerFactory(final boolean flag)
- {
- requireJBossURLStreamHandlerFactory = Primitives.valueOf(flag);
- }
-
- /**
- * Get the current value of the requireJBossURLStreamHandlerFactory flag.
- *
- * @return The current value of the requireJBossURLStreamHandlerFactory flag.
- *
- * @jmx:managed-attribute
- */
- public boolean getRequireJBossURLStreamHandlerFactory()
- {
- if (requireJBossURLStreamHandlerFactory == null)
- {
- String value = props.getProperty(ServerConfig.REQUIRE_JBOSS_URL_STREAM_HANDLER_FACTORY, null);
- if (value == null)
- {
- requireJBossURLStreamHandlerFactory = Primitives.valueOf(ServerConfig.DEFAULT_REQUIRE_JBOSS_URL_STREAM_HANDLER_FACTORY);
- }
- else
- {
- requireJBossURLStreamHandlerFactory = new Boolean(value);
- }
- }
- return requireJBossURLStreamHandlerFactory.booleanValue();
- }
-
- /**
- * Set the filename of the root deployable that will be used to finalize
- * the bootstrap process.
- *
- * @param filename The filename of the root deployable.
- *
- * @jmx:managed-attribute
- */
- public void setRootDeploymentFilename(final String filename)
- {
- this.rootDeployableFilename = filename;
- }
-
- /**
- * Get the filename of the root deployable that will be used to finalize
- * the bootstrap process.
- *
- * @return The filename of the root deployable.
- *
- * @jmx:managed-attribute
- */
- public String getRootDeploymentFilename()
- {
- if (rootDeployableFilename == null)
- {
- rootDeployableFilename = props.getProperty(ServerConfig.ROOT_DEPLOYMENT_FILENAME,
- ServerConfig.DEFAULT_ROOT_DEPLOYMENT_FILENAME);
- }
-
- return rootDeployableFilename;
- }
-
- /**
- * Get a URL from configuration.
- */
- private URL getURL(final String name) throws MalformedURLException
- {
- String value = props.getProperty(name, null);
- if (value != null)
- {
- if (!value.endsWith("/")) value += "/";
- return new URL(value);
- }
-
- return null;
- }
-
- /**
- * Get a File from configuration.
- * @return the CanonicalFile form for the given name.
- */
- private File getFile(final String name)
- {
- String value = props.getProperty(name, null);
- if (value != null)
- {
- try
- {
- File f = new File(value);
- return f.getCanonicalFile();
- }
- catch(IOException e)
- {
- return new File(value);
- }
- }
-
- return null;
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,190 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server;
-
-import java.io.File;
-import java.net.URL;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface ServerConfigImplMBean
-{
- /** Default ObjectName */
- static final ObjectName OBJECT_NAME =
- ObjectNameFactory.create("jboss.system:type=ServerConfig");
-
- /**
- * Get the local home directory which the server is running from.
- */
- File getHomeDir();
-
- /**
- * Get the home URL which the server is running from.
- */
- URL getHomeURL();
-
- /**
- * Get the home URL which the server is running from.
- */
- URL getLibraryURL();
-
- /**
- * Get the patch URL for the server.
- */
- URL getPatchURL();
-
- /**
- * Get the name of the server.
- */
- String getServerName();
-
- /**
- * Get the base directory for calculating server home directories.
- */
- File getServerBaseDir();
-
- /**
- * Get the server home directory.
- */
- File getServerHomeDir();
-
- /**
- * Get the directory where log files will be stored.
- * @return the writable log directory
- */
- java.io.File getServerLogDir();
-
- /**
- * Get the directory where temporary files will be stored.
- */
- File getServerTempDir();
-
- /**
- * Get the directory where local data will be stored.
- */
- File getServerDataDir();
-
- /**
- * Get the base directory for calculating server home URLs.
- */
- URL getServerBaseURL();
-
- /**
- * Get the server home URL.
- */
- URL getServerHomeURL();
-
- /**
- * Get the server library URL.
- */
- URL getServerLibraryURL();
-
- /**
- * Get the server configuration URL.
- */
- URL getServerConfigURL();
-
- /**
- * Get the current value of the flag that indicates if we are
- * using the platform MBeanServer as the main jboss server.
- * Both the {@link ServerConfig.PLATFORM_MBEANSERVER}
- * property must be set, and the jvm must be jdk1.5+
- */
- boolean getPlatformMBeanServer();
-
- /**
- * Enable or disable exiting the JVM when {@link Server#shutdown}
- * is called. If enabled, then shutdown calls {@link Server#exit}.
- * If disabled, then only the shutdown hook will be run.
- * @param flag True to enable calling exit on shutdown.
- */
- void setExitOnShutdown(boolean flag);
-
- /**
- * Get the current value of the exit on shutdown flag.
- * @return The current value of the exit on shutdown flag.
- */
- boolean getExitOnShutdown();
-
- /**
- * Enable or disable blocking when {@link Server#shutdown} is called.
- * If enabled, then shutdown will be called in the current thread.
- * If disabled, then the shutdown hook will be run ansynchronously
- * in a separate thread.
- * @param flag True to enable blocking shutdown.
- */
- void setBlockingShutdown(boolean flag);
-
- /**
- * Get the current value of the blocking shutdown flag.
- * @return The current value of the blocking shutdown flag.
- */
- boolean getBlockingShutdown();
-
- /**
- * Set the RequireJBossURLStreamHandlerFactory flag. if false,
- * exceptions when setting the URLStreamHandlerFactory will
- * be logged and ignored.
- * @param flag True to enable blocking shutdown.
- */
- void setRequireJBossURLStreamHandlerFactory(boolean flag);
-
- /**
- * Get the current value of the requireJBossURLStreamHandlerFactory flag.
- * @return The current value of the requireJBossURLStreamHandlerFactory flag.
- */
- boolean getRequireJBossURLStreamHandlerFactory();
-
- /**
- * Set the filename of the root deployable that will be used to
- * finalize the bootstrap process.
- * @param filename The filename of the root deployable.
- */
- void setRootDeploymentFilename(String filename);
-
- /**
- * Get the filename of the root deployable that will be used to
- * finalize the bootstrap process.
- * @return The filename of the root deployable.
- */
- String getRootDeploymentFilename();
-
- /**
- * Get the native dir for unpacking
- *
- * @return the directory
- */
- File getServerNativeDir() ;
-
- /**
- * Get the temporary deployment dir for unpacking
- *
- * @return the directory
- */
- File getServerTempDeployDir() ;
-
-}
Deleted: trunk/system/src/main/org/jboss/system/server/ServerConfigLocator.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerConfigLocator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerConfigLocator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,47 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server;
-
-import org.jboss.mx.util.MBeanProxyExt;
-
-/**
- * A helper for locating the {@link ServerConfig} instance
- * for the running server.
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- */
-public class ServerConfigLocator
-{
- private static volatile ServerConfig instance = null;
-
- public static ServerConfig locate()
- {
- if (instance == null) {
- instance = (ServerConfig)
- MBeanProxyExt.create(ServerConfig.class,
- ServerConfigImplMBean.OBJECT_NAME);
- }
-
- return instance;
- }
-}
Modified: trunk/system/src/main/org/jboss/system/server/ServerConfigUtil.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerConfigUtil.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerConfigUtil.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -135,6 +135,12 @@
if (longUrl.startsWith(serverHomeUrl))
return ".../" + longUrl.substring(serverHomeUrl.length());
else
- return longUrl;
+ {
+ String jarServerHomeUrl = "jar:" + serverHomeUrl;
+ if (longUrl.startsWith(jarServerHomeUrl))
+ return ".../" + longUrl.substring(jarServerHomeUrl.length());
+ else
+ return longUrl;
+ }
}
}
Deleted: trunk/system/src/main/org/jboss/system/server/ServerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,1113 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system.server;
-
-import java.io.File;
-import java.lang.reflect.Method;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Properties;
-import java.util.logging.LogManager;
-
-import javax.management.Attribute;
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanServer;
-import javax.management.MBeanServerFactory;
-import javax.management.Notification;
-import javax.management.NotificationEmitter;
-import javax.management.NotificationFilter;
-import javax.management.NotificationListener;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-
-import org.jboss.Version;
-import org.jboss.deployment.IncompleteDeploymentException;
-import org.jboss.deployment.MainDeployerMBean;
-import org.jboss.logging.JBossJDKLogManager;
-import org.jboss.logging.Logger;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.mx.util.MBeanServerLocator;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.net.protocol.URLStreamHandlerFactory;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.system.server.jmx.LazyMBeanServer;
-import org.jboss.util.StopWatch;
-import org.jboss.util.file.FileSuffixFilter;
-import org.jboss.util.file.Files;
-
-/**
- * The main container component of a JBoss server instance.
- *
- * <h3>Concurrency</h3>
- * This class is <b>not</b> thread-safe.
- *
- * @jmx:mbean name="jboss.system:type=Server"
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public class ServerImpl
- implements Server, ServerImplMBean, NotificationEmitter
-{
- private final static ObjectName DEFAULT_LOADER_NAME =
- ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
-
- /** Instance logger. */
- private Logger log;
-
- /** Container for version information. */
- private final Version version = Version.getInstance();
-
- /** Package information for org.jboss */
- private final Package jbossPackage = Package.getPackage("org.jboss");
-
- /** The basic configuration for the server. */
- private ServerConfigImpl config;
-
- /** The JMX MBeanServer which will serve as our communication bus. */
- private MBeanServer server;
-
- /** When the server was started. */
- private Date startDate;
-
- /** Flag to indicate if we are started. */
- private boolean started;
-
- /** The JVM shutdown hook */
- private ShutdownHook shutdownHook;
-
- /** The JBoss Life Thread */
- private LifeThread lifeThread;
-
- /** The NotificationBroadcaster implementation delegate */
- private JBossNotificationBroadcasterSupport broadcasterSupport;
-
- /** The bootstrap UCL class loader ObjectName */
- private ObjectName bootstrapUCLName;
- /** A flag indicating if shutdown has been called */
- private boolean isInShutdown;
-
- /**
- * No-arg constructor for {@link ServerLoader}.
- */
- public ServerImpl()
- {
- }
-
- /**
- * Initialize the Server instance.
- *
- * @param props The configuration properties for the server.
- *
- * @throws IllegalStateException Already initialized.
- * @throws Exception Failed to initialize.
- */
- public void init(final Properties props) throws IllegalStateException, Exception
- {
- if (props == null)
- throw new IllegalArgumentException("props is null");
- if (config != null)
- throw new IllegalStateException("already initialized");
-
- ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
-
- try
- {
- Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
- doInit(props);
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(oldCL);
- }
- }
-
- /** Actually does the init'ing... */
- private void doInit(final Properties props) throws Exception
- {
- // Create a new config object from the give properties
- this.config = new ServerConfigImpl(props);
-
- /* Initialize the logging layer using the Server.class. The server log
- directory is initialized prior to this to ensure the jboss.server.log.dir
- system property is set in case its used by the logging configs.
- */
- config.getServerLogDir();
- log = Logger.getLogger(Server.class);
-
- // Create the NotificationBroadcaster delegate
- broadcasterSupport = new JBossNotificationBroadcasterSupport();
-
- // Set the VM temp directory to the server tmp dir
- boolean overrideTmpDir = Boolean.getBoolean("jboss.server.temp.dir.overrideJavaTmpDir");
- if( overrideTmpDir )
- {
- File serverTmpDir = config.getServerTempDir();
- System.setProperty("java.io.tmpdir", serverTmpDir.getCanonicalPath());
- }
-
- // Setup URL handlers - do this before initializing the ServerConfig
- initURLHandlers();
- config.initURLs();
-
- log.info("Starting JBoss (MX MicroKernel)...");
-
- if (jbossPackage != null)
- {
- // Show what release this is...
- log.info("Release ID: " +
- jbossPackage.getImplementationTitle() + " " +
- jbossPackage.getImplementationVersion());
- }
- else
- {
- log.warn("could not get package info to display release, either the " +
- "jar manifest in jboss-system.jar has been mangled or you're " +
- "running unit tests from ant outside of JBoss itself.");
- }
-
- log.debug("Using config: " + config);
-
- // make sure our impl type is exposed
- log.debug("Server type: " + getClass());
-
- // log the boot classloader
- ClassLoader cl = getClass().getClassLoader();
- log.debug("Server loaded through: " + cl.getClass().getName());
-
- // log the boot URLs
- if (cl instanceof NoAnnotationURLClassLoader)
- {
- NoAnnotationURLClassLoader nacl = (NoAnnotationURLClassLoader)cl;
- URL[] bootURLs = nacl.getAllURLs();
- log.debug("Boot URLs:");
- for (int i = 0; i < bootURLs.length; i++)
- {
- log.debug(" " + bootURLs[i]);
- }
- }
-
- // Log the basic configuration elements
- log.debug("Home Dir: " + config.getHomeDir());
- log.info("Home URL: " + config.getHomeURL());
- log.debug("Library URL: " + config.getLibraryURL());
- log.debug("Patch URL: " + config.getPatchURL());
- log.info("Server Name: " + config.getServerName());
- log.debug("Server Home Dir: " + config.getServerHomeDir());
- log.debug("Server Home URL: " + config.getServerHomeURL());
- log.debug("Server Data Dir: " + config.getServerDataDir());
- log.debug("Server Temp Dir: " + config.getServerTempDir());
- log.debug("Server Config URL: " + config.getServerConfigURL());
- log.debug("Server Library URL: " + config.getServerLibraryURL());
- log.debug("Root Deployment Filename: " + config.getRootDeploymentFilename());
- }
-
- /**
- * The <code>initURLHandlers</code> method calls
- * internalInitURLHandlers. if requireJBossURLStreamHandlers is
- * false, any exceptions are logged and ignored.
- *
- */
- private void initURLHandlers()
- {
- if (config.getRequireJBossURLStreamHandlerFactory())
- {
- internalInitURLHandlers();
- } // end of if ()
- else
- {
- try
- {
- internalInitURLHandlers();
- }
- catch (SecurityException e)
- {
- log.warn("You do not have permissions to set URLStreamHandlerFactory", e);
- } // end of try-catch
- catch (Error e)
- {
- log.warn("URLStreamHandlerFactory already set", e);
- } // end of catch
- } // end of else
- }
-
- /**
- * Set up our only URLStreamHandlerFactory.
- * This is needed to ensure Sun's version is not used (as it leaves files
- * locked on Win2K/WinXP platforms.
- */
- private void internalInitURLHandlers()
- {
- try
- {
- // Install a URLStreamHandlerFactory that uses the TCL
- URL.setURLStreamHandlerFactory(new URLStreamHandlerFactory());
-
- // Preload JBoss URL handlers
- URLStreamHandlerFactory.preload();
- }
- catch (Error error)
- { //very naughty but we HAVE to do this or
- //we'll fail if we ever try to do this again
- log.warn("Caught Throwable Error, this probably means " +
- "we've already set the URLStreamHAndlerFactory before");
- //Sys.out because we don't have logging yet
- }
-
- // Include the default JBoss protocol handler package
- String handlerPkgs = System.getProperty("java.protocol.handler.pkgs");
- if (handlerPkgs != null)
- {
- handlerPkgs += "|org.jboss.net.protocol";
- }
- else
- {
- handlerPkgs = "org.jboss.net.protocol";
- }
- System.setProperty("java.protocol.handler.pkgs", handlerPkgs);
- }
-
- /**
- * Get the typed server configuration object which the
- * server has been initalized to use.
- *
- * @return Typed server configuration object.
- *
- * @throws IllegalStateException Not initialized.
- */
- public ServerConfig getConfig() throws IllegalStateException
- {
- if (config == null)
- throw new IllegalStateException("not initialized");
-
- return config;
- }
-
- /**
- * Check if the server is started.
- *
- * @return True if the server is started, else false.
- * @jmx:managed-attribute
- */
- public boolean isStarted()
- {
- return started;
- }
-
- /**
- Check if the shutdown operation has been called/is in progress.
-
- @return true if shutdown has been called, false otherwise
- */
- public boolean isInShutdown()
- {
- return isInShutdown;
- }
-
- /**
- * Start the Server instance.
- *
- * @throws IllegalStateException Already started or not initialized.
- * @throws Exception Failed to start.
- */
- public void start() throws IllegalStateException, Exception
- {
- // make sure we are initialized
- getConfig();
-
- // make sure we aren't started yet
- if (started)
- throw new IllegalStateException("already started");
-
- ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
-
- try
- {
- Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
-
- // Deal with those pesky JMX throwables
- try
- {
- doStart();
- }
- catch (Exception e)
- {
- JMXExceptionDecoder.rethrow(e);
- }
- }
- catch (Throwable t)
- {
- log.debug("Failed to start", t);
-
- if (t instanceof Exception)
- throw (Exception)t;
- if (t instanceof Error)
- throw (Error)t;
-
- throw new org.jboss.util.UnexpectedThrowable(t);
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(oldCL);
- }
- }
-
- /** Actually does the starting... */
- private void doStart() throws Exception
- {
- // See how long it takes us to start up
- StopWatch watch = new StopWatch(true);
-
- // remeber when we we started
- startDate = new Date();
-
- log.debug("Starting General Purpose Architecture (GPA)...");
-
- // Create the MBeanServer
- String builder = System.getProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY,
- ServerConstants.DEFAULT_MBEAN_SERVER_BUILDER_CLASS);
- System.setProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY, builder);
-
- // Check if we'll use the platform MBeanServer or instantiate our own
- if (config.getPlatformMBeanServer() == true)
- {
- // jdk1.5+
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- Class clazz = cl.loadClass("java.lang.management.ManagementFactory");
- Method method = clazz.getMethod("getPlatformMBeanServer", null);
- server = (MBeanServer)method.invoke(null, null);
- // Tell the MBeanServerLocator to point to this server
- MBeanServerLocator.setJBoss(server);
- /* If the LazyMBeanServer was used, we need to reset to the jboss
- MBeanServer to use our implementation for the jboss services.
- */
- server = LazyMBeanServer.resetToJBossServer(server);
- }
- else
- {
- // Create our own MBeanServer
- server = MBeanServerFactory.createMBeanServer("jboss");
- }
- log.debug("Created MBeanServer: " + server);
-
- // Register server components
- server.registerMBean(this, ServerImplMBean.OBJECT_NAME);
- server.registerMBean(config, ServerConfigImplMBean.OBJECT_NAME);
-
- // Initialize spine boot libraries
- RepositoryClassLoader ucl = initBootLibraries();
- bootstrapUCLName = ucl.getObjectName();
- server.registerMBean(ucl, bootstrapUCLName);
-
- // Set ServiceClassLoader as classloader for the construction of
- // the basic system
- Thread.currentThread().setContextClassLoader(ucl);
-
- // General Purpose Architecture information
- createMBean("org.jboss.system.server.ServerInfo",
- "jboss.system:type=ServerInfo");
-
- // Service Controller
- ObjectName controller = createMBean("org.jboss.system.ServiceController",
- "jboss.system:service=ServiceController");
-
- // Main Deployer
- ObjectName mainDeployer = startBootService(controller,
- "org.jboss.deployment.MainDeployer", "jboss.system:service=MainDeployer");
- server.setAttribute(mainDeployer,
- new Attribute("ServiceController", controller));
-
- // Install the shutdown hook
- shutdownHook = new ShutdownHook(controller, mainDeployer);
- shutdownHook.setDaemon(true);
-
- try
- {
- Runtime.getRuntime().addShutdownHook(shutdownHook);
- log.debug("Shutdown hook added");
- }
- catch (Exception e)
- {
- log.warn("Failed to add shutdown hook; ignoring", e);
- }
-
- // JARDeployer, required to process <classpath>
- startBootService(controller, "org.jboss.deployment.JARDeployer",
- "jboss.system:service=JARDeployer");
-
- // SARDeployer, required to process *-service.xml
- startBootService(controller, "org.jboss.deployment.SARDeployer",
- "jboss.system:service=ServiceDeployer");
-
- log.info("Core system initialized");
-
- // Ok, now deploy the root deployable to finish the job
-
- MainDeployerMBean md = (MainDeployerMBean)
- MBeanProxyExt.create(MainDeployerMBean.class, mainDeployer, server);
-
- try
- {
- md.deploy(config.getServerConfigURL() + config.getRootDeploymentFilename());
- }
- catch (IncompleteDeploymentException e)
- {
- log.error("Root deployment has missing dependencies; continuing", e);
- }
-
- lifeThread = new LifeThread();
- lifeThread.start();
-
- started = true;
-
- // Send a notification that the startup is complete
- Notification msg = new Notification(START_NOTIFICATION_TYPE, this, 1);
- msg.setUserData(new Long(watch.getLapTime()));
- sendNotification(msg);
-
- watch.stop();
-
- if (jbossPackage != null)
- {
- // Tell the world how fast it was =)
- log.info("JBoss (MX MicroKernel) [" + jbossPackage.getImplementationVersion() +
- "] Started in " + watch);
- }
- else
- {
- log.warn("could not get package info to display release, either the " +
- "jar manifest in jboss-boot.jar has been mangled or you're " +
- "running unit tests from ant outside of JBoss itself.");
- }
- }
-
- /**
- * Instantiate and register a service for the given classname into the MBean server.
- */
- private ObjectName createMBean(final String classname, String name)
- throws Exception
- {
- ObjectName mbeanName = null;
- if( name != null )
- mbeanName = new ObjectName(name);
- try
- {
- // See if there is an xmbean descriptor for the bootstrap mbean
- URL xmbeanDD = new URL("resource:xmdesc/"+classname+"-xmbean.xml");
- Object resource = server.instantiate(classname);
- // Create the XMBean
- Object[] args = {resource, xmbeanDD};
- String[] sig = {Object.class.getName(), URL.class.getName()};
- ObjectInstance instance = server.createMBean("org.jboss.mx.modelmbean.XMBean",
- mbeanName,
- bootstrapUCLName,
- args,
- sig);
- mbeanName = instance.getObjectName();
- log.debug("Created system XMBean: "+mbeanName);
- }
- catch(Exception e)
- {
- log.debug("Failed to create xmbean for: "+classname);
- mbeanName = server.createMBean(classname, mbeanName).getObjectName();
- log.debug("Created system MBean: " + mbeanName);
- }
-
- return mbeanName;
- }
-
- /**
- * Instantiate/register, create and start a service for the given classname.
- */
- private ObjectName startBootService(final ObjectName controllerName,
- final String classname, final String name)
- throws Exception
- {
- ObjectName mbeanName = createMBean(classname, name);
-
- // now go through the create/start sequence on the new service
-
- Object[] args = { mbeanName };
- String[] sig = { ObjectName.class.getName() };
-
- server.invoke(controllerName, "create", args, sig);
- server.invoke(controllerName, "start", args, sig);
-
- return mbeanName;
- }
-
- /**
- * Initialize the boot libraries.
- */
- private RepositoryClassLoader initBootLibraries() throws Exception
- {
- // Build the list of URL for the spine to boot
- List list = new ArrayList();
-
- // Add the patch URL. If the url protocol is file, then
- // add the contents of the directory it points to
- URL patchURL = config.getPatchURL();
- if (patchURL != null)
- {
- if (patchURL.getProtocol().equals("file"))
- {
- File dir = new File(patchURL.getFile());
- if (dir.exists())
- {
- // Add the local file patch directory
- list.add(dir.toURL());
-
- // Add the contents of the directory too
- File[] jars = dir.listFiles(new FileSuffixFilter(new String[] { ".jar", ".zip" }, true));
-
- for (int j = 0; jars != null && j < jars.length; j++)
- {
- list.add(jars[j].getCanonicalFile().toURL());
- }
- }
- }
- else
- {
- list.add(patchURL);
- }
- }
-
- // Add the server configuration directory to be able to load config files as resources
- list.add(config.getServerConfigURL());
-
- // Not needed, ServerImpl will have the basics on its classpath from ServerLoader
- // may want to bring this back at some point if we want to have reloadable core
- // components...
-
- // URL libraryURL = config.getLibraryURL();
- // list.add(new URL(libraryURL, "jboss-spine.jar"));
-
- log.debug("Boot url list: " + list);
-
- // Create loaders for each URL
- RepositoryClassLoader loader = null;
- for (Iterator iter = list.iterator(); iter.hasNext();)
- {
- URL url = (URL)iter.next();
- log.debug("Creating loader for URL: " + url);
-
- // This is a boot URL, so key it on itself.
- Object[] args = {url, Boolean.TRUE};
- String[] sig = {"java.net.URL", "boolean"};
- loader = (RepositoryClassLoader) server.invoke(DEFAULT_LOADER_NAME, "newClassLoader", args, sig);
- }
- return loader;
- }
-
- /**
- * Shutdown the Server instance and run shutdown hooks.
- *
- * <p>If the exit on shutdown flag is true, then {@link #exit}
- * is called, else only the shutdown hook is run.
- *
- * @jmx:managed-operation
- *
- * @throws IllegalStateException No started.
- */
- public void shutdown() throws IllegalStateException
- {
- if (log.isTraceEnabled())
- log.trace("Shutdown caller:", new Throwable("Here"));
-
- if (!started)
- throw new IllegalStateException("Server not started");
-
- isInShutdown = true;
- boolean exitOnShutdown = config.getExitOnShutdown();
- boolean blockingShutdown = config.getBlockingShutdown();
- log.info("Shutting down the server, blockingShutdown: " + blockingShutdown);
-
- if (exitOnShutdown)
- {
- exit(0);
- }
- else
- {
- // signal lifethread to exit; if no non-daemon threads
- // remain, the JVM will eventually exit
- lifeThread.interrupt();
-
- if (blockingShutdown)
- {
- shutdownHook.shutdown();
- }
- else
- {
- // start in new thread to give positive
- // feedback to requesting client of success.
- new Thread()
- {
- public void run()
- {
- // just run the hook, don't call System.exit, as we may
- // be embeded in a vm that would not like that very much
- shutdownHook.shutdown();
- }
- }.start();
- }
- }
- }
-
- /**
- * Exit the JVM, run shutdown hooks, shutdown the server.
- *
- * @jmx:managed-operation
- *
- * @param exitcode The exit code returned to the operating system.
- */
- public void exit(final int exitcode)
- {
- // exit() in new thread so that we might have a chance to give positive
- // feed back to requesting client of success.
- new Thread()
- {
- public void run()
- {
- log.info("Server exit(" + exitcode + ") called");
-
- // Set exit code in the shutdown hook, in case halt is enabled
- shutdownHook.setHaltExitCode(exitcode);
-
- // Initiate exiting, shutdown hook will be called
- Runtime.getRuntime().exit(exitcode);
- }
- }.start();
- }
-
- /**
- * Exit the JVM with code 1, run shutdown hooks, shutdown the server.
- *
- * @jmx:managed-operation
- */
- public void exit()
- {
- exit(1);
- }
-
- /**
- * Forcibly terminates the currently running Java virtual machine.
- *
- * @param exitcode The exit code returned to the operating system.
- *
- * @jmx:managed-operation
- */
- public void halt(final int exitcode)
- {
- // halt() in new thread so that we might have a chance to give positive
- // feed back to requesting client of success.
- new Thread()
- {
- public void run()
- {
- System.err.println("Server halt(" + exitcode + ") called, halting the JVM now!");
- Runtime.getRuntime().halt(exitcode);
- }
- }.start();
- }
-
- /**
- * Forcibly terminates the currently running Java virtual machine.
- * Halts with code 1.
- *
- * @jmx:managed-operation
- */
- public void halt()
- {
- halt(1);
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // Runtime Access //
- ///////////////////////////////////////////////////////////////////////////
-
- /** A simple helper used to log the Runtime memory information. */
- private void logMemoryUsage(final Runtime rt)
- {
- log.info("Total/free memory: " + rt.totalMemory() + "/" + rt.freeMemory());
- }
-
- /**
- * Hint to the JVM to run the garbage collector.
- *
- * @jmx:managed-operation
- */
- public void runGarbageCollector()
- {
- Runtime rt = Runtime.getRuntime();
-
- logMemoryUsage(rt);
- rt.gc();
- log.info("Hinted to the JVM to run garbage collection");
- logMemoryUsage(rt);
- }
-
- /**
- * Hint to the JVM to run any pending object finailizations.
- *
- * @jmx:managed-operation
- */
- public void runFinalization()
- {
- Runtime.getRuntime().runFinalization();
- log.info("Hinted to the JVM to run any pending object finalizations");
- }
-
- /**
- * Enable or disable tracing method calls at the Runtime level.
- *
- * @jmx:managed-operation
- */
- public void traceMethodCalls(final Boolean flag)
- {
- Runtime.getRuntime().traceMethodCalls(flag.booleanValue());
- }
-
- /**
- * Enable or disable tracing instructions the Runtime level.
- *
- * @jmx:managed-operation
- */
- public void traceInstructions(final Boolean flag)
- {
- Runtime.getRuntime().traceInstructions(flag.booleanValue());
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // Server Information //
- ///////////////////////////////////////////////////////////////////////////
-
- /**
- * @jmx:managed-attribute
- */
- public Date getStartDate()
- {
- return startDate;
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getVersion()
- {
- return version.toString();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getVersionName()
- {
- return version.getName();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildNumber()
- {
- return version.getBuildNumber();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildJVM()
- {
- return version.getBuildJVM();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildOS()
- {
- return version.getBuildOS();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildID()
- {
- return version.getBuildID();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildDate()
- {
- return version.getBuildDate();
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // NotificationEmitter //
- ///////////////////////////////////////////////////////////////////////////
-
- public void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
- {
- broadcasterSupport.addNotificationListener(listener, filter, handback);
- }
-
- public void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException
- {
- broadcasterSupport.removeNotificationListener(listener);
- }
-
- public void removeNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
- throws ListenerNotFoundException
- {
- broadcasterSupport.removeNotificationListener(listener, filter, handback);
- }
-
- public MBeanNotificationInfo[] getNotificationInfo()
- {
- return broadcasterSupport.getNotificationInfo();
- }
-
- public void sendNotification(Notification notification)
- {
- broadcasterSupport.sendNotification(notification);
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // Lifecycle Thread //
- ///////////////////////////////////////////////////////////////////////////
-
- /** A simple thread that keeps the vm alive in the event there are no
- * other threads started.
- */
- private class LifeThread
- extends Thread
- {
- Object lock = new Object();
- LifeThread()
- {
- super("JBossLifeThread");
- }
- public void run()
- {
- synchronized (lock)
- {
- try
- {
- lock.wait();
- }
- catch (InterruptedException ignore)
- {
- }
- }
- log.debug("LifeThread.run() exits!");
- }
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // Shutdown Hook //
- ///////////////////////////////////////////////////////////////////////////
-
- private class ShutdownHook
- extends Thread
- {
- /** The ServiceController which we will ask to shut things down with. */
- private ObjectName controller;
-
- /** The MainDeployer which we will ask to undeploy everything. */
- private ObjectName mainDeployer;
-
- /** Whether to halt the JMV at the end of the shutdown hook */
- private boolean forceHalt = true;
-
- /** The exit code to use if forceHalt is enabled */
- private int haltExitCode;
-
- /** Mark when shutdown has been performed */
- private boolean shutdownCalled;
-
- public ShutdownHook(final ObjectName controller, final ObjectName mainDeployer)
- {
- super("JBoss Shutdown Hook");
-
- this.controller = controller;
- this.mainDeployer = mainDeployer;
-
- String value = System.getProperty("jboss.shutdown.forceHalt", null);
- if (value != null)
- {
- forceHalt = new Boolean(value).booleanValue();
- }
- }
-
- public void setHaltExitCode(int haltExitCode)
- {
- this.haltExitCode = haltExitCode;
- }
-
- public void run()
- {
- log.info("Runtime shutdown hook called, forceHalt: " + forceHalt);
-
- // shutdown the server
- shutdown();
-
- // Execute the jdk JBossJDKLogManager doReset
- LogManager lm = LogManager.getLogManager();
- if (lm instanceof JBossJDKLogManager)
- {
- JBossJDKLogManager jbosslm = (JBossJDKLogManager)lm;
- jbosslm.doReset();
- }
-
- // later bitch - other shutdown hooks may be killed
- if (forceHalt)
- {
- System.out.println("Halting VM");
- Runtime.getRuntime().halt(haltExitCode);
- }
- }
-
- public void shutdown()
- {
- if (log.isTraceEnabled())
- log.trace("Shutdown caller:", new Throwable("Here"));
-
- // avoid entering twice; may happen when called directly
- // from ServerImpl.shutdown(), then called again when all
- // non-daemon threads have exited and the ShutdownHook runs.
- if (shutdownCalled)
- return;
- else
- shutdownCalled = true;
-
- // Send a notification that server stop is initiated
- Notification msg = new Notification(STOP_NOTIFICATION_TYPE, this, 2);
- sendNotification(msg);
-
- // MainDeployer.shutdown()
- log.info("JBoss SHUTDOWN: Undeploying all packages");
- shutdownDeployments();
-
- // ServiceController.shutdown()
- log.debug("Shutting down all services");
- shutdownServices();
-
- // Make sure all mbeans are unregistered
- removeMBeans();
-
- // Cleanup tmp/deploy dir
- log.debug("Deleting server tmp/deploy directory");
- File tmp = config.getServerTempDir();
- File tmpDeploy = new File(tmp, "deploy");
- Files.delete(tmpDeploy);
-
- // Done
- log.info("Shutdown complete");
- System.out.println("Shutdown complete");
- }
-
- protected void shutdownDeployments()
- {
- try
- {
- // get the deployed objects from ServiceController
- server.invoke(mainDeployer,
- "shutdown",
- new Object[0],
- new String[0]);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to shutdown deployer", t);
- }
- }
-
- /**
- * The <code>shutdownServices</code> method calls the one and only
- * ServiceController to shut down all the mbeans registered with it.
- */
- protected void shutdownServices()
- {
- try
- {
- // get the deployed objects from ServiceController
- server.invoke(controller,
- "shutdown",
- new Object[0],
- new String[0]);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to shutdown services", t);
- }
- }
-
- /**
- * The <code>removeMBeans</code> method uses the mbean server to unregister
- * all the mbeans registered here.
- */
- protected void removeMBeans()
- {
- try
- {
- server.unregisterMBean(ServiceControllerMBean.OBJECT_NAME);
- server.unregisterMBean(ServerConfigImplMBean.OBJECT_NAME);
- server.unregisterMBean(ServerImplMBean.OBJECT_NAME);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to unregister mbeans", t);
- }
- try
- {
- MBeanServer registeredServer = server;
- if (config.getPlatformMBeanServer() == true)
- registeredServer = LazyMBeanServer.getRegisteredMBeanServer(server);
- MBeanServerFactory.releaseMBeanServer(registeredServer);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to release mbean server", t);
- }
- }
- }
-}
Deleted: trunk/system/src/main/org/jboss/system/server/ServerImplMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerImplMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerImplMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,123 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system.server;
-
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface ServerImplMBean
-{
- /** The default object name */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:type=Server");
-
- // Attributes ----------------------------------------------------
-
- /** The server start date */
- Date getStartDate();
-
- /** The server version */
- String getVersion();
-
- /** The server version code name */
- String getVersionName();
-
- /** The date the server was build (compiled) */
- String getBuildNumber();
-
- /** The JVM used to build the server */
- String getBuildJVM();
-
- /** The Operating System used to build the server */
- String getBuildOS();
-
- /** The build id */
- String getBuildID();
-
- /** The date the server was build */
- String getBuildDate();
-
- /** The server state, true if started, false otherwise */
- boolean isStarted();
-
- /** A flag indicating if shutdown has been called */
- boolean isInShutdown();
-
- // Operations ----------------------------------------------------
-
- /**
- * Shutdown the Server instance and run shutdown hooks.
- *
- * If the exit on shutdown flag is true, then {@link #exit} is called,
- * else only the shutdown hook is run.
- * @throws IllegalStateException No started.
- */
- void shutdown() throws IllegalStateException;
-
- /**
- * Shutdown the server, the JVM and run shutdown hooks.
- * @param exitcode The exit code returned to the operating system.
- */
- void exit(int exitcode);
-
- /**
- * Shutdown the server, the JVM and run shutdown hooks. Exits with code 1.
- */
- void exit();
-
- /**
- * Forcibly terminates the currently running Java virtual machine.
- * @param exitcode The exit code returned to the operating system.
- */
- void halt(int exitcode);
-
- /**
- * Forcibly terminates the currently running Java virtual machine. Exits with code 1.
- */
- void halt();
-
- /**
- * Hint to the JVM to run the garbage collector.
- */
- void runGarbageCollector();
-
- /**
- * Hint to the JVM to run any pending object finailizations.
- */
- void runFinalization();
-
- /**
- * Enable or disable tracing method calls at the Runtime level.
- */
- void traceMethodCalls(Boolean flag);
-
- /**
- * Enable or disable tracing instructions the Runtime level.
- */
- void traceInstructions(Boolean flag);
-
-}
Modified: trunk/system/src/main/org/jboss/system/server/ServerInfo.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerInfo.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerInfo.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -183,7 +183,7 @@
}
}
- return name == null ? OBJECT_NAME : name;
+ return name == null ? new ObjectName(OBJECT_NAME_STR) : name;
}
public void postRegister(Boolean registrationDone)
Modified: trunk/system/src/main/org/jboss/system/server/ServerInfoMBean.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerInfoMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerInfoMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -23,8 +23,6 @@
import javax.management.ObjectName;
-import org.jboss.mx.util.ObjectNameFactory;
-
/**
* ServerInfo MBean interface.
*
@@ -33,7 +31,7 @@
public interface ServerInfoMBean
{
/** The default ObjectName */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:type=ServerInfo");
+ final String OBJECT_NAME_STR = "jboss.system:type=ServerInfo";
// Attributes ----------------------------------------------------
Modified: trunk/system/src/main/org/jboss/system/server/ServerLoader.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerLoader.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/ServerLoader.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -77,10 +77,10 @@
* proper libraries.
*/
public static final String DEFAULT_BOOT_LIBRARY_LIST =
- "log4j-boot.jar,jboss-common.jar,jboss-system.jar,jboss-xml-binding.jar,namespace.jar,jboss-container.jar,jboss-dependency.jar,jboss-microcontainer.jar";
+ "log4j-boot.jar,jboss-common-core-2.0.0.jar,jboss-logging-spi-2.0.0.jar,jboss-logging-log4j-2.0.0.jar,jboss-logging-jdk-2.0.0.jar,jboss-system.jar,jboss-xml-binding.jar,jboss-container.jar,jboss-dependency.jar,jboss-microcontainer.jar,jboss-deployers.jar,dom4j.jar,jboss-j2se.jar,jboss-mbeans.jar,jboss-jmx.jar,jboss-system-jmx.jar";
/** The default server type. */
- public static final String DEFAULT_SERVER_TYPE = "org.jboss.system.server.ServerImpl";
+ public static final String DEFAULT_SERVER_TYPE = "org.jboss.system.server.profileservice.ServerImpl";
/**
* Configuration properties.
@@ -277,17 +277,18 @@
/**
* Construct a new instance of Server, loading all required classes from
- * the given ClossLoader.
+ * the given ClassLoader.
+ * @param typename - the fqcn of the Server implementation
+ * @param loader - the ClassLoader to load typename with
*/
- protected Server createServer(final String typename, final ClassLoader classLoader) throws Exception
+ protected Server createServer(final String typename, final ClassLoader loader)
+ throws Exception
{
// load the class first
- Class type = classLoader.loadClass(typename);
+ Class type = loader.loadClass(typename);
// and then create a new instance
Server server = (Server) type.newInstance();
-
- // here ya go
return server;
}
}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,66 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.system.server.profileservice;
+
+import java.io.IOException;
+import java.util.HashMap;
+
+import org.jboss.beans.info.spi.PropertyInfo;
+import org.jboss.deployers.spi.management.ManagedObject;
+import org.jboss.deployers.spi.management.ManagementView;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.profileservice.spi.NoSuchDeploymentException;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.NoSuchProfileException;
+import org.jboss.profileservice.spi.ProfileService;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class ManagementViewImpl
+ implements ManagementView
+{
+ private ProfileService ps;
+
+ ManagementViewImpl(ProfileService ps)
+ {
+ this.ps = ps;
+ }
+
+ public ManagedObject getView(ProfileKey key, String deploymentName)
+ throws NoSuchProfileException, NoSuchDeploymentException
+ {
+ Profile profile = ps.getProfile(key);
+ DeploymentContext d = profile.getDeployment(deploymentName);
+ // TODO ManagedObject mo = d.getManagedObject();
+ // return mo;
+ return null;
+ }
+
+ public void setView(ProfileKey key, String deploymentName, HashMap<String, PropertyInfo> view)
+ throws NoSuchProfileException, IOException
+ {
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,386 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import java.net.URL;
+import java.util.Collection;
+import java.util.Enumeration;
+
+import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.dependency.spi.ControllerContext;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.IncompleteDeploymentException;
+import org.jboss.deployers.spi.IncompleteDeployments;
+import org.jboss.deployers.spi.IncompleteDeploymentsBuilder;
+import org.jboss.deployers.spi.deployment.MainDeployer;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.kernel.Kernel;
+import org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap;
+import org.jboss.kernel.plugins.deployment.xml.BasicXMLDeployer;
+import org.jboss.kernel.spi.dependency.KernelController;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.ProfileService;
+import org.jboss.system.server.Server;
+
+/**
+ * An extension of the kernel basic bootstrap that boots the mc from
+ * {profileName}/deployer-beans.xml descriptors using the BasicXMLDeployer, and
+ * loads additional deployments using the ProfileService.
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class ProfileServiceBootstrap extends BasicBootstrap
+{
+ /** The bootstrap file */
+ public static String DEPLOYERS_XML_NAME = "deployer-beans.xml";
+
+ /** The name of the profile that is being booted */
+ protected String profileName;
+
+ /** The Server instance bootstraping the profile service */
+ protected Server server;
+
+ /** The kernel deployer used to load the server deployers */
+ protected BasicXMLDeployer kernelDeployer;
+
+ /** The controller */
+ protected KernelController controller;
+
+ /** The server MainDeployer */
+ protected MainDeployer mainDeployer;
+
+ /** The server ProfileService */
+ protected ProfileService profileService;
+
+ /** The deployer beans prefix */
+ protected String deployerBeansPrefix;
+
+ /** An explicit deployer-beans.xml URL to deploy */
+ protected URL bootstrapURL;
+
+ /**
+ * Create a new ProfileServiceBootstrap.
+ */
+ public ProfileServiceBootstrap()
+ {
+ this("default", null);
+ }
+
+ /**
+ * Create a new ProfileServiceBootstrap.
+ *
+ * @param name the name
+ * @param server the server instance
+ */
+ public ProfileServiceBootstrap(String name, Server server)
+ {
+ this.profileName = name;
+ this.server = server;
+ }
+
+ public Server getServer()
+ {
+ return server;
+ }
+
+ /**
+ * Return the MainDeployer bean.
+ *
+ * @return the MainDeployer bean if bootstrap succeeded, null otherwise.
+ */
+ public MainDeployer getMainDeployer()
+ {
+ return mainDeployer;
+ }
+
+ /**
+ * Return the ProfileService bean.
+ *
+ * @return the ProfileService bean if bootstrap succeeded, null otherwise
+ */
+ public ProfileService getProfileService()
+ {
+ return profileService;
+ }
+
+ /**
+ * Return the bootstrap XML kernel deployer.
+ *
+ * @return BasicXMLDeployer instance.
+ */
+ public BasicXMLDeployer getKernelDeployer()
+ {
+ return kernelDeployer;
+ }
+
+ /**
+ * Get the deployer bean prefix
+ *
+ * @return the prefix
+ */
+ public String getDeployerBeansPrefix()
+ {
+ return deployerBeansPrefix;
+ }
+
+ /**
+ * Set the prefix to add to the DEPLOYERS_XML_NAME in order to create the
+ * classpath resource to look for bootstrap descriptors.
+ *
+ * @param prefix - the prefix for the bootstrap descriptor resource. If null
+ * or empty, a value of profileName + "/" is used.
+ */
+ public void setDeployerBeansPrefix(String prefix)
+ {
+ if (prefix != null && prefix.length() == 0)
+ prefix = null;
+ this.deployerBeansPrefix = prefix;
+ }
+
+ /**
+ * Get the bootstrap url
+ *
+ * @return the bootstrap url
+ */
+ public URL getBootstrapURL()
+ {
+ return bootstrapURL;
+ }
+
+ /**
+ * Set the explicit kernel bootstrap deployer-beans.xml URL. If set, not
+ * resource discovery will be preformed.
+ *
+ * @param bootstrapURL - URL to the bootstrap deployer-beans.xml
+ */
+ public void setBootstrapURL(URL bootstrapURL)
+ {
+ this.bootstrapURL = bootstrapURL;
+ }
+
+ @Override
+ public void bootstrap() throws Throwable
+ {
+ // Bootstrap the core kernel
+ super.bootstrap();
+
+ kernelDeployer = new BasicXMLDeployer(getKernel());
+
+ if (bootstrapURL == null)
+ {
+ ClassLoader cl = Thread.currentThread().getContextClassLoader();
+
+ String bootstrapResName;
+ if (deployerBeansPrefix == null)
+ bootstrapResName = profileName + "/" + DEPLOYERS_XML_NAME;
+ else
+ bootstrapResName = deployerBeansPrefix + DEPLOYERS_XML_NAME;
+
+ log.debug("Scanning for bootstrap resources: " + bootstrapResName);
+ Enumeration<URL> descriptors = cl.getResources(bootstrapResName);
+ while (descriptors.hasMoreElements())
+ {
+ URL url = descriptors.nextElement();
+ log.debug("Found: "+url);
+ deploy(url);
+ }
+
+ String metaInfBootstrapResName = "META-INF/" + bootstrapResName;
+ log.debug("Scanning for bootstrap resources: " + metaInfBootstrapResName);
+ descriptors = cl.getResources(metaInfBootstrapResName);
+ while (descriptors.hasMoreElements())
+ {
+ URL url = descriptors.nextElement();
+ log.debug("Found: "+url);
+ deploy(url);
+ }
+ }
+ else
+ {
+ deploy(bootstrapURL);
+ }
+
+ Kernel kernel = getKernel();
+ controller = kernel.getController();
+
+ // Register the Server instance in the kernel
+ if (server != null)
+ {
+ AbstractBeanMetaData metaData = new AbstractBeanMetaData("JBossServer", server.getClass().getName());
+ controller.install(metaData, server);
+ }
+
+ // Validate that everything is ok
+ checkIncomplete();
+
+ // Get the beans TODO injection!
+ profileService = getBean(controller, "ProfileService", ProfileService.class);
+ log.debug("Using ProfileService: " + profileService);
+ mainDeployer = getBean(controller, "MainDeployer", MainDeployer.class);
+ log.debug("Using MainDeployer: " + mainDeployer);
+
+ // Load the profile beans
+ try
+ {
+ loadProfile(profileName);
+ }
+ catch (IncompleteDeploymentException e)
+ {
+ log.error("Failed to load profile: " + e.getMessage());
+ }
+ catch (Exception e)
+ {
+ log.error("Failed to load profile: ", e);
+ }
+ }
+
+ /**
+ * Get a bean
+ *
+ * @param <T> the expected type
+ * @param controller the controller
+ * @param name the bean name
+ * @param expectedType the expected type
+ * @return the bean
+ * @throws IllegalStateException if the bean is not installed or has the wrong type
+ */
+ protected <T> T getBean(KernelController controller, Object name, Class<T> expectedType)
+ {
+ ControllerContext context = controller.getInstalledContext(name);
+ if (context == null)
+ throw new IllegalStateException("Context not installed: " + name);
+ Object result = context.getTarget();
+ if (result == null)
+ throw new IllegalStateException("No target for " + name);
+ if (expectedType.isInstance(result) == false)
+ throw new IllegalStateException(name + " expected " + expectedType.getName() + " was " + result.getClass().getName());
+ return expectedType.cast(result);
+ }
+
+ /**
+ * Bootstrap deployment of the
+ *
+ * @param url the deployment url
+ * @throws Throwable for any error
+ */
+ protected void deploy(URL url) throws Throwable
+ {
+ log.debug("Deploying bootstrap config: " + url);
+ kernelDeployer.deploy(url);
+ }
+
+ /**
+ * Undeploy a url
+ *
+ * @param url the deployment url
+ */
+ protected void undeploy(URL url)
+ {
+ try
+ {
+ log.debug("Undeploying bootstrap config: " + url);
+ kernelDeployer.undeploy(url);
+ }
+ catch (Throwable t)
+ {
+ log.warn("Error during undeployment: " + url, t);
+ }
+ }
+
+ /**
+ * Load the deployments associated with the named profile and deploy them
+ * using the MainDeployer.
+ *
+ * @param name
+ * @throws Throwable
+ * @throws NullPointerException if either the MainDeployer or ProfileService
+ * have not been injected.
+ */
+ protected void loadProfile(String name) throws Throwable
+ {
+ MainDeployer deployer = getMainDeployer();
+ if (deployer == null)
+ throw new NullPointerException("MainDeployer has not been set");
+ ProfileService ps = getProfileService();
+ if (ps == null)
+ throw new NullPointerException("ProfileService has not been set");
+
+ // Load the named profile
+ ProfileKey key = new ProfileKey(name);
+ Profile profile = ps.getProfile(key);
+
+ // HACK
+ DeploymentContext first = null;
+
+ // Deploy the bootstrap
+ Collection<DeploymentContext> boostraps = profile.getBootstraps();
+ for (DeploymentContext d : boostraps)
+ {
+ deployer.addDeploymentContext(d);
+ if (first == null)
+ first = d;
+ }
+ deployer.process();
+ checkIncomplete();
+
+ ClassLoader cl = first.getClassLoader();
+ Thread thread = Thread.currentThread();
+ ClassLoader old = thread.getContextClassLoader();
+ if (cl != null)
+ thread.setContextClassLoader(cl);
+ try
+ {
+
+ // Deploy the profile deployers
+ Collection<DeploymentContext> profileDeployers = profile.getDeployers();
+ for (DeploymentContext d : profileDeployers)
+ deployer.addDeploymentContext(d);
+ deployer.process();
+ checkIncomplete();
+
+ // Deploy the profile deployments
+ Collection<DeploymentContext> profileDeployments = profile.getDeployments();
+ for (DeploymentContext d : profileDeployments)
+ deployer.addDeploymentContext(d);
+ deployer.process();
+ checkIncomplete();
+ }
+ finally
+ {
+ thread.setContextClassLoader(old);
+ }
+ }
+
+ /**
+ * Check whether we are incomplete
+ *
+ * @throws DeploymentException the deployment exception
+ */
+ protected void checkIncomplete() throws DeploymentException
+ {
+ IncompleteDeployments incomplete = IncompleteDeploymentsBuilder.build(mainDeployer, controller);
+ if (incomplete.isIncomplete())
+ throw new IncompleteDeploymentException(incomplete);
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,126 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import java.io.IOException;
+
+import org.jboss.deployers.spi.management.ManagementView;
+import org.jboss.profileservice.spi.NoSuchProfileException;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.ProfileService;
+import org.jboss.system.server.profile.basic.ProfileImpl;
+
+
+/**
+ * An initial ProfileService impl for loading server deployments.
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class ProfileServiceImpl
+ implements ProfileService
+{
+ private String name;
+ private String profileRoot;
+ private Profile defaultImpl;
+ private ManagementView mgtView;
+
+ public ProfileServiceImpl(String name) throws IOException
+ {
+ this.name = name;
+ mgtView = new ManagementViewImpl(this);
+ }
+ // Properties ------------------------
+
+ public String getName()
+ {
+ return this.name;
+ }
+ public void setName(String name)
+ {
+ this.name = name;
+ }
+ public String getProfileRoot()
+ {
+ return this.profileRoot;
+ }
+ public void setProfileRoot(String profileRoot)
+ {
+ this.profileRoot = profileRoot;
+ }
+
+ public void start()
+ {
+ defaultImpl = new ProfileImpl(profileRoot, name);
+ }
+
+ // ProfileService implementation --------------------
+ public String[] getDomains()
+ {
+ String[] domains = {ProfileKey.DEFAULT};
+ return domains;
+ }
+
+ public ProfileKey[] getProfileKeys()
+ {
+ ProfileKey[] keys = {new ProfileKey(null)};
+ return keys;
+ }
+
+ /**
+ * Always returns the default profile.
+ */
+ public Profile getProfile(ProfileKey key)
+ throws NoSuchProfileException
+ {
+ return defaultImpl;
+ }
+
+ public String[] getProfileDeploymentNames(ProfileKey key)
+ throws NoSuchProfileException
+ {
+ String[] names = {"default"};
+ return names;
+ }
+
+ public ManagementView getViewManager()
+ {
+ return mgtView;
+ }
+ public void setViewManager(ManagementView mgtView)
+ {
+ this.mgtView = mgtView;
+ }
+
+ // Admin of profiles @todo could be an option plugin
+ public Profile newProfile(ProfileKey key)
+ {
+ return new ProfileImpl(profileRoot, name);
+ }
+
+ public void removeProfile(ProfileKey key)
+ throws NoSuchProfileException
+ {
+ }
+}
+
Added: trunk/system/src/main/org/jboss/system/server/profileservice/SecurityActions.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/SecurityActions.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/SecurityActions.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import java.security.PrivilegedAction;
+import java.security.AccessController;
+
+/**
+ * Package privileged actions.
+ *
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+class SecurityActions
+{
+ static String getSystemProperty(final String name, final String defaultValue)
+ {
+ PrivilegedAction<String> action = new PrivilegedAction<String>()
+ {
+ public String run()
+ {
+ return System.getProperty(name, defaultValue);
+ }
+ };
+ return AccessController.doPrivileged(action);
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,766 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.jboss.system.server.profileservice;
+
+import java.io.File;
+import java.net.URL;
+import java.util.Date;
+import java.util.Properties;
+
+import javax.management.Notification;
+import javax.management.NotificationBroadcasterSupport;
+import javax.management.NotificationEmitter;
+
+import org.jboss.Version;
+import org.jboss.deployers.spi.deployment.MainDeployer;
+import org.jboss.kernel.Kernel;
+import org.jboss.kernel.plugins.deployment.BasicKernelDeployer;
+import org.jboss.kernel.spi.event.KernelEvent;
+import org.jboss.logging.Logger;
+import org.jboss.net.protocol.URLStreamHandlerFactory;
+import org.jboss.system.server.Server;
+import org.jboss.system.server.ServerConfig;
+import org.jboss.system.server.BaseServerConfig;
+import org.jboss.util.StopWatch;
+
+
+/**
+ * A Server implementation that uses the deployer-beans.xml and ProfileService
+ * to boot the server.
+ *
+ * @author Scott.Stark at jboss.org
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision$
+ */
+public class ServerImpl extends NotificationBroadcasterSupport
+ implements Server, NotificationEmitter
+{
+ /** Instance logger. */
+ private Logger log;
+
+ /** Container for version information. */
+ private final Version version = Version.getInstance();
+
+ /** Package information for org.jboss */
+ private final Package jbossPackage = Package.getPackage("org.jboss");
+
+ /** The kernel bootstrap */
+ private ProfileServiceBootstrap bootstrap;
+ /** A resource prefix */
+ private String deployerBeansPrefix;
+
+ /** The basic configuration for the server. */
+ private BaseServerConfig config;
+
+ /** When the server was started. */
+ private Date startDate;
+
+ /** Flag to indicate if we are started. */
+ private boolean started;
+ /** A flag indicating if start has been called */
+ private boolean isInStart;
+ /** A flag indicating if shutdown has been called */
+ private boolean isInShutdown;
+
+ /** The JVM shutdown hook */
+ private ShutdownHook shutdownHook;
+
+ /** The JBoss Life Thread */
+ private LifeThread lifeThread;
+
+ /**
+ * No-arg constructor for ServerImpl
+ */
+ public ServerImpl()
+ {
+ }
+
+ /**
+ * Initialize the Server instance.
+ *
+ * @param props - The configuration properties for the server.
+ *
+ * @throws IllegalStateException Already initialized.
+ * @throws Exception Failed to initialize.
+ */
+ public void init(final Properties props)
+ throws IllegalStateException, Exception
+ {
+ if (props == null)
+ throw new IllegalArgumentException("props is null");
+ if (config != null)
+ throw new IllegalStateException("already initialized");
+
+ ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
+
+ try
+ {
+ Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
+ doInit(props);
+ }
+ finally
+ {
+ Thread.currentThread().setContextClassLoader(oldCL);
+ }
+ }
+
+ /**
+ * Initialize server configuration and jvm settings.
+ * @param props
+ * @throws Exception
+ */
+ private void doInit(final Properties props) throws Exception
+ {
+ // Create a new config object from the give properties
+ this.config = new BaseServerConfig(props);
+ this.deployerBeansPrefix = props.getProperty("jboss.server.deployerBeansPrefix");
+
+ // Set the VM temp directory to the server tmp dir
+ boolean overrideTmpDir = Boolean.getBoolean("jboss.server.temp.dir.overrideJavaTmpDir");
+ if( overrideTmpDir )
+ {
+ File serverTmpDir = config.getServerTempDir();
+ System.setProperty("java.io.tmpdir", serverTmpDir.getCanonicalPath());
+ }
+
+ /* Initialize the logging layer using the ServerImpl class. The server log
+ directory is initialized prior to this to ensure the jboss.server.log.dir
+ system property is set in case its used by the logging configs.
+ */
+ config.getServerLogDir();
+ log = Logger.getLogger(getClass());
+
+ // Setup URL handlers - do this before initializing the ServerConfig
+ initURLHandlers();
+ config.initURLs();
+
+ log.info("Starting JBoss (Microcontainer)...");
+
+ if (jbossPackage != null)
+ {
+ // Show what release this is...
+ log.info("Release ID: " +
+ jbossPackage.getImplementationTitle() + " " +
+ jbossPackage.getImplementationVersion());
+ }
+ else
+ {
+ log.warn("could not get package info to display release, either the " +
+ "jar manifest in jboss-system.jar has been mangled or you're " +
+ "running unit tests from ant outside of JBoss itself.");
+ }
+
+ log.debug("Using config: " + config);
+
+ // make sure our impl type is exposed
+ log.debug("Server type: " + getClass());
+
+ // Log the basic configuration elements
+ log.info("Home Dir: " + config.getHomeDir());
+ log.info("Home URL: " + config.getHomeURL());
+ log.info("Library URL: " + config.getLibraryURL());
+ log.info("Patch URL: " + config.getPatchURL());
+ log.info("Server Name: " + config.getServerName());
+ log.info("Server Home Dir: " + config.getServerHomeDir());
+ log.info("Server Home URL: " + config.getServerHomeURL());
+ log.info("Server Data Dir: " + config.getServerDataDir());
+ log.info("Server Temp Dir: " + config.getServerTempDir());
+ log.info("Server Config URL: " + config.getServerConfigURL());
+ log.info("Server Library URL: " + config.getServerLibraryURL());
+ log.info("Root Deployment Filename: " + config.getRootDeploymentFilename());
+ }
+
+ /**
+ * The <code>initURLHandlers</code> method calls
+ * internalInitURLHandlers. if requireJBossURLStreamHandlers is
+ * false, any exceptions are logged and ignored.
+ *
+ */
+ private void initURLHandlers()
+ {
+ if (config.getRequireJBossURLStreamHandlerFactory())
+ {
+ internalInitURLHandlers();
+ } // end of if ()
+ else
+ {
+ try
+ {
+ internalInitURLHandlers();
+ }
+ catch (SecurityException e)
+ {
+ log.warn("You do not have permissions to set URLStreamHandlerFactory", e);
+ } // end of try-catch
+ catch (Error e)
+ {
+ log.warn("URLStreamHandlerFactory already set", e);
+ } // end of catch
+ } // end of else
+ }
+
+ /**
+ * Set up our only URLStreamHandlerFactory.
+ * This is needed to ensure Sun's version is not used (as it leaves files
+ * locked on Win2K/WinXP platforms.
+ */
+ private void internalInitURLHandlers()
+ {
+ try
+ {
+ // Install a URLStreamHandlerFactory that uses the TCL
+ URL.setURLStreamHandlerFactory(new URLStreamHandlerFactory());
+
+ // Preload JBoss URL handlers
+ URLStreamHandlerFactory.preload();
+ }
+ catch (Error error)
+ { //very naughty but we HAVE to do this or
+ //we'll fail if we ever try to do this again
+ log.warn("Caught Throwable Error, this probably means " +
+ "we've already set the URLStreamHAndlerFactory before");
+ }
+
+ // Include the default JBoss protocol handler package
+ String handlerPkgs = System.getProperty("java.protocol.handler.pkgs");
+ if (handlerPkgs != null)
+ {
+ handlerPkgs += "|org.jboss.net.protocol";
+ }
+ else
+ {
+ handlerPkgs = "org.jboss.net.protocol";
+ }
+ System.setProperty("java.protocol.handler.pkgs", handlerPkgs);
+ }
+
+ /**
+ * Get the typed server configuration object which the
+ * server has been initalized to use.
+ *
+ * @return Typed server configuration object.
+ *
+ * @throws IllegalStateException Not initialized.
+ */
+ public ServerConfig getConfig() throws IllegalStateException
+ {
+ if (config == null)
+ throw new IllegalStateException("not initialized");
+
+ return config;
+ }
+
+ /**
+ * Check if the server is started.
+ *
+ * @return True if the server is started, else false.
+ */
+ public boolean isStarted()
+ {
+ return started;
+ }
+
+ /**
+ Check if the shutdown operation has been called/is in progress.
+
+ @return true if shutdown has been called, false otherwise
+ */
+ public boolean isInShutdown()
+ {
+ return isInShutdown;
+ }
+
+ /**
+ * Start the Server instance.
+ *
+ * @throws IllegalStateException Already started or not initialized.
+ * @throws Exception Failed to start.
+ */
+ public void start() throws IllegalStateException, Exception
+ {
+ synchronized( this )
+ {
+ if( isInStart == false )
+ {
+ isInStart = true;
+ }
+ else
+ {
+ log.debug("Already in start, ignoring duplicate start");
+ return;
+ }
+ }
+
+ // make sure we are initialized
+ getConfig();
+
+ // make sure we aren't started yet
+ if (started)
+ throw new IllegalStateException("already started");
+
+ ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
+
+ try
+ {
+ ClassLoader myCL = getClass().getClassLoader();
+ /*
+ URL libURL = config.getLibraryURL();
+ // Hack to add the jmx jars until the mc/legacy jmx integration is cleaned up
+ URL[] jmxJars = {
+ new URL(libURL, "dom4j.jar"),
+ new URL(libURL, "jboss-j2se.jar"),
+ new URL(libURL, "jboss-jmx.jar"),
+ new URL(libURL, "jboss-mbeans.jar"),
+ new URL(libURL, "jboss-system-jmx.jar")
+ };
+ NoAnnotationURLClassLoader jmxLoader = new NoAnnotationURLClassLoader(jmxJars, myCL);
+ Thread.currentThread().setContextClassLoader(jmxLoader);
+ */
+ Thread.currentThread().setContextClassLoader(myCL);
+ doStart();
+ }
+ catch (Throwable t)
+ {
+ log.debug("Failed to start", t);
+
+ if (t instanceof Exception)
+ throw (Exception)t;
+ if (t instanceof Error)
+ throw (Error)t;
+
+ throw new org.jboss.util.UnexpectedThrowable(t);
+ }
+ finally
+ {
+ Thread.currentThread().setContextClassLoader(oldCL);
+ isInStart = false;
+ }
+ }
+
+ /**
+ * Start the server by booting the kernel, loading deployers, and loading
+ * the profile deployments.
+ *
+ * @throws Throwable for any error
+ */
+ private void doStart() throws Throwable
+ {
+ // See how long it takes us to start up
+ StopWatch watch = new StopWatch(true);
+
+ // remeber when we we started
+ startDate = new Date();
+
+ bootstrap = new ProfileServiceBootstrap(config.getServerName(), this);
+ if( deployerBeansPrefix != null )
+ {
+ bootstrap.setDeployerBeansPrefix(deployerBeansPrefix);
+ log.info("Starting Microcontainer, deployerBeansPrefix="+deployerBeansPrefix);
+ }
+ else
+ {
+ URL configURL = config.getServerConfigURL();
+ URL bootstrapURL = new URL(configURL, ProfileServiceBootstrap.DEPLOYERS_XML_NAME);
+ log.info("Starting Microcontainer, bootstrapURL="+bootstrapURL);
+ bootstrap.setBootstrapURL(bootstrapURL);
+ }
+
+ // Install the shutdown hook
+ shutdownHook = new ShutdownHook();
+ shutdownHook.setDaemon(true);
+ try
+ {
+ Runtime.getRuntime().addShutdownHook(shutdownHook);
+ log.debug("Shutdown hook added");
+ }
+ catch (Exception e)
+ {
+ log.warn("Failed to add shutdown hook; ignoring", e);
+ }
+
+ bootstrap.run();
+
+ lifeThread = new LifeThread();
+ lifeThread.start();
+
+ started = true;
+
+ // Send a notification that the startup is complete
+ KernelEvent startEvent = bootstrap.createEvent(START_NOTIFICATION_TYPE, new Long(watch.getLapTime()));
+ bootstrap.fireKernelEvent(startEvent);
+ // Send a JMX notification that the startup is complete
+ Notification msg = new Notification(START_NOTIFICATION_TYPE, this, 1);
+ msg.setUserData(new Long(watch.getLapTime()));
+ sendNotification(msg);
+
+ watch.stop();
+
+ if (jbossPackage != null)
+ {
+ // Tell the world how fast it was =)
+ log.info("JBoss (Microcontainer) [" + jbossPackage.getImplementationVersion() +
+ "] Started in " + watch);
+ }
+ else
+ {
+ log.warn("could not get package info to display release, either the " +
+ "jar manifest in run.jar has been mangled or you're " +
+ "running unit tests from ant outside of JBoss itself.");
+ }
+ }
+
+ /**
+ * Shutdown the Server instance and run shutdown hooks.
+ *
+ * <p>If the exit on shutdown flag is true, then {@link #exit()}
+ * is called, else only the shutdown hook is run.
+ *
+ * @throws IllegalStateException No started.
+ */
+ public void shutdown() throws IllegalStateException
+ {
+ if (!started)
+ throw new IllegalStateException("not started");
+
+ final ServerImpl server = this;
+
+ log.debug("Shutting down");
+
+ isInShutdown = true;
+ boolean exitOnShutdown = config.getExitOnShutdown();
+ boolean blockingShutdown = config.getBlockingShutdown();
+
+ log.debug("exitOnShutdown: " + exitOnShutdown);
+ log.debug("blockingShutdown: " + blockingShutdown);
+
+ lifeThread.interrupt();
+
+ if (exitOnShutdown)
+ {
+ server.exit(0);
+ }
+ else if (blockingShutdown)
+ {
+ shutdownHook.shutdown();
+ } // end of if ()
+ else
+ {
+ // start in new thread to give positive
+ // feedback to requesting client of success.
+ new Thread()
+ {
+ public void run()
+ {
+ // just run the hook, don't call System.exit, as we may
+ // be embeded in a vm that would not like that very much
+ shutdownHook.shutdown();
+ }
+ }.start();
+ }
+ }
+
+ /**
+ * Shutdown the server, the JVM and run shutdown hooks.
+ *
+ * @param exitcode The exit code returned to the operating system.
+ */
+ public void exit(final int exitcode)
+ {
+ // start in new thread so that we might have a chance to give positive
+ // feed back to requesting client of success.
+ new Thread()
+ {
+ public void run()
+ {
+ log.info("Shutting down the JVM now!");
+ Runtime.getRuntime().exit(exitcode);
+ }
+ }.start();
+ }
+
+ /**
+ * Shutdown the server, the JVM and run shutdown hooks. Exits with
+ * code 1.
+ */
+ public void exit()
+ {
+ exit(1);
+ }
+
+ /**
+ * Forcibly terminates the currently running Java virtual machine.
+ *
+ * @param exitcode The exit code returned to the operating system.
+ */
+ public void halt(final int exitcode)
+ {
+ // Send a stop event msg
+ KernelEvent stopEvent = bootstrap.createEvent(STOP_NOTIFICATION_TYPE, null);
+ bootstrap.fireKernelEvent(stopEvent);
+
+ // start in new thread so that we might have a chance to give positive
+ // feed back to requesting client of success.
+ new Thread()
+ {
+ public void run()
+ {
+ System.err.println("Halting the system now!");
+ Runtime.getRuntime().halt(exitcode);
+ }
+ }.start();
+ }
+
+ /**
+ * Forcibly terminates the currently running Java virtual machine.
+ * Exits with code 1.
+ */
+ public void halt()
+ {
+ halt(1);
+ }
+
+
+ ///////////////////////////////////////////////////////////////////////////
+ // Runtime Access //
+ ///////////////////////////////////////////////////////////////////////////
+
+ /**
+ * A simple helper used to log the Runtime memory information.
+ *
+ * @param rt the runtime
+ */
+ private void logMemoryUsage(final Runtime rt)
+ {
+ log.info("Total/free memory: " + rt.totalMemory() + "/" + rt.freeMemory());
+ }
+
+ /**
+ * Hint to the JVM to run the garbage collector.
+ */
+ public void runGarbageCollector()
+ {
+ Runtime rt = Runtime.getRuntime();
+
+ logMemoryUsage(rt);
+ rt.gc();
+ log.info("Hinted to the JVM to run garbage collection");
+ logMemoryUsage(rt);
+ }
+
+ /**
+ * Hint to the JVM to run any pending object finalizations.
+ */
+ public void runFinalization()
+ {
+ Runtime.getRuntime().runFinalization();
+ log.info("Hinted to the JVM to run any pending object finalizations");
+ }
+
+ /**
+ * Enable or disable tracing method calls at the Runtime level.
+ *
+ * @param flag whether to enable trace
+ */
+ public void traceMethodCalls(final Boolean flag)
+ {
+ Runtime.getRuntime().traceMethodCalls(flag.booleanValue());
+ }
+
+ /**
+ * Enable or disable tracing instructions the Runtime level.
+ *
+ * @param flag whether to enable trace
+ */
+ public void traceInstructions(final Boolean flag)
+ {
+ Runtime.getRuntime().traceInstructions(flag.booleanValue());
+ }
+
+
+ ///////////////////////////////////////////////////////////////////////////
+ // Server Information //
+ ///////////////////////////////////////////////////////////////////////////
+
+ public Date getStartDate()
+ {
+ return startDate;
+ }
+
+ public String getVersion()
+ {
+ return version.toString();
+ }
+
+ public String getVersionName()
+ {
+ return version.getName();
+ }
+
+ public String getBuildNumber()
+ {
+ return version.getBuildNumber();
+ }
+
+ public String getBuildJVM()
+ {
+ return version.getBuildJVM();
+ }
+
+ public String getBuildOS()
+ {
+ return version.getBuildOS();
+ }
+
+ public String getBuildID()
+ {
+ return version.getBuildID();
+ }
+
+ /**
+ * The server build date
+ * @return server build date
+ */
+ public String getBuildDate()
+ {
+ return version.getBuildDate();
+ }
+
+ /**
+ * The server kernel.
+ * @return server kernel.
+ */
+ public Kernel getKernel()
+ {
+ return bootstrap.getKernel();
+ }
+
+ /** A simple thread that keeps the vm alive in the event there are no
+ * other threads started.
+ */
+ private class LifeThread
+ extends Thread
+ {
+ Object lock = new Object();
+ LifeThread()
+ {
+ super("JBossLifeThread");
+ }
+ public void run()
+ {
+ synchronized (lock)
+ {
+ try
+ {
+ lock.wait();
+ }
+ catch (InterruptedException ignore)
+ {
+ }
+ }
+ log.info("LifeThread.run exits!");
+ }
+ }
+
+ ///////////////////////////////////////////////////////////////////////////
+ // Shutdown Hook //
+ ///////////////////////////////////////////////////////////////////////////
+
+ private class ShutdownHook
+ extends Thread
+ {
+ private boolean forceHalt = true;
+
+ public ShutdownHook()
+ {
+ super("JBoss Shutdown Hook");
+
+ String value = SecurityActions.getSystemProperty("jboss.shutdown.forceHalt", null);
+ if (value != null)
+ {
+ forceHalt = new Boolean(value).booleanValue();
+ }
+ }
+
+ public void run()
+ {
+ shutdown();
+ if (forceHalt)
+ {
+ System.out.println("Halting VM");
+ Runtime.getRuntime().halt(0);
+ }
+ }
+
+ public void shutdown()
+ {
+ // Send a notification that mbeanServer stop is initiated
+ log.info("JBoss SHUTDOWN");
+ Notification msg = new Notification(Server.STOP_NOTIFICATION_TYPE, this, 2);
+ sendNotification(msg);
+ log.info("Undeploying all packages");
+ shutdownDeployments();
+
+ log.debug("Shutting down Microcontainer");
+ System.out.println("Shutting down Microcontainer");
+
+ // Shutdown the core kernel
+ shutdownKernel();
+
+ log.info("Shutdown complete");
+ System.out.println("Shutdown complete");
+ }
+
+ protected void shutdownDeployments()
+ {
+ try
+ {
+ MainDeployer deployer = bootstrap.getMainDeployer();
+ if (deployer != null)
+ deployer.shutdown();
+ }
+ catch (Exception e)
+ {
+ log.error("Failed to shutdown deployer", e);
+ }
+ }
+
+ /**
+ * The <code>shutdownServices</code> method calls the one and only
+ * ServiceController to shut down all the mbeans registered with it.
+ */
+ protected void shutdownKernel()
+ {
+ try
+ {
+ BasicKernelDeployer deployer = bootstrap.getKernelDeployer();
+ if (deployer != null)
+ deployer.shutdown();
+ }
+ catch (Exception e)
+ {
+ log.error("Failed to shutdown services", e);
+ }
+ }
+
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import org.jboss.deployers.plugins.structure.AbstractDeploymentContext;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * VFSBootstrapScannerImpl.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class VFSBootstrapScannerImpl extends VFSScanner
+{
+ protected DeploymentContext add(Profile profile, VirtualFile file) throws Exception
+ {
+ DeploymentContext deployment = new AbstractDeploymentContext(file);
+ if( profile.getBootstrap(deployment.getName()) == null )
+ profile.addBootstrap(deployment);
+ return deployment;
+ }
+
+ protected void remove(Profile profile, String name)
+ {
+ profile.removeBootstrap(name);
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import org.jboss.deployers.plugins.structure.AbstractDeploymentContext;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * VFSDeployerScannerImpl.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class VFSDeployerScannerImpl extends VFSScanner
+{
+ protected DeploymentContext add(Profile profile, VirtualFile file) throws Exception
+ {
+ DeploymentContext deployment = new AbstractDeploymentContext(file);
+ if( profile.getDeployer(deployment.getName()) == null )
+ profile.addDeployer(deployment);
+ return deployment;
+ }
+
+ protected void remove(Profile profile, String name)
+ {
+ profile.removeDeployer(name);
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import org.jboss.deployers.plugins.structure.AbstractDeploymentContext;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * VFSDeploymentScannerImpl.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class VFSDeploymentScannerImpl extends VFSScanner
+{
+ protected DeploymentContext add(Profile profile, VirtualFile file) throws Exception
+ {
+ DeploymentContext deployment = new AbstractDeploymentContext(file);
+ if( profile.getDeployment(deployment.getName()) == null )
+ profile.addDeployment(deployment);
+ return deployment;
+ }
+
+ protected void remove(Profile profile, String name)
+ {
+ profile.removeDeployment(name);
+ }
+}
Added: trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,712 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.system.server.profileservice;
+
+import java.io.IOException;
+import java.net.URI;
+import java.net.URISyntaxException;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.Map;
+import java.util.StringTokenizer;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.CopyOnWriteArrayList;
+
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.net.protocol.URLLister;
+import org.jboss.net.protocol.URLLister.URLFilter;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.ProfileService;
+import org.jboss.util.JBossObject;
+import org.jboss.util.StringPropertyReplacer;
+import org.jboss.virtual.VFS;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * A DeploymentScanner build on top of the VFS and ProfileService. This is a
+ * first pass to flesh out the APIs/concepts.
+ *
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ * @author Scott.Stark at jboss.org
+ * @author adrian at jboss.org
+ * @version $Revision$
+ */
+public abstract class VFSScanner extends JBossObject
+{
+ /** The profile service */
+ private ProfileService profileService;
+
+ /** The profile service key */
+ private ProfileKey profileKey;
+
+ /** The URIfied ServerHomeURL */
+ private URI serverHomeURI;
+
+ /** The list of URIs to scan */
+ private List<URI> uriList = new CopyOnWriteArrayList<URI>();
+
+ /** The list of VirtualFiles to scan */
+ private List<VirtualFile> vdfList = new CopyOnWriteArrayList<VirtualFile>();;
+
+ /** Allow a filter for scanned directories */
+ private URLLister.URLFilter filter;
+
+ /** Whether to search for files inside directories whose names containing no dots */
+ private boolean doRecursiveSearch = true;
+
+ /** A map of deployed virtual files to their names */
+ private Map<VirtualFile, String> deployedSet = new ConcurrentHashMap<VirtualFile, String>();
+
+ /**
+ * Get the profileKey.
+ *
+ * @return the profileKey.
+ */
+ public ProfileKey getProfileKey()
+ {
+ return profileKey;
+ }
+
+ /**
+ * Set the profileKey.
+ *
+ * @param profileKey the profileKey.
+ */
+ public void setProfileKey(ProfileKey profileKey)
+ {
+ this.profileKey = profileKey;
+ }
+
+ /**
+ * Get the profileService.
+ *
+ * @return the profileService.
+ */
+ public ProfileService getProfileService()
+ {
+ return profileService;
+ }
+
+ /**
+ * Set the profileService.
+ *
+ * @param profileService the profileService.
+ */
+ public void setProfileService(ProfileService profileService)
+ {
+ this.profileService = profileService;
+ }
+
+ /**
+ * Set the uris
+ *
+ * @param listspec the uris
+ * @throws URISyntaxException
+ * @throws IOException
+ */
+ public void setURIs(final String listspec) throws URISyntaxException, IOException
+ {
+ if (listspec == null)
+ {
+ throw new NullPointerException("listspec argument cannot be null");
+ }
+ List<URI> list = new LinkedList<URI>();
+
+ StringTokenizer stok = new StringTokenizer(listspec, ",");
+ while (stok.hasMoreTokens())
+ {
+ String urispec = stok.nextToken().trim();
+
+ log.debug("Adding URI from spec: " + urispec);
+
+ URI uri = makeURI(urispec);
+
+ log.debug("URI: " + uri);
+
+ list.add(uri);
+ }
+ setURIList(list);
+ }
+
+ /**
+ * Set the uri list
+ *
+ * @param list the list
+ * @throws IOException
+ */
+ public void setURIList(final List<URI> list) throws IOException
+ {
+ if (list == null)
+ {
+ throw new NullPointerException("list argument cannot be null");
+ }
+
+ // start out with a fresh list
+ uriList.clear();
+
+ for(int n = 0; n < list.size(); n ++)
+ {
+ URI uri = list.get(n);
+ if (uri == null)
+ {
+ throw new IllegalArgumentException("list element["+n+"] is null");
+ }
+ addURI(uri);
+ }
+ log.debug("URI list: " + uriList);
+ }
+
+ /**
+ * Get the uri list
+ *
+ * @return the list
+ */
+ public List<URI> getURIList()
+ {
+ return new ArrayList<URI>(uriList);
+ }
+
+ /**
+ * Set whether to do recursive search
+ *
+ * @param recurse true when recurisve
+ */
+ public void setRecursiveSearch(boolean recurse)
+ {
+ doRecursiveSearch = recurse;
+ }
+
+ /**
+ * Get the recursive search
+ *
+ * @return true when recursive
+ */
+ public boolean getRecursiveSearch()
+ {
+ return doRecursiveSearch;
+ }
+
+ /**
+ * Set the filer
+ *
+ * @param classname the filer class name
+ * @throws ClassNotFoundException when the class is not found
+ * @throws IllegalAccessException when the class's default constructor is not public
+ * @throws InstantiationException when there is an error constructing the class
+ */
+ public void setFilter(String classname)
+ throws ClassNotFoundException, IllegalAccessException, InstantiationException
+ {
+ Class filterClass = Thread.currentThread().getContextClassLoader().loadClass(classname);
+ filter = (URLLister.URLFilter)filterClass.newInstance();
+ }
+
+ /**
+ * Get the filer
+ *
+ * @return the filter
+ */
+ public String getFilter()
+ {
+ if (filter == null)
+ {
+ return null;
+ }
+ return filter.getClass().getName();
+ }
+
+ /**
+ * Set the filter instance
+ *
+ * @param filter ther filter
+ */
+ public void setFilterInstance(URLFilter filter)
+ {
+ this.filter = filter;
+ }
+
+ /**
+ * Get the filter instance
+ *
+ * @return the filter
+ */
+ public URLFilter getFilterInstance()
+ {
+ return filter;
+ }
+
+ /**
+ * Add a uri
+ *
+ * @param uri the uri
+ * @throws IOException for an error accessing the uri
+ */
+ public void addURI(final URI uri) throws IOException
+ {
+ if (uri == null)
+ {
+ throw new NullPointerException("uri argument cannot be null");
+ }
+ if( uriList.add(uri) == true )
+ {
+ log.debug("Added URI: " + uri);
+ VirtualFile vf = getVFforURI(uri);
+ vdfList.add(vf);
+ }
+ }
+
+ /**
+ * Remove a uri
+ *
+ * @param uri the uri
+ * @throws IOException for an error accessing the uri
+ */
+ public void removeURI(final URI uri)
+ throws IOException
+ {
+ if (uri == null)
+ {
+ throw new NullPointerException("uri argument cannot be null");
+ }
+ VirtualFile vf = getVFforURI(uri);
+ vdfList.remove(vf);
+ boolean success = uriList.remove(uri);
+
+ if (success)
+ {
+ log.debug("Removed URI: " + uri);
+ }
+ }
+
+ /**
+ * Whether it has the uri
+ *
+ * @param uri the uri
+ * @return when the uri is configured
+ */
+ public boolean hasURI(final URI uri)
+ {
+ if (uri == null)
+ {
+ throw new NullPointerException("uri argument cannot be null");
+ }
+ return uriList.contains(uri);
+ }
+
+ /**
+ * Start the scan
+ *
+ * @throws Exception for any error
+ */
+ public void start() throws Exception
+ {
+ // synchronize uriList and vdfList because only at this point
+ // setVirtualFileFactory() injection has been performed
+ vdfList.clear();
+ for (Iterator<URI> i = uriList.iterator(); i.hasNext(); )
+ {
+ URI uri = i.next();
+ VirtualFile vf = this.getVFforURI(uri);
+ vdfList.add(vf);
+ }
+ if( profileKey == null )
+ {
+ profileKey = new ProfileKey("default");
+ }
+ scan();
+ }
+
+ /**
+ * Scan
+ *
+ * @throws Exception for any error
+ */
+ public synchronized void scan() throws Exception
+ {
+ if (vdfList == null)
+ {
+ throw new IllegalStateException("not initialized");
+ }
+
+ boolean trace = log.isTraceEnabled();
+
+ // Scan for deployments
+ if (trace)
+ {
+ log.trace("Scanning for new deployments");
+ }
+
+ // VirtualFiles to deploy
+ List<VirtualFile> toDeployList = new LinkedList<VirtualFile>();
+ synchronized (vdfList)
+ {
+ for (Iterator i = vdfList.iterator(); i.hasNext();)
+ {
+ VirtualFile component = (VirtualFile)i.next();
+ if (component.isFile())
+ {
+ // treat this as a deployable unit
+ toDeployList.add(component);
+ }
+ else if (component.isDirectory())
+ {
+ // process (possibly recursively) the dir
+ addDeployments(toDeployList, component);
+ }
+ }
+ }
+
+ if (trace)
+ {
+ log.trace("toDeployList");
+ for (Iterator i = toDeployList.iterator(); i.hasNext();)
+ {
+ log.trace(i.next());
+ }
+ }
+ LinkedList<VirtualFile> toRemoveList = new LinkedList<VirtualFile>();
+ LinkedList<VirtualFile> toCheckForUpdateList = new LinkedList<VirtualFile>();
+
+ synchronized (deployedSet)
+ {
+ // remove previously deployed URLs no longer needed
+ for (VirtualFile deployedComponent : deployedSet.keySet())
+ {
+ if (toDeployList.contains(deployedComponent))
+ {
+ toCheckForUpdateList.add(deployedComponent);
+ }
+ else
+ {
+ toRemoveList.add(deployedComponent);
+ }
+ }
+ }
+
+ // ********
+ // Undeploy
+ // ********
+
+ for (Iterator i = toRemoveList.iterator(); i.hasNext();)
+ {
+ VirtualFile deployedComponent = (VirtualFile)i.next();
+ undeploy(deployedComponent);
+ }
+
+ // ********
+ // Redeploy
+ // ********
+
+ // compute the DeployedURL list to update
+ ArrayList<VirtualFile> toUpdateList = new ArrayList<VirtualFile>(toCheckForUpdateList.size());
+ for (Iterator i = toCheckForUpdateList.iterator(); i.hasNext();)
+ {
+ VirtualFile deployedComponent = (VirtualFile)i.next();
+ if (isModified(deployedComponent))
+ {
+ if (trace)
+ {
+ log.trace("Re-deploying " + deployedComponent);
+ }
+ toUpdateList.add(deployedComponent);
+ }
+ }
+
+ // sort to update list
+ //Collections.sort(toUpdateList, sorter);
+
+ // Undeploy in order
+ for (int i = toUpdateList.size() - 1; i >= 0; i--)
+ {
+ VirtualFile vf = toUpdateList.get(i);
+ undeploy(vf);
+ }
+
+ // Deploy in order
+ for (int i = 0; i < toUpdateList.size(); i++)
+ {
+ VirtualFile vf = toUpdateList.get(i);
+ deploy(vf);
+ }
+
+ // ******
+ // Deploy
+ // ******
+
+ //Collections.sort(toDeployList, sorter);
+ for (Iterator i = toDeployList.iterator(); i.hasNext();)
+ {
+ VirtualFile component = (VirtualFile)i.next();
+
+ // if component is not deployed already, deploy it
+ if (!deployedSet.containsKey(component))
+ {
+ deploy(component);
+ }
+
+ // component must have been deployed by now, so remove it from list
+ i.remove();
+
+ /* Check to see if mainDeployer suffix list has changed, if so, then resort
+ if (i.hasNext() && updateSorter())
+ {
+ Collections.sort(toDeployList, sorter);
+ i = toDeployList.iterator();
+ }
+ */
+ }
+
+ /* TODO: Validate that there are still incomplete deployments
+ if (lastIncompleteDeploymentException != null)
+ {
+ try
+ {
+ Object[] args = {};
+ String[] sig = {};
+ getServer().invoke(getDeployer(), "checkIncompleteDeployments", args, sig);
+ }
+ catch (Exception e)
+ {
+ Throwable t = JMXExceptionDecoder.decode(e);
+ log.error(t);
+ }
+ }
+ */
+ }
+
+ /**
+ * Make a uri
+ *
+ * @param urispec the uri spec
+ * @return the uri
+ * @throws URISyntaxException for an error parsing he uri
+ */
+ private URI makeURI(String urispec) throws URISyntaxException
+ {
+ // First replace URI with appropriate properties
+ urispec = StringPropertyReplacer.replaceProperties(urispec);
+ return serverHomeURI.resolve(urispec);
+ }
+
+ /**
+ * A helper to find all deployments under a directory component
+ * and add them to the supplied list.
+ *
+ * We may recurse.
+ *
+ * @param list the list of virtual files
+ * @param root the root file
+ * @throws IOException for any error
+ */
+ private void addDeployments(List<VirtualFile> list, VirtualFile root)
+ throws IOException
+ {
+ List<VirtualFile> components = root.getChildren();
+
+ for (VirtualFile component : components)
+ {
+ if (component.isFile())
+ {
+ // the first arg in filter.accept is not used!
+ if (filter == null || filter.accept(null, component.getName()))
+ {
+ list.add(component);
+ }
+ }
+ else if (component.isDirectory())
+ {
+ if (component.getName().indexOf('.') == -1 && this.doRecursiveSearch)
+ {
+ // recurse if not '.' in name and recursive search is enabled
+ addDeployments(list, component);
+ }
+ else
+ {
+ list.add(component);
+ }
+ }
+ }
+ }
+
+ /**
+ * A helper to deploy the given component using the deployer.
+ *
+ * @param component the virtual file
+ */
+ private void deploy(final VirtualFile component)
+ {
+ // If the deployer is null simply ignore the request
+ if (profileService == null)
+ {
+ return;
+ }
+ if (log.isTraceEnabled())
+ {
+ log.trace("Deploying: " + component);
+ }
+
+ DeploymentContext deployment = null;
+ try
+ {
+ Profile profile = profileService.getProfile(profileKey);
+ deployment = add(profile, component);
+ }
+ catch (Exception e)
+ {
+ log.debug("Failed to deploy: " + component, e);
+ }
+
+ /* TODO
+ String watchPath = getWatchURL(deployment);
+ VirtualFile watchComponent = null;
+ long deployedLastModified = -1;
+ try
+ {
+ if (watchPath != null)
+ {
+ watchComponent = component.findChild(watchPath);
+ deployedLastModified = watchComponent.getLastModified();
+ }
+ else
+ {
+ deployedLastModified = component.getLastModified();
+ }
+ }
+ catch (IOException e)
+ {
+ log.warn(e);
+ }
+ component.setContext(new ComponentContext(watchComponent, deployedLastModified));
+ */
+
+ if (!deployedSet.containsKey(component))
+ {
+ deployedSet.put(component, deployment.getName());
+ }
+ }
+
+ /**
+ * A helper to undeploy the given component using the deployer.
+ *
+ * @param component the component
+ */
+ private void undeploy(final VirtualFile component)
+ {
+ try
+ {
+ if (log.isTraceEnabled())
+ {
+ log.trace("Undeploying: " + component);
+ }
+ String name = deployedSet.remove(component);
+ Profile profile = profileService.getProfile(profileKey);
+ remove(profile, name);
+ }
+ catch (Exception e)
+ {
+ log.error("Failed to undeploy: " + component, e);
+ }
+ }
+
+ /**
+ * Remove the component
+ *
+ * @param profile the profile
+ * @param file the virtual file
+ * @return the deployment context or null if not added, e.g. it already exists
+ * @throws Exception for any error
+ */
+ protected abstract DeploymentContext add(Profile profile, VirtualFile file) throws Exception;
+
+ /**
+ * Remove the component
+ *
+ * @param profile the profile
+ * @param name the name
+ */
+ protected abstract void remove(Profile profile, String name);
+
+ /**
+ * Helper to get the watchURL for a deployment, if different.
+ * Returns null otherwise
+ *
+ * @param deployment the deployment
+ * @return the watch url
+ */
+ /* TODO
+ private String getWatchURL(DeploymentContext deployment)
+ {
+ String watchPath = (String) deployment.getPredeterminedManagedObjects().getAttachment("WATCH_URL");
+ return watchPath;
+ }
+ /*/
+
+ /**
+ * Helper to find out if a deployed component has been modified
+ * TODO: How should this be implemented
+ *
+ * @param component the component
+ * @return true when modified
+ * @throws IOException for any error accessing the file
+ */
+ public boolean isModified(VirtualFile component) throws IOException
+ {
+ // get the context stored with every deployed component
+ ComponentContext cc = null; //(ComponentContext)component.getContext();
+
+ // get modification time at the time of deployment
+ long deployedLastModified = cc.deployedLastModified;
+
+ // find out the current lastModified time either from
+ // the component or the watched component, if exists
+ long lastModified = (cc.watchComponent != null) ? cc.watchComponent.getLastModified()
+ : component.getLastModified();
+
+ return deployedLastModified != lastModified;
+ }
+
+ private VirtualFile getVFforURI(URI uri)
+ throws IOException
+ {
+ VFS vfs = VFS.getVFS(uri);
+ return vfs.getRoot();
+ }
+
+ /**
+ * Simple holder class to let us store extra info
+ * on a VirtualFile object
+ */
+ private static class ComponentContext
+ {
+ public VirtualFile watchComponent;
+ public long deployedLastModified;
+
+ public ComponentContext(VirtualFile watchComponent, long deployedLastModified)
+ {
+ this.watchComponent = watchComponent;
+ this.deployedLastModified = deployedLastModified;
+ }
+ }
+}
Copied: trunk/system/src/resources/dtd/jboss-service_5_0.dtd (from rev 57107, branches/MC_VDF_WORK/system/src/resources/dtd/jboss-service_5_0.dtd)
Modified: trunk/system/src/resources/log4j.properties
===================================================================
--- trunk/system/src/resources/log4j.properties 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/resources/log4j.properties 2006-09-23 20:55:54 UTC (rev 57108)
@@ -21,3 +21,4 @@
log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
log4j.appender.CONSOLE.layout.ConversionPattern=%d{ABSOLUTE} %-5p [%c{1}] %m%n
+#log4j.category.org.jboss.deployers=TRACE#org.jboss.logging.XLevel
Modified: trunk/system/src/resources/tests/bootstrap/default/deployer-beans.xml
===================================================================
--- trunk/system/src/resources/tests/bootstrap/default/deployer-beans.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/resources/tests/bootstrap/default/deployer-beans.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -5,39 +5,47 @@
during the load of the org.jboss.system.server.profileservice.ServerImpl
entry point.
-->
-<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="urn:jboss:bean-deployer:2.0 ../../../../../kernel/src/resources/schema/bean-deployer_2_0.xsd"
- xmlns="urn:jboss:bean-deployer:2.0">
- <!-- -->
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+
+ <!-- The profile service -->
<bean name="ProfileService" class="org.jboss.system.server.profileservice.ProfileServiceImpl">
<constructor>
<parameter>${jboss.server.name}</parameter>
</constructor>
- <property name="profileRoot">${jbosstest.deploy.dir}</property>
+ <property name="profileRoot">${jboss.server.home.url}/profile</property>
</bean>
-
+
<!-- The MainDeployer -->
- <bean name="MainDeployer" class="org.jboss.deployers.plugins.MainDeployerImpl">
- <property name="VFSFactory"><inject bean="VFSFactory"/></property>
+ <bean name="MainDeployer" class="org.jboss.deployers.plugins.deployment.MainDeployerImpl">
+ <property name="structureDeployers">
+ <list>
+ <!-- JAR Structure -->
+ <bean name="JARStructure" class="org.jboss.deployers.plugins.structure.vfs.jar.JARStructure"/>
+ <!-- File Structure -->
+ <bean name="FileStructure" class="org.jboss.deployers.plugins.structure.vfs.file.FileStructure"/>
+ </list>
+ </property>
+ <property name="deployers">
+ <list>
+ <!-- POJO Deployment -->
+ <bean name="BeanDeployer" class="org.jboss.deployers.plugins.deployers.kernel.BeanDeployer"/>
+ <bean name="KernelDeploymentDeployer" class="org.jboss.deployers.plugins.deployers.kernel.KernelDeploymentDeployer"/>
+ <bean name="BeanMetaDataDeployer" class="org.jboss.deployers.plugins.deployers.kernel.BeanMetaDataDeployer">
+ <constructor><parameter><inject bean="jboss.kernel:service=Kernel"/></parameter></constructor>
+ </bean>
+ </list>
+ </property>
</bean>
- <bean name="VFSFactory" class="org.jboss.vfs.file.DefaultVFSFactory">
- </bean>
-
- <!-- Deployers. Declaration order defines the deployer chain order
- -->
- <bean name="ClassLoadingDeployer" class="org.jboss.deployers.plugins.classloading.ClassLoadingDeployer">
- <property name="mainDeployer"><inject bean="MainDeployer"/></property>
- </bean>
- <bean name="BeanDeployer" class="org.jboss.deployers.plugins.bean.BeanDeployer">
- <property name="mainDeployer"><inject bean="MainDeployer"/></property>
- </bean>
-
+
<!-- Hot deployment service that directly uses the MainDeployer -->
- <bean name="VFSDeploymentScanner" class="org.jboss.deployers.plugins.scanner.VFSDeploymentScannerImpl">
- <property name="mainDeployer"><inject bean="MainDeployer"/></property>
+ <bean name="VFSDeploymentScanner" class="org.jboss.system.server.profileservice.VFSDeploymentScannerImpl">
+ <property name="profileService"><inject bean="ProfileService"/></property>
<property name="URIList">
- <list elementClass="java.net.URI"><value>${jbosstest.deploy.dir}/${jboss.server.name}</value></list>
- </property>
+ <list elementClass="java.net.URI">
+ <!-- Standard hot deployment directory -->
+ <value>${jboss.server.home.url}deploy/</value>
+ </list>
+ </property>
</bean>
-
+
</deployment>
Deleted: trunk/system/src/tests/org/jboss/test/AbstractSystemTest.java
===================================================================
--- trunk/system/src/tests/org/jboss/test/AbstractSystemTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/tests/org/jboss/test/AbstractSystemTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,84 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test;
-
-import org.jboss.logging.Logger;
-import org.jboss.util.UnexpectedThrowable;
-
-/**
- * A SystemTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.2 $
- */
-public class AbstractSystemTest extends AbstractTestCaseWithSetup
-{
- private static Logger staticLog = Logger.getLogger(AbstractSystemTest.class);
-
- // @fixme move to AbstractTestCase
- public static void checkThrowableDeep(Class<? extends Throwable> expected, Throwable throwable) throws Exception
- {
- assertNotNull(expected);
- assertNotNull(throwable);
-
- Throwable original = throwable;
-
- while (throwable.getCause() != null)
- throwable = throwable.getCause();
-
- if (expected.equals(throwable.getClass()) == false)
- {
- if (original instanceof Exception)
- throw (Exception) original;
- else
- throw new UnexpectedThrowable("UnexpectedThrowable", original);
- }
- else
- {
- staticLog.debug("Got expected " + expected.getName() + "(" + throwable + ")");
- }
- }
-
- /**
- * Create a new ContainerTest.
- *
- * @param name the test name
- */
- public AbstractSystemTest(String name)
- {
- super(name);
- }
-
- /**
- * Default setup with security manager enabled
- *
- * @param clazz the class
- * @return the delegate
- * @throws Exception for any error
- */
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- AbstractTestDelegate delegate = new AbstractTestDelegate(clazz);
- delegate.enableSecurity = true;
- return delegate;
- }
-}
Deleted: trunk/system/src/tests/org/jboss/test/SystemAllTestSuite.java
===================================================================
--- trunk/system/src/tests/org/jboss/test/SystemAllTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system/src/tests/org/jboss/test/SystemAllTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,51 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test;
-
-import org.jboss.test.system.SystemTestSuite;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * All Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class SystemAllTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("All Tests");
-
- suite.addTest(SystemTestSuite.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx (from rev 57107, branches/MC_VDF_WORK/system-jmx)
Property changes on: trunk/system-jmx
___________________________________________________________________
Name: svn:ignore
+
output
Deleted: trunk/system-jmx/.classpath
===================================================================
--- branches/MC_VDF_WORK/system-jmx/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,29 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src/main"/>
- <classpathentry excluding="**/*.java" output="output/eclipse-test-support-classes" kind="src" path="src/tests-support"/>
- <classpathentry output="output/eclipse-test-classes" kind="src" path="src/tests"/>
- <classpathentry kind="lib" path="src/resources/tests"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry combineaccessrules="false" kind="src" path="/j2se"/>
- <classpathentry combineaccessrules="false" kind="src" path="/mbeans"/>
- <classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
- <classpathentry combineaccessrules="false" kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-dependency.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-microcontainer.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
- <classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
- <classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
- <classpathentry sourcepath="/home/svn/JBossHead/projects/test/trunk/test/src/main" kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
- <classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/resolver.jar"/>
- <classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/xercesImpl.jar"/>
- <classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/xml-apis.jar"/>
- <classpathentry combineaccessrules="false" kind="src" path="/jmx"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-jdk/lib/jboss-logging-jdk-2.0.0.jar"/>
- <classpathentry kind="output" path="output/eclipse-classes"/>
-</classpath>
Copied: trunk/system-jmx/.classpath (from rev 57107, branches/MC_VDF_WORK/system-jmx/.classpath)
Deleted: trunk/system-jmx/.project
===================================================================
--- branches/MC_VDF_WORK/system-jmx/.project 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/.project 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>system-jmx</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
Copied: trunk/system-jmx/.project (from rev 57107, branches/MC_VDF_WORK/system-jmx/.project)
Deleted: trunk/system-jmx/build-support-jars.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/build-support-jars.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/build-support-jars.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-<project name="tests-support-jars" default="jars">
-
- <property name="build.test" value="output/classes-tests-support" />
- <property name="build.test.lib" value="src/resources/org/jboss/test/classloading" />
-
- <target name="jars" description="Build the tests-support tree jars"
- depends="jar1, jar2CPjar1, jar2, jar3" />
-
- <macrodef name="build-test-jar" description="build a jar from a name patter">
- <attribute name="name" description="Basename for jar/package" />
- <attribute name="package" default="@{name" description="Basename for package" />
- <attribute name="classpath" default="" description="Class-Path manifest value" />
- <sequential>
- <mkdir dir="${build.test.lib}" />
- <mkdir dir="${build.test.resources}/@{name}" />
- <jar destfile="${build.test.lib}/@{name}.jar">
- <manifest>
- <attribute name="Class-Path" value="@{classpath}" />
- </manifest>
- <!-- Include all content under org/jboss/test/support/@{package} -->
- <fileset dir="${build.test}">
- <include name="org/jboss/test/support/@{package}/**"/>
- </fileset>
- <!-- Include all resources under output/resources/tests-resources/@{name} -->
- <zipfileset dir="${build.test.resources}/@{name}">
- <include name="**" />
- </zipfileset>
- </jar>
- </sequential>
- </macrodef>
-
- <target name="jar1">
- <build-test-jar name="jar1" />
- </target>
- <target name="jar2CPjar1">
- <build-test-jar name="jar2CPjar1" package="jar2" classpath="jar1.jar" />
- </target>
- <target name="jar2">
- <build-test-jar name="jar2" />
- </target>
- <target name="jar3">
- <build-test-jar name="jar3" />
- </target>
-</project>
\ No newline at end of file
Copied: trunk/system-jmx/build-support-jars.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/build-support-jars.xml)
Deleted: trunk/system-jmx/build-test.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/build-test.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/build-test.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,274 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE project [
- <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
- <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
- <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
- <!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
-]>
-
-<!-- $Id$ -->
-
-<project default="main" name="JBoss/System Tests">
-
- <!-- ================================================================== -->
- <!-- Setup -->
- <!-- ================================================================== -->
-
- <!--
- | Include the common Buildmagic elements.
- |
- | This defines several different targets, properties and paths.
- | It also sets up the basic extention tasks amoung other things.
- -->
-
- &buildmagic;
-
- <!--
- | Include the normal targets.
- -->
- &targets;
-
- <!-- ================================================================== -->
- <!-- Configuration -->
- <!-- ================================================================== -->
-
- <!--
- | Configure the build system.
- |
- | This target is invoked by the Buildmagic initialization logic and
- | should contain module specific configuration elements.
- -->
- <property name="javac.deprecation" value="false" />
- <property name="javac.target" value="5" />
- <property name="javac.source" value="5" />
-
- <target name="configure" unless="configure.disable">
-
- <!-- =================== -->
- <!-- Basic Configuration -->
- <!-- =================== -->
-
- <!-- Module name(s) & version -->
- <property name="module.name" value="system" />
- <property name="source.java" value="${module.source}/tests" />
- <property name="source.test" value="${module.source}/tests-support"
- description="A source tree not included in the test classpath by default used to test class loading." />
- <property name="build.classes" value="${module.output}/classes-tests" />
- <property name="build.test" value="${module.output}/classes-tests-support"
- description="source.test classes"/>
- <property name="build.test.lib" value="${module.output}/test-lib"
- description="Separate lib directory for source.test classes"/>
- <property name="build.test.resources" value="${module.output}/resources/tests-support"
- description="Root of the tests-support resources"/>
- <property name="build.testlog" value="${module.output}/log" />
- <property name="build-bypass.disabled" value="true" />
- <property name="build.gen.test" value="${module.output}/gen-test"/>
-
- <!-- ========= -->
- <!-- Libraries -->
- <!-- ========= -->
-
- &libraries;
-
- <!-- The combined library classpath -->
- <path id="library.classpath">
- <path refid="junit.junit.classpath" />
- <path refid="gnu.getopt.classpath" />
- <path refid="javassist.classpath" />
- <path refid="apache.log4j.classpath" />
- <path refid="oswego.concurrent.classpath" />
- <path refid="jboss.jbossxb.classpath" />
- <path refid="jboss.common.core.classpath"/>
- <path refid="jboss.common.logging.spi.classpath"/>
- <path refid="jboss.common.logging.log4j.classpath"/>
- <path refid="jboss.common.logging.jdk.classpath"/>
- <path refid="jboss.profiler.jvmti.classpath" />
- <path refid="apache.xerces.classpath" />
- <path refid="dom4j.dom4j.classpath" />
- </path>
-
- <!-- ======= -->
- <!-- Modules -->
- <!-- ======= -->
-
- &modules;
- <!-- this -->
- <property name="jboss.this.root" value="${module.root}/output" />
- <property name="jboss.this.lib" value="${jboss.this.root}/lib" />
- <path id="jboss.this.classpath">
- <fileset dir="${jboss.this.lib}">
- <include name="*.jar" />
- <exclude name="run.jar" />
- </fileset>
- </path>
-
- <!-- The combined dependant module classpath -->
- <path id="dependentmodule.classpath">
- <path refid="jboss.microcontainer.classpath"/>
- <path refid="jboss.j2se.classpath" />
- <path refid="jboss.mbeans.classpath" />
- <path refid="jboss.jmx.classpath" />
- <path refid="jboss.system.classpath" />
- <path refid="jboss.test.classpath" />
- <pathelement location="output/classes" />
- </path>
-
- <!-- ===== -->
- <!-- Tasks -->
- <!-- ===== -->
-
- <call target="_default:task-init" />
-
- <path id="thirdparty.classpath">
- <path refid="library.classpath" />
- <path refid="dependentmodule.classpath" />
- </path>
-
- </target>
- <patternset id="compile-resources.pattern">
- <include name="${src.resources}/**" />
- </patternset>
-
- <!-- ================================================================== -->
- <!-- Compile -->
- <!-- ================================================================== -->
-
- <!--
- | Compile everything.
- |
- | This target should depend on other compile-* targets for each
- | different type of compile that needs to be performed, short of
- | documentation compiles.
- -->
-
- <target name="compile" description="Compile all source files."
- depends="_default:compile-classes, _default:compile-test-classes, _default:compile-resources" />
-
- <target name="compile-tests-support" depends="init" unless="compile.disable"
- description="Compile the ${source.support.java} tree">
- <mkdir dir="${build.support.classes}"/>
-
- <javac destdir="${build.support.classes}"
- optimize="${javac.optimize}"
- target="${javac.target}"
- source="${javac.source}"
- debug="${javac.debug}"
- depend="${javac.depend}"
- verbose="${javac.verbose}"
- deprecation="${javac.deprecation}"
- includeAntRuntime="${javac.include.ant.runtime}"
- includeJavaRuntime="${javac.include.java.runtime}"
- includes="${javac.includes}"
- excludes="${javac.excludes}"
- failonerror="${javac.fail.onerror}">
- <bootclasspath>
- <path refid="javac.bootclasspath"/>
- </bootclasspath>
- <src path="${source.support.java}"/>
- <classpath refid="javac.classpath"/>
- </javac>
- </target>
-
- <!-- ================================================================== -->
- <!-- Archives -->
- <!-- ================================================================== -->
-
- <target name="module-jars">
- <!-- Build jboss-system-jmx-test.jar -->
- <jar jarfile="${build.lib}/jboss-system-jmx-test.jar" manifest="${build.etc}/default.mf">
- <fileset dir="${build.classes}"/>
- <fileset dir="${build.resources}/tests">
- <include name="org/**"/>
- </fileset>
- </jar>
- </target>
- <!-- Jars built from the independent src/tests-support,output/tests-support-classes trees -->
- <target name="tests-support-jars" depends="compile-tests-support">
- <ant antfile="build-support-jars.xml" inheritAll="true" dir="." />
- <call target="_default:compile-resources"/>
- </target>
-
- <!-- ================================================================== -->
- <!-- Tests -->
- <!-- ================================================================== -->
-
- <target name="tests" depends="most"
- description="Execute all tests in the given test directory.">
- <mkdir dir="${build.reports}" />
- <mkdir dir="${build.testlog}" />
- <!-- Remove the test.log so each run has a fresh log -->
- <delete file="${build.testlog}/test.log" />
- <junit dir="${module.output}" printsummary="yes" haltonerror="false" haltonfailure="false" fork="true">
-
- <sysproperty key="build.testlog" value="${build.testlog}" />
- <syspropertyset id="jbosstest-properties">
- <propertyref prefix="jbosstest" />
- </syspropertyset>
-
- <classpath>
- <pathelement location="${build.classes}" />
- <pathelement location="${build.resources}/tests" />
- <path refid="javac.classpath" />
- <path refid="apache.xerces.classpath" />
- </classpath>
-
- <formatter type="plain" usefile="true" />
- <formatter type="xml" usefile="true" />
-
- <batchtest todir="${build.reports}" haltonerror="false" haltonfailure="false" fork="true">
-
- <fileset dir="${build.classes}">
- <include name="org/jboss/test/**/*TestCase.class" />
- </fileset>
- </batchtest>
- </junit>
- </target>
-
- <target name="one-test" depends="init"
- description="Execute the test defined by ${test}">
- <mkdir dir="${build.reports}" />
- <mkdir dir="${build.testlog}" />
- <!-- Remove the test.log so each run has a fresh log -->
- <delete file="${build.testlog}/test.log" />
- <junit dir="${module.output}" printsummary="yes" haltonerror="false" haltonfailure="false" fork="true">
-
- <sysproperty key="build.testlog" value="${build.testlog}" />
- <syspropertyset id="jbosstest-properties">
- <propertyref prefix="jbosstest" />
- </syspropertyset>
-
- <classpath>
- <pathelement location="${build.classes}" />
- <pathelement location="${build.resources}/tests" />
- <path refid="thirdparty.classpath" />
- <path refid="apache.xerces.classpath"/>
- </classpath>
-
- <formatter type="plain" usefile="true" />
- <formatter type="xml" usefile="true" />
-
- <test todir="${build.reports}" name="${test}" haltonerror="${junit.batchtest.haltonerror}" haltonfailure="${junit.batchtest.haltonfailure}" fork="${junit.batchtest.fork}" />
- </junit>
- </target>
-
- <target name="memory-test" depends="most" description="Execute MemoryLeakTestCase">
- <mkdir dir="${build.reports}" />
- <mkdir dir="${build.testlog}" />
-
- <junit printsummary="yes" fork="yes" haltonfailure="no">
- <classpath>
- <pathelement location="${build.classes}" />
- <pathelement location="${build.resources}" />
- <path refid="thirdparty.classpath" />
- <path refid="javac.classpath" />
- <path refid="apache.xerces.classpath" />
- </classpath>
- <jvmarg value="-agentlib:jbossAgent" />
- <formatter type="plain" usefile="true" />
- <formatter type="xml" usefile="true" />
- <test fork="yes" todir="${build.reports}" name="org.jboss.test.memorytests.ClassInfoMemoryTestCase" />
- </junit>
-
- </target>
-
-</project>
Copied: trunk/system-jmx/build-test.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/build-test.xml)
Deleted: trunk/system-jmx/build.bat
===================================================================
--- branches/MC_VDF_WORK/system-jmx/build.bat 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/build.bat 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,89 +0,0 @@
- at echo off
-REM ======================================================================
-REM
-REM This is the main entry point for the build system.
-REM
-REM Users should be sure to execute this file rather than 'ant' to ensure
-REM the correct version is being used with the correct configuration.
-REM
-REM ======================================================================
-REM
-REM $Id: build.bat 24242 2004-10-04 20:13:37Z andd $
-REM
-REM Authors:
-REM Jason Dillon <jason at planet57.com>
-REM Sacha Labourey <sacha.labourey at cogito-info.ch>
-REM
-
-REM ******************************************************
-REM Ignore the ANT_HOME variable: we want to use *our*
-REM ANT version and associated JARs.
-REM ******************************************************
-REM Ignore the users classpath, cause it might mess
-REM things up
-REM ******************************************************
-
-SETLOCAL
-
-set CLASSPATH=
-set ANT_HOME=
-set ANT_OPTS=-Djava.protocol.handler.pkgs=org.jboss.net.protocol -Dbuild.script=build.bat
-
-REM ******************************************************
-REM - "for" loops have been unrolled for compatibility
-REM with some WIN32 systems.
-REM ******************************************************
-
-set NAMES=tools;tools\ant;tools\apache\ant
-set SUBFOLDERS=..;..\..;..\..\..;..\..\..\..
-
-REM ******************************************************
-REM ******************************************************
-
-SET EXECUTED=FALSE
-for %%i in (%NAMES%) do call :subLoop %%i %1 %2 %3 %4 %5 %6
-
-goto :EOF
-
-
-REM ******************************************************
-REM ********* Search for names in the subfolders *********
-REM ******************************************************
-
-:subLoop
-for %%j in (%SUBFOLDERS%) do call :testIfExists %%j\%1\bin\ant.bat %2 %3 %4 %5 %6 %7
-
-goto :EOF
-
-
-REM ******************************************************
-REM ************ Test if ANT Batch file exists ***********
-REM ******************************************************
-
-:testIfExists
-if exist %1 call :BatchFound %1 %2 %3 %4 %5 %6 %7 %8
-
-goto :EOF
-
-
-REM ******************************************************
-REM ************** Batch file has been found *************
-REM ******************************************************
-
-:BatchFound
-if (%EXECUTED%)==(FALSE) call :ExecuteBatch %1 %2 %3 %4 %5 %6 %7 %8
-set EXECUTED=TRUE
-
-goto :EOF
-
-REM ******************************************************
-REM ************* Execute Batch file only once ***********
-REM ******************************************************
-
-:ExecuteBatch
-echo Calling %1 %2 %3 %4 %5 %6 %7 %8
-call %1 %2 %3 %4 %5 %6 %7 %8
-
-:end
-
-if "%NOPAUSE%" == "" pause
Copied: trunk/system-jmx/build.bat (from rev 57107, branches/MC_VDF_WORK/system-jmx/build.bat)
Deleted: trunk/system-jmx/build.sh
===================================================================
--- branches/MC_VDF_WORK/system-jmx/build.sh 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/build.sh 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,172 +0,0 @@
-#!/bin/sh
-### ====================================================================== ###
-## ##
-## This is the main entry point for the build system. ##
-## ##
-## Users should be sure to execute this file rather than 'ant' to ensure ##
-## the correct version is being used with the correct configuration. ##
-## ##
-### ====================================================================== ###
-
-# $Id: build.sh 24242 2004-10-04 20:13:37Z andd $
-
-PROGNAME=`basename $0`
-DIRNAME=`dirname $0`
-GREP="grep"
-ROOT="/"
-
-# Ignore user's ANT_HOME if it is set
-ANT_HOME=""
-
-# the default search path for ant
-ANT_SEARCH_PATH="\
- tools
- tools/ant \
- tools/apache/ant \
- ant"
-
-# the default build file name
-ANT_BUILD_FILE="build.xml"
-
-# the default arguments
-ANT_OPTIONS="-find $ANT_BUILD_FILE"
-
-# Use the maximum available, or set MAX_FD != -1 to use that
-MAX_FD="maximum"
-
-# OS specific support (must be 'true' or 'false').
-cygwin=false;
-darwin=false;
-case "`uname`" in
- CYGWIN*)
- cygwin=true
- ;;
-
- Darwin*)
- darwin=true
- ;;
-esac
-
-#
-# Helper to complain.
-#
-die() {
- echo "${PROGNAME}: $*"
- exit 1
-}
-
-#
-# Helper to complain.
-#
-warn() {
- echo "${PROGNAME}: $*"
-}
-
-#
-# Helper to source a file if it exists.
-#
-maybe_source() {
- for file in $*; do
- if [ -f "$file" ]; then
- . $file
- fi
- done
-}
-
-search() {
- search="$*"
- for d in $search; do
- ANT_HOME="`pwd`/$d"
- ANT="$ANT_HOME/bin/ant"
- if [ -x "$ANT" ]; then
- # found one
- echo $ANT_HOME
- break
- fi
- done
-}
-
-#
-# Main function.
-#
-main() {
- # if there is a build config file. then source it
- maybe_source "$DIRNAME/build.conf" "$HOME/.build.conf"
-
- # Increase the maximum file descriptors if we can
- if [ $cygwin = "false" ]; then
- MAX_FD_LIMIT=`ulimit -H -n`
- if [ $? -eq 0 ]; then
- if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ]; then
- # use the system max
- MAX_FD="$MAX_FD_LIMIT"
- fi
-
- ulimit -n $MAX_FD
- if [ $? -ne 0 ]; then
- warn "Could not set maximum file descriptor limit: $MAX_FD"
- fi
- else
- warn "Could not query system maximum file descriptor limit: $MAX_FD_LIMIT"
- fi
- fi
-
- # try the search path
- ANT_HOME=`search $ANT_SEARCH_PATH`
-
- # try looking up to root
- if [ "x$ANT_HOME" = "x" ]; then
- target="build"
- _cwd=`pwd`
-
- while [ "x$ANT_HOME" = "x" ] && [ "$cwd" != "$ROOT" ]; do
- cd ..
- cwd=`pwd`
- ANT_HOME=`search $ANT_SEARCH_PATH`
- done
-
- # make sure we get back
- cd $_cwd
-
- if [ "$cwd" != "$ROOT" ]; then
- found="true"
- fi
-
- # complain if we did not find anything
- if [ "$found" != "true" ]; then
- die "Could not locate Ant; check \$ANT or \$ANT_HOME."
- fi
- fi
-
- # make sure we have one
- ANT=$ANT_HOME/bin/ant
- if [ ! -x "$ANT" ]; then
- die "Ant file is not executable: $ANT"
- fi
-
- # need to specify planet57/buildmagic protocol handler package
- ANT_OPTS="-Djava.protocol.handler.pkgs=org.jboss.net.protocol"
-
- # setup some build properties
- ANT_OPTS="$ANT_OPTS -Dbuild.script=$0"
-
- # change to the directory where the script lives so users are not forced
- # to be in the same directory as build.xml
- cd $DIRNAME
-
- # export some stuff for ant
- export ANT ANT_HOME ANT_OPTS
-
- # execute in debug mode, or simply execute
- if [ "x$ANT_DEBUG" != "x" ]; then
- /bin/sh -x $ANT $ANT_OPTIONS "$@"
- else
- exec $ANT $ANT_OPTIONS "$@"
- fi
-}
-
-##
-## Bootstrap
-##
-
-main "$@"
Copied: trunk/system-jmx/build.sh (from rev 57107, branches/MC_VDF_WORK/system-jmx/build.sh)
Deleted: trunk/system-jmx/build.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,182 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE project [
- <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
- <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
- <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
- <!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
-]>
-
-<!-- ====================================================================== -->
-<!-- -->
-<!-- JBoss, the OpenSource J2EE webOS -->
-<!-- -->
-<!-- Distributable under LGPL license. -->
-<!-- See terms of license at http://www.gnu.org. -->
-<!-- -->
-<!-- ====================================================================== -->
-
-<!-- $Id: build.xml 55118 2006-08-03 16:33:33Z adrian at jboss.org $ -->
-
-<project default="main" name="JBoss/SystemJMX">
-
- <!-- ================================================================== -->
- <!-- Setup -->
- <!-- ================================================================== -->
-
- <!--
- | Include the common Buildmagic elements.
- |
- | This defines several different targets, properties and paths.
- | It also sets up the basic extention tasks amoung other things.
- -->
-
- &buildmagic;
-
- <!--
- | Include the normal targets.
- -->
- &targets;
-
- <!-- ================================================================== -->
- <!-- Configuration -->
- <!-- ================================================================== -->
-
- <!--
- | Configure the build system.
- |
- | This target is invoked by the Buildmagic initialization logic and
- | should contain module specific configuration elements.
- -->
-
- <target name="configure" unless="configure.disable">
-
- <!-- =================== -->
- <!-- Basic Configuration -->
- <!-- =================== -->
-
- <!-- Module name(s) & version -->
- <property name="module.name" value="system-jmx"/>
- <property name="module.Name" value="JBoss SystemJMX"/>
- <property name="module.version" value="DEV"/>
-
- <!-- ========= -->
- <!-- Libraries -->
- <!-- ========= -->
-
- &libraries;
-
- <!-- The combined library classpath -->
- <path id="library.classpath">
- <path refid="junit.junit.classpath"/>
- <path refid="gnu.getopt.classpath"/>
- <path refid="apache.xerces.classpath"/>
- <path refid="apache.log4j.classpath"/>
- <path refid="apache.commons.classpath"/>
- <path refid="oswego.concurrent.classpath"/>
- <path refid="dom4j.dom4j.classpath"/>
- <path refid="jboss.jbossxb.classpath"/>
- <path refid="jboss.microcontainer.classpath"/>
- <path refid="jboss.common.core.classpath"/>
- <path refid="jboss.common.logging.spi.classpath"/>
- <path refid="jboss.common.logging.log4j.classpath"/>
- <path refid="jboss.common.logging.jdk.classpath"/>
- </path>
-
- <!-- ======= -->
- <!-- Modules -->
- <!-- ======= -->
-
- &modules;
-
- <!-- The combined dependant module classpath -->
- <path id="dependentmodule.classpath">
- <path refid="jboss.j2se.classpath"/>
- <path refid="jboss.mbeans.classpath"/>
- <path refid="jboss.system.classpath"/>
- </path>
-
- <!-- ===== -->
- <!-- Tasks -->
- <!-- ===== -->
-
- <property name="jar.prefix" value="jboss-system-jmx"/>
- <property name="javac.target" value="1.5"/>
- <property name="javac.source" value="1.5"/>
- <property name="jar.client.includes"
- value="org/jboss/deployment/DeploymentException*,
- org/jboss/deployment/IncompleteDeploymentException*,
- org/jboss/deployment/Deployer*,
- org/jboss/system/Service.class,
- org/jboss/system/server/ServerLoader*.class,
- org/jboss/system/server/Server.class,
- org/jboss/system/server/ServerConfig.class,
- **/*MBean.class"
- />
-
- <patternset id="compile-resources.filter.pattern">
- <include name="**/*"/>
- <exclude name="tests/**"/>
- </patternset>
-
- <patternset id="compile-resources.pattern">
- <include name="tests/**"/>
- </patternset>
-
- <call target="_default:task-init"/>
-
- </target>
-
- <!-- ================================================================== -->
- <!-- Compile -->
- <!-- ================================================================== -->
-
- <!--
- | Compile everything.
- |
- | This target should depend on other compile-* targets for each
- | different type of compile that needs to be performed, short of
- | documentation compiles.
- -->
-
- <target name="compile"
- description="Compile all source files."
- depends="_default:compile-classes,
- _default:compile-resources,
- _default:compile-etc"/>
-
- <!-- ================================================================== -->
- <!-- Archives -->
- <!-- ================================================================== -->
-
- <!--
- | Build all jar files.
- -->
- <target name="module-jars" >
-
- <!-- Server and client jars -->
- <call target="_default:server-client-jars"/>
-
- <!--
- | JBoss/Testsuite Support
- -->
-
- <!-- testsuite-support.jar -->
- <jar jarfile="${build.lib}/testsuite-support.jar" manifest="${build.etc}/default.mf">
- <fileset dir="${build.classes}">
- <include name="org/jboss/deployment/**"/>
- <include name="org/jboss/system/Service.class"/>
- <include name="org/jboss/system/ServiceMBean.class"/>
- <include name="org/jboss/system/*MBeanSupport.class"/>
- <include name="org/jboss/system/MBeanClassLoader*.class"/>
- <include name="org/jboss/system/UnifiedClassLoader*.class"/>
- <include name="org/jboss/system/ServiceLibraries*.class"/>
- <include name="org/jboss/system/server/*MBean.class"/>
- <include name="org/jboss/system/server/ServerConfigLocator.class"/>
- <include name="org/jboss/system/server/ServerConfig.class"/>
- <include name="org/jboss/system/server/Server.class"/>
- </fileset>
- </jar>
-
- </target>
-
-</project>
Copied: trunk/system-jmx/build.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/build.xml)
Copied: trunk/system-jmx/src (from rev 57107, branches/MC_VDF_WORK/system-jmx/src)
Copied: trunk/system-jmx/src/etc (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/etc)
Deleted: trunk/system-jmx/src/etc/default.mf
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/etc/default.mf 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/etc/default.mf 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-Manifest-Version: 1.0
-Created-By: @java.vm.version@ (@java.vm.vendor@)
-Specification-Title: @specification.title@
-Specification-Version: @specification.version@
-Specification-Vendor: @specification.vendor@
-Implementation-Title: @implementation.title@
-Implementation-URL: @implementation.url@
-Implementation-Version: @implementation.version@
-Implementation-Vendor: @implementation.vendor@
-Implementation-Vendor-Id: @implementation.vendor.id@
Copied: trunk/system-jmx/src/etc/default.mf (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/etc/default.mf)
Deleted: trunk/system-jmx/src/etc/run.mf
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/etc/run.mf 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/etc/run.mf 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-Manifest-Version: 1.0
-Created-By: @java.vm.version@ (@java.vm.vendor@)
-Specification-Title: @specification.title@
-Specification-Version: @specification.version@
-Specification-Vendor: @specification.vendor@
-Implementation-Title: @implementation.title@
-Implementation-URL: @implementation.url@
-Implementation-Version: @implementation.version@
-Implementation-Vendor: @implementation.vendor@
-Implementation-Vendor-Id: @implementation.vendor.id@
-Main-Class: org.jboss.Main
-Class-Path: ../client/getopt.jar
Copied: trunk/system-jmx/src/etc/run.mf (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/etc/run.mf)
Copied: trunk/system-jmx/src/main (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main)
Copied: trunk/system-jmx/src/main/org (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org)
Copied: trunk/system-jmx/src/main/org/jboss (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss)
Copied: trunk/system-jmx/src/main/org/jboss/deployment (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment)
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,121 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.net.URL;
-import javax.management.ObjectName;
-import org.jboss.mx.loading.LoaderRepositoryFactory;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.system.ServiceMBeanSupport;
-
-
-/** A service that allows one to add an arbitrary URL to a named LoaderRepository.
- *
- * Created: Sun Jun 30 13:17:22 2002
- *
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @version $Revision$
- *
- * @jmx:mbean name="jboss:type=Service,service=ClasspathExtension"
- * extends="org.jboss.system.ServiceMBean"
- */
-public class ClasspathExtension
- extends ServiceMBeanSupport
- implements ClasspathExtensionMBean
-{
- private String metadataURL;
- private ObjectName loaderRepository;
- private RepositoryClassLoader ucl;
-
- public ClasspathExtension()
- {
-
- }
-
- /**
- * mbean get-set pair for field metadataURL
- * Get the value of metadataURL
- * @return value of metadataURL
- *
- * @jmx:managed-attribute
- */
- public String getMetadataURL()
- {
- return metadataURL;
- }
-
- /**
- * Set the value of metadataURL
- * @param metadataURL Value to assign to metadataURL
- *
- * @jmx:managed-attribute
- */
- public void setMetadataURL(String metadataURL)
- {
- this.metadataURL = metadataURL;
- }
-
- /**
- * mbean get-set pair for field loaderRepository
- * Get the value of loaderRepository
- * @return value of loaderRepository
- *
- * @jmx:managed-attribute
- */
- public ObjectName getLoaderRepository()
- {
- return loaderRepository;
- }
-
-
- /**
- * Set the value of loaderRepository
- * @param loaderRepository Value to assign to loaderRepository
- *
- * @jmx:managed-attribute
- */
- public void setLoaderRepository(ObjectName loaderRepository)
- {
- this.loaderRepository = loaderRepository;
- }
-
- protected void createService() throws Exception
- {
- if (metadataURL != null)
- {
- URL url = new URL(metadataURL);
- if( loaderRepository == null )
- loaderRepository = LoaderRepositoryFactory.DEFAULT_LOADER_REPOSITORY;
- Object[] args = {url, url, Boolean.TRUE};
- String[] sig = {"java.net.URL", "java.net.URL", "boolean"};
- ucl = (RepositoryClassLoader) server.invoke(loaderRepository,
- "newClassLoader",args, sig);
- } // end of if ()
- }
-
- protected void destroyService() throws Exception
- {
- if (ucl != null)
- ucl.unregister();
- }
-
-}// ClasspathExtension
Copied: trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtension.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/**
- * MBean interface.
- */
-public interface ClasspathExtensionMBean extends org.jboss.system.ServiceMBean {
-
- //default object name
- public static final javax.management.ObjectName OBJECT_NAME = org.jboss.mx.util.ObjectNameFactory.create("jboss:type=Service,service=ClasspathExtension");
-
- /**
- * mbean get-set pair for field metadataURL Get the value of metadataURL
- * @return value of metadataURL
- */
- java.lang.String getMetadataURL() ;
-
- /**
- * Set the value of metadataURL
- * @param metadataURL Value to assign to metadataURL
- */
- void setMetadataURL(java.lang.String metadataURL) ;
-
- /**
- * mbean get-set pair for field loaderRepository Get the value of loaderRepository
- * @return value of loaderRepository
- */
- javax.management.ObjectName getLoaderRepository() ;
-
- /**
- * Set the value of loaderRepository
- * @param loaderRepository Value to assign to loaderRepository
- */
- void setLoaderRepository(javax.management.ObjectName loaderRepository) ;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/ClasspathExtensionMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,35 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/**
- * Comment
- *
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision$
- */
-public interface DefaultDeploymentSorter
-{
- String[] getSuffixOrder();
-
- void setSuffixOrder(String[] suffixOrder);
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DefaultDeploymentSorter.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/Deployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/Deployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/Deployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,69 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.net.URL;
-
-/**
- * The interface which a deployer must implement.
- *
- * <p>Clients should use the MainDeployer to deploy URLs.
- *
- * @jmx:mbean
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- */
-public interface Deployer
-{
- /**
- * Deploys a package identified by a URL
- *
- * @param url an <code>URL</code> value
- *
- * @throws DeploymentException Failed to deploy URL.
- *
- * @jmx:managed-operation
- */
- void deploy(URL url) throws DeploymentException;
-
- /**
- * Undeploys a package identified by a URL
- *
- * @param url an <code>URL</code> value
- *
- * @throws DeploymentException Failed to undeploy URL.
- *
- * @jmx:managed-operation
- */
- void undeploy(URL url) throws DeploymentException;
-
- /**
- * Tells you if a packaged identified by a URL is deployed.
- *
- * @param url an <code>URL</code> value
- * @return a <code>boolean</code> value
- *
- * @jmx:managed-operation
- */
- boolean isDeployed(URL url);
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/Deployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/Deployer.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/Deployer.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/**
- * MBean interface.
- */
-public interface DeployerMBean {
-
- /**
- * Deploys a package identified by a URL
- * @param url an <code>URL</code> value
- * @throws DeploymentException Failed to deploy URL.
- */
- void deploy(java.net.URL url) throws org.jboss.deployment.DeploymentException;
-
- /**
- * Undeploys a package identified by a URL
- * @param url an <code>URL</code> value
- * @throws DeploymentException Failed to undeploy URL.
- */
- void undeploy(java.net.URL url) throws org.jboss.deployment.DeploymentException;
-
- /**
- * Tells you if a packaged identified by a URL is deployed.
- * @param url an <code>URL</code> value
- * @return a <code>boolean</code> value
- */
- boolean isDeployed(java.net.URL url) ;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DeployerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentException.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeploymentException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,96 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/**
- * Thrown by a deployer if an application component could not be
- * deployed.
- *
- * @see DeployerMBean
- *
- * @deprecated use org.jboss.deployers.spi.DeploymentException
- * @author <a href="mailto:toby.allsopp at peace.com">Toby Allsopp</a>
- * @version $Revision$
- */
-public class DeploymentException extends org.jboss.deployers.spi.DeploymentException
-{
- /** @since 4.0.2 */
- private static final long serialVersionUID = 1416258464473965574L;
-
- /**
- * Rethrow a throwable as a deployment exception if it isn't already.
- *
- * @param message the message
- * @param t the throwable
- * @throws DeploymentException always
- */
- public static DeploymentException rethrowAsDeploymentException(String message, Throwable t)
- throws DeploymentException
- {
- if (t instanceof DeploymentException)
- throw (DeploymentException) t;
- else
- throw new DeploymentException(message, t);
- }
-
- /**
- * Construct a <tt>DeploymentException</tt> with the specified detail
- * message.
- *
- * @param msg Detail message.
- */
- public DeploymentException(String msg)
- {
- super(msg);
- }
-
- /**
- * Construct a <tt>DeploymentException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param msg Detail message.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public DeploymentException(String msg, Throwable nested)
- {
- super(msg, nested);
- }
-
- /**
- * Construct a <tt>DeploymentException</tt> with the specified
- * nested <tt>Throwable</tt>.
- *
- * @param nested Nested <tt>Throwable</tt>.
- */
- public DeploymentException(Throwable nested)
- {
- super(nested);
- }
-
- /**
- * Construct a <tt>DeploymentException</tt> with no detail.
- */
- public DeploymentException()
- {
- super();
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentException.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentException.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentException.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,501 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.Serializable;
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-import java.util.jar.JarFile;
-import java.util.jar.Manifest;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.loading.LoaderRepositoryFactory;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
-import org.jboss.util.collection.ListSet;
-import org.jboss.util.file.Files;
-import org.w3c.dom.Document;
-
-/**
- * Service Deployment Info .
- *
- * Every deployment (even the J2EE ones) should be seen at some point as
- * Service Deployment info
- *
- * @see org.jboss.system.Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:David.Maplesden at orion.co.nz">David Maplesden</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:daniel.schulze at telkel.com">Daniel Schulze</a>
- * @author <a href="mailto:Christoph.Jung at infor.de">Christoph G. Jung</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @version $Revision$ <p>
- */
-public class DeploymentInfo implements Serializable
-{
- /** @since 4.0.1 */
- private static final long serialVersionUID = 1131841473723490707L;
-
- private static final Logger log = Logger.getLogger(DeploymentInfo.class);
-
- // Variables ------------------------------------------------------------
-
- /** The initial construction timestamp */
- public Date date = new Date();
-
- /** the URL identifing this SDI **/
- public URL url;
-
- /** An optional URL to a local copy of the deployment */
- public URL localUrl;
-
- /** The URL used to watch for changes when the deployment is unpacked */
- public URL watch;
-
- /** The suffix of the deployment url */
- public String shortName;
-
- /** The last system time the deployment inited by the MainDeployer */
- public long lastDeployed = 0;
-
- /** use for "should we redeploy failed" */
- public long lastModified = 0;
-
- /** A free form status for the "state" can be Deployed/failed etc etc */
- public String status;
-
- /** The current state of the deployment */
- public DeploymentState state = DeploymentState.CONSTRUCTED;
-
- /** The subdeployer that handles the deployment */
- public transient SubDeployer deployer;
-
- /** Unified CL is a global scope class loader **/
- public transient RepositoryClassLoader ucl;
-
- /** local Cl is a CL that is used for metadata loading, if ejb-jar.xml is
- left in the parent CL through old deployments, this makes sure that we
- use the local version. You must use the URLClassLoader.findResource method
- to restrict loading to the deployment URL.
- */
- public transient URLClassLoader localCl;
-
- /** A CL for preloading annotations, it should be made available
- * in the deployment create step.
- */
- public transient URLClassLoader annotationsCl;
-
- /** The classpath declared by this xml descriptor, needs <classpath> entry **/
- public final Collection classpath = new ArrayList();
-
- /** The mbeans deployed */
- public final List<ObjectName> mbeans = new ArrayList<ObjectName>();
-
- /** Anyone can have subdeployments */
- public final Set subDeployments = new ListSet();
-
- /** And the subDeployments have a parent */
- public DeploymentInfo parent = null;
-
- /** the web root context in case of war file */
- public String webContext;
-
- /** the manifest entry of the deployment (if any)
- * manifest is not serializable ... is only needed
- * at deployment time, so we mark it transient
- */
- public transient Manifest manifest;
-
- /**
- * Each Deployment is really mapping one to one to a XML document, here in
- * its parsed form. A xerces document (org.apache.xerces.dom.DocumentImpl)
- * is serializable.
- */
- public Document document;
-
- /** An optional URL to the URL of the document loaded */
- public URL documentUrl;
-
- /** We can hold "typed" metadata, really an interpretation of the bare XML document */
- public transient Object metaData;
-
- /** If this deployed as part of an EAR, there may be an alernative DD */
- public String alternativeDD;
-
- /** An arbitrary map of state associated with the deployment */
- public transient HashMap context = new HashMap();
-
- /** Is this a stand-alone service descriptor */
- public boolean isXML;
-
- /** Is this a stand-alone script */
- public boolean isScript;
-
- /** Does the deployment url point to a directory */
- public boolean isDirectory;
-
- /**
- * The variable <code>deployedObject</code> can contain the MBean that
- * is created through the deployment. for instance, deploying an ejb-jar
- * results in an EjbModule mbean, which is stored here.
- */
- public ObjectName deployedObject;
-
- /** The configuration of the loader repository for this deployment */
- public LoaderRepositoryConfig repositoryConfig;
-
- /** The MBeanServer associated with the deployment */
- private transient MBeanServer server;
-
- /**
- * CTOR
- */
- public DeploymentInfo(final URL url, final DeploymentInfo parent, final MBeanServer server)
- throws DeploymentException
- {
- this.server = server;
- // The key url the deployment comes from
- this.url = url;
-
- // this may be changed by deployers in case of directory and xml file following
- this.watch = url;
-
- // Whether we are part of a subdeployment or not
- this.parent = parent;
-
- // Is it a directory?
- if (url.getProtocol().startsWith("file") && new File(url.getFile()).isDirectory())
- this.isDirectory = true;
-
- // Does it even exist?
- if (!isDirectory)
- {
- try
- {
- url.openStream().close();
- }
- catch (Exception e)
- {
- throw new DeploymentException("url " + url + " could not be opened, does it exist?");
- }
- }
-
- if (parent != null)
- {
- parent.subDeployments.add(this);
- // Use the repository of our topmost parent
- repositoryConfig = getTopRepositoryConfig();
- }
-
- // The "short name" for the deployment http://myserver/mybean.ear should yield "mybean.ear"
- shortName = getShortName(url.getPath());
-
- // Do we have an XML descriptor only deployment?
- isXML = shortName.toLowerCase().endsWith(".xml");
-
- // Do we have a stand-olone script deployment?
- isScript = shortName.toLowerCase().endsWith(".bsh");
- }
-
- public MBeanServer getServer()
- {
- return server;
- }
-
- public void setServer(MBeanServer server)
- {
- this.server = server;
- }
-
- /** Create a UnifiedClassLoader for the deployment that loads from
- the localUrl and uses its parent deployments url as its orignal
- url. Previously xml descriptors simply used the TCL but since the UCLs
- are now registered as mbeans each must be unique.
- */
- public void createClassLoaders() throws Exception
- {
- // create a local classloader for local files, don't go with the UCL for ejb-jar.xml
- if( localCl == null )
- localCl = new URLClassLoader(new URL[] {localUrl});
-
- /* Walk the deployment tree to find the parent deployment and obtain its
- url to use as our URL from which this deployment unit originated. This
- is used to determine permissions using the original URL namespace.
- Also pick up the LoaderRepository from the topmost ancestor.
- */
- URL origUrl = url;
- DeploymentInfo current = this;
- while (current.parent != null)
- {
- current = current.parent;
- }
- origUrl = current.url;
- repositoryConfig = current.repositoryConfig;
- if( parent == null )
- {
- if( repositoryConfig == null )
- repositoryConfig = new LoaderRepositoryConfig();
- // Make sure the specified LoaderRepository exists.
- LoaderRepositoryFactory.createLoaderRepository(server, repositoryConfig);
- log.debug("createLoaderRepository from config: "+repositoryConfig);
- // the classes are passed to a UCL that will share the classes with the whole base
-
- Object[] args = { isXML ? null : localUrl, origUrl, Boolean.TRUE };
- String[] sig = { "java.net.URL", "java.net.URL", "boolean" };
- ucl = (RepositoryClassLoader) server.invoke(repositoryConfig.repositoryName,
- "newClassLoader",args, sig);
- }
- else
- {
- // Add a reference to the LoaderRepository
- LoaderRepositoryFactory.createLoaderRepository(server, repositoryConfig);
- // Add the deployment URL to the parent UCL
- ucl = parent.ucl;
- ucl.addURL(localUrl);
- }
- // Add any library jars seen before the UCL was created
- if( classpath.size() > 0 )
- {
- Iterator jars = classpath.iterator();
- while( jars.hasNext() )
- {
- URL jar = (URL) jars.next();
- ucl.addURL(jar);
- }
- }
- }
-
- /** Set the UnifiedLoaderRepository info for the deployment. This can only
- * be called for the parent deployment, and must be done early in the
- * Subdeployer init(DeploymentInfo) method prior to any class loading.
- * @throws Exception
- */
- public void setRepositoryInfo(LoaderRepositoryConfig config)
- throws Exception
- {
- if( parent != null )
- {
- log.warn("Only the root deployment can set the loader repository, "
- + "ignoring config="+config);
- return;
- }
-
- this.repositoryConfig = config;
- // Recreate the ucl if it exists
- if( ucl != null )
- {
- ucl.unregister();
- // Make sure the specified LoaderRepository exists.
- LoaderRepositoryFactory.createLoaderRepository(server, repositoryConfig);
- log.debug("createLoaderRepository from config: "+repositoryConfig);
- // the classes are passed to a UCL that will share the classes with the whole base
-
- Object[] args = { isXML ? null : localUrl, url, Boolean.TRUE };
- String[] sig = { "java.net.URL", "java.net.URL", "boolean" };
- ucl = (RepositoryClassLoader) server.invoke(repositoryConfig.repositoryName,
- "newClassLoader",args, sig);
- }
- }
-
- /** All library jars referenced through either the manifest references
- * or sar classpaths are added to the root DeploymentInfo class loader. This
- * is neccessary to avoid IllegalAccessErrors due to classes in a pkg
- * being split across jars
- */
- public void addLibraryJar(URL libJar)
- {
- DeploymentInfo current = this;
- while (current.parent != null)
- {
- current = current.parent;
- }
- /* If the UCL exists add the jar to it else use the classpath to
- indicate that the jars need to be added when the ucl is created.
- */
- if( current.ucl != null )
- current.ucl.addURL(libJar);
- else
- classpath.add(libJar);
- }
-
- /** The the class loader repository name of the top most DeploymentInfo
- */
- public LoaderRepositoryConfig getTopRepositoryConfig()
- {
- LoaderRepositoryConfig topConfig = repositoryConfig;
- DeploymentInfo info = this;
- while( info.parent != null )
- {
- info = info.parent;
- topConfig = info.repositoryConfig;
- }
- return topConfig;
- }
-
- /**
- * getManifest returns (if present) the deployment's manifest
- * it is lazy loaded to work from the localURL
- */
- public Manifest getManifest()
- {
- try
- {
- if (manifest == null)
- {
- File file = new File(localUrl.getFile());
-
- if (file.isDirectory())
- {
- FileInputStream fis = new FileInputStream(new File(file, "META-INF/MANIFEST.MF"));
- manifest = new Manifest(fis);
- fis.close();
- }
- else if(isXML == false)// a jar
- manifest = new JarFile(file).getManifest();
- }
-
- return manifest;
- }
- // It is ok to barf at any time in the above, means no manifest
- catch (Exception ignored) { return null;}
- }
-
- public void cleanup()
- {
- // Remove the deployment UCL
- if( parent == null && ucl != null )
- ucl.unregister();
- ucl = null;
-
- // Remove any deployment specific repository
- if ( repositoryConfig != null )
- {
- LoaderRepositoryFactory.destroyLoaderRepository(server,
- repositoryConfig.repositoryName);
- }
-
- subDeployments.clear();
- mbeans.clear();
- context.clear();
- if (localUrl == null || localUrl.equals(url))
- {
- log.debug("Not deleting localUrl, it is null or not a copy: " + localUrl);
- }
- else if (Files.delete(localUrl.getFile()))
- {
- log.debug("Cleaned Deployment: " + localUrl);
- }
- else
- {
- log.debug("Could not delete " + localUrl + " restart will delete it");
- }
-
- // Clean up references to other objects
- localCl = null;
- annotationsCl = null;
- localUrl = null;
- repositoryConfig = null;
- watch = null;
- parent = null;
- manifest = null;
- document = null;
- metaData = null;
- server = null;
- classpath.clear();
- state = DeploymentState.DESTROYED;
- // Who is using this after clear?
- // deployer = null;
- }
-
- /** The sortName concatenated with the canonical names of all parents. */
- public String getCanonicalName()
- {
- String name = shortName;
- if (parent != null)
- name = parent.getCanonicalName() + "/" + name;
- return name;
- }
-
- private String getShortName(String name)
- {
- if (name.endsWith("/")) name = name.substring(0, name.length() - 1);
- name = name.substring(name.lastIndexOf("/") + 1);
- return name;
- }
-
- public int hashCode()
- {
- return url.hashCode();
- }
-
- public boolean equals(Object other)
- {
- if (other instanceof DeploymentInfo)
- {
- return ((DeploymentInfo) other).url.equals(this.url);
- }
- return false;
- }
-
- public String toString()
- {
- StringBuffer s = new StringBuffer(super.toString());
- s.append(" { url=" + url + " }\n");
- s.append(" deployer: " + deployer + "\n");
- s.append(" status: " + status + "\n");
- s.append(" state: " + state + "\n");
- s.append(" watch: " + watch + "\n");
- s.append(" altDD: " + alternativeDD + "\n");
- s.append(" lastDeployed: " + lastDeployed + "\n");
- s.append(" lastModified: " + lastModified + "\n");
- s.append(" mbeans:\n");
- for (Iterator i = mbeans.iterator(); i.hasNext(); )
- {
- ObjectName o = (ObjectName)i.next();
- try
- {
- String state = (String)server.getAttribute(o, "StateString");
- s.append(" " + o + " state: " + state + "\n");
- }
- catch (Exception e)
- {
- s.append(" " + o + " (state not available)\n");
- } // end of try-catch
-
- } // end of for ()
-
- return s.toString();
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java)
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -0,0 +1,503 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+package org.jboss.deployment;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.Serializable;
+import java.net.URL;
+import java.net.URLClassLoader;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+import java.util.jar.JarFile;
+import java.util.jar.Manifest;
+
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+
+import org.jboss.logging.Logger;
+import org.jboss.mx.loading.LoaderRepositoryFactory;
+import org.jboss.mx.loading.RepositoryClassLoader;
+import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
+import org.jboss.util.collection.ListSet;
+import org.jboss.util.file.Files;
+import org.w3c.dom.Document;
+
+/**
+ * Service Deployment Info .
+ *
+ * Every deployment (even the J2EE ones) should be seen at some point as
+ * Service Deployment info
+ *
+ * @see org.jboss.system.Service
+ *
+ * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
+ * @author <a href="mailto:David.Maplesden at orion.co.nz">David Maplesden</a>
+ * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
+ * @author <a href="mailto:daniel.schulze at telkel.com">Daniel Schulze</a>
+ * @author <a href="mailto:Christoph.Jung at infor.de">Christoph G. Jung</a>
+ * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
+ * @version $Revision$ <p>
+ */
+public class DeploymentInfo implements Serializable
+{
+ /** @since 4.0.1 */
+ private static final long serialVersionUID = 1131841473723490707L;
+
+ private static final Logger log = Logger.getLogger(DeploymentInfo.class);
+
+ // Variables ------------------------------------------------------------
+
+ /** The initial construction timestamp */
+ public Date date = new Date();
+
+ /** the URL identifing this SDI **/
+ public URL url;
+
+ /** An optional URL to a local copy of the deployment */
+ public URL localUrl;
+
+ /** The URL used to watch for changes when the deployment is unpacked */
+ public URL watch;
+
+ /** The suffix of the deployment url */
+ public String shortName;
+
+ /** The last system time the deployment inited by the MainDeployer */
+ public long lastDeployed = 0;
+
+ /** use for "should we redeploy failed" */
+ public long lastModified = 0;
+
+ /** A free form status for the "state" can be Deployed/failed etc etc */
+ public String status;
+
+ /** The current state of the deployment */
+ public DeploymentState state = DeploymentState.CONSTRUCTED;
+
+ /** The subdeployer that handles the deployment */
+ public transient SubDeployer deployer;
+
+ /** Unified CL is a global scope class loader **/
+ public transient RepositoryClassLoader ucl;
+
+ /** local Cl is a CL that is used for metadata loading, if ejb-jar.xml is
+ left in the parent CL through old deployments, this makes sure that we
+ use the local version. You must use the URLClassLoader.findResource method
+ to restrict loading to the deployment URL.
+ */
+ public transient URLClassLoader localCl;
+
+ /** A CL for preloading annotations, it should be made available
+ * in the deployment create step.
+ */
+ public transient URLClassLoader annotationsCl;
+
+ /** The classpath declared by this xml descriptor, needs <classpath> entry **/
+ public final Collection classpath = new ArrayList();
+
+ /** The mbeans deployed */
+ public final List<ObjectName> mbeans = new ArrayList<ObjectName>();
+
+ /** Anyone can have subdeployments */
+ public final Set subDeployments = new ListSet();
+
+ /** And the subDeployments have a parent */
+ public DeploymentInfo parent = null;
+
+ /** the web root context in case of war file */
+ public String webContext;
+
+ /** the manifest entry of the deployment (if any)
+ * manifest is not serializable ... is only needed
+ * at deployment time, so we mark it transient
+ */
+ public transient Manifest manifest;
+
+ /**
+ * Each Deployment is really mapping one to one to a XML document, here in
+ * its parsed form. A xerces document (org.apache.xerces.dom.DocumentImpl)
+ * is serializable.
+ */
+ public Document document;
+
+ /** An optional URL to the URL of the document loaded */
+ public URL documentUrl;
+
+ /** We can hold "typed" metadata, really an interpretation of the bare XML document */
+ public transient Object metaData;
+
+ /** If this deployed as part of an EAR, there may be an alernative DD */
+ public String alternativeDD;
+
+ /** An arbitrary map of state associated with the deployment */
+ public transient HashMap context = new HashMap();
+
+ /** Is this a stand-alone service descriptor */
+ public boolean isXML;
+
+ /** Is this a stand-alone script */
+ public boolean isScript;
+
+ /** Does the deployment url point to a directory */
+ public boolean isDirectory;
+
+ /** Are the subdeploymets already sorted */
+ public boolean sortedSubDeployments = false ;
+ /**
+ * The variable <code>deployedObject</code> can contain the MBean that
+ * is created through the deployment. for instance, deploying an ejb-jar
+ * results in an EjbModule mbean, which is stored here.
+ */
+ public ObjectName deployedObject;
+
+ /** The configuration of the loader repository for this deployment */
+ public LoaderRepositoryConfig repositoryConfig;
+
+ /** The MBeanServer associated with the deployment */
+ private transient MBeanServer server;
+
+ /**
+ * CTOR
+ */
+ public DeploymentInfo(final URL url, final DeploymentInfo parent, final MBeanServer server)
+ throws DeploymentException
+ {
+ this.server = server;
+ // The key url the deployment comes from
+ this.url = url;
+
+ // this may be changed by deployers in case of directory and xml file following
+ this.watch = url;
+
+ // Whether we are part of a subdeployment or not
+ this.parent = parent;
+
+ // Is it a directory?
+ if (url.getProtocol().startsWith("file") && new File(url.getFile()).isDirectory())
+ this.isDirectory = true;
+
+ // Does it even exist?
+ if (!isDirectory)
+ {
+ try
+ {
+ url.openStream().close();
+ }
+ catch (Exception e)
+ {
+ throw new DeploymentException("url " + url + " could not be opened, does it exist?");
+ }
+ }
+
+ if (parent != null)
+ {
+ parent.subDeployments.add(this);
+ // Use the repository of our topmost parent
+ repositoryConfig = getTopRepositoryConfig();
+ }
+
+ // The "short name" for the deployment http://myserver/mybean.ear should yield "mybean.ear"
+ shortName = getShortName(url.getPath());
+
+ // Do we have an XML descriptor only deployment?
+ isXML = shortName.toLowerCase().endsWith(".xml");
+
+ // Do we have a stand-olone script deployment?
+ isScript = shortName.toLowerCase().endsWith(".bsh");
+ }
+
+ public MBeanServer getServer()
+ {
+ return server;
+ }
+
+ public void setServer(MBeanServer server)
+ {
+ this.server = server;
+ }
+
+ /** Create a UnifiedClassLoader for the deployment that loads from
+ the localUrl and uses its parent deployments url as its orignal
+ url. Previously xml descriptors simply used the TCL but since the UCLs
+ are now registered as mbeans each must be unique.
+ */
+ public void createClassLoaders() throws Exception
+ {
+ // create a local classloader for local files, don't go with the UCL for ejb-jar.xml
+ if( localCl == null )
+ localCl = new URLClassLoader(new URL[] {localUrl});
+
+ /* Walk the deployment tree to find the parent deployment and obtain its
+ url to use as our URL from which this deployment unit originated. This
+ is used to determine permissions using the original URL namespace.
+ Also pick up the LoaderRepository from the topmost ancestor.
+ */
+ URL origUrl = url;
+ DeploymentInfo current = this;
+ while (current.parent != null)
+ {
+ current = current.parent;
+ }
+ origUrl = current.url;
+ repositoryConfig = current.repositoryConfig;
+ if( parent == null )
+ {
+ if( repositoryConfig == null )
+ repositoryConfig = new LoaderRepositoryConfig();
+ // Make sure the specified LoaderRepository exists.
+ LoaderRepositoryFactory.createLoaderRepository(server, repositoryConfig);
+ log.debug("createLoaderRepository from config: "+repositoryConfig);
+ // the classes are passed to a UCL that will share the classes with the whole base
+
+ Object[] args = { isXML ? null : localUrl, origUrl, Boolean.TRUE };
+ String[] sig = { "java.net.URL", "java.net.URL", "boolean" };
+ ucl = (RepositoryClassLoader) server.invoke(repositoryConfig.repositoryName,
+ "newClassLoader",args, sig);
+ }
+ else
+ {
+ // Add a reference to the LoaderRepository
+ LoaderRepositoryFactory.createLoaderRepository(server, repositoryConfig);
+ // Add the deployment URL to the parent UCL
+ ucl = parent.ucl;
+ ucl.addURL(localUrl);
+ }
+ // Add any library jars seen before the UCL was created
+ if( classpath.size() > 0 )
+ {
+ Iterator jars = classpath.iterator();
+ while( jars.hasNext() )
+ {
+ URL jar = (URL) jars.next();
+ ucl.addURL(jar);
+ }
+ }
+ }
+
+ /** Set the UnifiedLoaderRepository info for the deployment. This can only
+ * be called for the parent deployment, and must be done early in the
+ * Subdeployer init(DeploymentInfo) method prior to any class loading.
+ * @throws Exception
+ */
+ public void setRepositoryInfo(LoaderRepositoryConfig config)
+ throws Exception
+ {
+ if( parent != null )
+ {
+ log.warn("Only the root deployment can set the loader repository, "
+ + "ignoring config="+config);
+ return;
+ }
+
+ this.repositoryConfig = config;
+ // Recreate the ucl if it exists
+ if( ucl != null )
+ {
+ ucl.unregister();
+ // Make sure the specified LoaderRepository exists.
+ LoaderRepositoryFactory.createLoaderRepository(server, repositoryConfig);
+ log.debug("createLoaderRepository from config: "+repositoryConfig);
+ // the classes are passed to a UCL that will share the classes with the whole base
+
+ Object[] args = { isXML ? null : localUrl, url, Boolean.TRUE };
+ String[] sig = { "java.net.URL", "java.net.URL", "boolean" };
+ ucl = (RepositoryClassLoader) server.invoke(repositoryConfig.repositoryName,
+ "newClassLoader",args, sig);
+ }
+ }
+
+ /** All library jars referenced through either the manifest references
+ * or sar classpaths are added to the root DeploymentInfo class loader. This
+ * is neccessary to avoid IllegalAccessErrors due to classes in a pkg
+ * being split across jars
+ */
+ public void addLibraryJar(URL libJar)
+ {
+ DeploymentInfo current = this;
+ while (current.parent != null)
+ {
+ current = current.parent;
+ }
+ /* If the UCL exists add the jar to it else use the classpath to
+ indicate that the jars need to be added when the ucl is created.
+ */
+ if( current.ucl != null )
+ current.ucl.addURL(libJar);
+ else
+ classpath.add(libJar);
+ }
+
+ /** The the class loader repository name of the top most DeploymentInfo
+ */
+ public LoaderRepositoryConfig getTopRepositoryConfig()
+ {
+ LoaderRepositoryConfig topConfig = repositoryConfig;
+ DeploymentInfo info = this;
+ while( info.parent != null )
+ {
+ info = info.parent;
+ topConfig = info.repositoryConfig;
+ }
+ return topConfig;
+ }
+
+ /**
+ * getManifest returns (if present) the deployment's manifest
+ * it is lazy loaded to work from the localURL
+ */
+ public Manifest getManifest()
+ {
+ try
+ {
+ if (manifest == null)
+ {
+ File file = new File(localUrl.getFile());
+
+ if (file.isDirectory())
+ {
+ FileInputStream fis = new FileInputStream(new File(file, "META-INF/MANIFEST.MF"));
+ manifest = new Manifest(fis);
+ fis.close();
+ }
+ else if(isXML == false)// a jar
+ manifest = new JarFile(file).getManifest();
+ }
+
+ return manifest;
+ }
+ // It is ok to barf at any time in the above, means no manifest
+ catch (Exception ignored) { return null;}
+ }
+
+ public void cleanup()
+ {
+ // Remove the deployment UCL
+ if( parent == null && ucl != null )
+ ucl.unregister();
+ ucl = null;
+
+ // Remove any deployment specific repository
+ if ( repositoryConfig != null )
+ {
+ LoaderRepositoryFactory.destroyLoaderRepository(server,
+ repositoryConfig.repositoryName);
+ }
+
+ subDeployments.clear();
+ mbeans.clear();
+ context.clear();
+ if (localUrl == null || localUrl.equals(url))
+ {
+ log.debug("Not deleting localUrl, it is null or not a copy: " + localUrl);
+ }
+ else if (Files.delete(localUrl.getFile()))
+ {
+ log.debug("Cleaned Deployment: " + localUrl);
+ }
+ else
+ {
+ log.debug("Could not delete " + localUrl + " restart will delete it");
+ }
+
+ // Clean up references to other objects
+ localCl = null;
+ annotationsCl = null;
+ localUrl = null;
+ repositoryConfig = null;
+ watch = null;
+ parent = null;
+ manifest = null;
+ document = null;
+ metaData = null;
+ server = null;
+ classpath.clear();
+ state = DeploymentState.DESTROYED;
+ // Who is using this after clear?
+ // deployer = null;
+ }
+
+ /** The sortName concatenated with the canonical names of all parents. */
+ public String getCanonicalName()
+ {
+ String name = shortName;
+ if (parent != null)
+ name = parent.getCanonicalName() + "/" + name;
+ return name;
+ }
+
+ private String getShortName(String name)
+ {
+ if (name.endsWith("/")) name = name.substring(0, name.length() - 1);
+ name = name.substring(name.lastIndexOf("/") + 1);
+ return name;
+ }
+
+ public int hashCode()
+ {
+ return url.hashCode();
+ }
+
+ public boolean equals(Object other)
+ {
+ if (other instanceof DeploymentInfo)
+ {
+ return ((DeploymentInfo) other).url.equals(this.url);
+ }
+ return false;
+ }
+
+ public String toString()
+ {
+ StringBuffer s = new StringBuffer(super.toString());
+ s.append(" { url=" + url + " }\n");
+ s.append(" deployer: " + deployer + "\n");
+ s.append(" status: " + status + "\n");
+ s.append(" state: " + state + "\n");
+ s.append(" watch: " + watch + "\n");
+ s.append(" altDD: " + alternativeDD + "\n");
+ s.append(" lastDeployed: " + lastDeployed + "\n");
+ s.append(" lastModified: " + lastModified + "\n");
+ s.append(" mbeans:\n");
+ for (Iterator i = mbeans.iterator(); i.hasNext(); )
+ {
+ ObjectName o = (ObjectName)i.next();
+ try
+ {
+ String state = (String)server.getAttribute(o, "StateString");
+ s.append(" " + o + " state: " + state + "\n");
+ }
+ catch (Exception e)
+ {
+ s.append(" " + o + " (state not available)\n");
+ } // end of try-catch
+
+ } // end of for ()
+
+ return s.toString();
+ }
+}
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfo.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.util.Comparator;
-
-/**
- * This comparator takes a delegate comparator that can compare URLs, and
- * applies that to DeploymentInfo objects
- */
-public class DeploymentInfoComparator implements Comparator {
-
- /** the delegate URL comparator */
- private Comparator urlComparator;
-
- public DeploymentInfoComparator(Comparator comp) {
- this.urlComparator = comp;
- }
-
- public int compare(Object o1, Object o2) {
- return urlComparator.compare(((DeploymentInfo)o1).url, ((DeploymentInfo)o2).url);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentInfoComparator.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,106 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.net.URL;
-import java.util.Comparator;
-
-import org.jboss.util.NullArgumentException;
-
-/**
- * A helper class for sorting deployments.
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author Scott.Stark at jboss.org
- */
-public class DeploymentSorter implements Comparator, DefaultDeploymentSorter
-{
- /**
- * The default order for sorting deployments; this has been deprecated,
- * order is really defined in SuffixOrderHelper class and/or individualy
- * within each subdeployer.
- *
- * @deprecated
- */
- public static final String[] DEFAULT_SUFFIX_ORDER = {
- ".deployer", "-deployer.xml", ".sar", "-service.xml", ".rar", "-ds.xml",
- ".har", ".jar", ".war", ".wsr", ".ear", ".zip", ".bsh", ".last"
- };
-
- protected String[] suffixOrder;
-
- public DeploymentSorter(String[] suffixOrder)
- {
- if (suffixOrder == null)
- throw new NullArgumentException("suffixOrder");
-
- this.suffixOrder = suffixOrder;
- }
-
- public DeploymentSorter()
- {
- this(DEFAULT_SUFFIX_ORDER);
- }
-
- public String[] getSuffixOrder()
- {
- return suffixOrder;
- }
- public void setSuffixOrder(String[] suffixOrder)
- {
- this.suffixOrder = suffixOrder;
- }
-
- /**
- * Return a negative number if o1 appears lower in the the suffix order than
- * o2.
- * If the suffixes are indentical, then sorts based on name.
- * This is so that deployment order of components is always identical.
- */
- public int compare(Object o1, Object o2)
- {
- URL u1 = (URL)o1;
- URL u2 = (URL)o2;
- int order = getExtensionIndex(u1) - getExtensionIndex(u2);
- if (order != 0)
- return order;
- return u1.getFile().compareTo(u2.getFile());
- }
-
- /**
- * Return the index that matches this url
- */
- public int getExtensionIndex(URL url)
- {
- String path = url.getPath();
- if (path.endsWith("/"))
- path = path.substring(0, path.length() - 1);
- int i = 0;
- for (; i < suffixOrder.length; i++)
- {
- if (path.endsWith(suffixOrder[i]))
- break;
- }
- return i;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentSorter.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentState.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentState.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/DeploymentState.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,116 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.io.ObjectStreamException;
-import java.io.Serializable;
-
-/**
- * A type-safe enumeration for the status a DeploymentInfo may be in
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class DeploymentState implements Serializable
-{
- /** @since 4.0.2 */
- private static final long serialVersionUID = -2319062412502366783L;
-
- public static final DeploymentState CONSTRUCTED = new DeploymentState("CONSTRUCTED");
- public static final DeploymentState INIT_WAITING_DEPLOYER = new DeploymentState("INIT_WAITING_DEPLOYER");
- public static final DeploymentState INIT_HAS_DEPLOYER = new DeploymentState("INIT_HAS_DEPLOYER");
- public static final DeploymentState INIT_DEPLOYER = new DeploymentState("INIT_DEPLOYER");
- public static final DeploymentState INITIALIZED = new DeploymentState("INITIALIZED");
-
- public static final DeploymentState CREATE_SUBDEPLOYMENTS = new DeploymentState("CREATE_SUBDEPLOYMENTS");
- public static final DeploymentState CREATE_DEPLOYER = new DeploymentState("CREATE_DEPLOYER");
- public static final DeploymentState CREATED = new DeploymentState("CREATED");
-
- public static final DeploymentState START_SUBDEPLOYMENTS = new DeploymentState("START_SUBDEPLOYMENTS");
- public static final DeploymentState START_DEPLOYER = new DeploymentState("START_DEPLOYER");
- public static final DeploymentState STARTED = new DeploymentState("STARTED");
-
- public static final DeploymentState STOPPED = new DeploymentState("STOPPED");
- public static final DeploymentState DESTROYED = new DeploymentState("DESTROYED");
- public static final DeploymentState FAILED = new DeploymentState("FAILED");
-
- private String state;
-
- /** Private CTOR to disable direct object construction
- */
- private DeploymentState(String state)
- {
- this.state = state;
- }
-
- /** A factory to translate a string into the corresponding DeploymentState.
- */
- public static DeploymentState getDeploymentState(String state)
- {
- DeploymentState theState = null;
- state = state.toUpperCase();
- if( state.equals("CONSTRUCTED") )
- theState = CONSTRUCTED;
- else if( state.equals("INIT_WAITING_DEPLOYER") )
- theState = INIT_WAITING_DEPLOYER;
- else if( state.equals("INIT_HAS_DEPLOYER") )
- theState = INIT_HAS_DEPLOYER;
- else if( state.equals("INIT_DEPLOYER") )
- theState = INIT_DEPLOYER;
- else if( state.equals("INITIALIZED") )
- theState = INITIALIZED;
- else if( state.equals("CREATE_SUBDEPLOYMENTS") )
- theState = CREATE_SUBDEPLOYMENTS;
- else if( state.equals("CREATE_DEPLOYER") )
- theState = CREATE_DEPLOYER;
- else if( state.equals("CREATED") )
- theState = CREATED;
- else if( state.equals("START_SUBDEPLOYMENTS") )
- theState = START_SUBDEPLOYMENTS;
- else if( state.equals("START_DEPLOYER") )
- theState = START_DEPLOYER;
- else if( state.equals("STARTED") )
- theState = STARTED;
- else if( state.equals("STOPPED") )
- theState = STOPPED;
- else if( state.equals("DESTROYED") )
- theState = DESTROYED;
- else if( state.equals("FAILED") )
- theState = FAILED;
-
- return theState;
- }
-
- public String toString()
- {
- return state;
- }
-
- /** Resolve objects on deserialization to one of the identity objects.
- */
- private Object readResolve() throws ObjectStreamException
- {
- Object identity = getDeploymentState(state);
- return identity;
- }
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentState.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/DeploymentState.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/DeploymentState.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,199 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.io.IOException;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.util.Collection;
-import java.util.Iterator;
-
-/**
- * IncompleteDeploymentException
- *
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public class IncompleteDeploymentException extends DeploymentException
-{
- /** @since 4.0.2 */
- private static final long serialVersionUID = 1428860525880893167L;
-
- /** non-serializable info */
- private transient final Collection mbeansWaitingForClasses;
- private transient final Collection mbeansWaitingForDepends;
- private transient final Collection rootCause;
- private transient final Collection incompletePackages;
- private transient final Collection waitingForDeployer;
-
- /** only serializable info */
- private String string;
-
- /**
- * CTOR
- *
- * @param mbeansWaitingForClasses
- * @param mbeansWaitingForDepends
- * @param rootCause
- * @param incompletePackages
- * @param waitingForDeployer
- */
- public IncompleteDeploymentException(final Collection mbeansWaitingForClasses,
- final Collection mbeansWaitingForDepends,
- final Collection rootCause,
- final Collection incompletePackages,
- final Collection waitingForDeployer)
- {
- if (mbeansWaitingForClasses == null
- || mbeansWaitingForDepends == null
- || rootCause == null
- ||incompletePackages == null
- || waitingForDeployer == null)
- {
- throw new IllegalArgumentException("All lists in IncompleteDeploymentException constructor must be supplied");
- } // end of if ()
-
- this.mbeansWaitingForClasses = mbeansWaitingForClasses;
- this.mbeansWaitingForDepends = mbeansWaitingForDepends;
- this.rootCause = rootCause;
- this.incompletePackages = incompletePackages;
- this.waitingForDeployer = waitingForDeployer;
- }
-
- /**
- * Get the MbeansWaitingForClasses value.
- * @return the MbeansWaitingForClasses value.
- */
- public Collection getMbeansWaitingForClasses()
- {
- return mbeansWaitingForClasses;
- }
-
- /**
- * Get the MbeansWaitingForDepends value.
- * @return the MbeansWaitingForDepends value.
- */
- public Collection getMbeansWaitingForDepends()
- {
- return mbeansWaitingForDepends;
- }
-
- /**
- * Get the IncompletePackages value.
- * @return the IncompletePackages value.
- */
- public Collection getIncompletePackages()
- {
- return incompletePackages;
- }
-
- /**
- * Get the WaitingForDeployer value.
- * @return the WaitingForDeployer value.
- */
- public Collection getWaitingForDeployer()
- {
- return waitingForDeployer;
- }
-
- /**
- * @return true is no information is contained at all
- */
- public boolean isEmpty()
- {
- return mbeansWaitingForClasses.size() == 0
- && mbeansWaitingForDepends.size() == 0
- && rootCause.size() == 0
- && incompletePackages.size() == 0
- && waitingForDeployer.size() == 0;
- }
-
- /**
- * Convert to String and cache the deployment information
- */
- public String toString()
- {
- if (string != null)
- {
- return string;
- }
-
- StringBuffer result = new StringBuffer("Incomplete Deployment listing:\n\n");
- if (waitingForDeployer.size() != 0)
- {
- result.append("--- Packages waiting for a deployer ---\n");
- appendCollection(result, waitingForDeployer);
- }
-
- if (incompletePackages.size() != 0)
- {
- result.append("--- Incompletely deployed packages ---\n");
- appendCollection(result, incompletePackages);
- }
-
- if (mbeansWaitingForClasses.size() != 0)
- {
- result.append("--- MBeans waiting for classes ---\n");
- appendCollection(result, mbeansWaitingForClasses);
- }
-
- if (mbeansWaitingForDepends.size() != 0)
- {
- result.append("--- MBeans waiting for other MBeans ---\n");
- appendCollection(result, mbeansWaitingForDepends);
- }
-
- if (rootCause.size() != 0)
- {
- result.append("--- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---\n");
- appendCollection(result, rootCause);
- }
-
- string = result.toString();
- return string;
- }
-
- private void appendCollection(StringBuffer result, Collection c)
- {
- for (Iterator i = c.iterator(); i.hasNext();)
- result.append(i.next().toString()).append('\n');
- }
-
- /**
- * Read-in the string-fied information produced by writeObject()
- */
- private void readObject(ObjectInputStream s) throws IOException, ClassNotFoundException
- {
- s.defaultReadObject();
- }
-
- /**
- * String-ify the contained information when serializing
- */
- private void writeObject(ObjectOutputStream s) throws IOException
- {
- toString();
- s.defaultWriteObject();
- }
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/IncompleteDeploymentException.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/JARDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/JARDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/JARDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,251 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.io.File;
-import java.io.FileFilter;
-import java.net.JarURLConnection;
-import java.net.URL;
-import java.net.URLConnection;
-import java.util.Arrays;
-import java.util.Enumeration;
-import java.util.jar.JarEntry;
-import java.util.jar.JarFile;
-
-import org.jboss.util.Strings;
-
-/**
- * This deployer exists to prevent deployment of packages whose deployers are not yet
- * deployed. It will accept only jar/zip format files or directories that don't
- * have a META-INF directory, or if they do, don't have any .xml files there. It
- * assumes any package with a META-INF/*.xml file needs a specialized deployer.
- *
- * @todo find a way to scan just the META-INF files, not the whole jar.
- *
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public class JARDeployer extends SubDeployerSupport
- implements JARDeployerMBean
-{
- /**
- * The suffixes we accept, along with their relative order.
- *
- * For JARDeployer, this is only used to populate the MainDeployer's
- * SuffixOrder list, it is not used to actually match deployment suffixes
- */
- private static final String[] DEFAULT_ENHANCED_SUFFIXES = new String[] {
- "700:.jar", // normal .jar
- "750:.zip", // normal .zip
- "900:.last" // make content of .last dirs/archives deploy last
- };
-
- private String[] descriptorNames = {
- ".xml"
- };
-
- /**
- * Default CTOR
- */
- public JARDeployer()
- {
- super.setEnhancedSuffixes(DEFAULT_ENHANCED_SUFFIXES);
- }
-
- public String[] getDescriptorNames()
- {
- return descriptorNames;
- }
-
- public void setDescriptorNames(String[] descriptorNames)
- {
- this.descriptorNames = descriptorNames;
- }
-
- // ServiceMBeanSupport methods
-
- protected void stopService()
- {
- // This can't be run right now since the JARDeployer is started before the MainDeployer,
- // so the MainDeployer is stopped first... so the JARDeployer can't unregister.
-
- // super.stopService();
- }
-
- // SubDeployer implementation
-
- /**
- * The <code>accepts</code> method is called by MainDeployer to
- * determine which deployer is suitable for a DeploymentInfo.
- *
- * @todo find a way to scan just the META-INF files, not the whole jar.
- *
- * @param di a <code>DeploymentInfo</code> value
- * @return a <code>boolean</code> value
- */
- public boolean accepts(DeploymentInfo di)
- {
- boolean trace = log.isTraceEnabled();
-
- try
- {
- // Reject extensions not configured in this subdeployer
- // but do consider accepting non-dotted deployments,
- // like deploy-hasingleton
- if (di.shortName.indexOf('.') != -1 && super.accepts(di) == false)
- {
- return false;
- }
-
- // Reject deployments with a WEB-INF/ directory
- URL wdDir = di.localCl.findResource("WEB-INF/");
- if (wdDir != null)
- {
- return false;
- }
-
- // Since a META-INF directory exists within rt.jar, we can't just do a
- // getResource (it will always return rt.jar's version).
- // The method we want is findResource, but it is marked protected in
- // ClassLoader. Fortunately, URLClassLoader exposes it which makes
- // this hack possible. Anybody have a better way to check a URL
- // for the existance of a META-INF??
- URL ddDir;
- try
- {
- ddDir = di.localCl.findResource("META-INF/");
- if (ddDir == null)
- {
- log.debug("No META-INF or WEB-INF resource found, assuming it if for us");
- return true;
- }
- }
- catch (ClassCastException e)
- {
- // assume there is a META-INF...
- ddDir = new URL(di.url, "META-INF/");
- }
-
- if (ddDir.getProtocol().equals("file"))
- {
- log.trace("File protocol: "+ddDir);
- File file = new File(ddDir.getFile());
- if (!file.exists())
- {
- log.warn("File not found: " + file);
- return true;
- }
-
- // Scan for any xml files in the META-INF dir
- File[] entries = file.listFiles(
- new FileFilter()
- {
- public boolean accept(File pathname)
- {
- boolean accept = false;
- String name = pathname.getName();
- for(int n = 0; accept == false && n < descriptorNames.length; n ++)
- {
- String d = descriptorNames[n];
- accept = name.endsWith(d);
- }
- return accept;
- }
- }
- );
- log.debug("XML entries found: " + entries.length);
- return entries.length == 0;
- } // end of if ()
- else if (ddDir.getProtocol().equals("jar") == true)
- {
- log.trace("jar protocol: " + ddDir);
- JarFile jarFile = null;
-
- try
- {
- URLConnection con = ddDir.openConnection();
- JarURLConnection jarConn = (JarURLConnection) con;
- /* Need to set caching to false otherwise closing the jarfile
- ends up conflicting with other users of the cached jar.
- */
- jarConn.setUseCaches(false);
- jarFile = jarConn.getJarFile();
-
- // Scan for any xml files in the META-INF dir
- if (trace)
- log.trace("Descriptor names=" + Arrays.asList(descriptorNames));
- for (Enumeration e = jarFile.entries(); e.hasMoreElements();)
- {
- JarEntry entry = (JarEntry)e.nextElement();
- String name = entry.getName();
- if (trace)
- log.trace("Looking at entry: '" + name + "'");
-
- // JBAS-2949 - Look for xml descriptors directly
- // under META-INF/, not in META-INF/ subdirectories
- if (name.startsWith("META-INF/") && Strings.count(name, "/") == 1)
- {
- for (int n = 0; n < descriptorNames.length; n ++)
- {
- if (name.endsWith(descriptorNames[n]))
- {
- log.debug("Found entry: '" + name + "', matching: '"
- + descriptorNames[n] + "', rejecting jar");
-
- // Do not accept this as jar file
- return false;
- }
- }
- }
- }
- }
- catch (Exception e)
- {
- log.warn("Looking inside jar failed; ignoring", e);
- return false;
- }
- finally
- {
- if (jarFile != null)
- jarFile.close();
- jarFile = null;
- }
-
- log.debug("No xml files found");
- return true;
- }
- else
- {
- log.debug("Unrecognized protocol: " + ddDir.getProtocol());
- }
-
- return false;
- }
- catch (Exception e)
- {
- log.trace("Ignored error", e);
- return false;
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/JARDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/JARDeployer.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/JARDeployer.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,46 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- *
- * @version $Revision$
- */
-public interface JARDeployerMBean extends SubDeployerMBean
-{
- /** The default ObjectName */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:service=JARDeployer");
-
- /**
- * The list of suffixes that define deployment descriptors which if
- * found in an archive META-INF directory indicate non-jar deployments
- * that should be ignored by the JARDeployer.
- */
- void setDescriptorNames(String[] descriptorNames);
- String[] getDescriptorNames();
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/JARDeployerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/MainDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/MainDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,1415 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.io.BufferedInputStream;
-import java.io.BufferedOutputStream;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-import java.util.Set;
-import java.util.StringTokenizer;
-import java.util.jar.Attributes;
-import java.util.jar.Manifest;
-
-import javax.management.JMException;
-import javax.management.MBeanServer;
-import javax.management.MalformedObjectNameException;
-import javax.management.Notification;
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceMBeanSupport;
-import org.jboss.system.server.ServerConfig;
-import org.jboss.system.server.ServerConfigLocator;
-import org.jboss.util.file.Files;
-import org.jboss.util.file.JarUtils;
-import org.jboss.util.stream.Streams;
-
-/**
- * The main/primary component for deployment.
- *
- * <p>MainDeployerMBean is generated by xdoclet.
- *
- * @deprecated see org.jboss.deployers.spi.MainDeployer
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public class MainDeployer extends ServiceMBeanSupport
- implements Deployer, MainDeployerMBean
-{
- /**
- * The variable <code>serviceController</code> is used by the
- * checkIncompleteDeployments method to ask for lists of mbeans
- * with deployment problems.
- */
- private ObjectName serviceController;
-
- /** Deployers **/
- private final LinkedList deployers = new LinkedList();
-
- /** A Map of URL -> DeploymentInfo */
- private final Map deploymentMap = Collections.synchronizedMap(new HashMap());
-
- /** A list of all deployments that have deployers. */
- private final List deploymentList = new ArrayList();
-
- /** A list of all deployments that do not have deployers. */
- private final List waitingDeployments = new ArrayList();
-
- /** A helper for sorting deployment URLs. */
- private final DeploymentSorter sorter = new DeploymentSorter();
-
- /** A helper for sorting deploymentInfos */
- private final Comparator infoSorter = new DeploymentInfoComparator(sorter);
-
- /** Helper class handling the SuffixOrder and EnhancedSuffixOrder attributes */
- private final SuffixOrderHelper suffixOrderHelper = new SuffixOrderHelper(sorter);
-
- /** Should local copies be made of resources on the local file system */
- private boolean copyFiles = true;
-
- /** The temporary directory for deployments. */
- private File tempDir;
-
- /** The string naming the tempDir **/
- private String tempDirString;
-
- /**
- * Explict no-args contsructor for JMX.
- */
- public MainDeployer()
- {
- // Is there a better place to obtain startup information?
- String localCopy = System.getProperty("jboss.deploy.localcopy");
- if (localCopy != null && (
- localCopy.equalsIgnoreCase("false") ||
- localCopy.equalsIgnoreCase("no") ||
- localCopy.equalsIgnoreCase("off")))
- {
- log.debug("Disabling local copies of file: urls");
- copyFiles = false;
- }
- }
-
-
- /** Get the flag indicating whether directory content will be deployed
- *
- * @return the file copy flag
- * @jmx.managed-attribute
- */
- public boolean getCopyFiles()
- {
- return copyFiles;
- }
- /** Set the flag indicating whether directory content will be deployed. The
- * default value is taken from the jboss.deploy.localcopy system
- * property.
- *
- * @param copyFiles the local copy flag value
- * @jmx.managed-attribute
- */
- public void setCopyFiles(boolean copyFiles)
- {
- this.copyFiles = copyFiles;
- }
-
- /** Get the temp directory
- *
- * @return the path to the local tmp directory
- * @jmx.managed-attribute
- */
- public File getTempDir()
- {
- return tempDir;
- }
- /** Set the temp directory
- *
- * @param tempDir the path to the local tmp directory
- * @jmx.managed-attribute
- */
- public void setTempDir(File tempDir)
- {
- this.tempDir = tempDir;
- }
-
- /** Get the temp directory
- *
- * @return the path to the local tmp directory
- * @jmx.managed-attribute
- */
- public String getTempDirString()
- {
- return tempDirString;
- }
-
- /** Get the ordering of the deployment suffixes
- *
- * @return the ordering of the deployment suffixes
- * @jmx.managed-attribute
- */
- public String[] getSuffixOrder()
- {
- return suffixOrderHelper.getSuffixOrder();
- }
-
- /** Get the enhanced suffix order
- *
- * @return the enhanced suffix order
- * @jmx.managed-attribute
- */
- public String[] getEnhancedSuffixOrder()
- {
- return suffixOrderHelper.getEnhancedSuffixes();
- }
-
- /** Set the enhanced suffix order
- *
- * @param enhancedSuffixOrder the enhanced suffix order
- * @jmx.managed-attribute
- */
- public void setEnhancedSuffixOrder(String[] enhancedSuffixOrder)
- {
- suffixOrderHelper.setEnhancedSuffixes(enhancedSuffixOrder);
- }
-
- /**
- * Describe <code>setServiceController</code> method here.
- *
- * @param serviceController an <code>ObjectName</code> value
- * @jmx.managed-attribute
- */
- public void setServiceController(final ObjectName serviceController)
- {
- this.serviceController = serviceController;
- }
-
- /**
- * The <code>listDeployed</code> method returns a collection of DeploymemtInfo
- * objects for the currently deployed packages.
- *
- * @return a <code>Collection</code> value
- * @jmx.managed-operation
- */
- public Collection listDeployed()
- {
- synchronized (deploymentList)
- {
- log.debug("deployment list string: " + deploymentList);
- return new ArrayList(deploymentList);
- }
- }
-
- /**
- * The <code>listDeployedModules</code> method returns a collection of
- * SerializableDeploymentInfo objects for the currently deployed packages.
- *
- * @return a <code>Collection</code> value
- * @jmx.managed-operation
- */
- public Collection listDeployedModules()
- {
- log.debug("listDeployedModules");
-
- HashMap map = new HashMap();
- synchronized (deploymentList)
- {
- Collection col = new ArrayList(deploymentList);
-
- // create a map entry for each deployment
- for (Iterator it = col.iterator(); it.hasNext();)
- {
- DeploymentInfo info = (DeploymentInfo) it.next();
- map.put(info.url, new SerializableDeploymentInfo(info));
- // assign parent and sub deployments
- fillParentAndChildrenSDI(info, map);
- }
- }
-
- // map.values is not serializable, so we copy
- return new ArrayList(map.values());
- }
-
- /**
- * Describe <code>listDeployedAsString</code> method here.
- *
- * @return a <code>String</code> value
- * @jmx.managed-operation
- */
- public String listDeployedAsString()
- {
- return "<pre>" + listDeployed() + "</pre>";
- }
-
- /**
- * The <code>listIncompletelyDeployed</code> method returns a list of packages that have
- * not deployed completely. The toString method will include any exception in the status
- * field.
- *
- * @return a <code>Collection</code> value
- * @jmx.managed-operation
- */
- public Collection listIncompletelyDeployed()
- {
- List id = new ArrayList();
- List copy;
- synchronized (deploymentList)
- {
- copy = new ArrayList(deploymentList);
- }
- for (Iterator i = copy.iterator(); i.hasNext();)
- {
- DeploymentInfo di = (DeploymentInfo)i.next();
- if (!"Deployed".equals(di.status) && !"Starting".equals(di.status))
- {
- id.add(di);
- } // end of if ()
-
- } // end of for ()
- return id;
- }
-
- /**
- * The <code>listWaitingForDeployer</code> method returns a collection
- * of the packages that currently have no identified deployer.
- *
- * @return a <code>Collection</code> value
- * @jmx.managed-operation
- */
- public Collection listWaitingForDeployer()
- {
- synchronized (waitingDeployments)
- {
- return new ArrayList(waitingDeployments);
- }
- }
-
- /**
- * The <code>addDeployer</code> method registers a deployer with the main deployer.
- * Any waiting packages are tested to see if the new deployer will deploy them.
- *
- * @param deployer a <code>SubDeployer</code> value
- * @jmx.managed-operation
- */
- public void addDeployer(final SubDeployer deployer)
- {
- log.debug("Adding deployer: " + deployer);
- ObjectName deployerName = deployer.getServiceName();
-
- synchronized(deployers)
- {
- deployers.addFirst(deployer);
- try
- {
- String[] suffixes = (String[]) server.getAttribute(deployerName, "EnhancedSuffixes");
- suffixOrderHelper.addEnhancedSuffixes(suffixes);
- }
- catch(Exception e)
- {
- log.debug(deployerName + " does not support EnhancedSuffixes");
- suffixOrderHelper.addSuffixes(deployer.getSuffixes(), deployer.getRelativeOrder());
- }
- }
-
- // Send a notification about the deployer addition
- Notification msg = new Notification(ADD_DEPLOYER, this, getNextNotificationSequenceNumber());
- msg.setUserData(deployerName);
- sendNotification(msg);
-
- synchronized (waitingDeployments)
- {
- List copy = new ArrayList(waitingDeployments);
- waitingDeployments.clear();
- for (Iterator i = copy.iterator(); i.hasNext();)
- {
- DeploymentInfo di = (DeploymentInfo)i.next();
- log.debug("trying to deploy with new deployer: " + di.shortName);
- try
- {
- di.setServer(server);
- deploy(di);
- }
- catch (DeploymentException e)
- {
- log.error("DeploymentException while trying to deploy a package with a new deployer", e);
- } // end of try-catch
- } // end of for ()
- }
- }
-
- /**
- * The <code>removeDeployer</code> method unregisters a deployer with the MainDeployer.
- * Deployed packages deployed with this deployer are undeployed.
- *
- * @param deployer a <code>SubDeployer</code> value
- * @jmx.managed-operation
- */
- public void removeDeployer(final SubDeployer deployer)
- {
- log.debug("Removing deployer: " + deployer);
- ObjectName deployerName = deployer.getServiceName();
- boolean removed = false;
-
- synchronized(deployers)
- {
- removed = deployers.remove(deployer);
- try
- {
- String[] suffixes = (String[]) server.getAttribute(deployerName, "EnhancedSuffixes");
- suffixOrderHelper.removeEnhancedSuffixes(suffixes);
- }
- catch(Exception e)
- {
- log.debug(deployerName + " does not support EnhancedSuffixes");
- suffixOrderHelper.removeSuffixes(deployer.getSuffixes(), deployer.getRelativeOrder());
- }
- }
-
- // Send a notification about the deployer removal
- if (removed)
- {
- Notification msg = new Notification(REMOVE_DEPLOYER, this, getNextNotificationSequenceNumber());
- msg.setUserData(deployerName);
- sendNotification(msg);
- }
-
- List copy;
- synchronized (deploymentList)
- {
- copy = new ArrayList(deploymentList);
- }
- for (Iterator i = copy.iterator(); i.hasNext(); )
- {
- DeploymentInfo di = (DeploymentInfo)i.next();
- if (di.deployer == deployer)
- {
- undeploy(di);
- di.deployer = null;
- synchronized (waitingDeployments)
- {
- waitingDeployments.add(di);
- }
- }
- }
- }
-
- /**
- * The <code>listDeployers</code> method returns a collection of ObjectNames of
- * deployers registered with the MainDeployer.
- *
- * @return a <code>Collection<ObjectName></code> value
- * @jmx.managed-operation
- */
- public Collection listDeployers()
- {
- ArrayList deployerNames = new ArrayList();
- synchronized(deployers)
- {
- for(int n = 0; n < deployers.size(); n ++)
- {
- SubDeployer deployer = (SubDeployer) deployers.get(n);
- ObjectName name = deployer.getServiceName();
- deployerNames.add(name);
- }
- }
- return deployerNames;
- }
-
- // ServiceMBeanSupport overrides ---------------------------------
-
- protected ObjectName getObjectName(MBeanServer server, ObjectName name)
- throws MalformedObjectNameException
- {
- return name == null ? OBJECT_NAME : name;
- }
-
- /**
- * The <code>createService</code> method is one of the ServiceMBean lifecyle operations.
- * (no jmx tag needed from superinterface)
- * @exception Exception if an error occurs
- */
- protected void createService() throws Exception
- {
- ServerConfig config = ServerConfigLocator.locate();
- // Get the temp directory location
- File basedir = config.getServerTempDir();
- // Set the local copy temp dir to tmp/deploy
- tempDir = new File(basedir, "deploy");
- // Delete any existing content
- Files.delete(tempDir);
- // Make sure the directory exists
- tempDir.mkdirs();
-
- // used in inLocalCopyDir
- tempDirString = tempDir.toURL().toString();
-
- // handles SuffixOrder & RelativeSuffixOrder attributes
- suffixOrderHelper.initialize();
- }
-
- /**
- * The <code>shutdown</code> method undeploys all deployed packages in
- * reverse order of their deployement.
- *
- * @jmx.managed-operation
- */
- public void shutdown()
- {
- // if we shutdown in the middle of a scan, it still might be possible that we try to redeploy
- // things we are busy killing...
- int deployCounter = 0;
-
- // undeploy everything in sight
- List copy;
- synchronized (deploymentList)
- {
- copy = new ArrayList(deploymentList);
- }
- for (ListIterator i = copy.listIterator(copy.size()); i.hasPrevious(); )
- {
- try
- {
- undeploy((DeploymentInfo)i.previous(), true);
- deployCounter++;
- }
- catch (Exception e)
- {
- log.info("exception trying to undeploy during shutdown", e);
- }
-
- }
- // Help GC
- this.deployers.clear();
- this.deploymentMap.clear();
- this.deploymentList.clear();
- this.waitingDeployments.clear();
- this.tempDir = null;
-
- log.debug("Undeployed " + deployCounter + " deployed packages");
- }
-
-
- /**
- * Describe <code>redeploy</code> method here.
- *
- * @param urlspec a <code>String</code> value
- * @exception DeploymentException if an error occurs
- * @exception MalformedURLException if an error occurs
- * @jmx.managed-operation
- */
- public void redeploy(String urlspec)
- throws DeploymentException, MalformedURLException
- {
- redeploy(new URL(urlspec));
- }
-
- /**
- * Describe <code>redeploy</code> method here.
- *
- * @param url an <code>URL</code> value
- * @exception DeploymentException if an error occurs
- * @jmx.managed-operation
- */
- public void redeploy(URL url) throws DeploymentException
- {
- DeploymentInfo sdi = getDeployment(url);
- if (sdi!= null)
- {
- redeploy(sdi);
- }
- else
- {
- deploy(url);
- } // end of else
- }
-
- /**
- * Describe <code>redeploy</code> method here.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- * @jmx.managed-operation
- */
- public void redeploy(DeploymentInfo sdi) throws DeploymentException
- {
- try
- {
- undeploy(sdi);
- }
- catch (Throwable t)
- {
- log.info("Throwable from undeployment attempt: ", t);
- } // end of try-catch
- sdi.setServer(server);
- deploy(sdi);
- }
-
- /**
- * The <code>undeploy</code> method undeploys a package identified by a string
- * representation of a URL.
- *
- * @param urlspec the stringfied url to undeploy
- * @jmx.managed-operation
- */
- public void undeploy(String urlspec)
- throws DeploymentException, MalformedURLException
- {
- undeploy(new URL(urlspec));
- }
-
- /**
- * The <code>undeploy</code> method undeploys a package identified by a URL
- *
- * @param url the url to undeploy
- * @jmx.managed-operation
- */
- public void undeploy(URL url) throws DeploymentException
- {
- DeploymentInfo sdi = getDeployment(url);
- if (sdi != null)
- {
- undeploy(sdi);
- }
- else
- {
- log.warn("undeploy '" + url + "' : package not deployed");
- }
- }
-
- /**
- * The <code>undeploy</code> method undeploys a package represented by a
- * DeploymentInfo object.
- *
- * @param di a <code>DeploymentInfo</code> value
- * @jmx.managed-operation
- */
- public void undeploy(DeploymentInfo di)
- {
- undeploy(di, false);
- }
- protected void undeploy(DeploymentInfo di, boolean isShutdown)
- {
- log.debug("Undeploying "+di.url);
- stop(di);
- destroy(di);
- }
-
- /**
- * The <code>stop</code> method is the first internal step of undeployment
- *
- * @param di a <code>DeploymentInfo</code> value
- */
- private void stop(DeploymentInfo di)
- {
- // Stop all sub-deployments
- ArrayList reverseSortedSubs = new ArrayList(di.subDeployments);
- Collections.sort(reverseSortedSubs, infoSorter);
- Collections.reverse(reverseSortedSubs);
- for (Iterator subs = reverseSortedSubs.iterator(); subs.hasNext();)
- {
- DeploymentInfo sub = (DeploymentInfo) subs.next();
- log.debug("Stopping sub deployment: "+sub.url);
- stop(sub);
- }
- // Lastly stop this deployment itself
- try
- {
- // Tell the respective deployer to undeploy this one
- if (di.deployer != null)
- {
- di.deployer.stop(di);
- di.status="Stopped";
- di.state = DeploymentState.STOPPED;
- }
- }
- catch (Throwable t)
- {
- log.error("Deployer stop failed for: " + di.url, t);
- }
-
- }
-
- /**
- * The <code>destroy</code> method is the second and final internal undeployment step.
- *
- * @param di a <code>DeploymentInfo</code> value
- */
- private void destroy(DeploymentInfo di)
- {
- // Destroy all sub-deployments
- ArrayList reverseSortedSubs = new ArrayList(di.subDeployments);
- Collections.sort(reverseSortedSubs, infoSorter);
- Collections.reverse(reverseSortedSubs);
- for (Iterator subs = reverseSortedSubs.iterator(); subs.hasNext();)
- {
- DeploymentInfo sub = (DeploymentInfo) subs.next();
- log.debug("Destroying sub deployment: "+sub.url);
- destroy(sub);
- }
- // Lastly destroy the deployment itself
- try
- {
- // Tell the respective deployer to undeploy this one
- if (di.deployer != null)
- {
- di.deployer.destroy(di);
- di.status="Destroyed";
- di.state = DeploymentState.DESTROYED;
- }
- }
- catch (Throwable t)
- {
- log.error("Deployer destroy failed for: " + di.url, t);
- di.state = DeploymentState.FAILED;
- }
-
- try
- {
- // remove from local maps
- synchronized (deploymentList)
- {
- deploymentMap.remove(di.url);
- if (deploymentList.lastIndexOf(di) != -1)
- {
- deploymentList.remove(deploymentList.lastIndexOf(di));
- }
- }
- synchronized (waitingDeployments)
- {
- waitingDeployments.remove(di);
- }
- // Nuke my stuff, this includes the class loader
- di.cleanup();
-
- log.debug("Undeployed "+di.url);
- }
- catch (Throwable t)
- {
- log.error("Undeployment cleanup failed: " + di.url, t);
- }
- }
-
- /**
- * The <code>deploy</code> method deploys a package identified by a
- * string representation of a URL.
- *
- * @param urlspec a <code>String</code> value
- * @exception MalformedURLException if an error occurs
- * @jmx.managed-operation
- */
- public void deploy(String urlspec)
- throws DeploymentException, MalformedURLException
- {
- if( server == null )
- throw new DeploymentException("The MainDeployer has been unregistered");
-
- URL url;
- try
- {
- url = new URL(urlspec);
- }
- catch (MalformedURLException e)
- {
- File file = new File(urlspec);
- url = file.toURL();
- }
-
- deploy(url);
- }
-
- /**
- * The <code>deploy</code> method deploys a package identified by a URL
- *
- * @param url an <code>URL</code> value
- * @jmx.managed-operation
- */
- public void deploy(URL url) throws DeploymentException
- {
- DeploymentInfo sdi = getDeployment(url);
- // if it does not exist create a new deployment
- if (sdi == null)
- {
- sdi = new DeploymentInfo(url, null, getServer());
- deploy(sdi);
- }
- if( sdi.state != DeploymentState.STARTED )
- checkIncompleteDeployments();
- }
-
- /**
- * The <code>deploy</code> method deploys a package represented by a DeploymentInfo object.
- *
- * @param deployment a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- * @jmx.managed-operation
- */
- public void deploy(DeploymentInfo deployment)
- throws DeploymentException
- {
- // If we are already deployed return
- if (isDeployed(deployment.url))
- {
- log.info("Package: " + deployment.url + " is already deployed");
- return;
- }
- log.debug("Starting deployment of package: " + deployment.url);
-
- boolean inited = false;
- try
- {
- inited = init(deployment);
- }
- catch (Throwable t)
- {
- log.error("Could not initialise deployment: " + deployment.url, t);
- DeploymentException.rethrowAsDeploymentException("Could not initialise deployment: " + deployment.url, t);
- }
- if ( inited )
- {
- create(deployment);
- start(deployment);
- log.debug("Deployed package: " + deployment.url);
- } // end of if ()
- else
- {
- log.debug("Deployment of package: " + deployment.url + " is waiting for an appropriate deployer.");
- } // end of else
- }
-
-
- /**
- * The <code>init</code> method is the first internal deployment step.
- * The tasks are to copy the code if necessary,
- * set up classloaders, and identify the deployer for the package.
- *
- * @param deployment a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- private boolean init(DeploymentInfo deployment) throws DeploymentException
- {
- // If we are already deployed return
- if (isDeployed(deployment.url))
- {
- log.info("Package: " + deployment.url + " is already deployed");
- return false;
- }
- log.debug("Starting deployment (init step) of package at: " + deployment.url);
- try
- {
- // Create a local copy of that File, the sdi keeps track of the copy directory
- if (deployment.localUrl == null)
- {
- makeLocalCopy(deployment);
- URL[] localCl = new URL[]{deployment.localUrl};
- deployment.localCl = new URLClassLoader(localCl);
- }
-
- // What deployer is able to deploy this file
- findDeployer(deployment);
-
- if(deployment.deployer == null)
- {
- deployment.state = DeploymentState.INIT_WAITING_DEPLOYER;
- log.debug("deployment waiting for deployer: " + deployment.url);
- synchronized (waitingDeployments)
- {
- if (waitingDeployments.contains(deployment) == false)
- waitingDeployments.add(deployment);
- }
- return false;
- }
- deployment.state = DeploymentState.INIT_DEPLOYER;
- //we have the deployer, continue deployment.
- deployment.deployer.init(deployment);
- // initialize the unified classloaders for this deployment
- deployment.createClassLoaders();
- deployment.state = DeploymentState.INITIALIZED;
-
- // Add the deployment to the map so we can detect circular deployments
- synchronized (deploymentList)
- {
- deploymentMap.put(deployment.url, deployment);
- }
-
- // create subdeployments as needed
- parseManifestLibraries(deployment);
-
- log.debug("found " + deployment.subDeployments.size() + " subpackages of " + deployment.url);
- // get sorted subDeployments
- ArrayList sortedSubs = new ArrayList(deployment.subDeployments);
- Collections.sort(sortedSubs, infoSorter);
- for (Iterator lt = sortedSubs.listIterator(); lt.hasNext();)
- {
- init((DeploymentInfo) lt.next());
- }
- }
- catch (Exception e)
- {
- deployment.state = DeploymentState.FAILED;
- DeploymentException.rethrowAsDeploymentException("exception in init of " + deployment.url, e);
- }
- finally
- {
- // whether you do it or not, for the autodeployer
- try
- {
- URL url = deployment.localUrl == null ? deployment.url : deployment.localUrl;
-
- long lastModified = -1;
-
- if (url.getProtocol().equals("file"))
- lastModified = new File(url.getFile()).lastModified();
- else
- lastModified = url.openConnection().getLastModified();
-
- deployment.lastModified=lastModified;
- deployment.lastDeployed=System.currentTimeMillis();
- }
- catch (IOException ignore)
- {
- deployment.lastModified=System.currentTimeMillis();
- deployment.lastDeployed=System.currentTimeMillis();
- }
-
- synchronized (deploymentList)
- {
- // Do we watch it? Watch only urls outside our copy directory.
- if (!inLocalCopyDir(deployment.url) && deploymentList.contains(deployment) == false)
- {
- deploymentList.add(deployment);
- log.debug("Watching new file: " + deployment.url);
- }
- }
- }
- return true;
- }
-
- /**
- * The <code>create</code> method is the second internal deployment step.
- * It should set up all information not
- * requiring other components. for instance, the ejb Container is created,
- * and the proxy bound into jndi.
- *
- * @param deployment a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- private void create(DeploymentInfo deployment) throws DeploymentException
- {
- log.debug("create step for deployment " + deployment.url);
- try
- {
- ArrayList sortedSubs = new ArrayList(deployment.subDeployments);
- Collections.sort(sortedSubs, infoSorter);
- for (Iterator lt = sortedSubs.listIterator(); lt.hasNext();)
- {
- create((DeploymentInfo) lt.next());
- }
- deployment.state = DeploymentState.CREATE_SUBDEPLOYMENTS;
-
- // Deploy this SDI, if it is a deployable type
- if (deployment.deployer != null)
- {
- try
- {
- deployment.state = DeploymentState.CREATE_DEPLOYER;
- deployment.deployer.create(deployment);
- // See if all mbeans are created...
- deployment.state = DeploymentState.CREATED;
- deployment.status="Created";
- log.debug("Done with create step of deploying " + deployment.shortName);
- }
- catch (Throwable t)
- {
- log.error("Could not create deployment: " + deployment.url, t);
- throw t;
- }
- }
- else
- {
- log.debug("Still no deployer for package in create step: " + deployment.shortName);
- } // end of else
- }
- catch (Throwable t)
- {
- log.trace("could not create deployment: " + deployment.url, t);
- deployment.status = "Deployment FAILED reason: " + t.getMessage();
- deployment.state = DeploymentState.FAILED;
- DeploymentException.rethrowAsDeploymentException("Could not create deployment: " + deployment.url, t);
- }
- }
-
- /**
- * The <code>start</code> method is the third and final internal deployment step.
- * The purpose is to set up relationships between components.
- * for instance, ejb links are set up here.
- *
- * @param deployment a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- private void start(DeploymentInfo deployment) throws DeploymentException
- {
- deployment.status = "Starting";
- log.debug("Begin deployment start " + deployment.url);
- try
- {
- ArrayList sortedSubs = new ArrayList(deployment.subDeployments);
- Collections.sort(sortedSubs, infoSorter);
- for (Iterator lt = sortedSubs.listIterator(); lt.hasNext();)
- {
- start((DeploymentInfo) lt.next());
- }
- deployment.state = DeploymentState.START_SUBDEPLOYMENTS;
-
- // Deploy this SDI, if it is a deployable type
- if (deployment.deployer != null)
- {
- try
- {
- deployment.state = DeploymentState.START_DEPLOYER;
- deployment.deployer.start(deployment);
- // See if all mbeans are started...
- Object[] args = {deployment, DeploymentState.STARTED};
- String[] sig = {"org.jboss.deployment.DeploymentInfo",
- "org.jboss.deployment.DeploymentState"};
- server.invoke(serviceController, "validateDeploymentState",args, sig);
- deployment.status = "Deployed";
- log.debug("End deployment start on package: "+ deployment.shortName);
- }
- catch (Throwable t)
- {
- log.error("Could not start deployment: " + deployment.url, t);
- throw t;
- }
- }
- else
- {
- log.debug("Still no deployer for package in start step: " + deployment.shortName);
- } // end of else
- }
- catch (Throwable t)
- {
- log.trace("could not start deployment: " + deployment.url, t);
- deployment.state = DeploymentState.FAILED;
- deployment.status = "Deployment FAILED reason: " + t.getMessage();
- DeploymentException.rethrowAsDeploymentException("Could not create deployment: " + deployment.url, t);
- }
- }
-
- /**
- * The <code>findDeployer</code> method attempts to find a deployer for the DeploymentInfo
- * supplied as a parameter.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- */
- private void findDeployer(DeploymentInfo sdi)
- {
- // If there is already a deployer use it
- if( sdi.deployer != null )
- {
- log.debug("using existing deployer "+sdi.deployer);
- return;
- }
-
- //
- // To deploy directories of beans one should just name the directory
- // mybean.ear/bla...bla, so that the directory gets picked up by the right deployer
- //
- synchronized(deployers)
- {
- for (Iterator iterator = deployers.iterator(); iterator.hasNext(); )
- {
- SubDeployer deployer = (SubDeployer) iterator.next();
- if (deployer.accepts(sdi))
- {
- sdi.deployer = deployer;
- log.debug("using deployer "+deployer);
- return;
- }
- }
- }
- log.debug("No deployer found for url: " + sdi.url);
- }
-
- /**
- * The <code>parseManifestLibraries</code> method looks into the manifest for classpath
- * goo, and tries to deploy referenced packages.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- */
- private void parseManifestLibraries(DeploymentInfo sdi)
- {
- String classPath = null;
-
- Manifest mf = sdi.getManifest();
-
- if( mf != null )
- {
- Attributes mainAttributes = mf.getMainAttributes();
- classPath = mainAttributes.getValue(Attributes.Name.CLASS_PATH);
- }
-
- if (classPath != null)
- {
- StringTokenizer st = new StringTokenizer(classPath);
- log.debug("resolveLibraries: "+classPath);
-
- while (st.hasMoreTokens())
- {
- URL lib = null;
- String tk = st.nextToken();
- log.debug("new manifest entry for sdi at "+sdi.shortName+" entry is "+tk);
-
- try
- {
- if (sdi.isDirectory)
- {
- File parentDir = new File(sdi.url.getPath()).getParentFile();
- lib = new File(parentDir, tk).toURL();
- }
- else
- {
- lib = new URL(sdi.url, tk);
- }
-
- // Only deploy this if it is not already being deployed
- if ( deploymentMap.containsKey(lib) == false )
- {
- /* Test that the only deployer for this is the JARDeployer.
- Any other type of deployment cannot be initiated through
- a manifest reference.
- */
- DeploymentInfo mfRef = new DeploymentInfo(lib, null, getServer());
- makeLocalCopy(mfRef);
- URL[] localURL = {mfRef.localUrl};
- mfRef.localCl = new java.net.URLClassLoader(localURL);
- findDeployer(mfRef);
- SubDeployer deployer = mfRef.deployer;
- if(deployer != null && (deployer instanceof JARDeployer) == false)
- {
- // Its a non-jar deployment that must be deployed seperately
- log.warn("Found non-jar deployer for " + tk + ": " + deployer);
- }
-
- // add the library
- sdi.addLibraryJar(lib);
- }
- }
- catch (Exception ignore)
- {
- log.debug("The manifest entry in "+sdi.url+" references URL "+lib+
- " which could not be opened, entry ignored", ignore);
- }
- }
- }
- }
-
- /**
- * Downloads the jar file or directory the src URL points to.
- * In case of directory it becomes packed to a jar file.
- */
- private void makeLocalCopy(DeploymentInfo sdi)
- {
- try
- {
- if (sdi.url.getProtocol().equals("file") && (!copyFiles || sdi.isDirectory))
- {
- // If local copies have been disabled, do nothing
- sdi.localUrl = sdi.url;
- return;
- }
- // Are we already in the localCopyDir?
- else if (inLocalCopyDir(sdi.url))
- {
- sdi.localUrl = sdi.url;
- return;
- }
- else
- {
- String shortName = sdi.shortName;
- File localFile = File.createTempFile("tmp", shortName, tempDir);
- sdi.localUrl = localFile.toURL();
- copy(sdi.url, localFile);
- }
- }
- catch (Exception e)
- {
- log.error("Could not make local copy for " + sdi.url, e);
- }
- }
-
- private boolean inLocalCopyDir(URL url)
- {
- int i = 0;
- String urlTest = url.toString();
- if( urlTest.startsWith("jar:") )
- i = 4;
-
- return urlTest.startsWith(tempDirString, i);
- }
-
- protected void copy(URL src, File dest) throws IOException
- {
- log.debug("Copying " + src + " -> " + dest);
-
- // Validate that the dest parent directory structure exists
- File dir = dest.getParentFile();
- if (!dir.exists())
- {
- boolean created = dir.mkdirs();
- if( created == false )
- throw new IOException("mkdirs failed for: "+dir.getAbsolutePath());
- }
-
- // Remove any existing dest content
- if( dest.exists() == true )
- {
- boolean deleted = Files.delete(dest);
- if( deleted == false )
- throw new IOException("delete of previous content failed for: "+dest.getAbsolutePath());
- }
-
- if (src.getProtocol().equals("file"))
- {
- File srcFile = new File(src.getFile());
- if (srcFile.isDirectory())
- {
- log.debug("Making zip copy of: " + srcFile);
- // make a jar archive of the directory
- OutputStream out = new BufferedOutputStream(new FileOutputStream(dest));
- JarUtils.jar(out, srcFile.listFiles());
- out.close();
- return;
- }
- }
-
- InputStream in = new BufferedInputStream(src.openStream());
- OutputStream out = new BufferedOutputStream(new FileOutputStream(dest));
- Streams.copy(in, out);
- out.flush();
- out.close();
- in.close();
- }
-
- /**
- * The <code>start</code> method starts a package identified by a URL
- *
- * @param urlspec an <code>URL</code> value
- * @jmx.managed-operation
- */
- public void start(String urlspec)
- throws DeploymentException, MalformedURLException
- {
- DeploymentInfo sdi = getDeployment(new URL(urlspec));
- if (sdi!= null)
- {
- start(sdi);
- }
- }
-
- /**
- * The <code>stop</code> method stops a package identified by a URL
- *
- * @param urlspec an <code>URL</code> value
- * @jmx.managed-operation
- */
- public void stop(String urlspec)
- throws DeploymentException, MalformedURLException
- {
- DeploymentInfo sdi = getDeployment(new URL(urlspec));
- if (sdi!= null)
- {
- stop(sdi);
- }
- }
-
- /**
- * The <code>isDeployed</code> method tells you if a package identified by a string
- * representation of a URL is currently deployed.
- *
- * @param url a <code>String</code> value
- * @return a <code>boolean</code> value
- * @exception MalformedURLException if an error occurs
- * @jmx.managed-operation
- */
- public boolean isDeployed(String url)
- throws MalformedURLException
- {
- return isDeployed(new URL(url));
- }
-
- /**
- * The <code>isDeployed</code> method tells you if a packaged identified by
- * a URL is deployed.
- * @param url an <code>URL</code> value
- * @return a <code>boolean</code> value
- * @jmx.managed-operation
- */
- public boolean isDeployed(URL url)
- {
- DeploymentInfo di = getDeployment(url);
- if (di == null)
- {
- return false;
- } // end of if ()
- return di.state == DeploymentState.STARTED;
- }
-
- /**
- * The <code>getDeployment</code> method returns the DeploymentInfo
- * object for the URL supplied.
- *
- * @param url an <code>URL</code> value
- * @return a <code>DeploymentInfo</code> value
- * @jmx.managed-operation
- */
- public DeploymentInfo getDeployment(URL url)
- {
- synchronized (deploymentList)
- {
- return (DeploymentInfo) deploymentMap.get(url);
- }
- }
-
- /**
- * The <code>getWatchUrl</code> method returns the URL that, when modified,
- * indicates that a redeploy is needed.
- *
- * @param url an <code>URL</code> value
- * @return a <code>URL</code> value
- * @jmx.managed-operation
- */
- public URL getWatchUrl(URL url)
- {
- DeploymentInfo info = getDeployment(url);
- return info == null ? null : info.watch;
- }
-
- /** Check the current deployment states and generate a IncompleteDeploymentException
- * if there are mbeans waiting for depedencies.
- * @exception IncompleteDeploymentException
- * @jmx.managed-operation
- */
- public void checkIncompleteDeployments() throws DeploymentException
- {
- try
- {
- Collection waitingForClasses = new HashSet();
- Collection waitingForDepends = (Collection)server.invoke(serviceController,
- "listIncompletelyDeployed",
- new Object[] {},
- new String[] {});
- Collection allServices = (Collection) server.invoke(serviceController,
- "listDeployed",
- new Object[] {},
- new String[] {});
-
- // Weed services that are waiting for other deployments
- Collection rootCause = new HashSet(waitingForDepends);
- Collection missing = new HashSet();
- for (Iterator i = rootCause.iterator(); i.hasNext();)
- {
- ServiceContext ctx = (ServiceContext) i.next();
- for (Iterator j = ctx.iDependOn.iterator(); j.hasNext(); )
- {
- ServiceContext dependee = (ServiceContext) j.next();
- if (dependee.state != ServiceContext.RUNNING)
- {
- // Add missing mbean
- if (allServices.contains(dependee) == false)
- missing.add(dependee);
- // We are not a root cause
- i.remove();
- break;
- }
- }
- }
- // Add missing mbeans to the root cause
- rootCause.addAll(missing);
-
- IncompleteDeploymentException ide = new IncompleteDeploymentException(
- waitingForClasses,
- waitingForDepends,
- rootCause,
- listIncompletelyDeployed(),
- listWaitingForDeployer());
- if (!ide.isEmpty())
- {
- throw ide;
- } // end of if ()
- }
- catch (JMException jme)
- {
- throw new DeploymentException(JMXExceptionDecoder.decode(jme));
- } // end of try-catch
- }
-
- /**
- * @param parent
- * @param map
- */
- private void fillParentAndChildrenSDI(DeploymentInfo parent, Map map)
- {
- Set subDeployments = parent.subDeployments;
- Iterator it = subDeployments.iterator();
- while (it.hasNext())
- {
- DeploymentInfo child = (DeploymentInfo) it.next();
- SerializableDeploymentInfo sdichild = returnSDI(child, map);
- sdichild.parent = returnSDI(parent, map);
- sdichild.parent.subDeployments.add(sdichild);
- fillParentAndChildrenSDI(child, map);
- }
- }
-
- private SerializableDeploymentInfo returnSDI(DeploymentInfo di, Map map)
- {
- SerializableDeploymentInfo sdi = (SerializableDeploymentInfo) map.get(di.url);
- if( sdi == null )
- {
- sdi = new SerializableDeploymentInfo(di);
- map.put(di.url, sdi);
- }
- return sdi;
- }
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/MainDeployer.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployer.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,35 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/** Constants for MainDeployers
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public interface MainDeployerConstants
-{
- /** The JMX notification type sent when a deployer is added */
- public static final String ADD_DEPLOYER = "org.jboss.deployment.MainDeployer.addDeployer";
- /** The JMX notification type sent when a deployer is removed */
- public static final String REMOVE_DEPLOYER = "org.jboss.deployment.MainDeployer.removeDeployer";
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerConstants.java
___________________________________________________________________
Name: svn:executable
+ *
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,250 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.io.File;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.Collection;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceMBean;
-
-/**
- * MainDeployer MBean interface
- *
- * @version $Revision$
- */
-public interface MainDeployerMBean extends
- ServiceMBean, DeployerMBean, MainDeployerConstants
-{
- /** The default ObjectName */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:service=MainDeployer");
-
- // Attributes ----------------------------------------------------
-
- /** Flag indicating whether directory content will be deployed.
- * The default value is taken from the jboss.deploy.localcopy system property. */
- boolean getCopyFiles();
- void setCopyFiles(boolean copyFiles);
-
- /** The path to the local tmp directory */
- File getTempDir();
- void setTempDir(File tempDir);
-
- /** The enhanced suffix order */
- String[] getEnhancedSuffixOrder();
- void setEnhancedSuffixOrder(String[] enhancedSuffixOrder);
-
- /** The ObjectName of the ServiceController */
- void setServiceController(ObjectName serviceController);
-
- /** The path to the local tmp directory in String form */
- String getTempDirString();
-
- /** The ordering of the deployment suffixes */
- String[] getSuffixOrder();
-
- // Operations ----------------------------------------------------
-
- /**
- * The <code>listDeployed</code> method returns a collection of
- * DeploymemtInfo objects for the currently deployed packages.
- * @return a <code>Collection</code> value
- */
- Collection listDeployed();
-
- /**
- * The <code>listDeployedModules</code> method returns a collection of
- * SerializableDeploymentInfo objects for the currently deployed packages.
- * @return a <code>Collection</code> value
- */
- Collection listDeployedModules();
-
- /**
- * Describe <code>listDeployedAsString</code> method here.
- * @return a <code>String</code> value
- */
- String listDeployedAsString();
-
- /**
- * The <code>listIncompletelyDeployed</code> method returns a list of
- * packages that have not deployed completely. The toString method will
- * include any exception in the status field.
- * @return a <code>Collection</code> value
- */
- Collection listIncompletelyDeployed();
-
- /**
- * The <code>listWaitingForDeployer</code> method returns a collection of
- * the packages that currently have no identified deployer.
- * @return a <code>Collection</code> value
- */
- Collection listWaitingForDeployer();
-
- /**
- * The <code>addDeployer</code> method registers a deployer with the
- * main deployer. Any waiting packages are tested to see if the new
- * deployer will deploy them.
- * @param deployer a <code>SubDeployer</code> value
- */
- void addDeployer(SubDeployer deployer);
-
- /**
- * The <code>removeDeployer</code> method unregisters a deployer with the
- * MainDeployer. Deployed packages deployed with this deployer are undeployed.
- * @param deployer a <code>SubDeployer</code> value
- */
- void removeDeployer(SubDeployer deployer);
-
- /**
- * The <code>listDeployers</code> method returns a collection of ObjectNames
- * of deployers registered with the MainDeployer.
- * @return a <code>Collection<ObjectName></code> value
- */
- Collection listDeployers();
-
- /**
- * The <code>shutdown</code> method undeploys all deployed packages
- * in reverse order of their deployement.
- */
- void shutdown();
-
- /**
- * Describe <code>redeploy</code> method here.
- * @param urlspec a <code>String</code> value
- * @exception DeploymentException if an error occurs
- * @exception java.net.MalformedURLException if an error occurs
- */
- void redeploy(String urlspec) throws DeploymentException, MalformedURLException;
-
- /**
- * Describe <code>redeploy</code> method here.
- * @param url an <code>URL</code> value
- * @exception DeploymentException if an error occurs
- */
- void redeploy(URL url) throws DeploymentException;
-
- /**
- * Describe <code>redeploy</code> method here.
- * @param sdi a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- */
- void redeploy(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>undeploy</code> method undeploys a package identified by a URL
- * @param url an <code>URL</code> value
- */
- void undeploy(URL url) throws DeploymentException;
-
- /**
- * The <code>undeploy</code> method undeploys a package identified by a string representation of a URL.
- * @param urlspec a <code>String</code> value
- * @exception java.net.MalformedURLException if an error occurs
- */
- void undeploy(String urlspec) throws DeploymentException, MalformedURLException;
-
- /**
- * The <code>undeploy</code> method undeploys a package represented by a DeploymentInfo object.
- * @param di a <code>DeploymentInfo</code> value
- */
- void undeploy(DeploymentInfo di);
-
- /**
- * The <code>deploy</code> method deploys a package identified by a string representation of a URL.
- * @param urlspec a <code>String</code> value
- * @exception java.net.MalformedURLException if an error occurs
- */
- void deploy(String urlspec) throws DeploymentException, MalformedURLException;
-
- /**
- * The <code>deploy</code> method deploys a package identified by a URL
- * @param url an <code>URL</code> value
- */
- void deploy(URL url) throws DeploymentException;
-
- /**
- * The <code>deploy</code> method deploys a package represented by a DeploymentInfo object.
- * @param deployment a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- */
- void deploy(DeploymentInfo deployment) throws DeploymentException;
-
- /**
- * The <code>start</code> method starts a package identified by a URL
- * @param urlspec an URL string value
- * @jmx.managed-operation
- */
- public void start(String urlspec) throws DeploymentException, MalformedURLException;
-
- /**
- * The <code>stop</code> method stop a package identified by a URL
- * @param urlspec an URL string value
- * @jmx.managed-operation
- */
- public void stop(String urlspec) throws DeploymentException, MalformedURLException;
-
- /**
- * The <code>isDeployed</code> method tells you if a package identified
- * by a string representation of a URL is currently deployed.
- * @param url a <code>String</code> value
- * @return a <code>boolean</code> value
- * @exception java.net.MalformedURLException if an error occurs
- */
- boolean isDeployed(String url) throws MalformedURLException;
-
- /**
- * The <code>isDeployed</code> method tells you if a packaged identified
- * by a URL is deployed.
- * @param url an <code>URL</code> value
- * @return a <code>boolean</code> value
- */
- boolean isDeployed(URL url);
-
- /**
- * The <code>getDeployment</code> method returns the DeploymentInfo object
- * for the URL supplied.
- * @param url an <code>URL</code> value
- * @return a <code>DeploymentInfo</code> value
- */
- DeploymentInfo getDeployment(URL url);
-
- /**
- * The <code>getWatchUrl</code> method returns the URL that,
- * when modified, indicates that a redeploy is needed.
- * @param url an <code>URL</code> value
- * @return a <code>URL</code> value
- */
- URL getWatchUrl(URL url);
-
- /**
- * Check the current deployment states and generate an
- * IncompleteDeploymentException if there are mbeans
- * waiting for depedencies.
- * @exception IncompleteDeploymentException
- */
- void checkIncompleteDeployments() throws DeploymentException;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/MainDeployerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.net.URL;
-
-import org.jboss.xb.binding.ObjectModelFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-
-/**
- * A simple subdeployer that deploys a managed object after parsing the
- * deployment's xml file using an ObjectModelFactory.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public abstract class ObjectModelFactorySimpleSubDeployerSupport extends SimpleSubDeployerSupport
-{
- /**
- * Get the object model factory
- *
- * @return the object model factory
- */
- public abstract ObjectModelFactory getObjectModelFactory();
-
- protected void parseMetaData(DeploymentInfo di, URL url) throws DeploymentException
- {
- try
- {
- Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
- ObjectModelFactory factory = getObjectModelFactory();
- Object root = null;
- di.metaData = unmarshaller.unmarshal(url.toString(), factory, root);
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error parsing meta data " + url, t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/ObjectModelFactorySimpleSubDeployerSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SARDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SARDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SARDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,719 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.util.ArrayList;
-import java.util.Enumeration;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-import java.util.jar.JarEntry;
-import java.util.jar.JarFile;
-
-import javax.management.MBeanServer;
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-
-import org.jboss.mx.loading.LoaderRepositoryFactory;
-import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.net.protocol.URLLister;
-import org.jboss.net.protocol.URLListerFactory;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.system.server.ServerConfig;
-import org.jboss.system.server.ServerConfigLocator;
-import org.jboss.util.StringPropertyReplacer;
-import org.jboss.util.Strings;
-import org.jboss.util.stream.Streams;
-import org.jboss.util.xml.JBossEntityResolver;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.xml.sax.InputSource;
-
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
-
-/**
- * This is the main Service Deployer API.
- *
- * @see org.jboss.system.Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:David.Maplesden at orion.co.nz">David Maplesden</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:sacha.labourey at cogito-info.ch">Sacha Labourey</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis<a/>
- * @version $Revision$
- */
-public class SARDeployer extends SubDeployerSupport
- implements SARDeployerMBean
-{
- /** The suffixes we accept, along with their relative order */
- private static final String[] DEFAULT_ENHANCED_SUFFIXES = new String[] {
- "050:.deployer",
- "050:-deployer.xml",
- "150:.sar",
- "150:-service.xml"
- };
-
- /** The deployment descriptor to look for */
- private static final String JBOSS_SERVICE = "META-INF/jboss-service.xml";
-
- /** A proxy to the ServiceController. */
- private ServiceControllerMBean serviceController;
-
- /** The server data directory. */
- private File dataDir;
-
- /** The server configuration base URL. For example,
- file:/<jboss_dist_root>/server/default. Relative service
- descriptor codebase elements are relative to this URL.
- */
- private URL serverHomeURL;
-
- /** A HashMap<ObjectName, DeploymentInfo> for the deployed services */
- private HashMap serviceDeploymentMap = new HashMap();
-
- /**
- * A Map<String, List<String>> of the suffix to accepted archive META-INF descriptor name
- * @todo externalize this
- */
- private Map suffixToDescriptorMap = new ConcurrentReaderHashMap();
-
- /** A flag indicating if the parser used for the service descriptor should be configured for namespaces */
- private boolean useNamespaceAwareParser;
-
- /**
- * Default CTOR
- */
- public SARDeployer()
- {
- setEnhancedSuffixes(DEFAULT_ENHANCED_SUFFIXES);
- // Add the .har to META-INF/{jboss-service.xml,hibernate-service.xml} mapping
- ArrayList tmp = new ArrayList();
- tmp.add(JBOSS_SERVICE);
- tmp.add("META-INF/hibernate-service.xml");
- suffixToDescriptorMap.put(".har", tmp);
- }
-
- public boolean isUseNamespaceAwareParser()
- {
- return useNamespaceAwareParser;
- }
-
- public void setUseNamespaceAwareParser(boolean useNamespaceAwareParser)
- {
- this.useNamespaceAwareParser = useNamespaceAwareParser;
- }
-
- /**
- * Get the associated service DeploymentInfo if found, null otherwise
- *
- * @param serviceName a service object name
- * @return The associated service DeploymentInfo if found, null otherwise
- * @jmx.managed-operation
- */
- public DeploymentInfo getService(ObjectName serviceName)
- {
- DeploymentInfo di = null;
- synchronized( serviceDeploymentMap )
- {
- di = (DeploymentInfo) serviceDeploymentMap.get(serviceName);
- }
- return di;
- }
-
- /**
- * Describe <code>init</code> method here.
- *
- * @param di a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- * @jmx.managed-operation
- */
- public void init(DeploymentInfo di)
- throws DeploymentException
- {
- try
- {
- if (di.url.getPath().endsWith("/"))
- {
- // the URL is a unpacked collection, watch the deployment descriptor
- di.watch = new URL(di.url, JBOSS_SERVICE);
- }
- else
- {
- // just watch the original URL
- di.watch = di.url;
- }
-
- // Get the document if not already present
- parseDocument(di);
-
- // Check for a custom loader-repository for scoping
- NodeList loaders = di.document.getElementsByTagName("loader-repository");
- if( loaders.getLength() > 0 )
- {
- Element loader = (Element) loaders.item(0);
- LoaderRepositoryConfig config = LoaderRepositoryFactory.parseRepositoryConfig(loader);
- di.setRepositoryInfo(config);
- }
-
- // In case there is a dependent classpath defined parse it
- parseXMLClasspath(di);
-
- // Copy local directory if local-directory element is present
- NodeList lds = di.document.getElementsByTagName("local-directory");
- log.debug("about to copy " + lds.getLength() + " local directories");
-
- for (int i = 0; i< lds.getLength(); i++)
- {
- Element ld = (Element)lds.item(i);
- String path = ld.getAttribute("path");
- log.debug("about to copy local directory at " + path);
-
- // Get the url of the local copy from the classloader.
- log.debug("copying from " + di.localUrl + path + " -> " + dataDir);
-
- inflateJar(di.localUrl, dataDir, path);
- }
- }
- catch (DeploymentException de)
- {
- throw de;
- }
- catch (Exception e)
- {
- throw new DeploymentException(e);
- }
-
- // invoke super-class initialization
- super.init(di);
- }
-
- /**
- * Describe <code>create</code> method here.
- *
- * @param di a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- * @jmx.managed-operation
- */
- public void create(DeploymentInfo di)
- throws DeploymentException
- {
- try
- {
- // install the MBeans in this descriptor
- log.debug("Deploying SAR, create step: url " + di.url);
-
- // Register the SAR UCL as an mbean so we can use it as the service loader
- ObjectName uclName = di.ucl.getObjectName();
- if( getServer().isRegistered(uclName) == false )
- {
- log.debug("Registering service UCL="+uclName);
- getServer().registerMBean(di.ucl, uclName);
- }
-
- List mbeans = di.mbeans;
- mbeans.clear();
- List descriptorMbeans = serviceController.install(di.document.getDocumentElement(), uclName);
- mbeans.addAll(descriptorMbeans);
-
- // create the services
- for (Iterator iter = di.mbeans.iterator(); iter.hasNext(); )
- {
- ObjectName service = (ObjectName)iter.next();
-
- // The service won't be created until explicitly dependent mbeans are created
- serviceController.create(service);
- synchronized( this.serviceDeploymentMap )
- {
- serviceDeploymentMap.put(service, di);
- }
- }
-
- // Generate a JMX notification for the create stage
- super.create(di);
- }
- catch(DeploymentException e)
- {
- log.debug("create operation failed for package "+ di.url, e);
- destroy(di);
- throw e;
- }
- catch (Exception e)
- {
- log.debug("create operation failed for package "+ di.url, e);
- destroy(di);
- throw new DeploymentException("create operation failed for package "
- + di.url, e);
- }
- }
-
- /**
- * The <code>start</code> method starts all the mbeans in this DeploymentInfo..
- *
- * @param di a <code>DeploymentInfo</code> value
- * @exception DeploymentException if an error occurs
- * @jmx.managed-operation
- */
- public void start(DeploymentInfo di) throws DeploymentException
- {
- log.debug("Deploying SAR, start step: url " + di.url);
- try
- {
- // start the services
-
- for (Iterator iter = di.mbeans.iterator(); iter.hasNext(); )
- {
- ObjectName service = (ObjectName)iter.next();
-
- // The service won't be started until explicitely dependent mbeans are started
- serviceController.start(service);
- }
- // Generate a JMX notification for the start stage
- super.start(di);
- }
- catch (Exception e)
- {
- stop(di);
- destroy(di);
- throw new DeploymentException("start operation failed on package "
- + di.url, e);
- }
- }
-
- /** The stop method invokes stop on the mbeans associatedw ith the deployment
- * in reverse order relative to create.
- *
- * @param di the <code>DeploymentInfo</code> value to stop.
- * @jmx.managed-operation
- */
- public void stop(DeploymentInfo di)
- {
- log.debug("undeploying document " + di.url);
-
- List services = di.mbeans;
- int lastService = services.size();
-
- // stop services in reverse order.
- for (ListIterator i = services.listIterator(lastService); i.hasPrevious();)
- {
- ObjectName name = (ObjectName)i.previous();
- log.debug("stopping mbean " + name);
- try
- {
- serviceController.stop(name);
- }
- catch (Exception e)
- {
- log.error("Could not stop mbean: " + name, e);
- } // end of try-catch
- }
-
- // Generate a JMX notification for the stop stage
- try
- {
- super.stop(di);
- }
- catch(Exception ignore)
- {
- }
- }
-
- /** The destroy method invokes destroy on the mbeans associated with
- * the deployment in reverse order relative to create.
- *
- * @param di a <code>DeploymentInfo</code> value
- * @jmx.managed-operation
- */
- public void destroy(DeploymentInfo di)
- {
- List services = di.mbeans;
- int lastService = services.size();
-
- for (ListIterator i = services.listIterator(lastService); i.hasPrevious();)
- {
- ObjectName name = (ObjectName)i.previous();
- log.debug("destroying mbean " + name);
- synchronized( serviceDeploymentMap )
- {
- serviceDeploymentMap.remove(name);
- }
-
- try
- {
- serviceController.destroy(name);
- }
- catch (Exception e)
- {
- log.error("Could not destroy mbean: " + name, e);
- } // end of try-catch
- }
-
- for (ListIterator i = services.listIterator(lastService); i.hasPrevious();)
- {
- ObjectName name = (ObjectName)i.previous();
- log.debug("removing mbean " + name);
- try
- {
- serviceController.remove(name);
- }
- catch (Exception e)
- {
- log.error("Could not remove mbean: " + name, e);
- } // end of try-catch
- }
-
- // Unregister the SAR UCL
- try
- {
- ObjectName uclName = di.ucl.getObjectName();
- if( getServer().isRegistered(uclName) == true )
- {
- log.debug("Unregistering service UCL="+uclName);
- getServer().unregisterMBean(uclName);
- }
- }
- catch(Exception ignore)
- {
- }
-
- // Generate a JMX notification for the destroy stage
- try
- {
- super.destroy(di);
- }
- catch(Exception ignore)
- {
- }
- }
-
- // ServiceMBeanSupport overrides --------------------------------
-
- /**
- * The startService method gets the mbeanProxies for MainDeployer
- * and ServiceController, used elsewhere.
- *
- * @exception Exception if an error occurs
- */
- protected void startService() throws Exception
- {
- super.startService();
-
- // get the controller proxy
- serviceController = (ServiceControllerMBean)
- MBeanProxyExt.create(ServiceControllerMBean.class,
- ServiceControllerMBean.OBJECT_NAME, server);
-
- // Get the data directory, install url & library url
- ServerConfig config = ServerConfigLocator.locate();
- dataDir = config.getServerDataDir();
- serverHomeURL = config.getServerHomeURL();
- }
-
- /**
- * This method stops all the applications in this server.
- */
- protected void stopService() throws Exception
- {
- // deregister with MainDeployer
- super.stopService();
-
- // Help GC
- serviceController = null;
- serverHomeURL = null;
- dataDir = null;
- }
-
-
- protected ObjectName getObjectName(MBeanServer server, ObjectName name)
- throws MalformedObjectNameException
- {
- return name == null ? OBJECT_NAME : name;
- }
-
- // Protected -----------------------------------------------------
-
- protected File[] listFiles(final String urlspec) throws Exception
- {
- URL url = Strings.toURL(urlspec);
-
- // url is already canonical thanks to Strings.toURL
- File dir = new File(url.getFile());
-
- File[] files = dir.listFiles(new java.io.FileFilter()
- {
- public boolean accept(File pathname)
- {
- String name = pathname.getName().toLowerCase();
- return (name.endsWith(".jar") || name.endsWith(".zip"));
- }
- });
-
- return files;
- }
-
- /**
- * @param di
- * @throws Exception
- */
- protected void parseXMLClasspath(DeploymentInfo di)
- throws Exception
- {
- ArrayList classpath = new ArrayList();
- URLListerFactory listerFactory = new URLListerFactory();
-
- NodeList children = di.document.getDocumentElement().getChildNodes();
- for (int i = 0; i < children.getLength(); i++)
- {
- if (children.item(i).getNodeType() == Node.ELEMENT_NODE)
- {
- Element classpathElement = (Element)children.item(i);
- if (classpathElement.getTagName().equals("classpath"))
- {
- log.debug("Found classpath element: " + classpathElement);
- if (!classpathElement.hasAttribute("codebase"))
- {
- throw new DeploymentException
- ("Invalid classpath element missing codebase: " + classpathElement);
- }
- String codebase = classpathElement.getAttribute("codebase").trim();
- // Replace any system property references like ${x}
- codebase = StringPropertyReplacer.replaceProperties(codebase);
-
- String archives = null;
- if (classpathElement.hasAttribute("archives"))
- {
- archives = classpathElement.getAttribute("archives").trim();
- // Replace any system property references like ${x}
- archives = StringPropertyReplacer.replaceProperties(archives);
- if ("".equals(archives))
- {
- archives = null;
- }
- }
-
- // Convert codebase to a URL
- // "." is resolved relative to the deployment
- // other URLs are resolved relative to SERVER_HOME
- URL codebaseUrl;
- if (".".equals(codebase))
- {
- codebaseUrl = new URL(di.url, "./");
- }
- else
- {
- if (archives != null && codebase.endsWith("/") == false)
- {
- codebase += "/";
- }
- codebaseUrl = new URL(serverHomeURL, codebase);
- }
- log.debug("codebase URL is " + codebaseUrl);
-
- if (archives == null)
- {
- // archives not supplied so add the codebase itself
- classpath.add(codebaseUrl);
- log.debug("added codebase to classpath");
- }
- else
- {
- // obtain a URLLister for the codebase and use it to obtain
- // the list of URLs to add
- log.debug("listing codebase for archives matching " + archives);
- URLLister lister = listerFactory.createURLLister(codebaseUrl);
- log.debug("URLLister class is " + lister.getClass().getName());
- classpath.addAll(lister.listMembers(codebaseUrl, archives));
- }
- } // end of if ()
-
- } // end of if ()
- } //end of for
-
- // Ok, now we've found the list of urls we need... deploy their classes.
- Iterator jars = classpath.iterator();
- while (jars.hasNext())
- {
- URL neededURL = (URL) jars.next();
- di.addLibraryJar(neededURL);
- log.debug("deployed classes for " + neededURL);
- }
- }
-
- /** Parse the META-INF/jboss-service.xml descriptor
- */
- protected void parseDocument(DeploymentInfo di)
- throws Exception
- {
- InputStream stream = null;
- try
- {
- if (di.document == null)
- {
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- factory.setNamespaceAware(useNamespaceAwareParser);
- DocumentBuilder parser = factory.newDocumentBuilder();
- URL docURL = di.localUrl;
- URLClassLoader localCL = di.localCl;
- // Load jboss-service.xml from the jar or directory
- if (di.isXML == false)
- {
- // Check the suffix to descriptor mapping
- String[] descriptors = getDescriptorName(di);
- for(int n = 0; n < descriptors.length; n ++)
- {
- String descriptor = descriptors[n];
- docURL = localCL.findResource(descriptor);
- if( docURL != null )
- {
- // If this is a unpacked deployment, update the watch url
- if (di.url.getPath().endsWith("/"))
- {
- di.watch = new URL(di.url, descriptor);
- log.debug("Updated watch URL to: "+di.watch);
- }
- break;
- }
- }
- // No descriptors, use the default META-INF/jboss-service.xml
- if( docURL == null )
- docURL = localCL.findResource(JBOSS_SERVICE);
- }
- // Validate that the descriptor was found
- if (docURL == null)
- throw new DeploymentException("Failed to find META-INF/jboss-service.xml for archive " + di.shortName);
-
- stream = docURL.openStream();
- InputSource is = new InputSource(stream);
- is.setSystemId(docURL.toString());
- parser.setEntityResolver(new JBossEntityResolver());
- di.document = parser.parse(is);
- }
- else
- {
- log.debug("Using existing deployment.document");
- }
- }
- finally
- {
- // Close the stream to get around "Too many open files"-errors
- try
- {
- stream.close();
- }
- catch (Exception ignore)
- {
- }
- }
- }
-
- /**
- * The <code>inflateJar</code> copies the jar entries
- * from the jar url jarUrl to the directory destDir.
- * It can be used on the whole jar, a directory, or
- * a specific file in the jar.
- *
- * @param url the <code>URL</code> if the directory or entry to copy.
- * @param destDir the <code>File</code> value of the directory in which to
- * place the inflated copies.
- *
- * @exception DeploymentException if an error occurs
- * @exception IOException if an error occurs
- */
- protected void inflateJar(URL url, File destDir, String path)
- throws DeploymentException, IOException
- {
- String filename = url.getFile();
- JarFile jarFile = new JarFile(filename);
- try
- {
- for (Enumeration e = jarFile.entries(); e.hasMoreElements(); )
- {
- JarEntry entry = (JarEntry)e.nextElement();
- String name = entry.getName();
-
- if (path == null || name.startsWith(path))
- {
- File outFile = new File(destDir, name);
- if (!outFile.exists())
- {
- if (entry.isDirectory())
- {
- outFile.mkdirs();
- }
- else
- {
- Streams.copyb(jarFile.getInputStream(entry),
- new FileOutputStream(outFile));
- }
- } // end of if (outFile.exists())
- } // end of if (matches path)
- }
- }
- finally
- {
- jarFile.close();
- }
- }
-
- // Private -------------------------------------------------------
-
- /**
- * Parse the deployment url for its suffix and return a list of the accepted service
- * descriptor names to look for.
- *
- * @param sdi - the sar deployment info
- * @return the array of sar archive/directory relative names of the service descriptor. If
- * there is no suffix to descriptor mapping, the default of {JBOSS_SERVICE} will be
- * returned.
- */
- private String[] getDescriptorName(DeploymentInfo sdi)
- {
- String[] descriptorNames = {JBOSS_SERVICE};
- String shortName = sdi.shortName;
- int dot = shortName.lastIndexOf('.');
- if( dot >= 0 )
- {
- String suffix = shortName.substring(dot);
- List descriptors = (List) suffixToDescriptorMap.get(suffix);
- if( descriptors != null )
- {
- descriptorNames = new String[descriptors.size()];
- descriptors.toArray(descriptorNames);
- }
- }
- return descriptorNames;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SARDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SARDeployer.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SARDeployer.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,46 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface SARDeployerMBean extends SubDeployerExtMBean
-{
- /** The default object name */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:service=ServiceDeployer");
-
- // Operations ----------------------------------------------------
-
- /**
- * Get the associated service DeploymentInfo if found, null otherwise
- *
- * @param serviceName a service object name
- * @return The associated service DeploymentInfo if found, null otherwise
- */
- DeploymentInfo getService(ObjectName serviceName);
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SARDeployerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.net.URL;
-
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
-
-/**
- * A simple subdeployer that deploys a managed object after parsing the
- * deployment's xml file using an SchemaBinding.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public abstract class SchemaBindingSimpleSubDeployerSupport extends SimpleSubDeployerSupport
-{
- /** The unmarshaller factory */
- private UnmarshallerFactory factory = UnmarshallerFactory.newInstance();
-
- /**
- * Get the schema binding
- *
- * @return the schema binding
- */
- public abstract SchemaBinding getSchemaBinding();
-
- protected void parseMetaData(DeploymentInfo di, URL url) throws DeploymentException
- {
- try
- {
- Unmarshaller unmarshaller = factory.newUnmarshaller();
- di.metaData = unmarshaller.unmarshal(url.toString(), getSchemaBinding());
- if (di.metaData == null)
- throw new RuntimeException("The xml " + url + " is not well formed!");
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error parsing meta data " + url, t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SchemaBindingSimpleSubDeployerSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.net.URL;
-
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
-import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
-
-/**
- * A simple subdeployer that deploys a managed object after parsing the
- * deployment's xml file using the SingletonSchemaResolverFactory.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public abstract class SchemaResolverSimpleSubDeployerSupport extends SimpleSubDeployerSupport
-{
- /** The unmarshaller factory */
- private UnmarshallerFactory factory = UnmarshallerFactory.newInstance();
-
- /** The resolver */
- private SchemaBindingResolver resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
-
- protected void parseMetaData(DeploymentInfo di, URL url) throws DeploymentException
- {
- try
- {
- Unmarshaller unmarshaller = factory.newUnmarshaller();
- di.metaData = unmarshaller.unmarshal(url.toString(), resolver);
- if (di.metaData == null)
- throw new RuntimeException("The xml " + url + " is not well formed!");
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error parsing meta data " + url, t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SchemaResolverSimpleSubDeployerSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,134 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-// $Id$
-
-import javax.management.ObjectName;
-import java.io.Serializable;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Date;
-import java.util.List;
-
-/**
- * DeploymentInfo for remote access by the DeploymentManager.
- * It provides a serializable subset of the information available in DeploymentInfo.
- *
- * @author thomas.diesler at jboss.org
- * @version $Revision$
- */
-public class SerializableDeploymentInfo implements Serializable
-{
- /** @since 4.0.2 */
- private static final long serialVersionUID = -3847995513551913798L;
-
- // The initial construction timestamp
- public Date date;
- // The URL identifing this SDI
- public URL url;
- // An optional URL to a local copy of the deployment
- public URL localUrl;
- // The URL used to watch for changes when the deployment is unpacked
- public URL watch;
- // The suffix of the deployment url
- public String shortName;
- // The last system time the deployment inited by the MainDeployer
- public long lastDeployed;
- // Use for "should we redeploy failed"
- public long lastModified;
- // A free form status for the "state" can be Deployed/failed etc etc
- public String status;
- // The current state of the deployment
- public DeploymentState state;
- // The subdeployer that handles the deployment
- public ObjectName deployer;
- // The classpath declared by this xml descriptor, needs <classpath> entry
- public Collection classpath = new ArrayList();
- // The mbeans deployed
- public List mbeans;
- // Anyone can have subdeployments
- public List subDeployments;
- // And the subDeployments have a parent
- public SerializableDeploymentInfo parent;
- // the web root context in case of war file
- public String webContext;
- // An optional URL to the URL of the document loaded
- public URL documentUrl;
- // Is this a stand-alone service descriptor
- public boolean isXML;
- public boolean isScript;
- // Does the deployment url point to a directory
- public boolean isDirectory;
- // Can contain the MBean that is created through the deployment
- public ObjectName deployedObject;
-
- // Constructors *****************************************************************************************************
-
- /**
- * Construct this object from a DeploymentInfo
- */
- public SerializableDeploymentInfo(DeploymentInfo info)
- {
- this.date = info.date;
- this.url = info.url;
- this.localUrl = info.localUrl;
- this.watch = info.watch;
- this.shortName = info.shortName;
- this.lastDeployed = info.lastDeployed;
- this.lastModified = info.lastModified;
- this.status = info.status;
- this.state = info.state;
- this.deployer = info.deployer.getServiceName();
- this.classpath = info.classpath;
- this.mbeans = info.mbeans;
- this.webContext = info.webContext;
- this.documentUrl = info.documentUrl;
- this.isXML = info.isXML;
- this.isScript = info.isScript;
- this.isDirectory = info.isDirectory;
- this.deployedObject = info.deployedObject;
-
- // we do these in a second iteration
- this.parent = null;
- this.subDeployments = new ArrayList();
- }
-
- /**
- * Returns a string representation of the object.
- */
- public String toString()
- {
- StringBuffer s = new StringBuffer(super.toString());
- s.append(" { url=" + url + " }\n");
- s.append(" deployer: " + deployer + "\n");
- s.append(" status: " + status + "\n");
- s.append(" state: " + state + "\n");
- s.append(" watch: " + watch + "\n");
- s.append(" lastDeployed: " + lastDeployed + "\n");
- s.append(" lastModified: " + lastModified + "\n");
- s.append(" mbeans: " + mbeans + "\n");
- s.append(" }\n");
- return s.toString();
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SerializableDeploymentInfo.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,408 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.io.File;
-import java.net.URL;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.system.ServiceControllerMBean;
-
-/**
- * A simple subdeployer that deploys a managed object after parsing the
- * deployment's xml file.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public abstract class SimpleSubDeployerSupport extends SubDeployerSupport
-{
- /** A proxy to the ServiceController. */
- private ServiceControllerMBean serviceController;
-
- /** Whether we registered the classloader */
- private boolean registeredClassLoader = false;
-
- /**
- * Get the package extension for this deployment
- *
- * @return the package extension
- */
- public abstract String getExtension();
-
- /**
- * Get the metadata url
- *
- * @return the meta data url
- */
- public abstract String getMetaDataURL();
-
- /**
- * Get the object name for this deployment
- *
- * @param di the deployment info
- * @return the object name
- */
- public abstract String getObjectName(DeploymentInfo di) throws DeploymentException;
-
- /**
- * Get the deployment class
- *
- * @return the deployment class
- */
- public abstract String getDeploymentClass();
-
- public boolean accepts(DeploymentInfo di)
- {
- String urlStr = di.url.toString();
- String extension = getExtension();
- return urlStr.endsWith(extension) || urlStr.endsWith(extension + '/');
- }
-
- public void init(DeploymentInfo di) throws DeploymentException
- {
- URL url = getMetaDataResource(di);
- parseMetaData(di, url);
- resolveWatch(di, url);
- super.init(di);
- }
-
- public void create(DeploymentInfo di) throws DeploymentException
- {
- determineObjectName(di);
- ObjectName uclName = registerClassLoader(di);
- try
- {
- registerDeployment(di, uclName);
- try
- {
- createService(di);
- try
- {
- super.create(di);
- }
- catch (Throwable t)
- {
- destroyService(di);
- }
- }
- catch (Throwable t)
- {
- unregisterDeployment(di);
- throw t;
- }
- }
- catch (Throwable t)
- {
- unregisterClassLoader(di);
- DeploymentException.rethrowAsDeploymentException("Error creating deployment " + di.url, t);
- }
- }
-
- public void start(DeploymentInfo di) throws DeploymentException
- {
- startService(di);
- try
- {
- super.start(di);
- }
- catch (Throwable t)
- {
- stopService(di);
- DeploymentException.rethrowAsDeploymentException("Error in start for deployment " + di.url, t);
- }
- }
-
- public void stop(DeploymentInfo di) throws DeploymentException
- {
- stopService(di);
- super.stop(di);
- }
-
- public void destroy(DeploymentInfo di) throws DeploymentException
- {
- try
- {
- destroyService(di);
- super.destroy(di);
- }
- finally
- {
- unregisterDeployment(di);
- unregisterClassLoader(di);
- }
- }
-
- public void postRegister(Boolean done)
- {
- super.postRegister(done);
-
- if (done.booleanValue())
- {
- serviceController = (ServiceControllerMBean)
- MBeanProxyExt.create(ServiceControllerMBean.class,
- ServiceControllerMBean.OBJECT_NAME,
- server);
- }
- }
-
- /**
- * Get the url of the meta data resource
- *
- * @param di the deployment info
- * @return the url of the meta data resource
- * @throws DeploymentException for any error
- */
- protected URL getMetaDataResource(DeploymentInfo di) throws DeploymentException
- {
- URL url = di.localCl.findResource(getMetaDataURL());
- if (url == null)
- throw new DeploymentException("Could not find meta data " + getMetaDataURL() + " for deployment " + di.url);
- return url;
- }
-
- /**
- * Parse the meta data
- *
- * @param di the deployment info
- * @param url the location of the meta data
- * @throws DeploymentException for any error
- */
- abstract protected void parseMetaData(DeploymentInfo di, URL url) throws DeploymentException;
-
- /**
- * Resolve the watch url
- *
- * @param di the deployment info
- * @param url the location of the meta data
- * @throws DeploymentException for any error
- */
- protected void resolveWatch(DeploymentInfo di, URL url) throws DeploymentException
- {
- // Assume we watch the main deployment
- di.watch = di.url;
-
- // Unless it is an unpacked directory
- if (di.url.getProtocol().equals("file"))
- {
- File file = new File(di.url.getFile());
- if (file.isDirectory())
- di.watch = url;
- }
- }
-
- /**
- * Determine the object name
- *
- * @param di the deployment info
- * @throws DeploymentException for any error
- */
- protected void determineObjectName(DeploymentInfo di) throws DeploymentException
- {
- String objectName = getObjectName(di);
- try
- {
- di.deployedObject = new ObjectName(objectName);
- }
- catch (MalformedObjectNameException e)
- {
- throw new DeploymentException("INTERNAL ERROR: Bad object name. " + objectName);
- }
- }
-
- /**
- * Register the UCL classloader
- *
- * @param di the deployment info
- * @return the object name of the classloader
- * @throws DeploymentException for any error
- */
- protected ObjectName registerClassLoader(DeploymentInfo di) throws DeploymentException
- {
- ObjectName uclName = null;
- try
- {
- RepositoryClassLoader ucl = di.ucl;
- uclName = ucl.getObjectName();
- if (server.isRegistered(uclName) == false)
- {
- server.registerMBean(di.ucl, uclName);
- registeredClassLoader = true;
- }
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error registering classloader " + uclName, t);
- }
- return uclName;
- }
-
- /**
- * Unregister the UCL classloader
- *
- * @param di the deployment info
- */
- protected void unregisterClassLoader(DeploymentInfo di)
- {
- ObjectName uclName = null;
- try
- {
- RepositoryClassLoader ucl = di.ucl;
- if (ucl != null)
- {
- uclName = ucl.getObjectName();
- if (registeredClassLoader && server.isRegistered(uclName))
- {
- server.unregisterMBean(uclName);
- registeredClassLoader = false;
- }
- }
- }
- catch (Throwable t)
- {
- log.warn("Error unregistering classloader " + uclName, t);
- }
- }
-
- /**
- * Register the deployment
- *
- * @param di the deployment info
- * @param uclName the object name of the classloader
- * @throws DeploymentException for any error
- */
- protected void registerDeployment(DeploymentInfo di, ObjectName uclName) throws DeploymentException
- {
- try
- {
- String deploymentClass = getDeploymentClass();
- server.createMBean(deploymentClass, di.deployedObject, uclName, new Object[] { di }, new String[] { DeploymentInfo.class.getName() });
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error registering deployment " + di.url, t);
- }
- }
-
- /**
- * Unregister the deployment
- *
- * @param di the deployment info
- */
- protected void unregisterDeployment(DeploymentInfo di)
- {
- try
- {
- if (server.isRegistered(di.deployedObject))
- server.unregisterMBean(di.deployedObject);
- }
- catch (Throwable t)
- {
- log.warn("Error unregistering deployment " + di.deployedObject, t);
- }
- }
-
- /**
- * Do the create lifecyle for the deployment
- *
- * @param di the deployment info
- * @throws DeploymentException for any error
- */
- protected void createService(DeploymentInfo di) throws DeploymentException
- {
- try
- {
- serviceController.create(di.deployedObject);
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error in create for deployment " + di.url, t);
- }
- }
-
- /**
- * Do the start lifecyle for the deployment
- *
- * @param di the deployment info
- * @throws DeploymentException for any error
- */
- protected void startService(DeploymentInfo di) throws DeploymentException
- {
- try
- {
- serviceController.start(di.deployedObject);
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error in start for deployment " + di.url, t);
- }
- }
-
- /**
- * Do the stop lifecyle for the deployment
- *
- * @param di the deployment info
- */
- protected void stopService(DeploymentInfo di)
- {
- try
- {
- if (di.deployedObject != null)
- serviceController.stop(di.deployedObject);
- }
- catch (Throwable t)
- {
- log.warn("Error in stop for deployment " + di.url, t);
- }
- }
-
- /**
- * Do the destroy lifecyle for the deployment
- *
- * @param di the deployment info
- */
- protected void destroyService(DeploymentInfo di) throws DeploymentException
- {
- try
- {
- if (di.deployedObject != null)
- serviceController.destroy(di.deployedObject);
- }
- catch (Throwable t)
- {
- log.warn("Error in destroy for deployment " + di.url, t);
- }
- try
- {
- if (di.deployedObject != null)
- serviceController.remove(di.deployedObject);
- }
- catch (Throwable t)
- {
- log.warn("Error in remove for deployment " + di.url, t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SimpleSubDeployerSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,138 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import javax.management.ObjectName;
-
-/**
- * The common interface for sub-deployer components which
- * perform the actual deployment services for application
- * components.
- *
- * @jmx:mbean extends="org.jboss.system.ServiceMBean"
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:toby.allsopp at peace.com">Toby Allsopp</a>
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- */
-public interface SubDeployer
-{
- /** The notification type send when a SubDeployer completes init */
- public static final String INIT_NOTIFICATION = "org.jboss.deployment.SubDeployer.init";
- /** The notification type send when a SubDeployer completes create */
- public static final String CREATE_NOTIFICATION = "org.jboss.deployment.SubDeployer.create";
- /** The notification type send when a SubDeployer completes start */
- public static final String START_NOTIFICATION = "org.jboss.deployment.SubDeployer.start";
- /** The notification type send when a SubDeployer completes stop */
- public static final String STOP_NOTIFICATION = "org.jboss.deployment.SubDeployer.stop";
- /** The notification type send when a SubDeployer completes destroy */
- public static final String DESTROY_NOTIFICATION = "org.jboss.deployment.SubDeployer.destroy";
-
- /**
- * Get the JMX ObjectName of the service that provides the SubDeployer
- * @return JMX ObjectName of the service
- *
- * @jmx:managed-attribute
- */
- public ObjectName getServiceName();
-
- /**
- * Get an array of suffixes of interest to this subdeployer
- * @return array of suffix strings
- *
- * @jmx:managed-attribute
- */
- public String[] getSuffixes();
-
- /**
- * Get the relative order of the specified suffixes
- * @return the relative order of the specified suffixes
- *
- * @jmx:managed-attribute
- */
- public int getRelativeOrder();
-
- /**
- * The <code>accepts</code> method is called by MainDeployer to
- * determine which deployer is suitable for a DeploymentInfo.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @return a <code>boolean</code> value
- *
- * @jmx:managed-operation
- */
- boolean accepts(DeploymentInfo sdi);
-
- /**
- * The <code>init</code> method lets the deployer set a few properties
- * of the DeploymentInfo, such as the watch url.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- *
- * @jmx:managed-operation
- */
- void init(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * Set up the components of the deployment that do not
- * refer to other components
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- *
- * @jmx:managed-operation
- */
- void create(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>start</code> method sets up relationships with other components.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- *
- * @jmx:managed-operation
- */
- void start(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>stop</code> method removes relationships between components.
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- *
- * @jmx:managed-operation
- */
- void stop(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>destroy</code> method removes individual components
- *
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- *
- * @jmx:managed-operation
- */
- void destroy(DeploymentInfo sdi) throws DeploymentException;
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployer.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployer.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/**
- * An extension interface that allows the retrieval
- * and setting of the combined suffixes and their relative
- * order supported by a SubDeployer.
- *
- * The syntax of an enhanced suffix is
- *
- * "order:suffix"
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public interface SubDeployerExt extends SubDeployer
-{
- /**
- * The list of supported suffixes
- * and their relative order.
- */
- void setEnhancedSuffixes(String[] enhancedSuffixes);
- String[] getEnhancedSuffixes();
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExt.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,43 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-/**
- * An extension mbean interface that allows the retrieval
- * and setting of the combined suffixes and their relative
- * order supported by a SubDeployer.
- *
- * The syntax of an enhanced suffix is
- *
- * "order:suffix"
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public interface SubDeployerExtMBean extends SubDeployerMBean
-{
- /**
- * The list of enhanced suffixes
- */
- void setEnhancedSuffixes(String[] enhancedSuffixes);
- String[] getEnhancedSuffixes();
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerExtMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,162 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import org.jboss.mx.interceptor.AbstractInterceptor;
-import org.jboss.mx.interceptor.Interceptor;
-import org.jboss.mx.server.Invocation;
-
-/**
- * Base class for SubDeployer interceptors.
- *
- * Override one or more of the init(), create(), start(), stop(), destroy()
- * methods to add behaviour. Don't forget to call invokeNext() inside
- * your implementation, if you want the call to be continued.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public abstract class SubDeployerInterceptor extends AbstractInterceptor
-{
- // Constructors --------------------------------------------------
-
- /**
- * Default CTOR
- */
- public SubDeployerInterceptor()
- {
- super();
- }
-
- /**
- * CTOR
- *
- * @param name - the name to use for this interceptor
- */
- public SubDeployerInterceptor(String name)
- {
- // invoker is unknown
- super(name);
- }
-
- // Interceptor implementation ------------------------------------
-
- /**
- * This invoke method checks for invocations of interest, .i.e.
- * init(), create(), start(), stop(), destroy() operation calls
- * with a single DeploymentInfo argument and wraps the invocation
- * with calls to corresponding init(), create(), etc. methods.
- */
- public Object invoke(Invocation invocation) throws Throwable
- {
- String type = invocation.getType();
-
- // make sure this is an operation invocation
- if (type.equals(Invocation.OP_INVOKE))
- {
- Object args[] = invocation.getArgs();
- Object retn = invocation.getReturnTypeClass();
-
- // make sure the signature matches -> void <methodName>(DeploymentInfo di)
- if ((args.length == 1) && (args[0] instanceof DeploymentInfo) && (retn == null))
- {
- String method = invocation.getName();
- DeploymentInfo di = (DeploymentInfo)args[0];
-
- if (method.equals("init"))
- {
- return init(invocation, di);
- }
- else if (method.equals("create"))
- {
- return create(invocation, di);
- }
- else if (method.equals("start"))
- {
- return start(invocation, di);
- }
- else if (method.equals("stop"))
- {
- return stop(invocation, di);
- }
- else if (method.equals("destroy"))
- {
- return destroy(invocation, di);
- }
- }
- }
- // if we reached this point invocation is of no interest
- // to SubDeployerInterceptor so simply forward it
- return invokeNext(invocation);
- }
-
- // Protected -----------------------------------------------------
-
- /**
- * Use this to forward the call
- */
- protected Object invokeNext(Invocation invocation) throws Throwable
- {
- // call the next in the interceptor chain,
- // if nobody follows dispatch the call
- Interceptor next = invocation.nextInterceptor();
- if (next != null)
- {
- return next.invoke(invocation);
- }
- else
- {
- return invocation.dispatch();
- }
- }
-
- // Protected overrides -------------------------------------------
-
- // Override the following methods to add behaviour. Remember
- // to call invokeNext() if you want the call to proceed.
-
- protected Object init(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- protected Object create(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- protected Object start(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- protected Object stop(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- protected Object destroy(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
-}
\ No newline at end of file
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptor.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,38 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import org.jboss.system.InterceptorServiceMBean;
-
-/**
- * Interface for SubDeployerInterceptor services.
- *
- * Empty since we inherit the Interceptable
- * settings from InterceptorServiceMBean.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public interface SubDeployerInterceptorMBean extends InterceptorServiceMBean
-{
- // Empty
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,220 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.Invocation;
-import org.jboss.system.InterceptorServiceMBeanSupport;
-
-/**
- * Base class that can be used for writing services
- * that dynamically hook to other interceptable deployers
- * in order to add functionality in the deployment cycle.
- *
- * We override attach() to install a different interceptor
- * from that of the base class that understands SubDeployer
- * calls. Note that the baseclass invoke(Invocation) won't be
- * called, so no need to override it.
- *
- * Simply call attach()/detach() from createService()/destroyService()
- * or startService()/stopService() pair methods to attach/detach the
- * interceptor to the configured Interceptable SubDeployer(s).
- * Then override any of the init/create/start/stop/destroy methods to
- * apply the extra interception functionality. Inside those methods
- * don't forget to forward the call using invokeNext().
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public abstract class SubDeployerInterceptorSupport extends InterceptorServiceMBeanSupport
- implements SubDeployerInterceptorMBean
-{
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs an <tt>SubDeployerInterceptorSupport</tt>.
- */
- public SubDeployerInterceptorSupport()
- {
- super();
- }
-
- /**
- * Constructs an <tt>SubDeployerInterceptorSupport</tt>.
- *
- * Pass-through to InterceptorServiceMBeanSupport.
- *
- * @param type The class type to determine Logger name from.
- */
- public SubDeployerInterceptorSupport(final Class type)
- {
- super(type);
- }
-
- /**
- * Constructs an <tt>SubDeployerInterceptorSupport</tt>.
- *
- * Pass-through to InterceptorServiceMBeanSupport.
- *
- * @param category The logger category name.
- */
- public SubDeployerInterceptorSupport(final String category)
- {
- super(category);
- }
-
- /**
- * Constructs an <tt>SubDeployerInterceptorSupport</tt>.
- *
- * Pass-through to InterceptorServiceMBeanSupport.
- *
- * @param log The logger to use.
- */
- public SubDeployerInterceptorSupport(final Logger log)
- {
- super(log);
- }
-
- // Protected API -------------------------------------------------
-
- /**
- * We override attach() from InterceptorServiceMBeanSupport
- * to attach a different interceptor that knows how to switch
- * init/create/start/stop/destroy SubDeployer calls.
- *
- * @throws Exception thrown on any interceptor registration error
- */
- protected void attach() throws Exception
- {
- super.attach(new XMBeanInterceptor());
- }
-
- // Override ------------------------------------------------------
-
- /**
- * Override
- */
- protected Object init(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- /**
- * Override
- */
- protected Object create(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- /**
- * Override
- */
- protected Object start(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- /**
- * Override
- */
- protected Object stop(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- /**
- * Override
- */
- protected Object destroy(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- // Private Inner Class -------------------------------------------
-
- /**
- * Simple SubDeployerInterceptor delegating to
- * the SubDeployerInterceptorSupport callbacks
- */
- private class XMBeanInterceptor extends SubDeployerInterceptor
- {
- public XMBeanInterceptor()
- {
- super("XMBeanInterceptor('" + SubDeployerInterceptorSupport.this.getServiceName() + "')");
- }
-
- protected Object init(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- logSubDeployerInvocation(invocation, di);
-
- // delegate
- return SubDeployerInterceptorSupport.this.init(invocation, di);
- }
-
- protected Object create(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- logSubDeployerInvocation(invocation, di);
-
- // delegate
- return SubDeployerInterceptorSupport.this.create(invocation, di);
- }
-
- protected Object start(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- logSubDeployerInvocation(invocation, di);
-
- // delegate
- return SubDeployerInterceptorSupport.this.start(invocation, di);
- }
-
- protected Object stop(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- logSubDeployerInvocation(invocation, di);
-
- // delegate
- return SubDeployerInterceptorSupport.this.stop(invocation, di);
- }
-
- protected Object destroy(Invocation invocation, DeploymentInfo di) throws Throwable
- {
- logSubDeployerInvocation(invocation, di);
-
- // delegate
- return SubDeployerInterceptorSupport.this.destroy(invocation, di);
- }
-
- protected void logSubDeployerInvocation(Invocation invocation, DeploymentInfo di)
- {
- if (SubDeployerInterceptorSupport.this.log.isTraceEnabled())
- {
- StringBuffer sbuf = new StringBuffer();
- sbuf.append("intercepting ").append(invocation.getName())
- .append("(), url=").append(di.url.toString())
- .append(", state=").append(di.state.toString());
-
- SubDeployerInterceptorSupport.this.log.trace(sbuf.toString());
- }
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerInterceptorSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,105 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceMBean;
-
-/**
- * MBean interface for SubDeployers
- *
- * @version <tt>$Revision$</tt>
- */
-public interface SubDeployerMBean extends ServiceMBean
-{
- // Attributes ----------------------------------------------------
-
- /**
- * Get the JMX ObjectName of the service that provides the SubDeployer
- * @return JMX ObjectName of the service
- */
- ObjectName getServiceName();
-
- /**
- * Get an array of suffixes of interest to this subdeployer
- * @return array of suffix strings
- */
- String[] getSuffixes();
-
- /**
- * Get the relative order of the specified suffixes
- * @return the relative order of the specified suffixes
- */
- int getRelativeOrder();
-
- // Operations ----------------------------------------------------
-
- /**
- * The <code>accepts</code> method is called by MainDeployer
- * to determine which deployer is suitable for a DeploymentInfo.
- * @param sdi a <code>DeploymentInfo</code> value
- * @return a <code>boolean</code> value
- */
- boolean accepts(DeploymentInfo sdi);
-
- /**
- * The <code>init</code> method lets the deployer set a few
- * properties of the DeploymentInfo, such as the watch url.
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- void init(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * Set up the components of the deployment that do not
- * refer to other components.
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- void create(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>start</code> method sets up relationships
- * with other components.
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- void start(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>stop</code> method removes relationships
- * between components.
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- void stop(DeploymentInfo sdi) throws DeploymentException;
-
- /**
- * The <code>destroy</code> method removes individual
- * components
- * @param sdi a <code>DeploymentInfo</code> value
- * @throws DeploymentException if an error occurs
- */
- void destroy(DeploymentInfo sdi) throws DeploymentException;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,618 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.OutputStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.Enumeration;
-import java.util.jar.JarEntry;
-import java.util.jar.JarFile;
-
-import javax.management.Notification;
-
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.system.ServiceMBeanSupport;
-import org.jboss.system.server.ServerConfig;
-import org.jboss.system.server.ServerConfigLocator;
-import org.jboss.system.server.ServerConfigUtil;
-import org.jboss.util.file.JarUtils;
-import org.jboss.util.stream.Streams;
-
-/**
- * An abstract {@link SubDeployer}.
- *
- * Provides registration with {@link MainDeployer} as well as
- * implementations of init, create, start, stop and destroy that
- * generate JMX notifications on completion of the method.
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- */
-public abstract class SubDeployerSupport extends ServiceMBeanSupport
- implements SubDeployerExt, SubDeployerExtMBean
-{
- /**
- * Holds the native library <em>suffix</em> for this system.
- *
- * Determined by examining the result of System.mapLibraryName(specialToken).
- * The special token defaults to "XxX", but can be changed by setting the
- * system property: <tt>org.jboss.deployment.SubDeployerSupport.nativeLibToken</tt>.
- */
- protected static final String nativeSuffix;
-
- /**
- * Holds the native library <em>prefix</em> for this system.
- *
- * @see #nativeSuffix
- */
- protected static final String nativePrefix;
-
- /** A proxy to the MainDeployer. */
- protected MainDeployerMBean mainDeployer;
-
- /** The temporary directory into which deployments are unpacked */
- protected File tempDeployDir;
-
- /** The list of enhancedSuffixes for this subdeployer */
- protected String[] enhancedSuffixes;
-
- /** The suffixes of interest to this subdeployer */
- protected String[] suffixes;
-
- /** The relative order of this subdeployer - not really used */
- protected int relativeOrder = -1;
-
- /** The temporary directory where native libs are unpacked. */
- private File tempNativeDir;
-
- /** Whether to load native libraries */
- private boolean loadNative = false;
-
- /**
- * The <code>createService</code> method is one of the ServiceMBean lifecyle operations.
- * (no jmx tag needed from superinterface)
- *
- * @exception Exception if an error occurs
- */
- protected void createService() throws Exception
- {
- // get the temporary directories to use
- ServerConfig config = ServerConfigLocator.locate();
- tempNativeDir = config.getServerNativeDir();
- tempDeployDir = config.getServerTempDeployDir();
- loadNative = ServerConfigUtil.isLoadNative();
-
- // Setup the proxy to mainDeployer
- mainDeployer = (MainDeployerMBean)
- MBeanProxyExt.create(MainDeployerMBean.class,
- MainDeployerMBean.OBJECT_NAME,
- server);
- }
-
- /**
- * Performs SubDeployer registration.
- */
- protected void startService() throws Exception
- {
- // Register with the main deployer
- mainDeployer.addDeployer(this);
- }
-
- /**
- * Performs SubDeployer deregistration.
- */
- protected void stopService() throws Exception
- {
- // Unregister with the main deployer
- mainDeployer.removeDeployer(this);
- }
-
- /**
- * Clean up.
- */
- protected void destroyService() throws Exception
- {
- // Help the GC
- mainDeployer = null;
- tempNativeDir = null;
- }
-
- /**
- * Set an array of suffixes of interest to this subdeployer.
- * No need to register twice suffixes that may refer to
- * unpacked deployments (e.g. .sar, .sar/).
- *
- * @param suffixes array of suffix strings
- */
- protected void setSuffixes(String[] suffixes)
- {
- this.suffixes = suffixes;
- }
-
- /**
- * Set the relative order of the specified suffixes
- * all to the same value.
- *
- * @param relativeOrder the relative order of the specified suffixes
- */
- protected void setRelativeOrder(int relativeOrder)
- {
- this.relativeOrder = relativeOrder;
- }
-
- /**
- * Set the enhanced suffixes list for this deployer,
- * causing also the supported suffixes list to be updated.
- *
- * Each enhanced suffix entries has the form:
- *
- * [order:]suffix
- *
- * No need to register twice suffixes that may refer to
- * unpacked deployments (e.g. .sar, .sar/).
- *
- * @param enhancedSuffixes
- */
- public void setEnhancedSuffixes(String[] enhancedSuffixes)
- {
- if (enhancedSuffixes != null)
- {
- int len = enhancedSuffixes.length;
- suffixes = new String[len];
-
- for (int i = 0; i < len; i++)
- {
- // parse each enhancedSuffix
- SuffixOrderHelper.EnhancedSuffix e =
- new SuffixOrderHelper.EnhancedSuffix(enhancedSuffixes[i]);
-
- suffixes[i] = e.suffix;
- }
- }
- this.enhancedSuffixes = enhancedSuffixes;
- }
-
- /**
- * Get an array of enhancedSuffixes
- *
- * @return array of enhanced suffix strings
- */
- public String[] getEnhancedSuffixes()
- {
- return enhancedSuffixes;
- }
-
- /**
- * Get an array of suffixes of interest to this subdeployer
- *
- * @return array of suffix strings
- */
- public String[] getSuffixes()
- {
- return suffixes;
- }
-
- /**
- * Get the relative order of the specified suffixes
- *
- * @return the relative order of the specified suffixes
- */
- public int getRelativeOrder()
- {
- return relativeOrder;
- }
-
- /**
- * A default implementation that uses the suffixes registered
- * through either setSuffixes() or setEnhancedSuffixes(), to
- * decide if a module is deployable by this deployer.
- *
- * If (according to DeploymentInfo) the deployment refers to
- * a directory, but not an xml or script deployment, then
- * the deployment suffix will be checked also against the
- * registered suffixes + "/".
- *
- * @param sdi the DeploymentInfo to check
- * @return whether the deployer can handle the deployment
- */
- public boolean accepts(DeploymentInfo sdi)
- {
- String[] acceptedSuffixes = getSuffixes();
- if (acceptedSuffixes == null)
- {
- return false;
- }
- else
- {
- String urlPath = sdi.url.getPath();
- String shortName = sdi.shortName;
- boolean checkDir = sdi.isDirectory && !(sdi.isXML || sdi.isScript);
-
- for (int i = 0; i < acceptedSuffixes.length; i++)
- {
- // First check the urlPath the might end in "/"
- // then check the shortName where "/" is removed
- if (urlPath.endsWith(acceptedSuffixes[i]) ||
- (checkDir && shortName.endsWith(acceptedSuffixes[i])))
- {
- return true;
- }
- }
- return false;
- }
- }
-
- /**
- * Sub-classes should override this method to provide
- * custom 'init' logic.
- *
- * <p>This method calls the processNestedDeployments(di) method and then
- * issues a JMX notification of type SubDeployer.INIT_NOTIFICATION.
- * This behaviour can overridden by concrete sub-classes. If further
- * initialization needs to be done, and you wish to preserve the
- * functionality, be sure to call super.init(di) at the end of your
- * implementation.
- */
- public void init(DeploymentInfo di) throws DeploymentException
- {
- processNestedDeployments(di);
-
- emitNotification(SubDeployer.INIT_NOTIFICATION, di);
- }
-
- /**
- * Sub-classes should override this method to provide
- * custom 'create' logic.
- *
- * This method issues a JMX notification of type SubDeployer.CREATE_NOTIFICATION.
- */
- public void create(DeploymentInfo di) throws DeploymentException
- {
- emitNotification(SubDeployer.CREATE_NOTIFICATION, di);
- }
-
- /**
- * Sub-classes should override this method to provide
- * custom 'start' logic.
- *
- * This method issues a JMX notification of type SubDeployer.START_NOTIFICATION.
- */
- public void start(DeploymentInfo di) throws DeploymentException
- {
- emitNotification(SubDeployer.START_NOTIFICATION, di);
- }
-
- /**
- * Sub-classes should override this method to provide
- * custom 'stop' logic.
- *
- * This method issues a JMX notification of type SubDeployer.START_NOTIFICATION.
- */
- public void stop(DeploymentInfo di) throws DeploymentException
- {
- emitNotification(SubDeployer.STOP_NOTIFICATION, di);
- }
-
- /**
- * Sub-classes should override this method to provide
- * custom 'destroy' logic.
- *
- * This method issues a JMX notification of type SubDeployer.DESTROY_NOTIFICATION.
- */
- public void destroy(DeploymentInfo di) throws DeploymentException
- {
- emitNotification(SubDeployer.DESTROY_NOTIFICATION, di);
- }
-
- /**
- * Simple helper to emit a subdeployer notification containing DeploymentInfo
- */
- protected void emitNotification(String type, DeploymentInfo di)
- {
- Notification notification = new Notification(type, this, getNextNotificationSequenceNumber());
- notification.setUserData(di);
- sendNotification(notification);
- }
-
- /**
- * The <code>processNestedDeployments</code> method searches for any nested and
- * deployable elements. Only Directories and Zipped archives are processed,
- * and those are delegated to the addDeployableFiles and addDeployableJar
- * methods respectively. This method can be overridden for alternate
- * behaviour.
- */
- protected void processNestedDeployments(DeploymentInfo di) throws DeploymentException
- {
- log.debug("looking for nested deployments in : " + di.url);
- if (di.isXML)
- {
- // no nested archives in an xml file
- return;
- }
-
- if (di.isDirectory)
- {
- File f = new File(di.url.getFile());
- if (!f.isDirectory())
- {
- // something is screwy
- throw new DeploymentException
- ("Deploy file incorrectly reported as a directory: " + di.url);
- }
-
- addDeployableFiles(di, f);
- }
- else
- {
- try
- {
- // Obtain a jar url for the nested jar
- URL nestedURL = JarUtils.extractNestedJar(di.localUrl, this.tempDeployDir);
- JarFile jarFile = new JarFile(nestedURL.getFile());
- addDeployableJar(di, jarFile);
- }
- catch (Exception e)
- {
- log.warn("Failed to add deployable jar: " + di.localUrl, e);
-
- //
- // jason: should probably throw new DeploymentException
- // ("Failed to add deployable jar: " + jarURLString, e);
- // rather than make assumptions to what type of deployable
- // file this was that failed...
- //
-
- return;
- }
- }
- }
-
- /**
- * This method returns true if the name is a recognized archive file.
- *
- * It will query the MainDeployer that keeps a dynamically updated
- * list of known archive extensions.
- *
- * @param name The "short-name" of the URL. It will have any trailing '/'
- * characters removed, and any directory structure has been removed.
- * @param url The full url.
- *
- * @return true iff the name ends in a known archive extension: .jar, .sar,
- * .ear, .rar, .zip, .wsr, .war, or if the name matches the native
- * library conventions.
- */
- protected boolean isDeployable(String name, URL url)
- {
- // any file under META-INF is not deployable; this method is called
- // also for zipped content, e.g. dir1/dir2.sar/META-INF/bla.xml
- if (url.getPath().indexOf("META-INF") != -1)
- {
- return false;
- }
- String[] acceptedSuffixes = mainDeployer.getSuffixOrder();
- for (int i = 0; i < acceptedSuffixes.length; i++)
- {
- if (name.endsWith(acceptedSuffixes[i]))
- {
- return true;
- }
- }
- // this is probably obsolete
- return (name.endsWith(nativeSuffix) && name.startsWith(nativePrefix));
- }
-
- /**
- * This method recursively searches the directory structure for any files
- * that are deployable (@see isDeployable). If a directory is found to
- * be deployable, then its subfiles and subdirectories are not searched.
- *
- * @param di the DeploymentInfo
- * @param dir The root directory to start searching.
- */
- protected void addDeployableFiles(DeploymentInfo di, File dir)
- throws DeploymentException
- {
- File[] files = dir.listFiles();
- for (int i = 0; i < files.length; i++)
- {
- File file = files[i];
- String name = file.getName();
- try
- {
- URL url = file.toURL();
- if (isDeployable(name, url))
- {
- deployUrl(di, url, name);
- // we don't want deployable units processed any further
- continue;
- }
- }
- catch (MalformedURLException e)
- {
- log.warn("File name invalid; ignoring: " + file, e);
- }
- if (file.isDirectory())
- {
- addDeployableFiles(di, file);
- }
- }
- }
-
- /**
- * This method searches the entire jar file for any deployable files
- * (@see isDeployable).
- *
- * @param di the DeploymentInfo
- * @param jarFile the jar file to process.
- */
- protected void addDeployableJar(DeploymentInfo di, JarFile jarFile)
- throws DeploymentException
- {
- String urlPrefix = "jar:"+di.localUrl.toString()+"!/";
- for (Enumeration e = jarFile.entries(); e.hasMoreElements();)
- {
- JarEntry entry = (JarEntry)e.nextElement();
- String name = entry.getName();
- try
- {
- URL url = new URL(urlPrefix+name);
- if (isDeployable(name, url))
- {
- // Obtain a jar url for the nested jar
- URL nestedURL = JarUtils.extractNestedJar(url, this.tempDeployDir);
- deployUrl(di, nestedURL, name);
- }
- }
- catch (MalformedURLException mue)
- {
- //
- // jason: why are we eating this exception?
- //
- log.warn("Jar entry invalid; ignoring: " + name, mue);
- }
- catch (IOException ex)
- {
- log.warn("Failed to extract nested jar; ignoring: " + name, ex);
- }
- }
- }
-
- protected void deployUrl(DeploymentInfo di, URL url, String name)
- throws DeploymentException
- {
- log.debug("nested deployment: " + url);
- try
- {
- //
- // jason: need better handling for os/arch specific libraries
- // should be able to have multipule native libs in an archive
- // one for each supported platform (os/arch), we only want to
- // load the one for the current platform.
- //
- // This probably means explitly listing the libraries in a
- // deployment descriptor, which could probably also be used
- // to explicitly map the files, as it might be possible to
- // share a native lib between more than one version, no need
- // to duplicate the file, metadata can be used to tell us
- // what needs to be done.
- //
- // Also need this mapping to get around the different values
- // which are used by vm vendors for os.arch and such...
- //
-
- if (name.endsWith(nativeSuffix) && name.startsWith(nativePrefix))
- {
- File destFile = new File(tempNativeDir, name);
- log.info("Loading native library: " + destFile.toString());
-
- File parent = destFile.getParentFile();
- if (!parent.exists()) {
- parent.mkdirs();
- }
-
- InputStream in = url.openStream();
- OutputStream out = new FileOutputStream(destFile);
- Streams.copyb(in, out);
-
- out.flush();
- out.close();
- in.close();
-
- if (loadNative)
- System.load(destFile.toString());
- }
- else
- {
- new DeploymentInfo(url, di, getServer());
- }
- }
- catch (Exception ex)
- {
- throw new DeploymentException
- ("Could not deploy sub deployment "+name+" of deployment "+di.url, ex);
- }
- }
-
- /////////////////////////////////////////////////////////////////////////
- // Class Property Configuration //
- /////////////////////////////////////////////////////////////////////////
-
- /**
- * Static configuration properties for this class. Allows easy access
- * to change defaults with system properties.
- */
- protected static class ClassConfiguration
- extends org.jboss.util.property.PropertyContainer
- {
- private String nativeLibToken = "XxX";
-
- public ClassConfiguration()
- {
- // properties will be settable under our enclosing classes group
- super(SubDeployerSupport.class);
-
- // bind the properties & the access methods
- bindMethod("nativeLibToken");
- }
-
- public void setNativeLibToken(final String token)
- {
- this.nativeLibToken = token;
- }
-
- public String getNativeLibToken()
- {
- return nativeLibToken;
- }
- }
-
- /** The singleton class configuration object for this class. */
- protected static final ClassConfiguration CONFIGURATION = new ClassConfiguration();
-
- //
- // jason: the following needs to be done after setting up the
- // class config reference, so it is moved it down here.
- //
-
- /**
- * Determine the native library suffix and prefix.
- */
- static
- {
- // get the token to use from config, incase the default needs
- // to be changed to resolve problem with a specific platform
- String token = CONFIGURATION.getNativeLibToken();
-
- // then determine what the prefix and suffixes are for this platform
- String nativex = System.mapLibraryName(token);
- int xPos = nativex.indexOf(token);
- nativePrefix = nativex.substring(0, xPos);
- nativeSuffix = nativex.substring(xPos + 3);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SubDeployerSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,459 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment;
-
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import java.util.StringTokenizer;
-
-import org.jboss.logging.Logger;
-
-/**
- * SuffixOrderHelper.
- *
- * This class wraps the SuffixOrder and EnhandedSuffixes attributes
- * of MainDeployer.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public final class SuffixOrderHelper
-{
- // Constants -----------------------------------------------------
-
- /**
- * Default EnhancedSuffixes
- *
- * Those values are indicative - we just know they'll work with
- * the compiled order of subdeployers like the aop or ejb3,
- * but any order can be set using the EnhancedSuffixes
- * attribute and/or the individual subdeployer's relative order.
- *
- * The commented out entries indicate those are dynamically
- * added by their respective subdeployers when they register.
- */
- public static final String[] DEFAULT_ENHANCED_SUFFIXES = {};
- /*
- Moved this list to org.jboss.deployment.MainDeployer-xmbean.xml
- so there are no hardcoded defaults.
- {
- //"050:.deployer",
- //"050:-deployer.xml",
- //"100:.aop",
- //"100:-aop.xml",
- //"150:.sar",
- //"150:-service.xml",
- //"200:.beans",
- "250:.rar",
- "300:-ds.xml",
- //"350:.har",
- "400:.jar", // ejb .jar
- //"450:.ejb3",
- //"450:.par",
- "500:.war", // don't comment out this!
- "600:.wsr",
- "650:.ear",
- //"700:.jar", // plain .jar
- //"750:.zip",
- "800:.bsh",
- "900:.last" // the JARDeployer really handles those?
- };
- */
-
- /** A default relative order just before 900:.last */
- public static final int DEFAULT_RELATIVE_ORDER = 850;
-
- /** The Logger */
- public static final Logger log = Logger.getLogger(SuffixOrderHelper.class);
-
- // Private Data --------------------------------------------------
-
- /** Wrapped DeploymentSorter that stores the value for SuffixOrder attribute */
- private final DeploymentSorter sorter;
-
- /** The actual value of EnhancedSuffixes attribute */
- private String[] enhancedSuffixes;
-
- /** List of sorted EnhancedSuffix instances */
- private List suffixes;
-
- /** Set of static String suffixes that cannot be overriden/removed */
- private Set staticSuffixes;
-
- // Constructor ---------------------------------------------------
-
- public SuffixOrderHelper(DeploymentSorter sorter)
- {
- this.sorter = sorter;
- this.suffixes = new ArrayList();
- this.staticSuffixes = new HashSet();
- }
-
- // Accessors -----------------------------------------------------
-
- /**
- * Getter only for the SuffixOrder as known by the MainDeployer and the Scanners
- *
- * The value is updated during init() with suffixes that remain constant.
- * After that suffixes are added/removed using the corresponding methods.
- *
- * @return the SuffixOrder string array
- */
- public String[] getSuffixOrder()
- {
- return sorter.getSuffixOrder();
- }
-
- /**
- * Getter for the EnhancedSuffixes attribute
- *
- * @return the EnhancedSuffixes string array
- */
- public String[] getEnhancedSuffixes()
- {
- return enhancedSuffixes;
- }
-
- /**
- * Setter for the EnhancedSuffixes attribute
- *
- * @param enhancedSuffixes the EnhancedSuffixes string array
- */
- public void setEnhancedSuffixes(String[] enhancedSuffixes)
- {
- this.enhancedSuffixes = enhancedSuffixes;
- }
-
- /**
- * Initialise the SuffixOrder from EnhancedSuffixes.
- *
- * If no enchangedSuffixes is specified, DEFAULT_ENHANCED_SUFFIXES
- * will be used. Individual entries may contain an additional order
- * element of the form [order:]suffix, e.g. 100:.sar
- *
- * The suffixes specified during init, will remain constant,
- * i.e. they can't be overriden or removed.
- */
- public void initialize()
- {
- // if enhancedSuffixes not provided, use the default
- if (enhancedSuffixes == null)
- {
- enhancedSuffixes = DEFAULT_ENHANCED_SUFFIXES;
- }
-
- // reset, just in case we are called more than once
- suffixes.clear();
- staticSuffixes.clear();
-
- // add all enhanced suffixes; mark them as static, too.
- for (int i = 0; i < enhancedSuffixes.length; i++)
- {
- EnhancedSuffix es = new EnhancedSuffix(enhancedSuffixes[i]);
- addSuffix(es);
-
- // mark all initial entries as static!
- staticSuffixes.add(es.suffix);
- }
-
- // set the resulting SuffixOrder
- sorter.setSuffixOrder(produceSuffixOrder());
- }
-
- /**
- * Add the specified enhanced suffixes in the correct
- * position(s) and regenerate the SuffixOrder, if needed.
- *
- * A suffix that exists already and is marked as static
- * will be skipped. Otherwise, duplicate entries are allowed.
- */
- public void addEnhancedSuffixes(String [] enhancedSuffixes)
- {
- if (enhancedSuffixes != null)
- {
- // remember the initial size of the list
- int size = suffixes.size();
-
- // add all enhanced suffixes
- for (int i = 0; i < enhancedSuffixes.length; i++)
- {
- EnhancedSuffix es = new EnhancedSuffix(enhancedSuffixes[i]);
- addSuffix(es);
- }
- if (suffixes.size() > size)
- {
- // suffixes were added, recreate the resulting SuffixOrder
- sorter.setSuffixOrder(produceSuffixOrder());
- }
- }
- }
-
- /**
- * Insert the specified suffixes in the correct position
- * and regenerate the SuffixOrder array, if needed.
- *
- * A suffix that exists already and is marked as static
- * will be skipped. Otherwise, duplicate entries are allowed.
- */
- public void addSuffixes(String[] suffixes, int relativeOrder)
- {
- if (suffixes != null)
- {
- // remember the initial size of the list
- int size = this.suffixes.size();
-
- for (int i = 0; i < suffixes.length; i++)
- {
- addSuffix(new EnhancedSuffix(suffixes[i], relativeOrder));
- }
-
- if (this.suffixes.size() > size)
- {
- // suffixes were added, recreate the resulting SuffixOrder
- sorter.setSuffixOrder(produceSuffixOrder());
- }
- }
- }
-
- /**
- * Remove the enhanced suffixes if they are not marked as static
- * and regenerate the SuffixOrder, if needed.
- */
- public void removeEnhancedSuffixes(String[] enhancedSuffixes)
- {
- if (enhancedSuffixes != null)
- {
- // remember the initial size of the list
- int size = suffixes.size();
-
- for (int i = 0; i < enhancedSuffixes.length; i++)
- {
- EnhancedSuffix es = new EnhancedSuffix(enhancedSuffixes[i]);
-
- // if this is a static suffix, don't remove
- if (staticSuffixes.contains(es.suffix))
- {
- continue;
- }
- else
- {
- // remove if exists
- suffixes.remove(es);
- }
- }
-
- if (this.suffixes.size() < size)
- {
- // entries removed, recreate the resulting SuffixOrder
- sorter.setSuffixOrder(produceSuffixOrder());
- }
- }
- }
-
- /**
- * Remove the specified suffixes if they are not marked as static
- * and regenerate the SuffixOrder, if needed.
- */
- public void removeSuffixes(String[] suffixes, int relativeOrder)
- {
- if (suffixes != null)
- {
- // remember the initial size of the list
- int size = this.suffixes.size();
-
- for (int i = 0; i < suffixes.length; i++)
- {
- // if this is a static suffix, don't remove
- if (staticSuffixes.contains(suffixes[i]))
- {
- continue;
- }
- else
- {
- // remove if exists
- this.suffixes.remove(new EnhancedSuffix(suffixes[i], relativeOrder));
- }
- }
-
- if (this.suffixes.size() < size)
- {
- // entries removed, recreate the resulting SuffixOrder
- sorter.setSuffixOrder(produceSuffixOrder());
- }
- }
- }
-
- // Private -------------------------------------------------------
-
- /**
- * Produce the SuffixOrder from the sorted suffixes ArrayList
- */
- private String[] produceSuffixOrder()
- {
- String[] suffixOrder = new String[suffixes.size()];
-
- for (int i = 0; i < suffixes.size(); i++)
- {
- suffixOrder[i] = ((EnhancedSuffix)suffixes.get(i)).suffix;
- }
- return suffixOrder;
- }
-
- /**
- * Add an EnhancedSuffix at the correct position in the sorted List.
- *
- * Sorting is based on EnhancedSuffix.order. A new entry with an equal
- * order value to an existing entry is placed AFTER the existing entry.
- *
- * If EnhancedSuffix.suffix exists in the staticSuffixes Set the entry
- * is NOT added. Otherwise, they EnhancedSuffix will be added, even
- * if it is a duplicate of an existing one.
- *
- * @param enhancedsuffix the enhanced suffix
- */
- private void addSuffix(EnhancedSuffix enhancedSuffix)
- {
- // if this is a static suffix, don't add it
- if (staticSuffixes.contains(enhancedSuffix.suffix))
- {
- log.debug("Static suffix exists; ignoring request for adding enhanced suffix: " + enhancedSuffix);
- }
- else
- {
- int size = suffixes.size();
-
- // if List empty, just add the suffix
- if (size == 0)
- {
- suffixes.add(enhancedSuffix);
- }
- else
- {
- // insertion sort starting from the last element
- for (int i = size - 1; i > -1; i--)
- {
- EnhancedSuffix entry = (EnhancedSuffix)suffixes.get(i);
- if (enhancedSuffix.order >= entry.order)
- {
- // add the suffix AFTER the entry and stop
- suffixes.add(i + 1, enhancedSuffix);
- break;
- }
- else if (i == 0)
- {
- // reached the beginning so add the suffix right there
- suffixes.add(0, enhancedSuffix);
- }
- }
- }
- }
- }
-
- /**
- * Inner class that encapsulates an enhanceSuffix
- * consisting of suffix + order
- */
- public final static class EnhancedSuffix
- {
- /** The suffix, e.g. .sar */
- public String suffix;
-
- /** The order, by convention a 3 digit number, e.g. 100 */
- public int order;
-
- /**
- * Simple CTOR
- */
- public EnhancedSuffix(String suffix, int order)
- {
- this.suffix = suffix;
- this.order = order;
- }
-
- /**
- * CTOR that parses an enhancedSuffix string of the form: [order:]suffix
- * If the optional 'order' is missing, use DEFAULT_RELATIVE_ORDER
- */
- public EnhancedSuffix(String enhancedSuffix) throws IllegalArgumentException
- {
- StringTokenizer tokenizer = new StringTokenizer(enhancedSuffix, ":");
- int tokens = tokenizer.countTokens();
-
- switch (tokens)
- {
- case 1:
- this.order = DEFAULT_RELATIVE_ORDER;
- this.suffix = enhancedSuffix;
- break;
-
- case 2:
- this.order = Integer.parseInt(tokenizer.nextToken());
- this.suffix = tokenizer.nextToken();
- break;
-
- default:
- throw new IllegalArgumentException("Cannot parse enhancedSuffix: " + enhancedSuffix);
- }
- }
-
- /**
- * Override equals to allow EnhancedSuffix to be searchable
- * using ArrayList.indexOf()/ArrayList.lastIndexOf()
- *
- * Base equality on both suffix and order
- */
- public boolean equals(Object other)
- {
- if (other == this)
- return true;
-
- if (!(other instanceof EnhancedSuffix))
- return false;
-
- EnhancedSuffix that = (EnhancedSuffix)other;
-
- // suffix shouldn't be null
- return this.suffix.equals(that.suffix) && this.order == that.order;
- }
-
- /**
- * Use both fields
- */
- public int hashCode()
- {
- int result = 17;
- result = 37 * result + suffix.hashCode();
- result = 37 * result + order;
- return result;
- }
-
- /**
- * Pretty print
- */
- public String toString()
- {
- return order + ":" + suffix;
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/SuffixOrderHelper.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,242 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import java.io.IOException;
-import java.io.InputStream;
-
-import javax.management.ObjectName;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.transform.Source;
-import javax.xml.transform.Templates;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMResult;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamSource;
-
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.system.server.ServerConfigUtil;
-import org.jboss.util.xml.DOMWriter;
-import org.jboss.util.xml.JBossEntityResolver;
-import org.jboss.util.xml.JBossErrorHandler;
-import org.w3c.dom.Document;
-import org.xml.sax.SAXException;
-
-/**
- * XSLSubDeployer
- *
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
- * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
- * @version <tt>$Revision$</tt>
- */
-public class XSLSubDeployer extends SubDeployerSupport implements XSLSubDeployerMBean
-{
- protected String xslUrl;
-
- protected String packageSuffix;
-
- protected String ddSuffix;
-
- protected DocumentBuilderFactory dbf;
-
- private Templates templates;
-
- protected ObjectName delegateName = SARDeployerMBean.OBJECT_NAME;
-
- protected SubDeployer delegate;
-
- /** A flag indicating if deployment descriptors should be validated */
- private boolean validateDTDs;
-
- public XSLSubDeployer()
- {
-
- }
-
- public void setXslUrl(final String xslUrl)
- {
- this.xslUrl = xslUrl;
- }
-
- public String getXslUrl()
- {
- return xslUrl;
- }
-
- public void setPackageSuffix(final String packageSuffix)
- {
- this.packageSuffix = packageSuffix;
- }
-
- public String getPackageSuffix()
- {
- return packageSuffix;
- }
-
- public void setDdSuffix(final String ddSuffix)
- {
- this.ddSuffix = ddSuffix;
- }
-
- public String getDdSuffix()
- {
- return ddSuffix;
- }
-
- public void setDelegateName(final ObjectName delegateName)
- {
- this.delegateName = delegateName;
- }
-
- public ObjectName getDelegateName()
- {
- return delegateName;
- }
- public boolean getValidateDTDs()
- {
- return validateDTDs;
- }
-
- public void setValidateDTDs(boolean validate)
- {
- this.validateDTDs = validate;
- }
-
- protected void createService() throws Exception
- {
- super.createService();
- delegate = (SubDeployer) MBeanProxyExt.create(SubDeployer.class, delegateName, server);
-
- TransformerFactory tf = TransformerFactory.newInstance();
- dbf = DocumentBuilderFactory.newInstance();
- dbf.setNamespaceAware(true);
- dbf.setValidating(validateDTDs);
-
- InputStream is = Thread.currentThread().getContextClassLoader().getResourceAsStream(xslUrl);
- StreamSource ss = new StreamSource(is);
- templates = tf.newTemplates(ss);
- log.debug("Created templates: " + templates);
- }
-
- protected void destroyService() throws Exception
- {
- templates = null;
- super.destroyService();
- }
-
- public boolean accepts(DeploymentInfo di)
- {
- String urlStr = di.url.toString();
- return (packageSuffix != null && (urlStr.endsWith(packageSuffix) || urlStr.endsWith(packageSuffix + "/")))
- || (ddSuffix != null && urlStr.endsWith(ddSuffix));
- }
-
- public void init(DeploymentInfo di) throws DeploymentException
- {
- if (di.document == null)
- findDd(di);
-
- try
- {
- Transformer trans = templates.newTransformer();
- String urlStr = di.url.toString();
- String shortURL = ServerConfigUtil.shortUrlFromServerHome(urlStr);
- trans.setErrorListener(new JBossErrorHandler(shortURL, null));
- Source s = new DOMSource(di.document);
- DOMResult r = new DOMResult();
- setParameters(trans);
-
- trans.transform(s, r);
-
- di.document = (Document) r.getNode();
- log.debug("transformed into doc: " + di.document);
- if (log.isDebugEnabled())
- {
- String docStr = DOMWriter.printNode(di.document, true);
- log.debug("transformed into doc: " + docStr);
- }
- }
- catch (TransformerException ce)
- {
- throw new DeploymentException("Problem with xsl transformation", ce);
- }
- delegate.init(di);
- }
-
- public void create(DeploymentInfo di) throws DeploymentException
- {
- delegate.create(di);
- }
-
- public void start(DeploymentInfo di) throws DeploymentException
- {
- delegate.start(di);
- }
-
- public void stop(DeploymentInfo di) throws DeploymentException
- {
- delegate.stop(di);
- }
-
- public void destroy(DeploymentInfo di) throws DeploymentException
- {
- delegate.destroy(di);
- }
-
- protected void setParameters(Transformer trans) throws TransformerException
- {
- //override to set document names etc.
- }
-
- protected void findDd(DeploymentInfo di) throws DeploymentException
- {
- try
- {
- DocumentBuilder db = dbf.newDocumentBuilder();
- String urlStr = di.url.toString();
- String shortURL = ServerConfigUtil.shortUrlFromServerHome(urlStr);
- JBossEntityResolver resolver = new JBossEntityResolver();
- db.setEntityResolver(resolver);
- db.setErrorHandler(new JBossErrorHandler(shortURL, resolver));
-
- if (ddSuffix != null && urlStr.endsWith(ddSuffix))
- di.document = db.parse(di.url.openStream());
- }
- catch (SAXException se)
- {
- throw new DeploymentException("Could not parse dd", se);
- }
- catch (IOException ioe)
- {
- throw new DeploymentException("Could not read dd", ioe);
- }
- catch (ParserConfigurationException pce)
- {
- throw new DeploymentException("Could not create document builder for dd", pce);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployer.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,49 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface XSLSubDeployerMBean extends SubDeployerExtMBean
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:service=XSLDeployer");
-
- void setXslUrl(String xslUrl);
- String getXslUrl();
-
- void setPackageSuffix(String packageSuffix);
- String getPackageSuffix();
-
- void setDdSuffix(String ddSuffix);
- String getDdSuffix();
-
- void setDelegateName(ObjectName delegateName);
- ObjectName getDelegateName();
-
- void setValidateDTDs(boolean validate);
- boolean getValidateDTDs();
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/XSLSubDeployerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/package.html
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/package.html 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/package.html 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,41 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
- <head>
- <!-- $Id$ -->
- <!--
-
- JBoss: The OpenSource J2EE WebOS
-
- Distributable under LGPL license.
- See terms of license at gnu.org.
-
- -->
- </head>
-
- <body bgcolor="white">
- <p>Core deployment framework and services.
-
- <h2>Package Specification</h2>
- <ul>
- <li><a href="javascript: alert('not available')">Not Available</a>
- </ul>
-
- <h2>Related Documentation</h2>
- <ul>
- <li><a href="javascript: alert('not available')">Not Available</a>
- </ul>
-
- <h2>Package Status</h2>
- <ul>
- <li><font color="green"><b>STABLE</b></font>
- </ul>
-
- <h2>Todo</h2>
- <ul>
- <li>???
- </ul>
-
- <!-- Put @see and @since tags down here. -->
-
- </body>
-</html>
Copied: trunk/system-jmx/src/main/org/jboss/deployment/package.html (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/package.html)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/package.html
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner)
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,382 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment.scanner;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployment.Deployer;
-import org.jboss.deployment.MainDeployerMBean;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.mx.util.MBeanProxyInstance;
-import org.jboss.system.MissingAttributeException;
-import org.jboss.system.ServiceMBeanSupport;
-import org.jboss.util.NullArgumentException;
-
-import EDU.oswego.cs.dl.util.concurrent.SynchronizedBoolean;
-
-/**
- * An abstract support class for implementing a deployment scanner.
- *
- * <p>Provides the implementation of period-based scanning, as well
- * as Deployer integration.
- *
- * <p>Sub-classes only need to implement {@link DeploymentScanner#scan}.
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author Scott.Stark at jboss.org
- */
-public abstract class AbstractDeploymentScanner extends ServiceMBeanSupport
- implements DeploymentScanner, DeploymentScannerMBean
-{
- /** The scan period in milliseconds */
- protected long scanPeriod = 5000;
-
- /** True if period based scanning is enabled. */
- protected boolean scanEnabled = true;
-
- /** The stop timeout */
- protected long stopTimeOut = 60000;
-
- /** A proxy to the deployer we are using. */
- protected Deployer deployer;
-
- protected MainDeployerMBean mainDeployer;
-
- /** The scanner thread. */
- protected ScannerThread scannerThread;
-
- /** HACK: Shutdown hook to get around problems with system service shutdown ordering. */
- private Thread shutdownHook;
-
-
- /////////////////////////////////////////////////////////////////////////
- // DeploymentScanner //
- /////////////////////////////////////////////////////////////////////////
-
- public void setDeployer(final ObjectName deployerName)
- {
- if (deployerName == null)
- throw new NullArgumentException("deployerName");
-
- deployer = (Deployer)
- MBeanProxyExt.create(Deployer.class, deployerName, server);
- }
-
- public ObjectName getDeployer()
- {
- return ((MBeanProxyInstance)deployer).getMBeanProxyObjectName();
- }
-
- /**
- * Period must be >= 0.
- */
- public void setScanPeriod(final long period)
- {
- if (period < 0)
- throw new IllegalArgumentException("ScanPeriod must be >= 0; have: " + period);
-
- this.scanPeriod = period;
- }
-
- public long getScanPeriod()
- {
- return scanPeriod;
- }
-
- public void setScanEnabled(final boolean flag)
- {
- this.scanEnabled = flag;
- }
-
- public boolean isScanEnabled()
- {
- return scanEnabled;
- }
-
- public long getStopTimeOut()
- {
- return stopTimeOut;
- }
-
- public void setStopTimeOut(long stopTimeOut)
- {
- this.stopTimeOut = stopTimeOut;
- }
-
- /** This is here to work around a bug in the IBM vm that causes an
- * AbstractMethodError to be thrown when the ScannerThread calls scan.
- * @throws Exception
- */
- public abstract void scan() throws Exception;
-
- /////////////////////////////////////////////////////////////////////////
- // Scanner Thread //
- /////////////////////////////////////////////////////////////////////////
-
- /**
- * Should use Timer/TimerTask instead? This has some issues with
- * interaction with ScanEnabled attribute. ScanEnabled works only
- * when starting/stopping.
- */
- public class ScannerThread
- extends Thread
- {
- /** We get our own logger. */
- protected Logger scannerLog = Logger.getLogger(ScannerThread.class);
-
- /** True if the scan loop should run. */
- protected SynchronizedBoolean enabled = new SynchronizedBoolean(false);
-
- /** True if we are shutting down. */
- protected SynchronizedBoolean shuttingDown = new SynchronizedBoolean(false);
-
- /** Lock/notify object. */
- protected Object lock = new Object();
-
- /** Active synchronization. */
- protected SynchronizedBoolean active = new SynchronizedBoolean(false);
-
- public ScannerThread(boolean enabled)
- {
- super("ScannerThread");
-
- this.enabled.set(enabled);
- }
-
- public void setEnabled(boolean enabled)
- {
- this.enabled.set(enabled);
-
- synchronized (lock)
- {
- lock.notifyAll();
- }
-
- scannerLog.debug("Notified that enabled: " + enabled);
- }
-
- public void shutdown()
- {
- enabled.set(false);
- shuttingDown.set(true);
-
- synchronized (lock)
- {
- lock.notifyAll();
- }
-
- scannerLog.debug("Notified to shutdown");
-
- // jason: shall we also interrupt this thread?
- }
-
- public void run()
- {
- scannerLog.debug("Running");
-
- active.set(true);
- try
- {
- while (shuttingDown.get() == false)
- {
- // If we are not enabled, then wait
- if (enabled.get() == false)
- {
- synchronized (active)
- {
- active.set(false);
- active.notifyAll();
- }
- try
- {
- scannerLog.debug("Disabled, waiting for notification");
- synchronized (lock)
- {
- lock.wait();
- }
- }
- catch (InterruptedException ignore)
- {
- }
- active.set(true);
- }
-
- loop();
- }
- }
- finally
- {
- synchronized (active)
- {
- active.set(false);
- active.notifyAll();
- }
- }
-
- scannerLog.debug("Shutdown");
- }
-
- protected void waitForInactive()
- {
- boolean interrupted = false;
- synchronized (active)
- {
- try
- {
- if (active.get() && stopTimeOut > 0)
- active.wait(stopTimeOut);
- }
- catch (InterruptedException ignored)
- {
- interrupted = true;
- }
- }
- if (interrupted)
- Thread.currentThread().interrupt();
- }
-
- public void doScan()
- {
- // Scan for new/removed/changed/whatever
- try {
- scan();
- }
- catch (Exception e) {
- scannerLog.error("Scanning failed; continuing", e);
- }
- }
-
- protected void loop()
- {
- while (enabled.get() && shuttingDown.get() == false)
- {
- doScan();
-
- // Sleep for scan period
- try
- {
- scannerLog.trace("Sleeping...");
- Thread.sleep(scanPeriod);
- }
- catch (InterruptedException ignore) {}
- }
- }
- }
-
-
- /////////////////////////////////////////////////////////////////////////
- // Service/ServiceMBeanSupport //
- /////////////////////////////////////////////////////////////////////////
-
- protected void createService() throws Exception
- {
- if (deployer == null)
- throw new MissingAttributeException("Deployer");
- mainDeployer = (MainDeployerMBean)MBeanProxyExt.create(MainDeployerMBean.class, MainDeployerMBean.OBJECT_NAME, server);
- // setup + start scanner thread
- scannerThread = new ScannerThread(false);
- scannerThread.setDaemon(true);
- scannerThread.start();
- log.debug("Scanner thread started");
-
- // HACK
- //
- // install a shutdown hook, as the current system service shutdown
- // mechanism will not call this until all other services have stopped.
- // we need to know soon, so we can stop scanning to try to avoid
- // starting new services when shutting down
-
- final ScannerThread _scannerThread = scannerThread;
- shutdownHook = new Thread("DeploymentScanner Shutdown Hook")
- {
- ScannerThread thread = _scannerThread;
-
- public void run()
- {
- thread.shutdown();
- }
- };
-
- try
- {
- Runtime.getRuntime().addShutdownHook(shutdownHook);
- }
- catch (Exception e)
- {
- log.warn("Failed to add shutdown hook", e);
- }
- }
-
- protected void startService() throws Exception
- {
- synchronized( scannerThread )
- {
- // scan before we enable the thread, so JBoss version shows up afterwards
- scannerThread.doScan();
-
- // enable scanner thread if we are enabled
- scannerThread.setEnabled(scanEnabled);
- }
- }
-
- protected void stopService() throws Exception
- {
- // disable scanner thread
- if( scannerThread != null )
- {
- scannerThread.setEnabled(false);
- scannerThread.waitForInactive();
- }
- }
-
- protected void destroyService() throws Exception
- {
- // drop our ref to deployer, so scan will fail
- deployer = null;
-
- // shutdown scanner thread
- if( scannerThread != null )
- {
- synchronized( scannerThread )
- {
- scannerThread.shutdown();
- }
- }
-
- // HACK
- //
- // remove the shutdown hook, we don't need it anymore
- try
- {
- Runtime.getRuntime().removeShutdownHook(shutdownHook);
- }
- catch (Exception ignore)
- {
- } // who cares really
-
- // help gc
- shutdownHook = null;
- scannerThread = null;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/AbstractDeploymentScanner.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,137 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment.scanner;
-
-import org.jboss.deployment.DefaultDeploymentSorter;
-
-import java.util.Comparator;
-import java.net.URL;
-
-/**
- * This is simialr to the PrefixDeploymentSorter in that it will order
- * files that do not start with a numeric value before those that do.
- * If two files begin with a number, will compare the numeric values.
- * However, if the two files do not have numeric prefixes, will
- * compare them using compareToIgnoreCase.
- *
- * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
- */
-public class AlphaNumericDeploymentSorter implements Comparator, DefaultDeploymentSorter
-{
-
- private PrefixDeploymentSorter sorter = new PrefixDeploymentSorter();
-
- public String[] getSuffixOrder()
- {
- return sorter.getSuffixOrder();
- }
-
- public void setSuffixOrder(String[] suffixOrder)
- {
- sorter.setSuffixOrder(suffixOrder);
- }
-
- public int compare(Object o1, Object o2)
- {
- int comp = sorter.compare(o1, o2);
-
- return comp == 0 ? alphaCompare(o1, o2) : comp;
- }
-
- private String convertURLToString(URL url)
- {
- String path = url.getPath();
- int nameEnd = path.length() - 1;
- if (nameEnd <= 0) {
- return "";
- }
-
- // ignore a trailing '/'
- if (path.charAt(nameEnd) == '/') {
- nameEnd--;
- }
-
- // find the previous URL separator: '/'
- int nameStart = path.lastIndexOf('/', nameEnd) + 1;
-
- return path.substring(nameStart);
-
- }
-
- public int alphaCompare(Object o1, Object o2)
- {
- String s1 = convertURLToString((URL)o1);
- boolean s1IsDigit = Character.isDigit(s1.charAt(0));
- String s2 = convertURLToString((URL)o2);
- boolean s2IsDigit = Character.isDigit(s2.charAt(0));
-
- if(s1IsDigit && !s2IsDigit)
- {
- return 1; // o1 is greater than o2, since has number and o2 does not
- }
- else if(!s1IsDigit && s2IsDigit)
- {
- return -1; //o1 is less than o2, since does not have number and o2 does
- }
- if(s1IsDigit && s2IsDigit) // numeric comapre
- {
- int num1 = getNumericPrefix(s1);
- int num2 = getNumericPrefix(s2);
- int diff = num1 - num2;
- if(diff != 0) // do not begin with same number
- {
- return diff;
- }
- else //numbers are the same, so have to compare rest of the string
- {
- String s1Suf = getAlphaSuffix(s1);
- String s2Sef = getAlphaSuffix(s2);
- return s1Suf.compareToIgnoreCase(s2Sef);
- }
- }
- else // alpha compare
- {
- return s1.compareToIgnoreCase(s2);
- }
- }
-
- private String getAlphaSuffix(String s1)
- {
- int x = 0;
- while(Character.isDigit(s1.charAt(x++)));
- return s1.substring(x);
- }
-
- private int getNumericPrefix(String s1)
- {
- int x = 0;
- String numS1 = null;
- while(Character.isDigit(s1.charAt(x++)))
- {
- numS1 = s1.substring(0, x);
- }
- int number = Integer.parseInt(numS1);
- return number;
- }
-
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/AlphaNumericDeploymentSorter.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,257 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment.scanner;
-
-import java.io.FileFilter;
-import java.io.File;
-import java.util.Arrays;
-import java.util.Comparator;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.net.URL;
-
-import org.jboss.net.protocol.URLLister;
-
-/**
- * <p>A simple filter for the URLDeploymentScanner. Three arrays are
- * maintained for checking: a prefix, suffix, and match array. If the
- * filename starts with any of the prefixes, ends with any of the
- * suffixes, or exactly matches any of the matches, then the accepts
- * method will return false.
- *
- * NOTE: the arrays *must* be sorted for the string matching to work,
- * and suffixes use the 'reverseComparator'
- *
- * @author somebody at jboss.org
- * @version $Revision$
- */
-public class DeploymentFilter implements FileFilter, URLLister.URLFilter
-{
- /**
- * Compare the strings backwards. This assists in suffix comparisons.
- */
- private static final Comparator reverseComparator = new Comparator()
- {
- public int compare(Object o1, Object o2)
- {
- int idx1 = ((String) o1).length();
- int idx2 = ((String) o2).length();
- int comp = 0;
-
- while (comp == 0 && idx1 > 0 && idx2 > 0)
- comp = ((String) o1).charAt(--idx1) - ((String) o2).charAt(--idx2);
-
- return (comp == 0) ? (idx1 - idx2) : comp;
- }
- };
-
- /** the default prefix list */
- private static final String[] DEFAULT_PREFIXES =
- {"#", "%", ",", ".", "_$"};
-
- /** the default suffix list */
- private static final String[] DEFAULT_SUFFIXES =
- {"#", "$", "%", "~", ",v",
- ".BAK", ".bak", ".old", ".orig", ".tmp", ".rej", ".sh" };
-
- /** the default matches list */
- private static final String[] DEFAULT_MATCHES =
- {".make.state", ".nse_depinfo", "CVS", "CVS.admin", "RCS", "RCSLOG",
- "SCCS", "TAGS", "core", "tags"};
-
- /** The list of disallowed suffixes, sorted using reverse values */
- private ArrayList suffixes;
-
- /** The sorted list of disallowed prefixes */
- private ArrayList prefixes;
-
- /** The sorted list of disallowed values */
- private ArrayList matches;
-
- /** Use the default values for suffixes, prefixes, and matches */
- public DeploymentFilter()
- {
- this(DEFAULT_MATCHES, DEFAULT_PREFIXES, DEFAULT_SUFFIXES);
- }
-
- /**
- * Create using a custom set of matches, prefixes, and suffixes. If any of
- * these arrays are null, then the corresponding default will be
- * substituted.
- */
- public DeploymentFilter(String[] matches, String[] prefixes, String[] suffixes)
- {
- if( matches == null )
- matches = DEFAULT_MATCHES;
- Arrays.sort(matches);
- this.matches = new ArrayList(Arrays.asList(matches));
-
- if( prefixes == null )
- prefixes = DEFAULT_PREFIXES;
- Arrays.sort(prefixes);
- this.prefixes = new ArrayList(Arrays.asList(prefixes));
-
- if( suffixes == null )
- suffixes = DEFAULT_SUFFIXES;
- Arrays.sort(suffixes, reverseComparator);
- this.suffixes = new ArrayList(Arrays.asList(suffixes));
- }
-
- public void addPrefix(String prefix)
- {
- this.prefixes.add(prefix);
- Collections.sort(this.prefixes);
- }
- public void addPrefixes(String[] prefixes)
- {
- this.prefixes.add(Arrays.asList(prefixes));
- Collections.sort(this.prefixes);
- }
-
- public void delPrefix(String prefix)
- {
- this.prefixes.remove(prefix);
- }
- public void delPrefixes(String[] prefixes)
- {
- this.prefixes.removeAll(Arrays.asList(prefixes));
- Collections.sort(this.prefixes);
- }
-
- public void addSuffix(String suffix)
- {
- this.suffixes.add(suffix);
- Collections.sort(this.suffixes, reverseComparator);
- }
- public void addSuffixes(String[] suffixes)
- {
- this.suffixes.add(Arrays.asList(suffixes));
- Collections.sort(this.suffixes, reverseComparator);
- }
-
- public void delSuffix(String suffix)
- {
- this.suffixes.remove(suffix);
- }
- public void delSuffixes(String[] suffixes)
- {
- this.suffixes.removeAll(Arrays.asList(suffixes));
- Collections.sort(this.suffixes, reverseComparator);
- }
-
- public String[] getSuffixes()
- {
- String[] tmp = new String[suffixes.size()];
- suffixes.toArray(tmp);
- return tmp;
- }
- public void setSuffixes(String[] suffixes)
- {
- Arrays.sort(suffixes, reverseComparator);
- this.suffixes.clear();
- this.suffixes.addAll(Arrays.asList(suffixes));
- }
-
- public String[] getPrefixes()
- {
- String[] tmp = new String[prefixes.size()];
- prefixes.toArray(tmp);
- return tmp;
- }
- public void setPrefixes(String[] prefixes)
- {
- Arrays.sort(prefixes);
- this.prefixes.clear();
- this.prefixes.addAll(Arrays.asList(prefixes));
- }
-
- public String[] getMatches()
- {
- String[] tmp = new String[matches.size()];
- matches.toArray(tmp);
- return tmp;
- }
- public void setMatches(String[] matches)
- {
- Arrays.sort(matches);
- this.matches.clear();
- this.matches.addAll(Arrays.asList(matches));
- }
-
- /**
- * If the filename matches any string in the prefix, suffix, or matches
- * array, return false. Perhaps a bit of overkill, but this method
- * operates in log(n) time, where n is the size of the arrays.
- *
- * @param file The file to be tested
- * @return <code>false</code> if the filename matches any of the prefixes,
- * suffixes, or matches.
- */
- public boolean accept(File file)
- {
- return accept(file.getName());
- }
-
- public boolean accept(URL baseURL, String memberName)
- {
- return accept(memberName);
- }
-
- private boolean accept(String name)
- {
- // check exact match
- int index = Collections.binarySearch(matches, name);
- if (index >= 0)
- return false;
-
- // check prefix
- index = Collections.binarySearch(prefixes, name);
- if (index >= 0)
- return false;
- if (index < -1)
- {
- // The < 0 index gives the first index greater than name
- int firstLessIndex = -2 - index;
- String prefix = (String) prefixes.get(firstLessIndex);
- // If name starts with an ingored prefix ignore name
- if( name.startsWith(prefix) )
- return false;
- }
-
- // check suffix
- index = Collections.binarySearch(suffixes, name, reverseComparator);
- if (index >= 0)
- return false;
- if (index < -1)
- {
- // The < 0 index gives the first index greater than name
- int firstLessIndex = -2 - index;
- String suffix = (String) suffixes.get(firstLessIndex);
- // If name ends with an ingored suffix ignore name
- if( name.endsWith(suffix) )
- return false;
- }
-
- // everything checks out.
- return true;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentFilter.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,109 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment.scanner;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.Service;
-
-/**
- * Provides the basic interface for a deployment scanner.
- *
- * <p>A deployment scanner scans for new, removed or changed
- * deployments.
- *
- * @jmx:mbean extends="org.jboss.system.ServiceMBean"
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- */
-public interface DeploymentScanner
- extends Service
-{
- /**
- * The ObjectName of the {@link Deployer} which we will use.
- *
- * @param deployerName The object name of the deployer to use.
- *
- * @jmx:managed-attribute
- */
- void setDeployer(ObjectName deployerName);
-
- /**
- * Get the ObjectName of the {@link Deployer} which we are using.
- *
- * @return The object name of the deployer we are using.
- *
- * @jmx:managed-attribute
- */
- ObjectName getDeployer();
-
- /**
- * Set the scan period for the scanner.
- *
- * @param period This is the time in milliseconds between scans.
- *
- * @throws IllegalArgumentException Period value out of range.
- *
- * @jmx:managed-attribute
- */
- void setScanPeriod(long period);
-
- /**
- * Get the scan period for the scanner.
- *
- * @return This is the time in milliseconds between scans.
- */
- long getScanPeriod();
-
- /**
- * Disable or enable the period based deployment scanning.
- *
- * <p>Manual scanning can still be performed by calling
- * {@link #scan}.
- *
- * @param flag True to enable or false to disable period
- * based scanning.
- *
- * @jmx:managed-attribute
- */
- void setScanEnabled(boolean flag);
-
- /**
- * Check if period based scanning is enabled.
- *
- * @return True if enabled, false if disabled.
- *
- * @jmx:managed-attribute
- */
- boolean isScanEnabled();
-
- /**
- * Scan for deployment changes.
- *
- * @throws IllegalStateException Not initialized.
- * @throws Exception Scan failed.
- *
- * @jmx:managed-operation
- */
- void scan() throws Exception;
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScanner.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,82 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment.scanner;
-
-/**
- * MBean interface.
- */
-public interface DeploymentScannerMBean extends org.jboss.system.ServiceMBean
-{
-
- /**
- * The ObjectName of the {@link Deployer} which we will use.
- * @param deployerName The object name of the deployer to use.
- */
- void setDeployer(javax.management.ObjectName deployerName);
-
- /**
- * Get the ObjectName of the {@link Deployer} which we are using.
- * @return The object name of the deployer we are using.
- */
- javax.management.ObjectName getDeployer();
-
- /**
- * Set the scan period for the scanner.
- * @param period This is the time in milliseconds between scans.
- * @throws IllegalArgumentException Period value out of range.
- */
- void setScanPeriod(long period);
-
- /**
- * Disable or enable the period based deployment scanning. <p>Manual scanning can still be performed by calling {@link #scan}.
- * @param flag True to enable or false to disable period based scanning.
- */
- void setScanEnabled(boolean flag);
-
- /**
- * Check if period based scanning is enabled.
- * @return True if enabled, false if disabled.
- */
- boolean isScanEnabled();
-
- /**
- * How long to wait in stop for the background thread to stop
- *
- * @return the time in milliseconds.
- */
- long getStopTimeOut();
-
- /**
- * How long to wait in stop for the background thread to stop
- *
- * @param stopTimeOut the time in milliseconds.
- */
- void setStopTimeOut(long stopTimeOut);
-
- /**
- * Scan for deployment changes.
- * @throws IllegalStateException Not initialized.
- * @throws Exception Scan failed.
- */
- void scan() throws java.lang.Exception;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/DeploymentScannerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,103 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.deployment.scanner;
-
-import java.util.Comparator;
-import java.net.URL;
-import org.jboss.deployment.DeploymentSorter;
-import org.jboss.deployment.DefaultDeploymentSorter;
-
-/**
- * <p>This class is a comparator to sort deployment URLs based on the existence
- * of a numeric prefix. The name portion of the URL is evaluated for any
- * leading digits. If they exist, then they will define a numerical ordering
- * for this comparator. If there is no leading digits, then they will
- * compare as less than any name with leading digits. In the case of a
- * tie, the DeploymentSorter is consulted (@see org.jboss.deployment.DeploymentSorter).
- *
- * <p>Ex.these names are in ascending order:
- * test.sar, crap.ear, 001test.jar, 5test.rar, 5foo.jar, 120bar.jar
- */
-public class PrefixDeploymentSorter implements Comparator, DefaultDeploymentSorter
-{
-
- /** This is used to break ties */
- private DeploymentSorter sorter = new DeploymentSorter();
-
- public String[] getSuffixOrder()
- {
- return sorter.getSuffixOrder();
- }
-
- public void setSuffixOrder(String[] suffixOrder)
- {
- sorter.setSuffixOrder(suffixOrder);
- }
-
- /**
- * As described in @see java.util.Comparator. This implements the
- * comparison technique described above.
- */
- public int compare(Object o1, Object o2) {
- int comp = getPrefixValue((URL)o1) - getPrefixValue((URL)o2);
-
- return comp == 0 ? sorter.compare(o1, o2) : comp;
- }
-
- /**
- * This extracts the prefix value from the name of a URL. If no prefix
- * value exists, this returns -1
- */
- private int getPrefixValue(URL url) {
- String path = url.getPath();
- int nameEnd = path.length() - 1;
- if (nameEnd <= 0) {
- return 0;
- }
-
- // ignore a trailing '/'
- if (path.charAt(nameEnd) == '/') {
- nameEnd--;
- }
-
- // find the previous URL separator: '/'
- int nameStart = path.lastIndexOf('/', nameEnd) + 1;
-
- // calculate where the digit-prefix ends
- int prefixEnd = nameStart;
- while (prefixEnd <= nameEnd && Character.isDigit(path.charAt(prefixEnd))) {
- prefixEnd++;
- }
-
- // If zero length prefix, return -1
- if (prefixEnd == nameStart) {
- return -1;
- }
-
- // strip leading zeroes
- while (nameStart < prefixEnd && path.charAt(nameStart) == '0') {
- nameStart++;
- }
-
- return (nameStart == prefixEnd) ? 0 : Integer.parseInt(path.substring(nameStart, prefixEnd));
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/PrefixDeploymentSorter.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,836 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment.scanner;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLConnection;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Set;
-import java.util.StringTokenizer;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DefaultDeploymentSorter;
-import org.jboss.deployment.IncompleteDeploymentException;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.net.protocol.URLLister;
-import org.jboss.net.protocol.URLListerFactory;
-import org.jboss.net.protocol.URLLister.URLFilter;
-import org.jboss.system.server.ServerConfig;
-import org.jboss.system.server.ServerConfigLocator;
-import org.jboss.util.NullArgumentException;
-import org.jboss.util.StringPropertyReplacer;
-
-/**
- * A URL-based deployment scanner. Supports local directory
- * scanning for file-based urls.
- *
- * @jmx:mbean extends="org.jboss.deployment.scanner.DeploymentScannerMBean"
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- */
-public class URLDeploymentScanner extends AbstractDeploymentScanner
- implements DeploymentScanner, URLDeploymentScannerMBean
-{
- /** A set of deployment URLs to skip **/
- protected Set skipSet = Collections.synchronizedSet(new HashSet());
-
- /** The list of URLs to scan. */
- protected List urlList = Collections.synchronizedList(new ArrayList());
-
- /** A set of scanned urls which have been deployed. */
- protected Set deployedSet = Collections.synchronizedSet(new HashSet());
-
- /** Helper for listing local/remote directory URLs */
- protected URLListerFactory listerFactory = new URLListerFactory();
-
- /** The server's home directory, for relative paths. */
- protected File serverHome;
-
- protected URL serverHomeURL;
-
- /** A sorter urls from a scaned directory to allow for coarse dependency
- ordering based on file type
- */
- protected Comparator sorter;
-
- /** Allow a filter for scanned directories */
- protected URLFilter filter;
-
- protected IncompleteDeploymentException lastIncompleteDeploymentException;
-
- /** Whether to search inside directories whose names containing no dots */
- protected boolean doRecursiveSearch = true;
-
- /**
- * @jmx:managed-attribute
- */
- public void setRecursiveSearch (boolean recurse)
- {
- doRecursiveSearch = recurse;
- }
-
- /**
- * @jmx:managed-attribute
- */
- public boolean getRecursiveSearch ()
- {
- return doRecursiveSearch;
- }
-
- /**
- * @jmx:managed-attribute
- */
- public void setURLList(final List list)
- {
- if (list == null)
- throw new NullArgumentException("list");
-
- // start out with a fresh list
- urlList.clear();
-
- Iterator iter = list.iterator();
- while (iter.hasNext())
- {
- URL url = (URL)iter.next();
- if (url == null)
- throw new NullArgumentException("list element");
-
- addURL(url);
- }
-
- log.debug("URL list: " + urlList);
- }
-
- /**
- * @jmx:managed-attribute
- *
- * @param classname The name of a Comparator class.
- */
- public void setURLComparator(String classname)
- throws ClassNotFoundException, IllegalAccessException,
- InstantiationException
- {
- sorter = (Comparator)Thread.currentThread().getContextClassLoader().loadClass(classname).newInstance();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getURLComparator()
- {
- if (sorter == null)
- return null;
- return sorter.getClass().getName();
- }
-
- /**
- * @jmx:managed-attribute
- *
- * @param classname The name of a FileFilter class.
- */
- public void setFilter(String classname)
- throws ClassNotFoundException, IllegalAccessException, InstantiationException
- {
- Class filterClass = Thread.currentThread().getContextClassLoader().loadClass(classname);
- filter = (URLFilter) filterClass.newInstance();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getFilter()
- {
- if (filter == null)
- return null;
- return filter.getClass().getName();
- }
-
-
- /**
- * @jmx:managed-attribute
- *
- * @param filter The URLFilter instance
- */
- public void setFilterInstance(URLFilter filter)
- {
- this.filter = filter;
- }
-
- /**
- * @jmx:managed-attribute
- */
- public URLFilter getFilterInstance()
- {
- return filter;
- }
-
- /**
- * @jmx:managed-attribute
- */
- public List getURLList()
- {
- // too bad, List isn't a cloneable
- return new ArrayList(urlList);
- }
-
- /**
- * @jmx:managed-operation
- */
- public void addURL(final URL url)
- {
- if (url == null)
- throw new NullArgumentException("url");
-
- try
- {
- // check if this is a valid url
- url.openConnection().connect();
- }
- catch (IOException e)
- {
- // either a bad configuration (non-existent url) or a transient i/o error
- log.warn("addURL(), caught " + e.getClass().getName() + ": " + e.getMessage());
- }
- urlList.add(url);
-
- log.debug("Added url: " + url);
- }
-
- /**
- * @jmx:managed-operation
- */
- public void removeURL(final URL url)
- {
- if (url == null)
- throw new NullArgumentException("url");
-
- boolean success = urlList.remove(url);
- if (success)
- {
- log.debug("Removed url: " + url);
- }
- }
-
- /**
- * @jmx:managed-operation
- */
- public boolean hasURL(final URL url)
- {
- if (url == null)
- throw new NullArgumentException("url");
-
- return urlList.contains(url);
- }
-
- /**
- * Temporarily ignore changes (addition, updates, removal) to a particular
- * deployment, identified by its deployment URL. The deployment URL is different
- * from the 'base' URLs that are scanned by the scanner (e.g. the full path to
- * deploy/jmx-console.war vs. deploy/). This can be used to avoid an attempt
- * by the scanner to deploy/redeploy/undeploy a URL that is being modified.
- *
- * To re-enable scanning of changes for a URL, use resumeDeployment(URL, boolean).
- *
- * @jmx:managed-operation
- */
- public void suspendDeployment(URL url)
- {
- if (url == null)
- throw new NullArgumentException("url");
-
- if (skipSet.add(url))
- log.debug("Deployment URL added to skipSet: " + url);
- else
- throw new IllegalStateException("Deployment URL already suspended: " + url);
- }
-
- /**
- * Re-enables scanning of a particular deployment URL, previously suspended
- * using suspendDeployment(URL). If the markUpToDate flag is true then the
- * deployment module will be considered up-to-date during the next scan.
- * If the flag is false, at the next scan the scanner will check the
- * modification date to decide if the module needs deploy/redeploy/undeploy.
- *
- * @jmx:managed-operation
- */
- public void resumeDeployment(URL url, boolean markUpToDate)
- {
- if (url == null)
- throw new NullArgumentException("url");
-
- if (skipSet.contains(url))
- {
- if (markUpToDate)
- {
- // look for the deployment and mark it as uptodate
- for (Iterator i = deployedSet.iterator(); i.hasNext(); )
- {
- DeployedURL deployedURL = (DeployedURL)i.next();
- if (deployedURL.url.equals(url))
- {
- // the module could have been removed..
- log.debug("Marking up-to-date: " + url);
- deployedURL.deployed();
- break;
- }
- }
- }
- // don't skip this url anymore
- skipSet.remove(url);
- log.debug("Deployment URL removed from skipSet: " + url);
- }
- else
- {
- throw new IllegalStateException("Deployment URL not suspended: " + url);
- }
- }
-
- /**
- * Lists all urls deployed by the scanner, each URL on a new line.
- *
- * @jmx:managed-operation
- */
- public String listDeployedURLs()
- {
- StringBuffer sbuf = new StringBuffer();
- for (Iterator i = deployedSet.iterator(); i.hasNext(); )
- {
- URL url = ((DeployedURL)i.next()).url;
- if (sbuf.length() > 0)
- {
- sbuf.append("\n").append(url);
- }
- else
- {
- sbuf.append(url);
- }
- }
- return sbuf.toString();
- }
-
- /////////////////////////////////////////////////////////////////////////
- // Management/Configuration Helpers //
- /////////////////////////////////////////////////////////////////////////
-
- /**
- * @jmx:managed-attribute
- */
- public void setURLs(final String listspec) throws MalformedURLException
- {
- if (listspec == null)
- throw new NullArgumentException("listspec");
-
- List list = new LinkedList();
-
- StringTokenizer stok = new StringTokenizer(listspec, ",");
- while (stok.hasMoreTokens())
- {
- String urlspec = stok.nextToken().trim();
- log.debug("Adding URL from spec: " + urlspec);
-
- URL url = makeURL(urlspec);
- log.debug("URL: " + url);
-
- list.add(url);
- }
-
- setURLList(list);
- }
-
- /**
- * A helper to make a URL from a full url, or a filespec.
- */
- protected URL makeURL(String urlspec) throws MalformedURLException
- {
- // First replace URL with appropriate properties
- //
- urlspec = StringPropertyReplacer.replaceProperties (urlspec);
- return new URL(serverHomeURL, urlspec);
- }
-
- /**
- * @jmx:managed-operation
- */
- public void addURL(final String urlspec) throws MalformedURLException
- {
- addURL(makeURL(urlspec));
- }
-
- /**
- * @jmx:managed-operation
- */
- public void removeURL(final String urlspec) throws MalformedURLException
- {
- removeURL(makeURL(urlspec));
- }
-
- /**
- * @jmx:managed-operation
- */
- public boolean hasURL(final String urlspec) throws MalformedURLException
- {
- return hasURL(makeURL(urlspec));
- }
-
- /**
- * A helper to deploy the given URL with the deployer.
- */
- protected void deploy(final DeployedURL du)
- {
- // If the deployer is null simply ignore the request
- if (deployer == null)
- return;
-
- try
- {
- if (log.isTraceEnabled())
- log.trace("Deploying: " + du);
-
- deployer.deploy(du.url);
- }
- catch (IncompleteDeploymentException e)
- {
- lastIncompleteDeploymentException = e;
- }
- catch (Exception e)
- {
- log.debug("Failed to deploy: " + du, e);
- }
-
- du.deployed();
-
- if (!deployedSet.contains(du))
- {
- deployedSet.add(du);
- }
- }
-
- /**
- * A helper to undeploy the given URL from the deployer.
- */
- protected void undeploy(final DeployedURL du)
- {
- try
- {
- if (log.isTraceEnabled())
- log.trace("Undeploying: " + du);
-
- deployer.undeploy(du.url);
- deployedSet.remove(du);
- }
- catch (Exception e)
- {
- log.error("Failed to undeploy: " + du, e);
- }
- }
-
- /**
- * Checks if the url is in the deployed set.
- */
- protected boolean isDeployed(final URL url)
- {
- DeployedURL du = new DeployedURL(url);
- return deployedSet.contains(du);
- }
-
- public synchronized void scan() throws Exception
- {
- lastIncompleteDeploymentException = null;
- if (urlList == null)
- throw new IllegalStateException("not initialized");
-
- updateSorter();
-
- boolean trace = log.isTraceEnabled();
- List urlsToDeploy = new LinkedList();
-
- // Scan for deployments
- if (trace)
- {
- log.trace("Scanning for new deployments");
- }
- synchronized (urlList)
- {
- for (Iterator i = urlList.iterator(); i.hasNext();)
- {
- URL url = (URL) i.next();
- try
- {
- if (url.toString().endsWith("/"))
- {
- // treat URL as a collection
- URLLister lister = listerFactory.createURLLister(url);
-
- // listMembers() will throw an IOException if collection url does not exist
- urlsToDeploy.addAll(lister.listMembers(url, filter, doRecursiveSearch));
- }
- else
- {
- // treat URL as a deployable unit
-
- // throws IOException if this URL does not exist
- url.openConnection().connect();
- urlsToDeploy.add(url);
- }
- }
- catch (IOException e)
- {
- // Either one of the configured URLs is bad, i.e. points to a non-existent
- // location, or it ends with a '/' but it is not a directory (so it
- // is really user's fault), OR some other hopefully transient I/O error
- // happened (e.g. out of file descriptors?) so log a warning.
- log.warn("Scan URL, caught " + e.getClass().getName() + ": " + e.getMessage());
-
- // We need to return because at least one of the listed URLs will
- // return no results, and so all deployments starting from that point
- // (e.g. deploy/) will get undeployed, see JBAS-3107.
- // On the other hand, in case of a bad configuration nothing will get
- // deployed. If really want independence of e.g. 2 deploy urls, more
- // than one URLDeploymentScanners can be setup.
- return;
- }
- }
- }
-
- if (trace)
- {
- log.trace("Updating existing deployments");
- }
- LinkedList urlsToRemove = new LinkedList();
- LinkedList urlsToCheckForUpdate = new LinkedList();
- synchronized (deployedSet)
- {
- // remove previously deployed URLs no longer needed
- for (Iterator i = deployedSet.iterator(); i.hasNext();)
- {
- DeployedURL deployedURL = (DeployedURL) i.next();
-
- if (skipSet.contains(deployedURL.url))
- {
- if (trace)
- log.trace("Skipping update/removal check for: " + deployedURL.url);
- }
- else
- {
- if (urlsToDeploy.contains(deployedURL.url))
- {
- urlsToCheckForUpdate.add(deployedURL);
- }
- else
- {
- urlsToRemove.add(deployedURL);
- }
- }
- }
- }
-
- // ********
- // Undeploy
- // ********
-
- for (Iterator i = urlsToRemove.iterator(); i.hasNext();)
- {
- DeployedURL deployedURL = (DeployedURL) i.next();
- if (trace)
- {
- log.trace("Removing " + deployedURL.url);
- }
- undeploy(deployedURL);
- }
-
- // ********
- // Redeploy
- // ********
-
- // compute the DeployedURL list to update
- ArrayList urlsToUpdate = new ArrayList(urlsToCheckForUpdate.size());
- for (Iterator i = urlsToCheckForUpdate.iterator(); i.hasNext();)
- {
- DeployedURL deployedURL = (DeployedURL) i.next();
- if (deployedURL.isModified())
- {
- if (trace)
- {
- log.trace("Re-deploying " + deployedURL.url);
- }
- urlsToUpdate.add(deployedURL);
- }
- }
-
- // sort to update list
- Collections.sort(urlsToUpdate, new Comparator()
- {
- public int compare(Object o1, Object o2)
- {
- return sorter.compare(((DeployedURL) o1).url, ((DeployedURL) o2).url);
- }
- });
-
- // Undeploy in order
- for (int i = urlsToUpdate.size() - 1; i >= 0;i--)
- {
- undeploy((DeployedURL) urlsToUpdate.get(i));
- }
-
- // Deploy in order
- for (int i = 0; i < urlsToUpdate.size();i++)
- {
- deploy((DeployedURL) urlsToUpdate.get(i));
- }
-
- // ******
- // Deploy
- // ******
-
- Collections.sort(urlsToDeploy, sorter);
- for (Iterator i = urlsToDeploy.iterator(); i.hasNext();)
- {
- URL url = (URL) i.next();
- DeployedURL deployedURL = new DeployedURL(url);
- if (deployedSet.contains(deployedURL) == false)
- {
- if (skipSet.contains(url))
- {
- if (trace)
- log.trace("Skipping deployment of: " + url);
- }
- else
- {
- if (trace)
- log.trace("Deploying " + deployedURL.url);
-
- deploy(deployedURL);
- }
- }
- i.remove();
- // Check to see if mainDeployer suffix list has changed.
- // if so, then resort
- if (i.hasNext() && updateSorter())
- {
- Collections.sort(urlsToDeploy, sorter);
- i = urlsToDeploy.iterator();
- }
- }
-
- // Validate that there are still incomplete deployments
- if (lastIncompleteDeploymentException != null)
- {
- try
- {
- Object[] args = {};
- String[] sig = {};
- getServer().invoke(getDeployer(),
- "checkIncompleteDeployments", args, sig);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error(t);
- }
- }
- }
-
- protected boolean updateSorter()
- {
- // Check to see if mainDeployer suffix list has changed.
- if (sorter instanceof DefaultDeploymentSorter)
- {
- DefaultDeploymentSorter defaultSorter = (DefaultDeploymentSorter)sorter;
- if (defaultSorter.getSuffixOrder() != mainDeployer.getSuffixOrder())
- {
- defaultSorter.setSuffixOrder(mainDeployer.getSuffixOrder());
- return true;
- }
- }
- return false;
- }
-
- /////////////////////////////////////////////////////////////////////////
- // Service/ServiceMBeanSupport //
- /////////////////////////////////////////////////////////////////////////
-
- public ObjectName preRegister(MBeanServer server, ObjectName name)
- throws Exception
- {
- // get server's home for relative paths, need this for setting
- // attribute final values, so we need to do it here
- ServerConfig serverConfig = ServerConfigLocator.locate();
- serverHome = serverConfig.getServerHomeDir();
- serverHomeURL = serverConfig.getServerHomeURL();
-
- return super.preRegister(server, name);
- }
-
- protected void createService() throws Exception
- {
- // Perform a couple of sanity checks
- if (this.filter == null)
- {
- throw new IllegalStateException("'FilterInstance' attribute not configured");
- }
- if (this.sorter == null)
- {
- throw new IllegalStateException("'URLComparator' attribute not configured");
- }
- // ok, proceed with normal createService()
- super.createService();
- }
-
- /////////////////////////////////////////////////////////////////////////
- // DeployedURL //
- /////////////////////////////////////////////////////////////////////////
-
- /**
- * A container and help class for a deployed URL.
- * should be static at this point, with the explicit scanner ref, but I'm (David) lazy.
- */
- protected class DeployedURL
- {
- public URL url;
- /** The url to check to decide if we need to redeploy */
- public URL watchUrl;
-
- public long deployedLastModified;
-
- public DeployedURL(final URL url)
- {
- this.url = url;
- }
-
- public void deployed()
- {
- deployedLastModified = getLastModified();
- }
- public boolean isFile()
- {
- return url.getProtocol().equals("file");
- }
-
- public File getFile()
- {
- return new File(url.getFile());
- }
-
- public boolean isRemoved()
- {
- if (isFile())
- {
- File file = getFile();
- return !file.exists();
- }
- return false;
- }
-
- public long getLastModified()
- {
- if (watchUrl == null)
- {
- try
- {
- Object o = getServer().invoke(
- getDeployer(),
- "getWatchUrl",
- new Object[] { url },
- new String[] { URL.class.getName() }
- );
- watchUrl = o == null ? url : (URL)o;
- getLog().debug("Watch URL for: " + url + " -> " + watchUrl);
- }
- catch (Exception e)
- {
- watchUrl = url;
- getLog().debug("Unable to obtain watchUrl from deployer. Use url: " + url, e);
- }
- }
-
- try
- {
- URLConnection connection;
- if (watchUrl != null)
- {
- connection = watchUrl.openConnection();
- }
- else
- {
- connection = url.openConnection();
- }
- // no need to do special checks for files...
- // org.jboss.net.protocol.file.FileURLConnection correctly
- // implements the getLastModified method.
- long lastModified = connection.getLastModified();
-
- return lastModified;
- }
- catch (java.io.IOException e)
- {
- log.warn("Failed to check modification of deployed url: " + url, e);
- }
- return -1;
- }
-
- public boolean isModified()
- {
- long lastModified = getLastModified();
- if (lastModified == -1)
- {
- // ignore errors fetching the timestamp - see bug 598335
- return false;
- }
- return deployedLastModified != lastModified;
- }
-
- public int hashCode()
- {
- return url.hashCode();
- }
-
- public boolean equals(final Object other)
- {
- if (other instanceof DeployedURL)
- {
- return ((DeployedURL)other).url.equals(this.url);
- }
- return false;
- }
-
- public String toString()
- {
- return super.toString() +
- "{ url=" + url +
- ", deployedLastModified=" + deployedLastModified +
- " }";
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScanner.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,99 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.deployment.scanner;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.List;
-
-import org.jboss.net.protocol.URLLister.URLFilter;
-
-/**
- * URLDeploymentScanner MBean interface.
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public interface URLDeploymentScannerMBean extends DeploymentScannerMBean
-{
- // Attributes ----------------------------------------------------
-
- void setRecursiveSearch(boolean recurse);
- boolean getRecursiveSearch();
-
- void setURLList(List list);
- List getURLList();
-
- void setURLComparator(String classname)
- throws ClassNotFoundException, IllegalAccessException, InstantiationException;
- String getURLComparator();
-
- void setFilter(String classname)
- throws ClassNotFoundException, IllegalAccessException, InstantiationException;
- String getFilter();
-
- void setFilterInstance(URLFilter filter);
- URLFilter getFilterInstance();
-
- void setURLs(String listspec) throws MalformedURLException;
-
- // Operations ----------------------------------------------------
-
- void addURL(URL url);
-
- void removeURL(URL url);
-
- boolean hasURL(URL url);
-
- void addURL(String urlspec) throws MalformedURLException;
-
- void removeURL(String urlspec) throws MalformedURLException;
-
- boolean hasURL(String urlspec) throws MalformedURLException;
-
- /**
- * Temporarily ignore changes (addition, updates, removal) to a particular
- * deployment, identified by its deployment URL. The deployment URL is different
- * from the 'base' URLs that are scanned by the scanner (e.g. the full path to
- * deploy/jmx-console.war vs. deploy/). This can be used to avoid an attempt
- * by the scanner to deploy/redeploy/undeploy a URL that is being modified.
- *
- * To re-enable scanning of changes for a URL, use resumeDeployment(URL, boolean).
- */
- void suspendDeployment(URL url);
-
- /**
- * Re-enables scanning of a particular deployment URL, previously suspended
- * using suspendDeployment(URL). If the markUpToDate flag is true then the
- * deployment module will be considered up-to-date during the next scan.
- * If the flag is false, at the next scan the scanner will check the
- * modification date to decide if the module needs deploy/redeploy/undeploy.
- */
- void resumeDeployment(URL url, boolean markUpToDate);
-
- /**
- * Lists all urls deployed by the scanner, each URL on a new line.
- */
- public String listDeployedURLs();
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/URLDeploymentScannerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/deployment/scanner/package.html
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/package.html 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/deployment/scanner/package.html 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,41 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
- <head>
- <!-- $Id$ -->
- <!--
-
- JBoss: The OpenSource J2EE WebOS
-
- Distributable under LGPL license.
- See terms of license at gnu.org.
-
- -->
- </head>
-
- <body bgcolor="white">
- <p>Deployment scanning framework and components.
-
- <h2>Package Specification</h2>
- <ul>
- <li><a href="javascript: alert('not available')">Not Available</a>
- </ul>
-
- <h2>Related Documentation</h2>
- <ul>
- <li><a href="javascript: alert('not available')">Not Available</a>
- </ul>
-
- <h2>Package Status</h2>
- <ul>
- <li><font color="green"><b>STABLE</b></font>
- </ul>
-
- <h2>Todo</h2>
- <ul>
- <li>???
- </ul>
-
- <!-- Put @see and @since tags down here. -->
-
- </body>
-</html>
Copied: trunk/system-jmx/src/main/org/jboss/deployment/scanner/package.html (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/deployment/scanner/package.html)
Property changes on: trunk/system-jmx/src/main/org/jboss/deployment/scanner/package.html
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/system-jmx/src/main/org/jboss/system (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system)
Deleted: trunk/system-jmx/src/main/org/jboss/system/BarrierController.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/BarrierController.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/BarrierController.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,396 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.Notification;
-import javax.management.ObjectName;
-
-/**
- * BarrierController service.
- *
- * A service that controls the lifecycle of a secondary mbean
- * (the BarrierMbean) that can be used as a dependency for other
- * services.
- *
- * Starting and stopping the barrier mbean (and as a result
- * all services depending on it) is performed by listening
- * for any kind of JMX notification. In particular we use
- * the handback object of a notification subscription to
- * qualify the start and stop signals.
- *
- * Manual control of the barrier is also supported through
- * startBarrier()/stopBarrier() methods.
- *
- * You may subclass BarrierController and override enableOnStartup()
- * to apply complex logic in deciding whether to initially start
- * the barrier (e.g. query some other mbean).
- *
- * @jmx:mbean
- * extends="org.jboss.system.ListenerServiceMBean"
- * name="jboss:service=BarrierController"
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class BarrierController extends ListenerServiceMBeanSupport
- implements BarrierControllerMBean
-{
- // Private Data --------------------------------------------------
-
- /** The ObjectName of the Barrier MBean */
- private ObjectName barrierName;
-
- /** The initial state of the barrier */
- private Boolean enableOnStartup;
-
- /** The notification subscription handback string that starts the barrier */
- private String startHandback;
-
- /** The notification subscription handback string that stops the barrier */
- private String stopHandback;
-
- /** The dynamic subscriptions flag */
- private Boolean dynamicSubscriptions;
-
- // Protected Data ------------------------------------------------
-
- /** The controlled Barrier */
- protected Barrier barrier;
-
- // Constructors --------------------------------------------------
-
- /**
- * Default CTOR
- */
- public BarrierController()
- {
- // empty
- }
-
- // Attributes ----------------------------------------------------
-
- /**
- * The controlled barrier StateString.
- *
- * @jmx.managed-attribute
- */
- public String getBarrierStateString()
- {
- return (barrier != null) ? barrier.getStateString() : null;
- }
-
- /**
- * The controlled barrier ObjectName.
- *
- * @jmx.managed-attribute
- */
- public void setBarrierObjectName(ObjectName barrierName)
- {
- // set once
- if (this.barrierName == null)
- {
- this.barrierName = barrierName;
- }
- }
-
- /**
- * The controlled barrier ObjectName.
- *
- * @jmx.managed-attribute
- */
- public ObjectName getBarrierObjectName()
- {
- return barrierName;
- }
-
-
- /**
- * The initial state of the barrier.
- *
- * If set, it overrides the internal call to enableOnStartup()
- * which will never get called.
- *
- * @jmx.managed-attribute
- */
- public void setBarrierEnabledOnStartup(Boolean enableOnStartup)
- {
- // set once
- if (this.enableOnStartup == null)
- {
- this.enableOnStartup = enableOnStartup;
- }
- }
-
- /**
- * The initial state of the barrier.
- *
- * Use the value set through setBarrierEnabledOnStartup()
- * otherwise call the internal enableOnStartup() override
- * to make a decision.
- *
- * @jmx.managed-attribute
- */
- public Boolean getBarrierEnabledOnStartup()
- {
- if (enableOnStartup == null)
- {
- // setBarrierEnabledOnStartup() not called
- // initialize through enableOnStartup()
- enableOnStartup = enableOnStartup();
- }
- return enableOnStartup;
- }
-
- /**
- * The notification subscription handback string that starts the barrier.
- *
- * @jmx.managed-attribute
- */
- public void setStartBarrierHandback(String startHandback)
- {
- // set once
- if (this.startHandback == null)
- {
- this.startHandback = startHandback;
- }
- }
-
- /**
- * The notification subscription handback string that starts the barrier.
- *
- * @jmx.managed-attribute
- */
- public String getStartBarrierHandback()
- {
- return startHandback;
- }
-
- /**
- * The notification subscription handback string that stops the barrier.
- *
- * @jmx.managed-attribute
- */
- public void setStopBarrierHandback(String stopHandback)
- {
- // set once
- if (this.stopHandback == null)
- {
- this.stopHandback = stopHandback;
- }
- }
-
- /**
- * The notification subscription handback string that stops the barrier.
- *
- * @jmx.managed-attribute
- */
- public String getStopBarrierHandback()
- {
- return stopHandback;
- }
-
- /**
- * The ability to dynamically subscribe for notifications.
- *
- * @jmx.managed-attribute
- */
- public void setDynamicSubscriptions(Boolean dynamicSubscriptions)
- {
- // set once
- if (this.dynamicSubscriptions == null)
- {
- this.dynamicSubscriptions = dynamicSubscriptions;
- }
- }
-
- /**
- * The ability to dynamically subscribe for notifications.
- *
- * @jmx.managed-attribute
- */
- public Boolean getDynamicSubscriptions()
- {
- if (dynamicSubscriptions == null)
- {
- dynamicSubscriptions = Boolean.TRUE;
- }
- return dynamicSubscriptions;
- }
-
- // Override ------------------------------------------------------
-
- /**
- * Override this method to apply complex logic whether
- * to start the Barrier service upon startup or not.
- *
- * This method will be only called once and only if
- * setBarrierEnabledOnStartup(Boolean) has not been called.
- *
- * The default implementation is to return false.
- */
- protected Boolean enableOnStartup()
- {
- return Boolean.FALSE;
- }
-
- // Lifecycle -----------------------------------------------------
-
- protected void createService() throws Exception
- {
- // create the Barrier
- barrier = new Barrier(getServiceName());
-
- // register with the MBeanServer
- getServer().registerMBean(barrier, barrierName);
-
- // implicitly call the ServiceController
- barrier.create();
-
- // conditionally start the barrier
- if (getBarrierEnabledOnStartup().booleanValue())
- {
- startBarrier();
- }
- // subscribe for notifications
- subscribe(getDynamicSubscriptions().booleanValue());
- }
-
- protected void destroyService()
- {
- // unsubscribe for notifications
- unsubscribe();
-
- try
- {
- // implicitly call the ServiceController
- barrier.destroy();
-
- // remove from MBeanServer
- getServer().unregisterMBean(barrierName);
- }
- catch (Throwable e)
- {
- log.debug("Unexpected error during destroy", e);
- }
-
- // cleanup
- barrier = null;
- }
-
- // ListenerServiceMBeanSupport -----------------------------------
-
- /**
- * Base on the handback object the decision
- * for starting/stopping the barrier
- */
- public void handleNotification2(Notification n, Object handback)
- {
- log.debug("Got notification: " + n);
-
- if (startHandback != null && startHandback.equals(handback))
- {
- log.debug("Saw '" + handback + "' handback, starting barrier");
- startBarrier();
- }
- else if (stopHandback != null && stopHandback.equals(handback))
- {
- log.debug("Saw '" + handback + "' handback, stopping barrier");
- stopBarrier();
- }
- }
-
- // Operations ----------------------------------------------------
-
- /**
- * Manually start the controlled barrier
- *
- * @jmx:managed-operation
- */
- public void startBarrier()
- {
- try
- {
- // implicitly call the ServiceController
- barrier.start();
- }
- catch (Throwable e)
- {
- log.warn("Failed to start barrier: " + barrierName, e);
- }
- }
-
- /**
- * Manually stop the controlled barrier
- *
- * @jmx:managed-operation
- */
- public void stopBarrier()
- {
- try
- {
- // implicitly call the ServiceController
- barrier.stop();
- }
- catch (Throwable e)
- {
- log.warn("Failed to stop barrier: " + barrierName, e);
- }
- }
-
- // Inner Class ---------------------------------------------------
-
- /**
- * The controlled barrier MBean interface
- */
- public static interface BarrierMBean
- {
- /** We just want to expose those attributes */
- ObjectName getBarrierController();
- String getStateString();
- int getState();
-
- /** Hook up with the ServiceController */
- void jbossInternalLifecycle(String method) throws Exception;
- }
-
- /**
- * The controlled barrier MBean class
- */
- public static class Barrier extends ServiceMBeanSupport implements BarrierMBean
- {
- /** The parent Controller */
- private ObjectName barrierController;
-
- /** CTOR */
- public Barrier(ObjectName barrierController)
- {
- this.barrierController = barrierController;
- }
-
- /** Accessor */
- public ObjectName getBarrierController()
- {
- return barrierController;
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/BarrierController.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/BarrierController.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/BarrierController.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,67 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.ObjectName;
-
-/**
- * BarrierController service interface
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public interface BarrierControllerMBean extends ListenerServiceMBean
-{
- // Attributes ----------------------------------------------------
-
- /** The controlled barrier StateString */
- String getBarrierStateString();
-
- /** The controlled barrier ObjectName */
- void setBarrierObjectName(ObjectName barrierName);
- ObjectName getBarrierObjectName();
-
- /** The initial state of the barrier */
- void setBarrierEnabledOnStartup(Boolean enableOnStartup);
- Boolean getBarrierEnabledOnStartup();
-
- /** The notification subscription handback string that starts the barrier */
- void setStartBarrierHandback(String startHandback);
- String getStartBarrierHandback();
-
- /** The notification subscription handback string that stops the barrier */
- void setStopBarrierHandback(String stopHandback);
- String getStopBarrierHandback();
-
- /** The ability to dynamically subscribe for notifications */
- void setDynamicSubscriptions(Boolean dynamicSubscriptions);
- Boolean getDynamicSubscriptions();
-
- // Operations ----------------------------------------------------
-
- /** Manually start the controlled barrier */
- void startBarrier();
-
- /** Manually stop the controlled barrier */
- void stopBarrier();
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/BarrierControllerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ConfigurationException.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ConfigurationException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ConfigurationException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,74 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import org.jboss.util.NestedException;
-
-/**
- * Thrown to indicate a non-fatal configuration related problem.
- *
- * @see ConfigurationService
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version <tt>$Revision$</tt>
- */
-public class ConfigurationException
- extends NestedException
-{
- /**
- * Construct a <tt>ConfigurationException</tt> with the specified detail
- * message.
- *
- * @param msg Detail message.
- */
- public ConfigurationException(String msg) {
- super(msg);
- }
-
- /**
- * Construct a <tt>ConfigurationException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param msg Detail message.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public ConfigurationException(String msg, Throwable nested) {
- super(msg, nested);
- }
-
- /**
- * Construct a <tt>ConfigurationException</tt> with the specified
- * nested <tt>Throwable</tt>.
- *
- * @param nested Nested <tt>Throwable</tt>.
- */
- public ConfigurationException(Throwable nested) {
- super(nested);
- }
-
- /**
- * Construct a <tt>ConfigurationException</tt> with no detail.
- */
- public ConfigurationException() {
- super();
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ConfigurationException.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ConfigurationException.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ConfigurationException.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,47 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.List;
-
-/**
- * MBean interface for services that dynamically attach an
- * interceptor to a set of target Interceptable (X)MBeans.
- *
- * @see InterceptorServiceMBeanSupport
- * @see org.jboss.mx.server.Interceptable
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public interface InterceptorServiceMBean extends ServiceMBean
-{
- // Attributes ----------------------------------------------------
-
- /**
- * The ObjectNames of the MBeans implementing the operations
- * in the org.jboss.mx.server.Interceptable interface
- */
- void setInterceptables(List interceptables);
- List getInterceptables();
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,275 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.interceptor.AbstractInterceptor;
-import org.jboss.mx.interceptor.DynamicInterceptor;
-import org.jboss.mx.interceptor.Interceptor;
-import org.jboss.mx.server.Invocation;
-
-/**
- * Helper class that can be used for writing MBean Services
- * that dynamically hook-up an Interceptor to other (X)MBeans
- * that have been configured as Interceptable.
- *
- * In a nutshell, call attach()/detach() from your
- * createService()/destroyService() or startService()/stopService()
- * pair methods to attach/detach an interceptor to the target mbean(s),
- * then override invoke() to do something with the invocations.
- *
- * You may also provide your own Interceptor, in which case
- * you should call attach(Interceptor).
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public abstract class InterceptorServiceMBeanSupport extends ServiceMBeanSupport
- implements InterceptorServiceMBean
-{
- // Private Data --------------------------------------------------
-
- /** The Interceptables to attach to */
- private List interceptables;
-
- /** The attached interceptor */
- private Interceptor interceptor;
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- */
- public InterceptorServiceMBeanSupport()
- {
- super();
- }
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param type The class type to determine Logger name from.
- */
- public InterceptorServiceMBeanSupport(final Class type)
- {
- super(type);
- }
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param category The logger category name.
- */
- public InterceptorServiceMBeanSupport(final String category)
- {
- super(category);
- }
-
- /**
- * Constructs an <tt>InterceptorServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param log The logger to use.
- */
- public InterceptorServiceMBeanSupport(final Logger log)
- {
- super(log);
- }
-
- // InterceptorServiceMBean ---------------------------------------
-
- public void setInterceptables(List interceptables)
- {
- // copy
- if (interceptables != null)
- {
- this.interceptables = new ArrayList(interceptables);
- }
- }
-
- public List getInterceptables()
- {
- // return a copy
- if (interceptables != null)
- {
- return new ArrayList(interceptables);
- }
- return null;
- }
-
- // Protected API -------------------------------------------------
-
- /**
- * Add our interceptor to the target Interceptables.
- *
- * Override invoke(Invocation) to handle the calls.
- *
- * @throws Exception thrown on any interceptor registration error
- */
- protected void attach() throws Exception
- {
- if (interceptor == null)
- {
- attach(new XMBeanInterceptor());
- }
- }
-
- /**
- * Add the provided interceptor to the target Interceptables.
- *
- * @param interceptor the interceptor to add
- * @throws Exception thrown on any interceptor registration error
- */
- protected void attach(Interceptor interceptor) throws Exception
- {
- if (interceptor == null)
- {
- throw new IllegalArgumentException("Null interceptor");
- }
-
- // check we haven't attached already
- if (this.interceptor != null)
- {
- throw new IllegalStateException("Interceptor already attached");
- }
-
- log.debug("Attaching interceptor: " + interceptor.getName());
-
- // remember the interceptor
- this.interceptor = interceptor;
-
- // add the interceptor to the Interceptables; an exception
- // will be thrown if any of them is not Interceptable,
- // in which case detach() should be called.
- if (interceptables != null)
- {
- Object[] params = new Object[] { interceptor };
- String[] signature = new String[] { Interceptor.class.getName() };
-
- for (Iterator i = interceptables.iterator(); i.hasNext(); )
- {
- ObjectName target = (ObjectName)i.next();
- super.server.invoke(target,
- DynamicInterceptor.ADD_INTERCEPTOR,
- params,
- signature);
-
- log.debug("Interceptor attached to: '" + target + "'");
- }
- }
- }
-
- /**
- * Remove the interceptor from the target Interceptables
- */
- protected void detach()
- {
- if (interceptor != null)
- {
- log.debug("Detaching interceptor: " + interceptor.getName());
- if (interceptables != null)
- {
- Object[] params = new Object[] { interceptor };
- String[] signature = new String[] { Interceptor.class.getName() };
-
- for (Iterator i = interceptables.iterator(); i.hasNext(); )
- {
- ObjectName target = (ObjectName)i.next();
- try
- {
- super.server.invoke(target,
- DynamicInterceptor.REMOVE_INTERCEPTOR,
- params,
- signature);
-
- log.debug("Interceptor detached from: '" + target + "'");
- }
- catch (Exception e)
- {
- log.debug("Caught exception while removing interceptor from '" +
- target + "'", e);
- }
- }
- }
- interceptor = null;
- }
- }
-
- /**
- * Use this to forward the call
- */
- protected Object invokeNext(Invocation invocation) throws Throwable
- {
- // call the next in the interceptor chain,
- // if nobody follows dispatch the call
- Interceptor next = invocation.nextInterceptor();
- if (next != null)
- {
- return next.invoke(invocation);
- }
- else
- {
- return invocation.dispatch();
- }
- }
-
- // Override ------------------------------------------------------
-
- /**
- * Override
- */
- protected Object invoke(Invocation invocation) throws Throwable
- {
- return invokeNext(invocation);
- }
-
- // Private Inner Class -------------------------------------------
-
- /**
- * Simple Interceptor delegating to
- * the invoke(Invocation) callback
- */
- private class XMBeanInterceptor extends AbstractInterceptor
- {
- public XMBeanInterceptor()
- {
- super("XMBeanInterceptor('" + InterceptorServiceMBeanSupport.this.getServiceName() + "')");
- }
-
- public Object invoke(Invocation invocation) throws Throwable
- {
- // delegate
- return InterceptorServiceMBeanSupport.this.invoke(invocation);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/InterceptorServiceMBeanSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * Thrown to indicate that a given attribute value is not valid.
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version <tt>$Revision$</tt>
- */
-public class InvalidAttributeException
- extends ConfigurationException
-{
- /**
- * Construct a <tt>InvalidAttributeException</tt> with the
- * specified detail message.
- *
- * @param name The attribute name.
- * @param msg The detail message.
- */
- public InvalidAttributeException(final String name, final String msg) {
- super(makeMessage(name, msg));
- }
-
- /**
- * Construct a <tt>InvalidAttributeException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param name The attribute name.
- * @param msg The detail message.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public InvalidAttributeException(final String name, final String msg, final Throwable nested)
- {
- super(makeMessage(name, msg), nested);
- }
-
- /**
- * Make a execption message for the attribute name and detail message.
- */
- private static String makeMessage(final String name, final String msg) {
- return "Invalid value for attribute '" + name + "': " + msg;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/InvalidAttributeException.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,123 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * An extension of the ServiceMBean interface that provides for
- * declarative JMX notification subscription handling.
- * <p>
- * The SubscriptionList attribute is used to specify the list
- * of MBeans/notifications that the listener service instance
- * will subscribe for.
- * <p>
- * The abstract class ListenerServiceMBeanSupport implements
- * this interface.
- *
- * @see ServiceMBean
- * @see ListenerServiceMBeanSupport
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public interface ListenerServiceMBean
- extends ServiceMBean
-{
- // Constants -----------------------------------------------------
-
- /** The XML subscription-list elements and attributes */
- public static final String SL_ROOT_ELEMENT = "subscription-list";
- public static final String SL_MBEAN_ELEMENT = "mbean";
- public static final String SL_FILTER_ELEMENT = "filter";
- public static final String SL_NOTIFICATION_ELEMENT = "notification";
- public static final String SL_MBEAN_NAME_ATTRIBUTE = "name";
- public static final String SL_MBEAN_HANDBACK_ATTRIBUTE = "handback";
- public static final String SL_FILTER_FACTORY_ATTRIBUTE = "factory";
- public static final String SL_NOTIFICATION_TYPE_ATTRIBUTE = "type";
-
- // Public --------------------------------------------------------
-
- /**
- * Used to configure at start-up the JMX notification subscriptions.
- *
- * The configuration is done inline in the mbean descriptor. For example:
- *
- * <code>
- * ...
- * <attribute name="SubscriptionList">
- * <subscription-list>
- * <mbean name="jboss.system:*">
- * <notification type="org.jboss.system.ServiceMBean.start"/>
- * <notification type="org.jboss.system.ServiceMBean.stop"/>
- * </mbean>
- * </subscription-list>
- * </attribute>
- * ...
- * </code>
- *
- * The filter mechanism has been extended to support specification
- * of arbitrary filters, using filter factory plugins:
- *
- * <code>
- * ...
- * <attribute name="SubscriptionList">
- * <subscription-list>
- * <mbean name="jboss.system:*">
- * <filter factory="NotificationFilterSupportFactory">
- * <enable type="org.jboss.system.ServiceMBean.start"/>
- * <enable type="org.jboss.system.ServiceMBean.stop"/>
- * </filter>
- * </mbean>
- * <mbean name="jboss.monitor:service=MemoryMonitor">
- * <filter factory="AttributeChangeNotificationFilterFactory">
- * <enable attribute-name="State"/>
- * </filter>
- * </mbean>
- * <mbean name="JMImplementation:type=MBeanServerDelegate">
- * <filter factory="MBeanServerNotificationFilterFactory">
- * <enable type="JMX.mbean"/>
- * <enable object-name="jboss:type=Service,name=SystemProperties"/>
- * </filter>
- * </mbean>
- * </subscription-list>
- * </attribute>
- * ...
- * </code>
- *
- * 'factory' is the full class name of a class that implements the
- * org.jboss.system.NotificationFilterFactory interface. If the
- * class cannot be loaded, a second attempt is made to load the
- * class from within the org.jboss.system.filterfactory package.
- *
- * Three NotificationFilterFactories corresponding to the three
- * "standard" jmx notification filters, have been pre-packaged.
- *
- * Those are:
- *
- * @see org.jboss.system.filterfactory.AttributeChangeNotificationFilterFactory
- * @see org.jboss.system.filterfactory.MBeanServerNotificationFilterFactory
- * @see org.jboss.system.filterfactory.NotificationFilterSupportFactory
- *
- * See also jboss-subscription.dtd
- **/
- public void setSubscriptionList(org.w3c.dom.Element list);
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,809 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import javax.management.InstanceNotFoundException;
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanServer;
-import javax.management.MBeanServerNotification;
-import javax.management.MalformedObjectNameException;
-import javax.management.Notification;
-import javax.management.NotificationFilter;
-import javax.management.NotificationFilterSupport;
-import javax.management.NotificationListener;
-import javax.management.ObjectName;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * An abstract base class that provides for declarative JMX notification
- * subscription handling.
- * <p>
- * A JBoss service that is in addition a NotificationListener can
- * subclass ListenerServiceMBeanSupport instead of ServiceMBeanSupport
- * and specify at run-time, inline in the MBean descriptor using the
- * SubscriptionList attribute, the set of MBeans/notifications the
- * service wants to subscribe/receive.
- * <p>
- * Call subscribe(boolean dynamicSubscriptions) at anytime to register to
- * those MBeans and for those notifications that match the specified criteria.
- * Call unsubscribe() to unsubscribe for Notifications.
- * <p>
- * If true is passed to subscribe() the baseclass will monitor for
- * registration events from the MBeanServer and automatically subscribe
- * to new instances of MBeans that match the subscription criteria.
- * Monitoring for unsubscribe events in not necessary, since the MBeanServer
- * automatically removes subscriptions to unregistering MBeans.
- * <p>
- * An alternative subscribe(boolean dynamicSubscription, ObjectName listener)
- * can be used to specify a different MBean as the receiver of the
- * subscribed notifications. The specified MBean must be a NotificationListener.
- * <p>
- * To handle the incoming notifications override the handleNotification2()
- * method. The usual handleNotification() method should not be overriden,
- * since it is used to monitor the incoming notifications for registration
- * events coming from the MBeanServer, before delegating to
- * handleNotification2(), in order to implement dynamic subscriptions.
- *
- * @see ListenerServiceMBean
- * @see NotificationFilterFactory
- *
- * REVISIONS
- * =========
- * 14/03/05, dimitris
- * The filter mechanism has been extended to support specification
- * of arbitrary filters, using dynamic filter factory plugins
- * implementing the NotificationFilterFactory interface.
- * Three filter factories corresponding to the "standard" jmx
- * notification filters are supplied by default in package
- * org.jboss.system.filterfactory.
- *
- * 19/10/04, dimitris
- * renamed inner class MBeanInfo to SubscriptionInfo and made public,
- * using NotificationFilter instead of NotificationFilterSupport and added new
- * subscribe(List subscriptionList, boolean dynamicSubscriptions, ObjectName listener)
- * to allow external programmatic specification of the subscription list.
- *
- * 28/02/04, dimitris
- * explicit subscribe()/unsubscribe() replaced implicit start()/stop();
- * dynamic subscription behaviour can be enabled/disabled, plus it is
- * now possible to specify an external MBean as notification listener.
- *
- * 02/02/04, dimitris
- * Initial version, that resulted by generalizing the notification
- * subscription mechanism of the snmp adapter.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- *
- * @version $Revision$
-**/
-public abstract class ListenerServiceMBeanSupport
- extends ServiceMBeanSupport
- implements ListenerServiceMBean, NotificationListener
-{
- // Private Data --------------------------------------------------
-
- /** The mbean subscription specification list */
- private List sublist; // if null, subscriptions not made
-
- /** The mbean subscription config in XML form */
- private Element xmllist; // set through SubscriptionList attribute
-
- /** monitoring and registering to new MBeans, as they appear */
- private boolean dynamicSubscriptions;
-
- /** the receiver of the notifications */
- private ObjectName listener;
-
- /** Handback to identify our own MBeanServerDelegate subscription */
- private Object myHandback;
-
- /** Filter to receive only registration events */
- private NotificationFilterSupport myFilter;
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- **/
- public ListenerServiceMBeanSupport()
- {
- super();
- init();
- }
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param type The class type to determine Logger name from.
- **/
- public ListenerServiceMBeanSupport(final Class type)
- {
- super(type);
- init();
- }
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param category The logger category name.
- **/
- public ListenerServiceMBeanSupport(final String category)
- {
- super(category);
- init();
- }
-
- /**
- * Constructs a <tt>ListenerServiceMBeanSupport</tt>.
- *
- * Pass-through to ServiceMBeanSupport.
- *
- * @param log The logger to use.
- **/
- public ListenerServiceMBeanSupport(final Logger log)
- {
- super(log);
- init();
- }
-
- // ListenerServiceMBean Implementation ---------------------------
-
- /**
- * Used to configure the JMX notification subscriptions.
- *
- * The configuration is done inline in the mbean descriptor.
- *
- * See jboss-subscription.dtd
- **/
- public void setSubscriptionList(Element list)
- {
- // deep copy the provided Element for later use
- // not sure if really necessary - play it safe
- this.xmllist = (Element)list.cloneNode(true);
- }
-
- // Public API ----------------------------------------------------
-
- /**
- * Subscribes this MBean for JMX notifications.
- *
- * @param dynamicSubscriptions indicates whether to monitor and subscribe
- * to new MBeans that match the specification.
- **/
- public void subscribe(boolean dynamicSubscriptions)
- throws Exception
- {
- subscribe(dynamicSubscriptions, this.getServiceName());
- }
-
- /**
- * Subscribes a listener MBean for JMX notifications.
- *
- * @param dynamicSubscriptions indicates whether to monitor and subscribe
- * to new MBeans that match the specification.
- * @param listener the receiver of the notifications.
- **/
- public void subscribe(boolean dynamicSubscriptions, ObjectName listener)
- throws Exception
- {
- // we need an xml subscription specification
- if (this.xmllist != null)
- {
- // Parse the XML spec
- log.debug("Parsing subscription specification");
- List subscriptionList = parseXMLSubscriptionSpec(this.xmllist);
-
- subscribe(subscriptionList, dynamicSubscriptions, listener);
- }
- else
- log.debug("Subscription specification not provided");
- }
-
- /**
- * Subscribes a listener MBean for JMX notifications.
- *
- * @param subscriptionList the list containing SubscriptionInfo data.
- * @param dynamicSubscriptions indicates whether to monitor and subscribe
- * to new MBeans that match the specification.
- * @param listener the receiver of the notifications.
- **/
- public void subscribe(List subscriptionList, boolean dynamicSubscriptions, ObjectName listener)
- throws Exception
- {
- // return if already subscribed
- if (this.sublist != null)
- return;
-
- // we need an subscription specification
- if (subscriptionList != null)
- {
- // store input
- this.sublist = subscriptionList;
- this.dynamicSubscriptions = dynamicSubscriptions;
- this.listener = listener;
-
- log.debug(this.sublist);
-
- log.debug("Subscribing for JMX notifications" +
- ", dynamic=" + dynamicSubscriptions +
- (this.getServiceName().equals(listener) ? "" :
- ", listener='" + listener + "'"));
-
- bulkRegister();
-
- if (dynamicSubscriptions == true)
- {
- // Subscribe to MBeanServerDelegate MBean for registrations
- getServer().addNotificationListener(
- new ObjectName(ServerConstants.MBEAN_SERVER_DELEGATE),
- this.getServiceName(),
- this.myFilter,
- this.myHandback
- );
-
- log.debug("Subscribed to MBeanServerDelegate, too");
- }
- }
- else
- log.debug("Subscription list not provided");
- }
-
- /**
- * Unsubscribes for JMX notifications
- **/
- public void unsubscribe()
- {
- // return if not subscribed
- if (this.sublist == null)
- return;
-
- log.debug("Removing all JMX notification subscriptions");
- bulkUnregister();
-
- if (this.dynamicSubscriptions == true)
- {
- // Unbscribe from MBeanServerDelegate MBean for registrations
- try {
- getServer().removeNotificationListener(
- new ObjectName(ServerConstants.MBEAN_SERVER_DELEGATE),
- this.getServiceName(),
- this.myFilter,
- this.myHandback
- );
-
- log.debug("Unsubscribed from MBeanServerDelegate, too");
- }
- catch (MalformedObjectNameException e)
- {
- // shouldn't happen!
- log.warn("Could not convert '" + ServerConstants.MBEAN_SERVER_DELEGATE
- + "' to ObjectName", e);
- }
- catch (InstanceNotFoundException e)
- {
- // shouldn't happen
- log.warn("Could not unsubscribe from non-existent MBeanServerDelegate!", e);
- }
- catch (ListenerNotFoundException e)
- {
- // shouldn't happend
- log.warn("Could not unsubscribe from MBeanServerDelegate", e);
- }
- }
- // use sublist to indicate we've unsubscribed
- this.sublist = null;
- }
-
- // NotificationListener -----------------------------------------
-
- /**
- * DO NOT OVERRIDE THIS!
- *
- * Handles dynamic subscriptions before delegating to
- * handleNotification2()
- **/
- public void handleNotification(Notification notification, Object handback)
- {
- // check if the notification is for me!
- if (this.dynamicSubscriptions == true && handback == this.myHandback)
- {
- if (log.isTraceEnabled())
- log.trace("It's for me: " + notification + ", handback:" + handback);
-
- String type = notification.getType();
- ObjectName target = null;
- try {
- target = ((MBeanServerNotification)notification).getMBeanName();
- }
- catch (ClassCastException e) {
- log.warn("MBeanServer sent unknown notification class type: " +
- notification.getClass().getName());
- return;
- }
-
- if (type.equals(MBeanServerNotification.REGISTRATION_NOTIFICATION))
- {
- // iterate over the subscription specification
- Iterator i = this.sublist.iterator();
-
- while (i.hasNext())
- {
- SubscriptionInfo mbeanInfo = (SubscriptionInfo)i.next();
-
- ObjectName objectName = mbeanInfo.getObjectName();
-
- try
- {
- if(objectName.apply(target))
- {
- log.debug("ObjectName: '" + target + "' matched '" + objectName + "'");
-
- // go for it!
- singleRegister(
- this.getServer(),
- target,
- this.listener,
- mbeanInfo.getFilter(),
- mbeanInfo.getHandback()
- );
- }
- }
- catch (Exception e)
- {
- // catch exceptions from apply()
- // shouldn't happen
- log.warn("Caught exception from ObjectName.apply("
- + target + ")", e);
- }
- }
- }
- else
- {
- log.warn("Got unknown notification type from MBeanServerDelegate: "
- + type);
- }
- }
- else // delegate to subclass
- handleNotification2(notification, handback);
- }
-
- /**
- * Override to add notification handling!
- **/
- public void handleNotification2(Notification notification, Object handback)
- {
- // empty!
- }
-
- // Private Methods -----------------------------------------------
-
- /**
- * Initialises myself
- **/
- private void init()
- {
- // just pickup a unique object
- this.myHandback = new Integer(Integer.MAX_VALUE);
-
- // allow only registration events
- this.myFilter = new NotificationFilterSupport();
- this.myFilter.enableType(MBeanServerNotification.REGISTRATION_NOTIFICATION);
- }
-
- /**
- * Subscribes for notifications to a single MBean
- **/
- private void singleRegister(
- MBeanServer server, ObjectName target, ObjectName listener,
- NotificationFilter filter, Object handback)
- {
- try
- {
- server.addNotificationListener(target, listener, filter, handback);
-
- logSubscription(target, listener, handback, filter);
- }
- catch (InstanceNotFoundException e)
- {
- // ignore - mbean might not be registered
- log.debug("Could not subscribe to: '" + target
- + "', target or listener MBean not registered");
- }
- catch (RuntimeException e)
- {
- log.warn("Failed to subscribe to: '" + target
- + "', maybe not a notification broadcaster or: '" + listener
- + "', maybe not a notification listener");
- }
- }
-
- /**
- * Unsubscribes for notifications from a single MBean
- **/
- private void singleUnregister(
- MBeanServer server, ObjectName target, ObjectName listener,
- NotificationFilter filter, Object handback)
- {
- try
- {
- // remove the matching subscription
- server.removeNotificationListener(target, listener, filter, handback);
-
- log.debug("Unsubscribed from: '" + target + "'");
- }
- catch (InstanceNotFoundException e)
- {
- // ignore - target mbean not present
- log.debug("Could not unsubscribe from non-existent: '"
- + target + "'");
- }
- catch (ListenerNotFoundException e)
- {
- // May happen if target is not a notification broadcaster
- // and so we hadn't registered in the first place
- log.debug("Could not unsubscribe from: '" + target + "'");
- }
- catch (RuntimeException e)
- {
- // whatever
- log.debug("Could not unsubscribe from: '" + target + "'");
- }
- }
-
- /**
- * Performs the notification subscriptions
- **/
- private void bulkRegister()
- {
- // iterate over the subscription specification
- Iterator i = this.sublist.iterator();
-
- // find out my server
- MBeanServer server = this.getServer();
-
- while (i.hasNext())
- {
- SubscriptionInfo mbeanInfo = (SubscriptionInfo)i.next();
-
- ObjectName objectName = mbeanInfo.getObjectName();
- Object handback = mbeanInfo.getHandback();
- NotificationFilter filter = mbeanInfo.getFilter();
-
- if (objectName.isPattern())
- {
- Set mset = server.queryNames(objectName, null);
-
- log.debug("ObjectName: '" + objectName + "' matched " + mset.size() + " MBean(s)");
-
- Iterator j = mset.iterator();
- while (j.hasNext())
- singleRegister(server, (ObjectName)j.next(), this.listener,
- filter, handback);
- }
- else
- singleRegister(server, objectName, this.listener, filter, handback);
- }
- }
-
- /**
- * Performs bulk unregistration
- **/
- private void bulkUnregister()
- {
- // iterate over the subscription specification
- Iterator i = this.sublist.iterator();
-
- // find out my server
- MBeanServer server = this.getServer();
-
- while (i.hasNext())
- {
- SubscriptionInfo mbeanInfo = (SubscriptionInfo)i.next();
-
- ObjectName objectName = mbeanInfo.getObjectName();
- Object handback = mbeanInfo.getHandback();
- NotificationFilter filter = mbeanInfo.getFilter();
-
- if (objectName.isPattern())
- {
- Set mset = server.queryNames(objectName, null);
-
- log.debug("ObjectName: '" + objectName + "' matched " + mset.size() + " MBean(s)");
-
- Iterator j = mset.iterator();
- while (j.hasNext())
- singleUnregister(server, (ObjectName)j.next(), this.listener,
- filter, handback);
- }
- else
- singleUnregister(server, objectName, this.listener, filter, handback);
- }
- }
-
- /**
- * Logs subscription info
- **/
- private void logSubscription(
- ObjectName objectName, ObjectName listener,
- Object handback, NotificationFilter filter)
- {
- StringBuffer sbuf = new StringBuffer(100);
-
- sbuf.append("Subscribed to: { objectName='").append(objectName);
- sbuf.append("', listener='").append(listener);
- sbuf.append("', handback=").append(handback);
- sbuf.append(", filter=");
- sbuf.append(filter == null ? null : filter.toString());
- sbuf.append(" }");
-
- log.debug(sbuf.toString());
- }
-
- /**
- * Encapsulte the factory and filter creation logic
- */
- private NotificationFilter createNotificationFilter(String factoryClass, Element filterConfig)
- throws Exception
- {
- NotificationFilterFactory factory;
- try
- {
- // try to load the factory Class
- Class clazz = Thread.currentThread().getContextClassLoader().loadClass(factoryClass);
- factory = (NotificationFilterFactory)clazz.newInstance();
- }
- catch (Exception e) // ClassNotFoundException, IllegalAccessException, InstantiationException
- {
- // factory class not found. Make a second try using
- // the 'org.jboss.system.filterfactory.' package prefix
- // for the "standard" filter factories provided with jboss.
- // If that fails, too, rethrow the original exception.
- try
- {
- factoryClass = "org.jboss.system.filterfactory." + factoryClass;
- Class clazz = Thread.currentThread().getContextClassLoader().loadClass(factoryClass);
- factory = (NotificationFilterFactory)clazz.newInstance();
- }
- catch (Exception inner)
- {
- throw e;
- }
- }
- // delegate the filter creation/configuration to the factory
- return factory.createNotificationFilter(filterConfig);
- }
-
- /**
- * Parses the XML subscription specification
- **/
- private ArrayList parseXMLSubscriptionSpec(Element root)
- throws Exception
- {
- ArrayList slist = new ArrayList();
-
- // parse level 0 - subscription-list
- if (!root.getNodeName().equals(SL_ROOT_ELEMENT))
- {
- throw new Exception("Expected '" + SL_ROOT_ELEMENT + "' element, "
- + "got: " + "'" + root.getNodeName() + "'");
- }
- else
- {
- NodeList rootlist = root.getChildNodes();
-
- for (int i = 0; i < rootlist.getLength(); i++)
- {
- // Parse level 1 - look for mbeans
- Node mbean = rootlist.item(i);
-
- if (mbean.getNodeName().equals(SL_MBEAN_ELEMENT))
- {
- // mbean found look for name & handback attrs
- String name = null;
-
- if (((Element)mbean).hasAttribute(SL_MBEAN_NAME_ATTRIBUTE))
- {
- name = ((Element)mbean).getAttribute(SL_MBEAN_NAME_ATTRIBUTE);
- }
- else
- {
- throw new Exception("'" + SL_MBEAN_ELEMENT + "' element must have a '"
- + SL_MBEAN_NAME_ATTRIBUTE + "' attribute");
- }
-
- String handback = null;
- if (((Element)mbean).hasAttribute(SL_MBEAN_HANDBACK_ATTRIBUTE))
- {
- handback = ((Element)mbean).getAttribute(SL_MBEAN_HANDBACK_ATTRIBUTE);
- }
-
- // try to convert name to the correct data type
- // may throw MalformedObjectNameException
- ObjectName objectName = new ObjectName(name);
-
- // Parse level 2 - see if we have a filter for this subscription
- NotificationFilter filter = null;
-
- NodeList mbeanChildren = mbean.getChildNodes();
-
- // check for filter spec, as a single mbean child node
- for (int j = 0; j < mbeanChildren.getLength(); j++)
- {
- Node mbeanChildNode = mbeanChildren.item(j);
-
- // check if this is a 'filter' node
- if (mbeanChildNode.getNodeName().equals(SL_FILTER_ELEMENT))
- {
- // look for the 'factory' attribute
- String factory = null;
- if (((Element)mbeanChildNode).hasAttribute(SL_FILTER_FACTORY_ATTRIBUTE))
- {
- factory = ((Element)mbeanChildNode).getAttribute(SL_FILTER_FACTORY_ATTRIBUTE);
-
- // instantiate the factory and request the filter
- filter = createNotificationFilter(factory, (Element)mbeanChildNode);
- break;
- }
- else
- {
- throw new Exception("'" + SL_FILTER_ELEMENT + "' element must have a '"
- + SL_FILTER_FACTORY_ATTRIBUTE + "' attribute");
- }
- }
- }
-
- if (filter == null)
- {
- // if no filter has been set check for old-style
- // <notification type="..."/> construct that results
- // in a fixed NotificationFilterSupport filter
-
- // need to find out all notification types (if any)
- // in order to create the Notification filter
- ArrayList tmplist = new ArrayList(mbeanChildren.getLength());
-
- for (int j = 0; j < mbeanChildren.getLength(); j++)
- {
- Node mbeanChildNode = mbeanChildren.item(j);
-
- // check if this is a 'notification' element
- if (mbeanChildNode.getNodeName().equals(SL_NOTIFICATION_ELEMENT))
- {
- // look for 'type' attribute
- String type = null;
- if (((Element)mbeanChildNode).hasAttribute(SL_NOTIFICATION_TYPE_ATTRIBUTE))
- {
- type = ((Element)mbeanChildNode).getAttribute(SL_NOTIFICATION_TYPE_ATTRIBUTE);
- tmplist.add(type);
- }
- else
- {
- throw new Exception("'" + SL_NOTIFICATION_ELEMENT + "' element must have a '"
- + SL_NOTIFICATION_TYPE_ATTRIBUTE + "' attribute");
- }
- }
- }
- // create the filter (if needed)
- if (tmplist.size() > 0)
- {
- NotificationFilterSupport sfilter = new NotificationFilterSupport();
- for (int j = 0; j < tmplist.size(); j++)
- {
- sfilter.enableType((String)tmplist.get(j));
- }
- filter = sfilter;
- }
- }
- slist.add(new SubscriptionInfo(objectName, handback, filter));
- }
- }
- }
- return slist;
- }
-
- // Inner Class ---------------------------------------------------
-
- /**
- * Inner data holder class to store the parsed subscription specification.
- **/
- public static final class SubscriptionInfo
- {
- // Private Data -----------------------------------------------
-
- /** MBean notification broadcaster or pattern */
- private ObjectName objectName;
-
- /** Optional handback object to identify a subscription */
- private Object handback;
-
- /** Arbitrary NotificationFilter */
- private NotificationFilter filter;
-
- // Constructor ------------------------------------------------
-
- /**
- * Simple CTOR
- **/
- public SubscriptionInfo(ObjectName objectName, Object handback, NotificationFilter filter)
- {
- this.objectName = objectName;
- this.handback = handback;
- this.filter = filter;
- }
-
- // Accessors --------------------------------------------------
- /**
- * Gets objectname
- **/
- public ObjectName getObjectName()
- {
- return this.objectName;
- }
-
- /**
- * Gets handback object
- **/
- public Object getHandback()
- {
- return this.handback;
- }
-
- /**
- * Gets notification filter
- **/
- public NotificationFilter getFilter()
- {
- return this.filter;
- }
-
- /**
- * Pretty prints
- **/
- public String toString()
- {
- StringBuffer sbuf = new StringBuffer(100);
-
- sbuf.append("SubscriptionInfo { objectName='").append(this.objectName);
- sbuf.append("', handback=").append(this.handback);
- sbuf.append(", filter=");
- sbuf.append(this.filter == null ? null : this.filter.toString());
-
- sbuf.append(" }");
-
- return sbuf.toString();
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ListenerServiceMBeanSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/MissingAttributeException.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/MissingAttributeException.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/MissingAttributeException.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * Thrown to indicate that a required attribute has not been set.
- *
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version <tt>$Revision$</tt>
- */
-public class MissingAttributeException
- extends ConfigurationException
-{
- /**
- * Construct a <tt>MissingAttributeException</tt> with the specified detail
- * message.
- *
- * @param name The attribute name.
- */
- public MissingAttributeException(final String name) {
- super(makeMessage(name));
- }
-
- /**
- * Construct a <tt>MissingAttributeException</tt> with the specified detail
- * message and nested <tt>Throwable</tt>.
- *
- * @param name The attribute name.
- * @param nested Nested <tt>Throwable</tt>.
- */
- public MissingAttributeException(final String name, final Throwable nested) {
- super(makeMessage(name), nested);
- }
-
- /**
- * Make a execption message for the attribute name.
- */
- private static String makeMessage(final String name) {
- return "Missing attribute '" + name + "'";
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/MissingAttributeException.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/MissingAttributeException.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/MissingAttributeException.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.NotificationFilter;
-
-import org.w3c.dom.Element;
-
-/**
- * Abstracts NotificationFilter creation based on an arbritrary
- * xml element fragment. Used by ListenerServiceMBeanSupport
- * to enable NotificationFilterFactory plugins.
- *
- * @see ListenerServiceMBeanSupport
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public interface NotificationFilterFactory
-{
- /**
- * Create a notification filter implementation and initialize
- * it, using the passed xml element fragment.
- *
- * @param filterConfig the xml fragment to use for configuring the filter
- * @return an initialized NotificationFilter
- * @throws Exception in case the xml fragment cannot be parsed properly
- */
- public NotificationFilter createNotificationFilter(Element filterConfig)
- throws Exception;
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/NotificationFilterFactory.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceBinding.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceBinding.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceBinding.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.ObjectName;
-
-/**
- * A policy used by ServiceController to allow the override
- * of MBean attribute values at configuration time.
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public interface ServiceBinding
-{
- /**
- * Possibly override the configuration of a service.
- *
- * @param serviceName the JMX ObjectName of the service
- * @exception Exception thrown on failure to override a configuration
- */
- void applyServiceConfig(ObjectName serviceName) throws Exception;
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceBinding.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceBinding.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceBinding.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,457 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.io.IOException;
-import java.io.StringWriter;
-import java.io.Writer;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.management.Attribute;
-import javax.management.InstanceNotFoundException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanInfo;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.system.metadata.ServiceValueContext;
-import org.jboss.util.xml.DOMWriter;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Service configuration helper.
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version <tt>$Revision$</tt>
- */
-public class ServiceConfigurator
-{
- /** The MBean server which this service is registered in. */
- private final MBeanServer server;
-
- /** The parent service controller */
- private final ServiceController serviceController;
-
- /** The ServiceCreator */
- private final ServiceCreator serviceCreator;
-
- /** The ServiceBinding plugin policy */
- private ServiceBinding serviceBinding;
-
- /** Instance logger. */
- private static final Logger log = Logger.getLogger(ServiceConfigurator.class);
-
- /**
- * Configure an MBean
- *
- * @param server the server
- * @param controller the service controller
- * @param objectName the object name
- * @param classLoaderName the classloader object name
- * @param attrs the attributes
- * @throws Exception for any error
- */
- public static void configure(MBeanServer server, ServiceController controller, ObjectName objectName, ObjectName classLoaderName, Collection<ServiceAttributeMetaData> attrs) throws Exception
- {
- server = checkMBeanServer(server, controller);
- ClassLoader cl = server.getClassLoader(classLoaderName);
- configure(server, controller, objectName, cl, attrs);
- }
-
- /**
- * Configure an MBean
- *
- * @param server the server
- * @param controller the service controller
- * @param objectName the object name
- * @param cl the classloader
- * @param attrs the attributes
- * @throws Exception for any error
- */
- public static void configure(MBeanServer server, ServiceController controller, ObjectName objectName, ClassLoader cl, Collection<ServiceAttributeMetaData> attrs) throws Exception
- {
- ServiceValueContext valueContext = new ServiceValueContext(server, controller, cl);
- server = checkMBeanServer(server, controller);
-
- HashMap<String, MBeanAttributeInfo> attributeMap = getAttributeMap(server, objectName);
-
- for (ServiceAttributeMetaData attribute : attrs)
- {
- String attributeName = attribute.getName();
- if (attributeName == null || attributeName.length() == 0)
- throw new DeploymentException("No or empty attribute name for " + objectName);
- MBeanAttributeInfo attributeInfo = attributeMap.get(attributeName);
- if (attributeInfo == null)
- throw new DeploymentException("No Attribute found with name: " + attributeName + " for " + objectName);
-
- valueContext.setAttributeInfo(attributeInfo);
- Object value = attribute.getValue(valueContext);
- try
- {
- log.debug(attributeName + " set to " + value + " in " + objectName);
- server.setAttribute(objectName, new Attribute(attributeName, value));
- }
- catch (Throwable t)
- {
- throw new DeploymentException("Exception setting attribute " + attributeName + " on mbean " + objectName, JMXExceptionDecoder.decode(t));
- }
- }
- }
-
- /**
- * Check the server/controller parameters
- *
- * @param server the server
- * @param controller the controller
- * @return the server
- */
- private static MBeanServer checkMBeanServer(MBeanServer server, ServiceController controller)
- {
- if (server != null)
- return server;
-
- if (controller != null)
- return controller.getMBeanServer();
-
- throw new IllegalArgumentException("Either the server or controller must be passed");
- }
-
- /**
- * Apply any service binding overrides
- *
- * @review why isn't the MBeanServer part of this api?
- * @param server the server
- * @param objectName the object name
- * @param serviceBinding the service binding
- * @throws Exception for any error
- */
- public static void applyServiceConfig(MBeanServer server, ObjectName objectName, ServiceBinding serviceBinding) throws Exception
- {
- try
- {
- serviceBinding.applyServiceConfig(objectName);
- }
- catch (Throwable e)
- {
- // serviceBinding is most probably a dynamic mbean proxy
- Throwable t = JMXExceptionDecoder.decode(e);
- log.warn("Failed to apply service binding override for " + objectName, t);
- }
- }
-
- /**
- * Get an attribute map for the MBean
- *
- * @param server the server
- * @param objectName the object name
- * @return a map of attribute name to attribute info
- * @throws Exception for any error
- */
- private static HashMap<String, MBeanAttributeInfo> getAttributeMap(MBeanServer server, ObjectName objectName) throws Exception
- {
- MBeanInfo info;
- try
- {
- info = server.getMBeanInfo(objectName);
- }
- catch (InstanceNotFoundException e)
- {
- // The MBean is no longer available
- throw new DeploymentException("Trying to configure nonexistent mbean: " + objectName);
- }
- catch (Exception e)
- {
- throw new DeploymentException("Could not get mbeanInfo", JMXExceptionDecoder.decode(e));
- }
- if (info == null)
- throw new DeploymentException("MBeanInfo is null for mbean: " + objectName);
- MBeanAttributeInfo[] attributes = info.getAttributes();
- HashMap<String, MBeanAttributeInfo> attributeMap = new HashMap<String, MBeanAttributeInfo>();
- for (int i = 0; i < attributes.length; i++)
- {
- MBeanAttributeInfo attr = attributes[i];
- attributeMap.put(attr.getName(), attr);
- }
-
- return attributeMap;
- }
-
- /**
- * Constructor
- *
- * @deprecated the service controller no longer uses the service configurator and vice-versa
- * @param server the mbean server
- * @param serviceController the servie controller
- * @param serviceCreator the service creator
- */
- public ServiceConfigurator(MBeanServer server, ServiceController serviceController, ServiceCreator serviceCreator)
- {
- if (server == null)
- throw new IllegalArgumentException("Null server");
- if (serviceCreator == null)
- throw new IllegalArgumentException("Null serverCreator");
-
- this.server = server;
- this.serviceController = serviceController;
- this.serviceCreator = serviceCreator;
- if (serviceController != null)
- this.serviceBinding = serviceController.getServiceBinding();
- }
-
- /**
- * Dynamically plug-in a ServiceBinding policy
- * to possibly override the configuration of a service.
- *
- * @param serviceBinding policy
- */
- public void setServiceBinding(ServiceBinding serviceBinding)
- {
- this.serviceBinding = serviceBinding;
- }
-
- /**
- * The <code>install</code> method iterates through the mbean tags in the
- * supplied xml configuration and creates and configures the mbeans shown.
- * The mbean configuration can be nested.
- *
- * @deprecated the service controller no longer uses the service configurator and vice-versa
- * @param config the xml <code>Element</code> containing the configuration of
- * the mbeans to create and configure.
- * @param loaderName the classloader's ObjectName
- * @return a <code>List</code> of ObjectNames of created mbeans.
- * @throws DeploymentException if an error occurs
- */
- public List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException
- {
- // Parse the xml
- ServiceMetaDataParser parser = new ServiceMetaDataParser(config);
- List<ServiceMetaData> metaDatas = parser.parse();
-
- // Track the registered object names
- List<ObjectName> result = new ArrayList<ObjectName>(metaDatas.size());
-
- // Go through each mbean in the passed xml
- for (ServiceMetaData metaData : metaDatas)
- {
- ObjectName objectName = metaData.getObjectName();
- Collection<ServiceAttributeMetaData> attrs = metaData.getAttributes();
- // Install and configure the mbean
- try
- {
- ServiceCreator.install(server, objectName, metaData, null);
- result.add(objectName);
- configure(server, null, objectName, loaderName, attrs);
- if (serviceBinding != null)
- applyServiceConfig(server, objectName, serviceBinding);
- }
- catch (Throwable t)
- {
- // Something went wrong
- for (ObjectName name : result)
- {
- try
- {
- serviceCreator.remove(name);
- }
- catch (Exception e)
- {
- log.error("Error removing mbean after failed deployment: " + name, e);
- }
- }
- DeploymentException.rethrowAsDeploymentException("Error during install", t);
- }
- }
- return result;
- }
-
- /**
- * Builds a string that consists of the configuration elements of the
- * currently running MBeans registered in the server.
- *
- * @todo replace with more sophisticated mbean persistence mechanism.
- * @param server the MBeanServer
- * @param serviceController the service controller
- * @param objectNames the object names to retrieve
- * @return the xml string
- * @throws Exception Failed to construct configuration.
- */
- public static String getConfiguration(MBeanServer server, ServiceController serviceController, ObjectName[] objectNames) throws Exception
- {
- Writer out = new StringWriter();
-
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- DocumentBuilder builder = factory.newDocumentBuilder();
- Document doc = builder.newDocument();
-
- Element serverElement = doc.createElement("server");
-
- // Store attributes as XML
- for (int j = 0; j < objectNames.length; j++)
- {
- Element mbeanElement = internalGetConfiguration(doc, server, serviceController, objectNames[j]);
- serverElement.appendChild(mbeanElement);
- }
-
- doc.appendChild(serverElement);
-
- // Write configuration
- new DOMWriter(out).setPrettyprint(true).print(doc);
-
- out.close();
-
- // Return configuration
- return out.toString();
- }
-
- private static Element internalGetConfiguration(Document doc, MBeanServer server, ServiceController serviceController, ObjectName name) throws Exception
- {
- Element mbeanElement = doc.createElement("mbean");
- mbeanElement.setAttribute("name", name.toString());
-
- MBeanInfo info = server.getMBeanInfo(name);
- mbeanElement.setAttribute("code", info.getClassName());
- MBeanAttributeInfo[] attributes = info.getAttributes();
- boolean trace = log.isTraceEnabled();
- for (int i = 0; i < attributes.length; i++)
- {
- if (trace)
- log.trace("considering attribute: " + attributes[i]);
- if (attributes[i].isReadable() && attributes[i].isWritable())
- {
- Element attributeElement = null;
- if (attributes[i].getType().equals("javax.management.ObjectName"))
- {
- attributeElement = doc.createElement("depends");
- attributeElement.setAttribute("optional-attribute-name", attributes[i].getName());
- }
- else
- {
- attributeElement = doc.createElement("attribute");
- attributeElement.setAttribute("name", attributes[i].getName());
- }
- Object value = server.getAttribute(name, attributes[i].getName());
-
- if (value != null)
- {
- if (value instanceof Element)
- {
- attributeElement.appendChild(doc.importNode((Element) value, true));
- }
- else
- {
- attributeElement.appendChild(doc.createTextNode(value.toString()));
- }
- }
- mbeanElement.appendChild(attributeElement);
- }
- }
-
- ServiceContext sc = serviceController.getServiceContext(name);
- for (Iterator i = sc.iDependOn.iterator(); i.hasNext();)
- {
- ServiceContext needs = (ServiceContext) i.next();
- Element dependsElement = doc.createElement("depends");
- dependsElement.appendChild(doc.createTextNode(needs.objectName.toString()));
- mbeanElement.appendChild(dependsElement);
- }
-
- return mbeanElement;
- }
-
- /**
- * Builds a string that consists of the configuration elements of the
- * currently running MBeans registered in the server.
- *
- * TODO replace with more sophisticated mbean persistence mechanism.
- * @param objectNames the object names
- * @return the xml string
- * @throws Exception Failed to construct configuration.
- */
- public String getConfiguration(ObjectName[] objectNames) throws Exception
- {
- return getConfiguration(server, serviceController, objectNames);
- }
-
- /**
- * A utility method that transforms the contents of the argument element into
- * a StringBuffer representation that can be reparsed.
- *
- * [FIXME] This is not a general DOMUtils method because of its funny contract. It does not
- * support multiple child elements neither can it deal with text content.
- *
- * @param element - the parent dom element whose contents are to be extracted as an xml document string.
- * @return the xml document string.
- * @throws IOException for an error during IO
- * @throws TransformerException for an erro during transformation
- */
- public static StringBuffer getElementContent(Element element) throws IOException, TransformerException
- {
- NodeList children = element.getChildNodes();
- Element content = null;
- for (int n = 0; n < children.getLength(); n++)
- {
- Node node = children.item(n);
- if (node.getNodeType() == Node.ELEMENT_NODE)
- {
- content = (Element)node;
- break;
- }
- }
- if (content == null)
- return null;
-
- // Get a parsable representation of this elements content
- DOMSource source = new DOMSource(content);
- TransformerFactory tFactory = TransformerFactory.newInstance();
- Transformer transformer = tFactory.newTransformer();
- StringWriter sw = new StringWriter();
- StreamResult result = new StreamResult(sw);
- transformer.transform(source, result);
- sw.close();
- return sw.getBuffer();
- }
-}
\ No newline at end of file
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceConfigurator.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceContext.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceContext.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceContext.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,130 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import java.io.Serializable;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import javax.management.ObjectName;
-
-/**
- * ServiceContext holds information for the Service
- *
- * @see Service
- * @see ServiceMBeanSupport
- *
- * @author <a href="mailto:marc.fleury at jboss.org">marc fleury</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ServiceContext implements Serializable
-{
- /** @since 4.0.2 */
- private static final long serialVersionUID = 7461263042948325633L;
-
- /** The possible string-fied states */
- private static final String[] stateNames = {
- "INSTALLED",
- "CONFIGURED",
- "CREATED",
- "RUNNING",
- "FAILED",
- "STOPPED",
- "DESTROYED",
- "NOTYETINSTALLED"
- };
-
- /** Valid service states */
- public static final int INSTALLED = 0;
- public static final int CONFIGURED = 1;
- public static final int CREATED = 2;
- public static final int RUNNING = 3;
- public static final int FAILED = 4;
- public static final int STOPPED = 5;
- public static final int DESTROYED = 6;
- public static final int NOTYETINSTALLED = 7;
-
- /** The name of the service **/
- public ObjectName objectName;
-
- /** State of the service **/
- public int state = NOTYETINSTALLED;
-
- /** Dependent beans **/
- public List<ServiceContext> iDependOn = new LinkedList<ServiceContext>();
-
- /** Beans that depend on me **/
- public List<ServiceContext> dependsOnMe = new LinkedList<ServiceContext>();
-
- /** The fancy proxy to my service calls **/
- public Service proxy;
-
- /** Cause for failure */
- public Throwable problem;
-
- public String getStateString()
- {
- return getStateString(state);
- }
-
- public static String getStateString(int stateInt)
- {
- return stateNames[stateInt];
- }
-
- public String toString()
- {
- StringBuffer sbuf = new StringBuffer(512);
-
- sbuf.append("ObjectName: ").append(objectName);
- sbuf.append("\n State: ").append(stateNames[state]);
-
- if (state == FAILED && problem != null)
- {
- sbuf.append("\n Reason: ").append(problem.toString());
- }
- printList(sbuf, "\n I Depend On:", iDependOn);
- printList(sbuf, "\n Depends On Me:", dependsOnMe);
-
- // this magically makes *all* jmx-console outputs look better :)
- sbuf.append("\n");
-
- return sbuf.toString();
- }
-
- private void printList(StringBuffer sbuf, String msg, List ctxs)
- {
- if (ctxs.size() > 0)
- {
- // only out stuff, if there are indeed dependencies
- sbuf.append(msg);
- for (Iterator i = ctxs.iterator(); i.hasNext(); )
- {
- ServiceContext sc = (ServiceContext) i.next();
- sbuf.append("\n ");
- sbuf.append(sc.objectName);
- }
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceContext.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceContext.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceContext.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceController.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceController.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceController.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,736 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-import java.util.concurrent.ConcurrentHashMap;
-import java.util.concurrent.CopyOnWriteArrayList;
-
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.Notification;
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.Controller;
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.dependency.spi.ControllerMode;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.dependency.spi.DependencyInfo;
-import org.jboss.dependency.spi.DependencyItem;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.DeploymentState;
-import org.jboss.kernel.Kernel;
-import org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap;
-import org.jboss.kernel.spi.dependency.KernelController;
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.system.microcontainer.LifecycleDependencyItem;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-import org.w3c.dom.Element;
-
-/**
- * This is the main Service Controller. A controller can deploy a service to a
- * jboss.system It installs by delegating, it configures by delegating<p>
- *
- * This class has been rewritten to delegate to the microcontainer's
- * generic controller. Like the original ServiceController, all state
- * transitions must be handled manually, e.g. driven by the deployer
- * invoking create, start, stop, etc.
- * That is with one exception; we register ourselves an automatic context.
- *
- * @see org.jboss.system.Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ServiceController extends JBossNotificationBroadcasterSupport
- implements ServiceControllerMBean, MBeanRegistration
-{
- /** The ObjectName of the default loader repository */
- public static final ObjectName DEFAULT_LOADER_REPOSITORY = ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
-
- /** The operation name for lifecycle */
- public static final String JBOSS_INTERNAL_LIFECYCLE = "jbossInternalLifecycle";
-
- /** The signature for lifecycle operations */
- public static final String[] JBOSS_INTERNAL_LIFECYCLE_SIG = new String[] { String.class.getName() };
-
- /** Class logger. */
- private static final Logger log = Logger.getLogger(ServiceController.class);
-
- /** The kernel */
- protected Kernel kernel;
-
- /** A callback to the JMX MBeanServer */
- protected MBeanServer server;
-
- /** The service binding */
- protected ServiceBinding serviceBinding;
-
- /** The contexts */
- protected Map<ObjectName, ServiceControllerContext> installed = new ConcurrentHashMap<ObjectName, ServiceControllerContext>();
-
- /** The contexts in installation order */
- protected CopyOnWriteArrayList<ServiceControllerContext> installedOrder = new CopyOnWriteArrayList<ServiceControllerContext>();
-
- /**
- * Get the MBeanServer
- *
- * @return the server
- */
- public MBeanServer getMBeanServer()
- {
- return server;
- }
-
- /**
- * Set the server.
- *
- * @param server the server.
- */
- public void setMBeanServer(MBeanServer server)
- {
- this.server = server;
- }
-
- /**
- * Get the kernel.
- *
- * @return the kernel.
- */
- public Kernel getKernel()
- {
- return kernel;
- }
-
- /**
- * Set the kernel.
- *
- * @param kernel the kernel.
- */
- public void setKernel(Kernel kernel)
- {
- this.kernel = kernel;
- }
-
- /**
- * Get the serviceBinding.
- *
- * @return the serviceBinding.
- */
- public ServiceBinding getServiceBinding()
- {
- return serviceBinding;
- }
-
- /**
- * Plugin a ServiceBinding policy
- *
- * @param serviceBinding policy
- */
- public void setServiceBinding(ServiceBinding serviceBinding)
- {
- this.serviceBinding = serviceBinding;
- }
-
- public List<ServiceContext> listDeployed()
- {
- // Retrieve the service context from all our installed contexts
- ArrayList<ServiceContext> result = new ArrayList<ServiceContext>(installedOrder.size());
- for (ServiceControllerContext context : installedOrder)
- result.add(context.getServiceContext());
- return result;
- }
-
- public List<ServiceContext> listIncompletelyDeployed()
- {
- // Retrieve the service contexts that are not deployed properly
- ArrayList<ServiceContext> result = new ArrayList<ServiceContext>();
- for (ServiceControllerContext context : installedOrder)
- {
- ServiceContext sc = context.getServiceContext();
- if (sc.state != ServiceContext.CREATED &&
- sc.state != ServiceContext.RUNNING &&
- sc.state != ServiceContext.STOPPED &&
- sc.state != ServiceContext.DESTROYED)
- {
- result.add(sc);
- }
- }
- return result;
- }
-
- public List<ObjectName> listDeployedNames()
- {
- // Get all the object names from our installed contexts
- ArrayList<ObjectName> result = new ArrayList<ObjectName>(installed.size());
- for (ObjectName name : installed.keySet())
- result.add(name);
- return result;
- }
-
- public String listConfiguration(ObjectName[] objectNames) throws Exception
- {
- return ServiceConfigurator.getConfiguration(server, this, objectNames);
- }
-
- public void validateDeploymentState(DeploymentInfo di, DeploymentState state)
- {
- ArrayList<ObjectName> mbeans = new ArrayList<ObjectName>(di.mbeans);
- if (di.deployedObject != null)
- mbeans.add(di.deployedObject);
- boolean mbeansStateIsValid = true;
- for (int m = 0; m < mbeans.size(); ++m)
- {
- ObjectName serviceName = mbeans.get(m);
- ServiceContext ctx = getServiceContext(serviceName);
- if (ctx != null && state == DeploymentState.STARTED)
- mbeansStateIsValid &= ctx.state == ServiceContext.RUNNING;
- }
- if (mbeansStateIsValid == true)
- di.state = state;
- }
-
- public List<ObjectName> install(List<ServiceMetaData> metaDatas, ObjectName loaderName) throws DeploymentException
- {
- KernelController controller = kernel.getController();
-
- // Track the registered mbeans both for returning the result
- // and uninstalling in the event of an error
- List<ObjectName> result = new ArrayList<ObjectName>(metaDatas.size());
- List<ServiceControllerContext> contexts = new ArrayList<ServiceControllerContext>(metaDatas.size());
-
- // Go through each mbean in the passed xml
- for (ServiceMetaData metaData : metaDatas)
- {
- metaData.setClassLoaderName(loaderName);
-
- // Install the context to the configured level
- ServiceControllerContext context = new ServiceControllerContext(this, metaData);
- try
- {
- doInstall(controller, context);
- contexts.add(context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- result.add(context.getObjectName());
- }
- catch (Throwable t)
- {
- // Something went wrong
- for (ServiceControllerContext ctx : contexts)
- safelyRemoveAnyRegisteredContext(ctx);
-
- DeploymentException.rethrowAsDeploymentException("Error during install", t);
- }
- }
- return result;
- }
-
- public ObjectName install(ServiceMetaData metaData, ObjectName loaderName) throws DeploymentException
- {
- KernelController controller = kernel.getController();
- metaData.setClassLoaderName(loaderName);
- ObjectName name = metaData.getObjectName();
-
- // Install the context to the configured level
- ServiceControllerContext context = new ServiceControllerContext(this, metaData);
- try
- {
- doInstall(controller, context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- return context.getObjectName();
- }
- catch (Throwable t)
- {
- throw DeploymentException.rethrowAsDeploymentException("Error during install " + name, t);
- }
- }
-
- public List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException
- {
- // Parse the xml
- ServiceMetaDataParser parser = new ServiceMetaDataParser(config);
- List<ServiceMetaData> metaDatas = parser.parse();
- return install(metaDatas, loaderName);
- }
-
- /**
- * Install an MBean without any meta data
- *
- * @param name the object name
- * @param object the mbean object
- * @throws DeploymentException for any error
- */
- public void install(ObjectName name, Object object) throws DeploymentException
- {
- if (name == null)
- throw new IllegalArgumentException("Null name");
- if (object == null)
- throw new IllegalArgumentException("Null object");
-
- KernelController controller = kernel.getController();
-
- ServiceControllerContext context = new ServiceControllerContext(this, name, object);
- try
- {
- doInstall(controller, context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- }
- catch (Throwable t)
- {
- // Something went wrong
- safelyRemoveAnyRegisteredContext(context);
-
- DeploymentException.rethrowAsDeploymentException("Error during install", t);
- }
- }
-
- public void register(ObjectName serviceName) throws Exception
- {
- register(serviceName, null);
- }
-
- public void register(ObjectName serviceName, Collection<ObjectName> depends) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to register null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("Registering service " + serviceName);
-
- // This is an already registered mbean
- KernelController controller = kernel.getController();
- ServiceControllerContext context = new ServiceControllerContext(this, serviceName);
- if (depends != null)
- addDependencies(context, depends);
-
- // Install the context to the configured level
- try
- {
- doInstall(controller, context);
- doChange(controller, context, ControllerState.CONFIGURED, "configure");
- }
- catch (Throwable t)
- {
- // Something went wrong
- safelyRemoveAnyRegisteredContext(context);
-
- DeploymentException.rethrowAsDeploymentException("Error during register: " + serviceName, t);
- }
- }
-
- public void create(ObjectName serviceName) throws Exception
- {
- create(serviceName, null);
- }
-
- public void create(ObjectName serviceName, Collection<ObjectName> depends) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to create null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("Creating service " + serviceName);
-
- // Register if not already done so
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- register(serviceName, depends);
- context = installed.get(serviceName);
- }
- ServiceContext ctx = context.getServiceContext();
-
- // If we are already created (can happen in dependencies) or failed just return
- if (ctx.state == ServiceContext.CREATED
- || ctx.state == ServiceContext.RUNNING
- || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring create request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go to the created state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.CREATE, "create");
- }
- catch (Throwable t)
- {
- log.warn("Problem creating service " + serviceName, t);
- }
- }
-
- public void start(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to start null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("starting service " + serviceName);
-
- // Register if not already done so
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- register(serviceName, null);
- context = installed.get(serviceName);
- }
- ServiceContext ctx = context.getServiceContext();
-
- // If we are already started (can happen in dependencies) just return
- if (ctx.state == ServiceContext.RUNNING || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring start request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go to the fully installed state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.INSTALLED, "start");
- }
- catch (Throwable t)
- {
- log.warn("Problem starting service " + serviceName, t);
- }
- }
-
- public void restart(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to restart null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("restarting service " + serviceName);
- stop(serviceName);
- start(serviceName);
- }
-
- public void stop(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to stop null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("stopping service: " + serviceName);
-
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- log.warn("Ignoring request to stop nonexistent service: " + serviceName);
- return;
- }
-
- // If we are already stopped (can happen in dependencies) just return
- ServiceContext ctx = context.getServiceContext();
- if (ctx.state != ServiceContext.RUNNING)
- {
- log.debug("Ignoring stop request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go back to the created state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.CREATE, null);
- }
- catch (Throwable t)
- {
- log.warn("Problem stopping service " + serviceName, t);
- }
- }
-
- public void destroy(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to destroy null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("destroying service: " + serviceName);
-
- ServiceControllerContext context = installed.get(serviceName);
- if (context == null)
- {
- log.warn("Ignoring request to destroy nonexistent service: " + serviceName);
- return;
- }
-
- // If we are already destroyed (can happen in dependencies) just return
- ServiceContext ctx = context.getServiceContext();
- if (ctx.state == ServiceContext.DESTROYED || ctx.state == ServiceContext.NOTYETINSTALLED || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring destroy request for service: " + ctx.objectName + " at state " + ctx.getStateString());
- return;
- }
-
- // Request the mbean go the configured state
- KernelController controller = kernel.getController();
- try
- {
- doChange(controller, context, ControllerState.CONFIGURED, null);
- }
- catch (Throwable t)
- {
- log.warn("Problem stopping service " + serviceName, t);
- }
- }
-
- public void remove(ObjectName objectName) throws Exception
- {
- if (objectName == null)
- {
- log.warn("Ignoring request to remove null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- // Removal can be attempted twice, this is because ServiceMBeanSupport does a "double check"
- // to make sure the ServiceController is tidied up
- // However, if the tidyup is done correctly, it invokes this method recursively:
- // ServiceController::remove -> MBeanServer::unregisterMBean
- // ServiceMBeanSupport::postDeregister -> ServiceController::remove
- ServiceControllerContext context = installed.remove(objectName);
- if (context == null)
- {
- log.trace("Ignoring request to remove nonexistent service: " + objectName);
- return;
- }
- installedOrder.remove(context);
- log.debug("removing service: " + objectName);
-
- // Uninstall the context
- safelyRemoveAnyRegisteredContext(context);
- }
-
- public ServiceContext getServiceContext(ObjectName serviceName)
- {
- ServiceControllerContext context = installed.get(serviceName);
- if (context != null)
- return context.getServiceContext();
- return null;
- }
-
- public void shutdown()
- {
- log.debug("Stopping " + installedOrder.size() + " services");
-
- KernelController controller = kernel.getController();
-
- int serviceCounter = 0;
-
- // Uninstall all the contexts we know about
- ListIterator<ServiceControllerContext> iterator = installedOrder.listIterator(installedOrder.size());
- while (iterator.hasPrevious())
- {
- ServiceControllerContext context = iterator.previous();
- controller.uninstall(context.getName());
- ++serviceCounter;
- }
- log.debug("Stopped " + serviceCounter + " services");
- }
-
- public ObjectName preRegister(MBeanServer server, ObjectName name)
- throws Exception
- {
- this.server = server;
-
- if( kernel == null )
- {
- // Bootstrap the microcontainer.
- BasicBootstrap bootstrap = new BasicBootstrap();
- bootstrap.run();
- kernel = bootstrap.getKernel();
- }
-
- log.debug("Controller MBean online");
- return name == null ? OBJECT_NAME : name;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- if (registrationDone.booleanValue() == false)
- log.fatal("Registration of ServiceController failed");
- else
- {
- // Register the ServiceController as a running service
- KernelController controller = kernel.getController();
- ServiceControllerContext context = new ServiceControllerContext(this, ServiceControllerMBean.OBJECT_NAME);
- context.setMode(ControllerMode.AUTOMATIC);
- try
- {
- controller.install(context);
- }
- catch (Throwable t)
- {
- log.fatal("Error registering service controller", t);
- }
- }
- }
-
- public void preDeregister()
- throws Exception
- {
- }
-
- public void postDeregister()
- {
- installed.clear();
- installedOrder.clear();
- server = null;
- }
-
- /**
- * Install a context
- *
- * @param controller the controller
- * @param context the context
- * @throws Throwable for any error
- */
- private void doInstall(KernelController controller, ServiceControllerContext context) throws Throwable
- {
- controller.install(context);
- installed.put(context.getObjectName(), context);
- installedOrder.add(context);
- }
-
- /**
- * Change a context
- *
- * @param controller the controller
- * @param context the context
- * @param requiredState the require state
- * @param logWait log the waiting dependencies
- * @throws Throwable for any error
- */
- private void doChange(KernelController controller, ServiceControllerContext context, ControllerState requiredState, String logWait) throws Throwable
- {
- if (ControllerMode.ON_DEMAND.equals(context.getMode()) == false)
- {
- controller.change(context, requiredState);
- ControllerState state = context.getState();
- if (logWait != null && requiredState.equals(state) == false && state != ControllerState.ERROR)
- log.debug("Waiting in " + logWait + " of " + context.getObjectName() + " on " + getUnresolvedDependencies(context, requiredState));
- }
- }
-
- /**
- * Sends outs controller notifications about service lifecycle events
- *
- * @param type the notification type
- * @param serviceName the service name
- */
- public void sendControllerNotification(String type, ObjectName serviceName)
- {
- Notification notification = new Notification(type, this, super.nextNotificationSequenceNumber());
- notification.setUserData(serviceName);
- sendNotification(notification);
- }
-
- /**
- * Add the passed lifecycle dependencies to the context
- *
- * @param context the context
- * @param depends the dependencies
- */
- private void addDependencies(ServiceControllerContext context, Collection<ObjectName> depends)
- {
- DependencyInfo info = context.getDependencyInfo();
- for (ObjectName other : depends)
- {
- info.addIDependOn(new LifecycleDependencyItem(context.getName(), other.getCanonicalName(), ControllerState.CREATE));
- info.addIDependOn(new LifecycleDependencyItem(context.getName(), other.getCanonicalName(), ControllerState.START));
- }
- }
-
- /**
- * Get the unresolved dependencies
- *
- * @param context the context
- * @param state the state we want to move to
- * @return the unresolved dependencies
- */
- private String getUnresolvedDependencies(ServiceControllerContext context, ControllerState state)
- {
- boolean first = true;
-
- StringBuilder builder = new StringBuilder();
- for (DependencyItem item : context.getDependencyInfo().getUnresolvedDependencies())
- {
- if (item.isResolved() == false && item.getWhenRequired() == state)
- {
- if (first)
- first = false;
- else
- builder.append(' ');
- builder.append(item.getIDependOn());
- }
- }
- return builder.toString();
- }
-
- /**
- * Safely remove any potentially registered context (usually after an error)
- *
- * @param ctx the context
- */
- private void safelyRemoveAnyRegisteredContext(ServiceControllerContext ctx)
- {
- // First the context must have a controller
- Controller controller = ctx.getController();
- if (controller != null)
- {
- // The name must be registered and it must be our context
- Object name = ctx.getName();
- ControllerContext registered = controller.getContext(name, null);
- if (registered == ctx)
- controller.uninstall(name);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceController.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceController.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceController.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,195 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.Collection;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.DeploymentState;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.w3c.dom.Element;
-
-/**
- * ServiceController MBean interface.
- *
- * @see org.jboss.system.Service
- */
-public interface ServiceControllerMBean
-{
- /** The default ObjectName */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:service=ServiceController");
-
- /**
- * Plugin a ServiceBinding policy
- *
- * @param serviceBinding policy
- */
- void setServiceBinding(ServiceBinding serviceBinding);
-
- /**
- * Lists the ServiceContexts of deployed mbeans
- *
- * @return the list of ServiceContexts for mbeans deployed through ServiceController.
- */
- List<ServiceContext> listDeployed();
-
- /**
- * The <code>listIncompletelyDeployed</code> method returns the
- * service contexts for the mbeans whose status is not CREATED,
- * RUNNING, STOPPED or DESTROYED. An MBean that has reached one
- * of the above states has its dependencies resolved.
- *
- * @return a List<ServiceContext>
- */
- List<ServiceContext> listIncompletelyDeployed();
-
- /**
- * lists ObjectNames of deployed mbeans deployed through
- * serviceController.
- *
- * @return a list of ObjectNames of deployed mbeans.
- */
- List<ObjectName> listDeployedNames();
-
- /**
- * Gets the Configuration attribute of the ServiceController object
- *
- * @param objectNames Description of Parameter
- * @return The Configuration value
- * @throws Exception Description of Exception
- */
- String listConfiguration(ObjectName[] objectNames) throws Exception;
-
- /**
- * Go through the mbeans of the DeploymentInfo and validate that
- * they are in a state at least equal to that of the argument state
- *
- * @param di the deployment info
- * @param state the deployment state
- */
- void validateDeploymentState(DeploymentInfo di, DeploymentState state);
-
- /**
- * Deploy the beans; deploy means "instantiate and configure" so the MBean
- * is created in the MBeanServer. You must call "create" and "start" separately
- * on the MBean to affect the service lifecycle deploy doesn't bother with service
- * lifecycle only MBean instanciation/registration/configuration.
- *
- * @param config
- * @param loaderName
- * @return Description of the Returned Value
- * @throws DeploymentException
- */
- List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException;
-
- /**
- * Register the mbean against the microkernel with no dependencies.
- *
- * @see #register(ObjectName, java.util.Collection)
- * @param serviceName the object name
- * @throws Exception for any error
- */
- void register(ObjectName serviceName) throws Exception;
-
- /**
- * Register the mbean against the microkernel with dependencies.
- *
- * @param serviceName the object name
- * @param depends the dependencies
- * @throws Exception for any error
- */
- void register(ObjectName serviceName, Collection<ObjectName> depends) throws Exception;
-
- /**
- * Create a service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void create(ObjectName serviceName) throws Exception;
-
- /**
- * Create a service with given dependencies
- *
- * @param serviceName Description of Parameter
- * @param depends the dependencies
- * @throws Exception Description of Exception
- */
- void create(ObjectName serviceName, Collection<ObjectName> depends) throws Exception;
-
- /**
- * Starts the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void start(ObjectName serviceName) throws Exception;
-
- /**
- * Stops and restarts the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void restart(ObjectName serviceName) throws Exception;
-
- /**
- * Stop the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void stop(ObjectName serviceName) throws Exception;
-
- /**
- * Destroy the indicated service
- *
- * @param serviceName Description of Parameter
- * @throws Exception Description of Exception
- */
- void destroy(ObjectName serviceName) throws Exception;
-
- /**
- * This MBean is going bye bye
- *
- * @param objectName Description of Parameter
- * @throws Exception Description of Exception
- */
- void remove(ObjectName objectName) throws Exception;
-
- /**
- * Describe <code>shutdown</code> method here.
- */
- void shutdown();
-
- /**
- * Lookup the ServiceContext for the given serviceName
- *
- * @param serviceName the service name
- * @return the service context
- */
- ServiceContext getServiceContext(ObjectName serviceName);
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceControllerMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceCreator.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceCreator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceCreator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,378 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.net.URL;
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-import javax.management.StandardMBean;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.server.registry.MBeanEntry;
-import org.jboss.mx.service.ServiceConstants;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.metadata.ServiceConstructorMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.util.UnreachableStatementException;
-import org.w3c.dom.Element;
-
-/**
- * A helper class for the controller.
- *
- * @see Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ServiceCreator
-{
- /** Instance logger. */
- private static final Logger log = Logger.getLogger(ServiceCreator.class);
-
- /** The MBean Registry Object Name */
- private static ObjectName MBEAN_REGISTRY = ObjectNameFactory.create(ServerConstants.MBEAN_REGISTRY);
-
- /** The server */
- private MBeanServer server;
-
- /**
- * Install an MBean
- *
- * @todo expand the meta data to include a pre-instantiated object
- * @param server the mbean server
- * @param objectName the object name
- * @param metaData the service metadata
- * @param mbean any mbean instance
- * @return the installed instance
- * @throws Exception for any error
- */
- public static ServiceInstance install(MBeanServer server, ObjectName objectName, ServiceMetaData metaData, Object mbean) throws Exception
- {
- if (server == null)
- throw new IllegalArgumentException("Null MBeanServer");
- if (objectName == null)
- throw new IllegalArgumentException("Null ObjectName");
- if (metaData == null && mbean == null)
- throw new IllegalArgumentException("Either metadata or an mbean object must be supplied");
-
- // Check for duplicate
- if (server.isRegistered(objectName))
- throw new DeploymentException("Trying to install an already registered mbean: " + objectName);
-
- try
- {
- ServiceInstance result = null;
-
- // No meta data just register directly
- if (metaData == null)
- {
- ObjectInstance instance = server.registerMBean(mbean, objectName);
- result = new ServiceInstance(instance, mbean);
- }
- else
- {
- String code = metaData.getCode();
- if (code == null || code.trim().length() == 0)
- throw new ConfigurationException("Missing or empty code for mbean " + objectName);
-
- String xmbeanDD = metaData.getXMBeanDD();
-
- // Not an XMBean
- if (xmbeanDD == null)
- {
- String interfaceName = metaData.getInterfaceName();
- if (interfaceName != null)
- result = installStandardMBean(server, objectName, metaData);
- else
- result = installPlainMBean(server, objectName, metaData);
- }
- // Embedded XMBean Descriptor
- else if (xmbeanDD.length() == 0)
- result = installEmbeddedXMBean(server, objectName, metaData);
- // Reference to external XMBean descriptor
- else
- result = installExternalXMBean(server, objectName, metaData);
- }
-
- log.debug("Created mbean: " + objectName);
- return result;
- }
- catch (Throwable e)
- {
- Throwable newE = JMXExceptionDecoder.decode(e);
-
- // didn't work, unregister in case the jmx agent is screwed.
- try
- {
- server.unregisterMBean(objectName);
- }
- catch (Throwable ignore)
- {
- }
-
- DeploymentException.rethrowAsDeploymentException("Unable to createMBean for " + objectName, newE);
- throw new UnreachableStatementException();
- }
- }
-
- /**
- * Install a StandardMBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installStandardMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
- String interfaceName = metaData.getInterfaceName();
-
- Class intf = loader.loadClass(interfaceName);
- log.debug("About to create bean resource: " + objectName + " with code: " + code + " and interface " + interfaceName);
- Object resource = server.instantiate(code,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
-
- log.debug("About to register StandardMBean : " + objectName);
- ObjectInstance instance = server.createMBean(StandardMBean.class.getName(),
- objectName,
- loaderName,
- new Object[] { resource, intf },
- new String[] { Object.class.getName() , Class.class.getName() });
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Install a plain MBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installPlainMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
-
- // This is a standard or dynamic mbean
- log.debug("About to create bean: " + objectName + " with code: " + code);
- ObjectInstance instance = server.createMBean(code,
- objectName,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
-
- MBeanEntry entry = (MBeanEntry) server.invoke(MBEAN_REGISTRY, "get", new Object[] { objectName }, new String[] { ObjectName.class.getName() });
- Object resource = entry.getResourceInstance();
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Install an embedded XMBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installEmbeddedXMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
-
- // This is an xmbean with an embedded mbean descriptor
- log.debug("About to create xmbean object: " + objectName + " with code: " + code + " with embedded descriptor");
- //xmbean: construct object first.
- Object resource = server.instantiate(code,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
-
- String xmbeanCode = metaData.getXMBeanCode();
- Element mbeanDescriptor = metaData.getXMBeanDescriptor();
- Object[] args = { resource, mbeanDescriptor, ServiceConstants.PUBLIC_JBOSSMX_XMBEAN_DTD_1_0 };
- String[] sig = { Object.class.getName(), Element.class.getName(), String.class.getName() };
- ObjectInstance instance = server.createMBean(xmbeanCode,
- objectName,
- loaderName,
- args,
- sig);
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Install an external XMBean
- *
- * @param server the mbean server
- * @param objectName the object name
- * @param metadata the service metadata
- * @return the installed instance
- * @throws Exception for any error
- */
- private static ServiceInstance installExternalXMBean(MBeanServer server, ObjectName objectName, ServiceMetaData metaData) throws Exception
- {
- ObjectName loaderName = metaData.getClassLoaderName();
- ClassLoader loader = server.getClassLoader(loaderName);
- String code = metaData.getCode();
- ServiceConstructorMetaData constructor = metaData.getConstructor();
- String xmbeanDD = metaData.getXMBeanDD();
-
- // This is an xmbean with an external descriptor
- log.debug("About to create xmbean object: " + objectName + " with code: " + code + " with descriptor: " + xmbeanDD);
- //xmbean: construct object first.
- Object resource = server.instantiate(code,
- loaderName,
- constructor.getParameters(loader),
- constructor.getSignature());
- // Try to find the dd first as a resource then as a URL
- URL xmbeanddUrl = null;
- try
- {
- xmbeanddUrl = resource.getClass().getClassLoader().getResource(xmbeanDD);
- }
- catch (Exception e)
- {
- }
-
- if (xmbeanddUrl == null)
- xmbeanddUrl = new URL(xmbeanDD);
-
- String xmbeanCode = metaData.getXMBeanCode();
-
- //now create the mbean
- Object[] args = { resource, xmbeanddUrl };
- String[] sig = { Object.class.getName(), URL.class.getName() };
- ObjectInstance instance = server.createMBean(xmbeanCode,
- objectName,
- loaderName,
- args,
- sig);
- return new ServiceInstance(instance, resource);
- }
-
- /**
- * Uninstall an MBean
- *
- * @param server the mbean server
- * @param objectName the object name
- */
- public static void uninstall(MBeanServer server, ObjectName objectName)
- {
- if (server == null)
- throw new IllegalArgumentException("Null MBeanServer");
- if (objectName == null)
- throw new IllegalArgumentException("Null ObjectName");
- try
- {
- log.debug("Removing mbean from server: " + objectName);
- server.unregisterMBean(objectName);
- }
- catch (Throwable t)
- {
- log.debug("Error unregistering mbean " + objectName, t);
- }
- }
-
- /**
- * Create a new ServiceCreator
- *
- * @deprecated This is no longer used and will be going away
- * @param server the mbean server
- */
- public ServiceCreator(final MBeanServer server)
- {
- if (server == null)
- throw new IllegalArgumentException("Null MBeanServer");
- this.server = server;
- }
-
- /**
- * Clean shutdown
- */
- public void shutdown()
- {
- this.server = null;
- }
-
- /**
- * Parses the given configuration document and creates MBean
- * instances in the current MBean server.
- *
- * @deprecated This is no longer used and will be going away
- * @param mbeanName the object name
- * @param loaderName the classloader
- * @param mbeanElement the config
- * @return the created object instance
- * @throws Exception for any error
- */
- public ObjectInstance install(ObjectName mbeanName, ObjectName loaderName, Element mbeanElement) throws Exception
- {
- if (mbeanName == null)
- throw new IllegalArgumentException("Null mbeanName");
- if (mbeanElement == null)
- throw new IllegalArgumentException("Null mbean element");
-
- ServiceMetaDataParser parser = new ServiceMetaDataParser(mbeanElement);
- List<ServiceMetaData> metaDatas = parser.parse();
- if (metaDatas.isEmpty())
- throw new DeploymentException("No mbeans found in passed configuration for " + mbeanName);
- ServiceMetaData metaData = metaDatas.get(0);
- metaData.setClassLoaderName(loaderName);
- ServiceInstance instance = install(server, mbeanName, metaData, null);
- return instance.getObjectInstance();
- }
-
- /**
- * Remove the installed object
- *
- * @param name the object name
- * @throws Exception for any error
- */
- public void remove(ObjectName name) throws Exception
- {
- if (name == null)
- throw new IllegalArgumentException("Null name");
- uninstall(server, name);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceCreator.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceCreator.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceCreator.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,354 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import java.util.List;
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanConstructorInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanParameterInfo;
-import javax.management.ReflectionException;
-
-import org.jboss.logging.Logger;
-
-/**
- * <description>
- *
- * @see <related>
- *
- * @author <a href="mailto:sacha.labourey at cogito-info.ch">Sacha Labourey</a>.
- * @version $Revision$
- *
- * <p><b>Revisions:</b>
- *
- * <p><b>6 janv. 2003 Sacha Labourey:</b>
- * <ul>
- * <li> First implementation </li>
- * </ul>
- */
-public class ServiceDynamicMBeanSupport
- extends ServiceMBeanSupport
- implements DynamicMBean
-{
-
- // Constants -----------------------------------------------------
-
- // Attributes ----------------------------------------------------
-
- // Static --------------------------------------------------------
-
- // Constructors --------------------------------------------------
-
- public ServiceDynamicMBeanSupport()
- {
- super();
- }
-
- public ServiceDynamicMBeanSupport(Class type)
- {
- super(type);
- }
-
- public ServiceDynamicMBeanSupport(String category)
- {
- super(category);
- }
-
- public ServiceDynamicMBeanSupport(Logger log)
- {
- super(log);
- }
-
- // Public --------------------------------------------------------
-
- // DynamicMBean implementation -----------------------------------
-
- public Object getAttribute(String attribute)
- throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- // locally managed attributes!
- //
- if("State".equals(attribute))
- {
- return new Integer(getState());
- }
- if("StateString".equals(attribute))
- {
- return getStateString();
- }
- if("Name".equals(attribute))
- {
- return getName();
- }
-
- // Wrapped attributes?
- //
- return getInternalAttribute (attribute);
-
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature)
- throws MBeanException, ReflectionException
- {
- try
- {
- if (ServiceController.JBOSS_INTERNAL_LIFECYCLE.equals(actionName))
- {
- jbossInternalLifecycle((String) params[0]);
- return null;
- }
- if (params == null || params.length == 0)
- {
- if ("create".equals(actionName))
- {
- create(); return null;
- }
- else if ("start".equals(actionName))
- {
- start(); return null;
- }
- else if ("stop".equals(actionName))
- {
- stop(); return null;
- }
- else if ("destroy".equals(actionName))
- {
- destroy(); return null;
- }
- }
- }
- catch (Exception e)
- {
- throw new MBeanException(e, "Exception in service lifecyle operation: " + actionName);
- }
-
- // If I am here, it means that the invocation has not been handled locally
- //
- try
- {
- return internalInvoke (actionName, params, signature);
- }
- catch (Exception e)
- {
- throw new MBeanException(e,
- "Exception invoking: " + actionName);
- }
- }
-
- public void setAttribute(Attribute attribute)
- throws
- AttributeNotFoundException,
- InvalidAttributeValueException,
- MBeanException,
- ReflectionException
- {
- setInternalAttribute (attribute);
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- AttributeList list = new AttributeList();
- if (attributes == null)
- return list;
- for (int i = 0; i < attributes.size(); ++i)
- {
- Attribute attribute = (Attribute) attributes.get(i);
- try
- {
- setAttribute(attribute);
- list.add(attribute);
- }
- catch (Throwable t)
- {
- log.debug("Error setting attribute " + attribute.getName(), t);
- }
- }
- return list;
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- AttributeList list = new AttributeList();
- if (attributes == null)
- return list;
- for (int i = 0; i < attributes.length; ++i)
- {
- try
- {
- Object value = getAttribute(attributes[i]);
- list.add(new Attribute(attributes[i], value));
- }
- catch (Throwable t)
- {
- log.debug("Error getting attribute " + attributes[i], t);
- }
- }
- return list;
- }
-
- public MBeanInfo getMBeanInfo()
- {
- MBeanParameterInfo[] noParams = new MBeanParameterInfo[] {};
-
- MBeanConstructorInfo[] ctorInfo = getInternalConstructorInfo();
-
- MBeanAttributeInfo[] attrs = getInternalAttributeInfo();
- MBeanAttributeInfo[] attrInfo = new MBeanAttributeInfo[3 + attrs.length];
- attrInfo[0] = new MBeanAttributeInfo("Name",
- "java.lang.String",
- "Return the service name",
- true,
- false,
- false);
- attrInfo[1] = new MBeanAttributeInfo("State",
- "int",
- "Return the service state",
- true,
- false,
- false);
- attrInfo[2] = new MBeanAttributeInfo("StateString",
- "java.lang.String",
- "Return the service's state as a String",
- true,
- false,
- false);
- System.arraycopy(attrs, 0, attrInfo, 3, attrs.length);
-
- MBeanParameterInfo[] jbossInternalLifecycleParms = new MBeanParameterInfo[1];
- jbossInternalLifecycleParms[0] = new MBeanParameterInfo("method", String.class.getName(), "The lifecycle method");
-
- MBeanOperationInfo[] ops = getInternalOperationInfo();
- MBeanOperationInfo[] opInfo = new MBeanOperationInfo[5 + ops.length];
- opInfo[0] = new MBeanOperationInfo("create",
- "create service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[1] = new MBeanOperationInfo("start",
- "start service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[2] = new MBeanOperationInfo("stop",
- "stop service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[3] = new MBeanOperationInfo("destroy",
- "destroy service lifecycle operation",
- noParams,
- "void",
- MBeanOperationInfo.ACTION);
-
- opInfo[4] = new MBeanOperationInfo(ServiceController.JBOSS_INTERNAL_LIFECYCLE,
- "Internal lifecycle (for internal use)",
- jbossInternalLifecycleParms,
- "void",
- MBeanOperationInfo.ACTION);
-
- System.arraycopy(ops, 0, opInfo, 5, ops.length);
-
- MBeanNotificationInfo[] notifyInfo = getInternalNotificationInfo();
- return new MBeanInfo(getClass().getName(),
- getInternalDescription(),
- attrInfo,
- ctorInfo,
- opInfo,
- notifyInfo);
- }
-
- // Y overrides ---------------------------------------------------
-
- // Package protected ---------------------------------------------
-
- // Protected -----------------------------------------------------
-
- protected String getInternalDescription()
- {
- return "DynamicMBean Service";
- }
-
- protected MBeanConstructorInfo[] getInternalConstructorInfo()
- {
- return new MBeanConstructorInfo[0];
- }
-
- protected MBeanAttributeInfo[] getInternalAttributeInfo()
- {
- return new MBeanAttributeInfo[0];
- }
-
- protected MBeanOperationInfo[] getInternalOperationInfo()
- {
- return new MBeanOperationInfo[0];
- }
-
- protected MBeanNotificationInfo[] getInternalNotificationInfo()
- {
- return new MBeanNotificationInfo[0];
- }
-
- protected Object getInternalAttribute(String attribute)
- throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- throw new AttributeNotFoundException ("Attribute not found " + attribute);
- }
-
- protected void setInternalAttribute(Attribute attribute)
- throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- throw new AttributeNotFoundException ("Attribute not found " + attribute);
- }
-
- protected Object internalInvoke(String actionName, Object[] params, String[] signature)
- throws MBeanException, ReflectionException
- {
- StringBuffer buffer = new StringBuffer();
- buffer.append(actionName);
- buffer.append('(');
- for (int i = 0; i < signature.length; ++i)
- {
- buffer.append(signature[i]);
- if (i < signature.length - 1)
- buffer.append(", ");
- }
- buffer.append(')');
- throw new MBeanException(new Exception("Operation not found " + buffer.toString()), "Operation not found " + actionName);
- }
-
-
- // Private -------------------------------------------------------
-
- // Inner classes -------------------------------------------------
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceDynamicMBeanSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceFactory.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-/**
- * The ServiceFactory interface is used to obtain a Service
- * proxy instance for a named MBean.
- *
- * @author <a href="mailto:Scott_Stark at displayscape.com">Scott Stark</a>.
- * @version $Revision$
- */
-public interface ServiceFactory
-{
- /**
- * Create a Service proxy instance for the MBean given by name.
- *
- * @param server The MBeanServer instance
- * @param name The name of the MBean that wishes to be managed by
- * the JBoss ServiceControl service.
- */
- Service createService(MBeanServer server, ObjectName name);
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceFactory.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceFactory.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceFactory.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceInstance.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceInstance.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceInstance.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,78 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.ObjectInstance;
-
-/**
- * ServiceInstance.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceInstance
-{
- /** The object instance */
- private ObjectInstance objectInstance;
-
- /** The object */
- private Object resource;
-
- /**
- * Create a new ServiceInstance.
- */
- public ServiceInstance()
- {
- }
-
- /**
- * Create a new ServiceInstance.
- *
- * @param objectInstance the object instance
- * @param resource the object
- */
- public ServiceInstance(ObjectInstance objectInstance, Object resource)
- {
- this.objectInstance = objectInstance;
- this.resource = resource;
- }
-
- /**
- * Get the resource.
- *
- * @return the resource.
- */
- public Object getResource()
- {
- return resource;
- }
-
- /**
- * Get the objectInstance.
- *
- * @return the objectInstance.
- */
- public ObjectInstance getObjectInstance()
- {
- return objectInstance;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceInstance.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceInstance.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,78 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-/**
- * An interface describing a JBoss service MBean.
- *
- * @see Service
- * @see ServiceMBeanSupport
- *
- * @author <a href="mailto:rickard.oberg at telkel.com">Rickard Öberg</a>
- * @author <a href="mailto:andreas at jboss.org">Andreas Schaefer</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public interface ServiceMBean
- extends Service
-{
- // Constants -----------------------------------------------------
-
- /** ServiceController notification types corresponding to service lifecycle events */
- public static final String CREATE_EVENT = "org.jboss.system.ServiceMBean.create";
- public static final String START_EVENT = "org.jboss.system.ServiceMBean.start";
- public static final String STOP_EVENT = "org.jboss.system.ServiceMBean.stop";
- public static final String DESTROY_EVENT = "org.jboss.system.ServiceMBean.destroy";
-
- public static final String[] states = {
- "Stopped", "Stopping", "Starting", "Started", "Failed",
- "Destroyed", "Created", "Unregistered", "Registered"
- };
-
- /** The Service.stop has completed */
- public static final int STOPPED = 0;
- /** The Service.stop has been invoked */
- public static final int STOPPING = 1;
- /** The Service.start has been invoked */
- public static final int STARTING = 2;
- /** The Service.start has completed */
- public static final int STARTED = 3;
- /** There has been an error during some operation */
- public static final int FAILED = 4;
- /** The Service.destroy has completed */
- public static final int DESTROYED = 5;
- /** The Service.create has completed */
- public static final int CREATED = 6;
- /** The MBean has been created but has not completed MBeanRegistration.postRegister */
- public static final int UNREGISTERED = 7;
- /** The MBean has been created and has completed MBeanRegistration.postRegister */
- public static final int REGISTERED = 8;
-
- // Public --------------------------------------------------------
-
- String getName();
- int getState();
- String getStateString();
-
- /** Detyped lifecycle invocation */
- void jbossInternalLifecycle(String method) throws Exception;
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,141 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system;
-
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.Set;
-
-import org.jboss.util.state.State;
-import org.jboss.util.state.StateMachine;
-import org.jboss.util.state.Transition;
-
-/**
- * A final class that encapsulates the constants necessary
- * for creating StateMachines that follow the ServiceMBean
- * lifecycle model.
- *
- * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public final class ServiceMBeanState
-{
- // ServiceMBean States
- public static final State STATE_UNREGISTERED = new State("Unregistered"); // Initial State
- public static final State STATE_REGISTERED = new State("Registered");
- public static final State STATE_CREATED = new State("Created");
- public static final State STATE_STARTING = new State("Starting");
- public static final State STATE_STARTED = new State("Started");
- public static final State STATE_STOPPING = new State("Stopping");
- public static final State STATE_STOPPED = new State("Stopped");
- public static final State STATE_DESTROYED = new State("Destroyed");
- public static final State STATE_FAILED = new State("Failed");
-
- // ServiceMBean State Transitions
- public static final Transition TRANS_REGISTER = new Transition("register", STATE_REGISTERED);
- public static final Transition TRANS_CREATE = new Transition("create", STATE_CREATED);
- public static final Transition TRANS_START_BEGIN = new Transition("startBegin", STATE_STARTING);
- public static final Transition TRANS_START_END = new Transition("startEnd", STATE_STARTED);
- public static final Transition TRANS_STOP_BEGIN = new Transition("stopBegin", STATE_STOPPING);
- public static final Transition TRANS_STOP_END = new Transition("stopEnd", STATE_STOPPED);
- public static final Transition TRANS_DESTROY = new Transition("destroy", STATE_DESTROYED);
- public static final Transition TRANS_UNREGISTER = new Transition("unregister", STATE_UNREGISTERED);
- public static final Transition TRANS_FAIL = new Transition("fail", STATE_FAILED);
-
- /** The possible set of States a ServiceMBean can be in */
- public static final Set STATES = new HashSet(
- Arrays.asList(new State[] {
- STATE_UNREGISTERED,
- STATE_REGISTERED,
- STATE_CREATED,
- STATE_STARTING,
- STATE_STARTED,
- STATE_STOPPING,
- STATE_STOPPED,
- STATE_DESTROYED,
- STATE_FAILED
- }));
-
- // Associate States with valid Transitions, or else, define explicitly
- // the ServiceMBean lifecycle that drives the StateMachine
- static
- {
- STATE_UNREGISTERED
- .addTransition(TRANS_REGISTER)
- .addTransition(TRANS_FAIL);
-
- STATE_REGISTERED
- .addTransition(TRANS_CREATE)
- .addTransition(TRANS_UNREGISTER)
- .addTransition(TRANS_FAIL);
-
- STATE_CREATED
- .addTransition(TRANS_START_BEGIN)
- .addTransition(TRANS_DESTROY)
- .addTransition(TRANS_FAIL);
-
- STATE_STARTING
- .addTransition(TRANS_START_END)
- .addTransition(TRANS_FAIL);
-
- STATE_STARTED
- .addTransition(TRANS_STOP_BEGIN)
- .addTransition(TRANS_FAIL);
-
- STATE_STOPPING
- .addTransition(TRANS_STOP_END)
- .addTransition(TRANS_FAIL);
-
- STATE_STOPPED
- .addTransition(TRANS_START_BEGIN)
- .addTransition(TRANS_DESTROY)
- .addTransition(TRANS_FAIL);
-
- STATE_DESTROYED
- .addTransition(TRANS_CREATE)
- .addTransition(TRANS_UNREGISTER)
- .addTransition(TRANS_FAIL);
-
- // STATE_FAILED - no transitions
- }
-
- /**
- * Create a new StateMachine that follows the ServiceMBean
- * lifecycle, initialized to the STATE_UNREGISTERED state.
- *
- * @param description A string description for this state machine, or null
- * @return the StateMachine
- */
- public static StateMachine createStateMachine(String description)
- {
- return new StateMachine(STATES, STATE_UNREGISTERED, description);
- }
-
- /**
- * Dissallow instances of this class
- */
- private ServiceMBeanState()
- {
- // empty
- }
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanState.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,510 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system;
-
-import javax.management.AttributeChangeNotification;
-import javax.management.JMException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.SARDeployerMBean;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-
-/**
- * An abstract base class JBoss services can subclass to implement a
- * service that conforms to the ServiceMBean interface. Subclasses must
- * override {@link #getName} method and should override
- * {@link #startService}, and {@link #stopService} as approriate.
- *
- * @see ServiceMBean
- *
- * @author <a href="mailto:rickard.oberg at telkel.com">Rickard Ãberg</a>
- * @author Scott.Stark at jboss.org
- * @author <a href="mailto:andreas at jboss.org">Andreas Schaefer</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @version $Revision$
- */
-public class ServiceMBeanSupport
- extends JBossNotificationBroadcasterSupport
- implements ServiceMBean, MBeanRegistration
-{
- /** The signature for service controller operations */
- public static final String[] SERVICE_CONTROLLER_SIG = new String[] { ObjectName.class.getName() };
-
- /**
- * The instance logger for the service. Not using a class logger
- * because we want to dynamically obtain the logger name from
- * concreate sub-classes.
- */
- protected Logger log;
-
- /** The MBeanServer which we have been register with. */
- protected MBeanServer server;
-
- /** The object name which we are registsred under. */
- protected ObjectName serviceName;
-
- /** The current state this service is in. */
- private int state = UNREGISTERED;
-
- /** For backwards compatibility */
- private boolean isJBossInternalLifecycleExposed = false;
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * <p>Sets up logging.
- */
- public ServiceMBeanSupport()
- {
- // can not call this(Class) because we need to call getClass()
- this.log = Logger.getLogger(getClass().getName());
- log.trace("Constructing");
- }
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * <p>Sets up logging.
- *
- * @param type The class type to determine category name from.
- */
- public ServiceMBeanSupport(final Class type)
- {
- this(type.getName());
- }
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * <p>Sets up logging.
- *
- * @param category The logger category name.
- */
- public ServiceMBeanSupport(final String category)
- {
- this(Logger.getLogger(category));
- }
-
- /**
- * Construct a <t>ServiceMBeanSupport</tt>.
- *
- * @param log The logger to use.
- */
- public ServiceMBeanSupport(final Logger log)
- {
- this.log = log;
- log.trace("Constructing");
- }
-
- /**
- * Use the short class name as the default for the service name.
- */
- public String getName()
- {
- // TODO: Check if this gets called often, if so cache this or remove if not used
- // use the logger so we can better be used as a delegate instead of sub-class
- return org.jboss.util.Classes.stripPackageName(log.getName());
- }
-
- public ObjectName getServiceName()
- {
- return serviceName;
- }
-
- /**
- * Provide access to the service DeploymentInfo. This is only available
- * after the service has passed its create step.
- *
- * @return The service DeploymentInfo if found registered under the SARDeployer.
- * @throws JMException - thrown on failure to invoke
- * SARDeployer.getService(ObjectName)
- */
- public DeploymentInfo getDeploymentInfo()
- throws JMException
- {
- Object[] args = {serviceName};
- String[] sig = {serviceName.getClass().getName()};
- DeploymentInfo sdi = (DeploymentInfo) server.invoke(SARDeployerMBean.OBJECT_NAME,
- "getService", args, sig);
- return sdi;
- }
-
- public MBeanServer getServer()
- {
- return server;
- }
-
- public int getState()
- {
- return state;
- }
-
- public String getStateString()
- {
- return states[state];
- }
-
- public Logger getLog()
- {
- return log;
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // State Mutators //
- ///////////////////////////////////////////////////////////////////////////
-
- public void create() throws Exception
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "create", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalCreate();
- }
-
- public void start() throws Exception
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "start", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalStart();
- }
-
- public void stop()
- {
- try
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "stop", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalStop();
- }
- catch (Throwable t)
- {
- log.warn("Error in stop " + jbossInternalDescription(), t);
- }
- }
-
- public void destroy()
- {
- try
- {
- if (serviceName != null && isJBossInternalLifecycleExposed)
- server.invoke(ServiceController.OBJECT_NAME, "destroy", new Object[] { serviceName }, SERVICE_CONTROLLER_SIG);
- else
- jbossInternalDestroy();
- }
- catch (Throwable t)
- {
- log.warn("Error in destroy " + jbossInternalDescription(), t);
- }
- }
-
- protected String jbossInternalDescription()
- {
- if (serviceName != null)
- return serviceName.toString();
- else
- return getName();
- }
-
- public void jbossInternalLifecycle(String method) throws Exception
- {
- if (method == null)
- throw new IllegalArgumentException("Null method name");
-
- if (method.equals("create"))
- jbossInternalCreate();
- else if (method.equals("start"))
- jbossInternalStart();
- else if (method.equals("stop"))
- jbossInternalStop();
- else if (method.equals("destroy"))
- jbossInternalDestroy();
- else
- throw new IllegalArgumentException("Unknown lifecyle method " + method);
- }
-
- protected void jbossInternalCreate() throws Exception
- {
- log.debug("Creating " + jbossInternalDescription());
-
- try
- {
- createService();
- state = CREATED;
- }
- catch (Exception e)
- {
- log.debug("Initialization failed " + jbossInternalDescription(), e);
- throw e;
- }
-
- log.debug("Created " + jbossInternalDescription());
- }
-
- protected void jbossInternalStart() throws Exception
- {
- if (state == STARTING || state == STARTED || state == STOPPING)
- return;
-
- if (state != CREATED && state != STOPPED && state != FAILED)
- {
- log.debug("Start requested before create, calling create now");
- create();
- }
-
- state = STARTING;
- sendStateChangeNotification(STOPPED, STARTING, getName() + " starting", null);
- log.debug("Starting " + jbossInternalDescription());
-
- try
- {
- startService();
- }
- catch (Exception e)
- {
- state = FAILED;
- sendStateChangeNotification(STARTING, FAILED, getName() + " failed", e);
- log.debug("Starting failed " + jbossInternalDescription(), e);
- throw e;
- }
-
- state = STARTED;
- sendStateChangeNotification(STARTING, STARTED, getName() + " started", null);
- log.debug("Started " + jbossInternalDescription());
- }
-
- protected void jbossInternalStop()
- {
- if (state != STARTED)
- return;
-
- state = STOPPING;
- sendStateChangeNotification(STARTED, STOPPING, getName() + " stopping", null);
- log.debug("Stopping " + jbossInternalDescription());
-
- try
- {
- stopService();
- }
- catch (Throwable e)
- {
- state = FAILED;
- sendStateChangeNotification(STOPPING, FAILED, getName() + " failed", e);
- log.warn("Stopping failed " + jbossInternalDescription(), e);
- return;
- }
-
- state = STOPPED;
- sendStateChangeNotification(STOPPING, STOPPED, getName() + " stopped", null);
- log.debug("Stopped " + jbossInternalDescription());
- }
-
- protected void jbossInternalDestroy()
- {
- if (state == DESTROYED)
- return;
-
- if (state == STARTED)
- {
- log.debug("Destroy requested before stop, calling stop now");
- stop();
- }
-
- log.debug("Destroying " + jbossInternalDescription());
-
- try
- {
- destroyService();
- }
- catch (Throwable t)
- {
- log.warn("Destroying failed " + jbossInternalDescription(), t);
- }
- state = DESTROYED;
- log.debug("Destroyed " + jbossInternalDescription());
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // JMX Hooks //
- ///////////////////////////////////////////////////////////////////////////
-
- /**
- * Callback method of {@link MBeanRegistration}
- * before the MBean is registered at the JMX Agent.
- *
- * <p>
- * <b>Attention</b>: Always call this method when you overwrite it in a subclass
- * because it saves the Object Name of the MBean.
- *
- * @param server Reference to the JMX Agent this MBean is registered on
- * @param name Name specified by the creator of the MBean. Note that you can
- * overwrite it when the given ObjectName is null otherwise the
- * change is discarded (maybe a bug in JMX-RI).
- */
- public ObjectName preRegister(MBeanServer server, ObjectName name)
- throws Exception
- {
- this.server = server;
-
- serviceName = getObjectName(server, name);
-
- return serviceName;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- if (!registrationDone.booleanValue())
- {
- log.info( "Registration is not done -> stop" );
- stop();
- }
- else
- {
- state = REGISTERED;
- // This is for backwards compatibility - see whether jbossInternalLifecycle is exposed
- try
- {
- MBeanInfo info = server.getMBeanInfo(serviceName);
- MBeanOperationInfo[] ops = info.getOperations();
- for (int i = 0; i < ops.length; ++i)
- {
- if (ops[i] != null && ServiceController.JBOSS_INTERNAL_LIFECYCLE.equals(ops[i].getName()))
- {
- isJBossInternalLifecycleExposed = true;
- break;
- }
- }
- }
- catch (Throwable t)
- {
- log.warn("Unexcepted error accessing MBeanInfo for " + serviceName, t);
- }
- }
- }
-
- public void preDeregister() throws Exception
- {
- }
-
- public void postDeregister()
- {
- server = null;
- serviceName = null;
- state = UNREGISTERED;
- }
-
- /**
- * The <code>getNextNotificationSequenceNumber</code> method returns
- * the next sequence number for use in notifications.
- *
- * @return a <code>long</code> value
- */
- protected long getNextNotificationSequenceNumber()
- {
- return nextNotificationSequenceNumber();
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // Concrete Service Overrides //
- ///////////////////////////////////////////////////////////////////////////
-
- /**
- * Sub-classes should override this method if they only need to set their
- * object name during MBean pre-registration.
- */
- protected ObjectName getObjectName(MBeanServer server, ObjectName name)
- throws MalformedObjectNameException
- {
- return name;
- }
-
- /**
- * Sub-classes should override this method to provide
- * custum 'create' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void createService() throws Exception {}
-
- /**
- * Sub-classes should override this method to provide
- * custum 'start' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void startService() throws Exception {}
-
- /**
- * Sub-classes should override this method to provide
- * custum 'stop' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void stopService() throws Exception {}
-
- /**
- * Sub-classes should override this method to provide
- * custum 'destroy' logic.
- *
- * <p>This method is empty, and is provided for convenience
- * when concrete service classes do not need to perform
- * anything specific for this state change.
- */
- protected void destroyService() throws Exception {}
-
- // Private -------------------------------------------------------
-
- /**
- * Helper for sending out state change notifications
- */
- private void sendStateChangeNotification(int oldState, int newState, String msg, Throwable t)
- {
- long now = System.currentTimeMillis();
-
- AttributeChangeNotification stateChangeNotification = new AttributeChangeNotification(
- this,
- getNextNotificationSequenceNumber(), now, msg,
- "State", "java.lang.Integer",
- new Integer(oldState), new Integer(newState)
- );
- stateChangeNotification.setUserData(t);
-
- sendNotification(stateChangeNotification);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/ServiceMBeanSupport.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers)
Deleted: trunk/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,72 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.deployers;
-
-import java.util.HashSet;
-import java.util.Set;
-import java.util.StringTokenizer;
-
-import org.jboss.virtual.VirtualFile;
-import org.jboss.virtual.VirtualFileFilter;
-
-/**
- * SARArchiveFilter.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SARArchiveFilter implements VirtualFileFilter
-{
- /** The patterns */
- private final Set<String> patterns;
-
- /** Whether there is the accept all wildcard */
- private final boolean allowAll;
-
- /**
- * Create a new SARArchiveFilter.
- *
- * @param patternsString the pattern string
- * @throws IllegalArgumentException for a null string
- */
- public SARArchiveFilter(String patternsString)
- {
- if (patternsString == null)
- throw new IllegalArgumentException("Null patternsString");
-
- StringTokenizer tokens = new StringTokenizer (patternsString, ",");
- patterns = new HashSet<String>(tokens.countTokens());
- for (int i=0; tokens.hasMoreTokens (); ++i)
- {
- String token = tokens.nextToken();
- patterns.add(token.trim());
- }
- allowAll = patterns.contains("*");
- }
-
- public boolean accepts(VirtualFile file)
- {
- if (allowAll)
- return true;
- return patterns.contains(file.getName());
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/SARArchiveFilter.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,134 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.deployers;
-
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.jboss.deployers.plugins.deployers.helpers.JAXPDeployer;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext;
-import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
-import org.jboss.system.metadata.ServiceDeployment;
-import org.jboss.system.metadata.ServiceDeploymentClassPath;
-import org.jboss.system.metadata.ServiceDeploymentParser;
-import org.jboss.system.server.ServerConfig;
-import org.jboss.system.server.ServerConfigLocator;
-import org.jboss.virtual.VFS;
-import org.jboss.virtual.VirtualFile;
-import org.w3c.dom.Document;
-
-/**
- * SARDeployer.<p>
- *
- * This deployer is responsible for looking for -service.xml
- * and creating the metadata object.<p>
- *
- * The {@link ServiceClassLoaderDeployer} and {@link ServiceDeployer} does the real work of deployment.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SARDeployer extends JAXPDeployer<ServiceDeployment>
-{
- /**
- * Create a new SARDeployer.
- *
- * @throws IllegalArgumentException for a null kernel
- */
- public SARDeployer()
- {
- super(ServiceDeployment.class);
- }
-
- protected ServiceDeployment parse(DeploymentUnit unit, VirtualFile file, Document document) throws Exception
- {
- ServiceDeploymentParser parser = new ServiceDeploymentParser(document);
- ServiceDeployment parsed = parser.parse();
- String name = file.toURI().toString();
- parsed.setName(name);
-
- List<ServiceDeploymentClassPath> classPaths = parsed.getClassPaths();
- if (classPaths != null)
- processXMLClasspath(unit.getDeploymentContext(), classPaths);
-
- LoaderRepositoryConfig config = parsed.getLoaderRepositoryConfig();
- if (config != null)
- unit.addAttachment(LoaderRepositoryConfig.class.getName(), config);
- return parsed;
- }
-
- public void deploy(DeploymentUnit unit) throws DeploymentException
- {
- createMetaData(unit, null, "-service.xml");
- }
-
- /**
- * Process the xml classpath
- *
- * @param context the context
- * @param classpaths the classpaths
- * @throws Exception for any error
- */
- private void processXMLClasspath(DeploymentContext context, List<ServiceDeploymentClassPath> classpaths) throws Exception
- {
- ArrayList<VirtualFile> classpath = new ArrayList<VirtualFile>();
-
- for (ServiceDeploymentClassPath path : classpaths)
- {
- String codebase = path.getCodeBase();
- String archives = path.getArchives();
-
- log.debug("Processing classpath: " + context.getName() + " codebase=" + codebase + " archives=" + archives);
- VirtualFile codebaseFile = context.getRoot();
- if (".".equals(codebase) == false)
- {
- ServerConfig config = ServerConfigLocator.locate();
- URL codeBaseURL = new URL(config.getServerHomeURL(), codebase);
- codebaseFile = VFS.getVirtualFile(codeBaseURL, "");
- }
-
- if (codebaseFile == null)
- throw new DeploymentException("Cannot use classpath without a root: " + context.getName());
-
- if (archives == null)
- {
- classpath.add(codebaseFile);
- log.debug("Using codebase as classpath: " + context.getName());
- }
- else
- {
- SARArchiveFilter filter = new SARArchiveFilter(archives);
- List<VirtualFile> archiveFiles = codebaseFile.getChildren(filter);
- classpath.addAll(archiveFiles);
- }
-
- }
-
- List<VirtualFile> origClassPath = context.getClassPath();
- if (origClassPath != null)
- classpath.addAll(origClassPath);
- context.setClassPath(classpath);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/SARDeployer.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,196 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.deployers;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.util.Set;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.deployers.plugins.deployers.helpers.AbstractTopLevelClassLoaderDeployer;
-import org.jboss.deployers.plugins.deployers.helpers.ClassPathVisitor;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext;
-import org.jboss.mx.loading.LoaderRepositoryFactory;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
-import org.jboss.system.ServiceController;
-import org.jboss.system.metadata.ServiceDeployment;
-import org.jboss.virtual.VirtualFile;
-
-/**
- * ServiceClassLoaderDeployer.<p>
- *
- * This deployer is responsible for creating classloaders for services of
- * type {@link ServiceDeployment}.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceClassLoaderDeployer extends AbstractTopLevelClassLoaderDeployer
-{
- /** The service controller */
- private final ServiceController controller;
-
- /**
- * Create a new ServiceDeployer.
- *
- * @param controller the service controller
- * @throws IllegalArgumentException for a null controller
- */
- public ServiceClassLoaderDeployer(ServiceController controller)
- {
- if (controller == null)
- throw new IllegalArgumentException("Null controller");
- this.controller = controller;
- }
-
- public ClassLoader createTopLevelClassLoader(DeploymentContext context) throws Exception
- {
- MBeanServer server = controller.getMBeanServer();
- DeploymentUnit unit = context.getDeploymentUnit();
-
- // Try to determine a root url
- VirtualFile root = context.getRoot();
- URL url = null;
- try
- {
- if (root != null)
- url = trimJARURL(root.toURL());
- }
- catch (Exception ignored)
- {
- log.debug("Unable to get URL for " + context.getName() + " reason=" + ignored);
- }
-
- // Check the loader repository config
- LoaderRepositoryConfig config = unit.getAttachment(LoaderRepositoryConfig.class);
- if (config == null)
- config = new LoaderRepositoryConfig();
- LoaderRepositoryFactory.createLoaderRepository(server, config);
-
- // Create the classloader
- Object[] args = { url, url, Boolean.TRUE };
- String[] sig = { "java.net.URL", "java.net.URL", "boolean" };
- RepositoryClassLoader ucl = (RepositoryClassLoader) server.invoke(config.repositoryName, "newClassLoader", args, sig);
-
- // Add in the classpath
- try
- {
- ClassPathVisitor visitor = new ClassPathVisitor();
- context.visit(visitor);
- Set<VirtualFile> classpath = visitor.getClassPath();
- for (VirtualFile path : classpath)
- {
- // TODO Weed duplicates from other deployments
- if (path != root)
- ucl.addURL(trimJARURL(path.toURL()));
- }
-
- // Register the classloader with the MBeanServer
- ObjectName uclName = ucl.getObjectName();
- if (server.isRegistered(uclName) == false)
- server.registerMBean(ucl, uclName);
- }
- catch (Throwable t)
- {
- internalRemoveClassLoader(context, ucl);
- throw DeploymentException.rethrowAsDeploymentException("Error creating classloader: " + context.getName(), t);
- }
-
- return ucl;
- }
-
- public void removeTopLevelClassLoader(DeploymentContext context)
- {
- RepositoryClassLoader ucl = (RepositoryClassLoader) context.getClassLoader();
- if (ucl == null)
- return;
- internalRemoveClassLoader(context, ucl);
- }
-
- /**
- * Remove the classloader
- *
- * @param context the deployment context
- * @param ucl the unified classloader
- */
- private void internalRemoveClassLoader(DeploymentContext context, RepositoryClassLoader ucl)
- {
- MBeanServer server = controller.getMBeanServer();
-
- // Remove the classloader from the MBeanServer
- try
- {
- ObjectName uclName = ucl.getObjectName();
- if (server.isRegistered(uclName) == true )
- server.unregisterMBean(uclName);
- }
- catch (Throwable t)
- {
- log.warn("Error unregistering classloader mbean: " + ucl + " for " + context.getName(), t);
- }
-
- // Remove the classloader from the loader repository
- try
- {
- ucl.unregister();
- }
- catch (Throwable t)
- {
- log.warn("Error unregistering ucl: " + ucl + " for " + context.getName(), t);
- }
-
- // Remove the loader repository
- try
- {
-
- DeploymentUnit unit = context.getDeploymentUnit();
- ServiceDeployment deployment = unit.getAttachment(ServiceDeployment.class);
- if (deployment != null)
- {
- LoaderRepositoryConfig config = unit.getAttachment(LoaderRepositoryConfig.class);
- if (config != null)
- LoaderRepositoryFactory.destroyLoaderRepository(server, config.repositoryName);
- }
- }
- catch (Throwable t)
- {
- log.warn("Error removing classloader from repository: " + ucl + " for " + context.getName(), t);
- }
- }
-
- // TODO figure out why this is necessary
- private URL trimJARURL(URL url) throws MalformedURLException
- {
- String temp = url.toString();
- if (temp.startsWith("jar:") && temp.endsWith("!/"))
- {
- temp = temp.substring(4, temp.length()-2);
- return new URL(temp);
- }
- return url;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceClassLoaderDeployer.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,162 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.deployers;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployers.plugins.deployers.helpers.AbstractSimpleRealDeployer;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceController;
-import org.jboss.system.metadata.ServiceDeployment;
-import org.jboss.system.metadata.ServiceMetaData;
-
-/**
- * ServiceDeployer.<p>
- *
- * This deployer is responsible for deploying services of
- * type {@link ServiceDeployment}.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDeployer extends AbstractSimpleRealDeployer<ServiceMetaData>
-{
- /** The service controller */
- private final ServiceController controller;
-
- /**
- * Create a new ServiceDeployer.
- *
- * @param controller the service controller
- * @throws IllegalArgumentException for a null controller
- */
- public ServiceDeployer(ServiceController controller)
- {
- super(ServiceMetaData.class);
- if (controller == null)
- throw new IllegalArgumentException("Null controller");
- this.controller = controller;
- }
-
- public void deploy(DeploymentUnit unit, ServiceMetaData deployment) throws DeploymentException
- {
- ObjectName name = deployment.getObjectName();
- try
- {
- ObjectName loaderName = deployment.getClassLoaderName();
- if (loaderName == null)
- {
- ClassLoader cl = unit.getClassLoader();
- if (cl != null && cl instanceof RepositoryClassLoader)
- loaderName = ((RepositoryClassLoader) cl).getObjectName();
- }
-
- controller.install(deployment, loaderName);
- ServiceContext context = controller.getServiceContext(name);
- if (context == null)
- throw new IllegalStateException("No context for " + name);
- try
- {
- create(context);
- try
- {
- start(context);
- }
- catch (Throwable t)
- {
- destroy(name);
- throw t;
- }
- }
- catch (Throwable t)
- {
- remove(name);
- throw t;
- }
- }
- catch (Throwable t)
- {
- throw DeploymentException.rethrowAsDeploymentException("Error deploying: " + name, t);
- }
- }
-
- public void undeploy(DeploymentUnit unit, ServiceMetaData deployment)
- {
- ObjectName name = deployment.getObjectName();
- ServiceContext context = controller.getServiceContext(name);
- if (context != null)
- {
- stop(name);
- destroy(name);
- remove(name);
- }
- }
-
- protected void create(ServiceContext context) throws Throwable
- {
- controller.create(context.objectName);
- }
-
- protected void start(ServiceContext context) throws Throwable
- {
- controller.start(context.objectName);
- }
-
- protected void stop(ObjectName name)
- {
- try
- {
- controller.stop(name);
- }
- catch (Throwable t)
- {
- log.warn("Error during stop for " + name, t);
- }
- }
-
- protected void destroy(ObjectName name)
- {
- try
- {
- controller.destroy(name);
- }
- catch (Throwable t)
- {
- log.warn("Error during destroy for " + name, t);
- }
- }
-
- protected void remove(ObjectName name)
- {
- try
- {
- controller.remove(name);
- }
- catch (Throwable t)
- {
- log.warn("Error during destroy for " + name, t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceDeployer.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,148 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.deployers;
-
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployers.plugins.deployers.helpers.AbstractComponentDeployer;
-import org.jboss.deployers.plugins.deployers.helpers.SimpleDeploymentVisitor;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.system.metadata.ServiceDeployment;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.w3c.dom.Element;
-
-/**
- * ServiceDeployer.<p>
- *
- * This deployer is responsible for deploying services of
- * type {@link ServiceDeployment}.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDeploymentDeployer extends AbstractComponentDeployer<ServiceDeployment, ServiceMetaData>
-{
- /**
- * Create a new ServiceDeploymentDeployer.
- */
- public ServiceDeploymentDeployer()
- {
- setDeploymentVisitor(new ServiceDeploymentVisitor());
- setComponentVisitor(new ServiceMetaDataVisitor());
- }
-
- protected static void addServiceComponent(DeploymentUnit unit, ServiceMetaData service)
- {
- ObjectName objectName = service.getObjectName();
- String name = objectName.getCanonicalName();
- DeploymentUnit component = unit.addComponent(name);
- component.addAttachment(ServiceMetaData.class.getName(), service);
- }
-
- protected static void removeServiceComponent(DeploymentUnit unit, ServiceMetaData service)
- {
- ObjectName objectName = service.getObjectName();
- String name = objectName.getCanonicalName();
- unit.removeComponent(name);
- }
-
- /**
- * ServiceDeploymentVisitor.
- */
- public class ServiceDeploymentVisitor implements SimpleDeploymentVisitor<ServiceDeployment>
- {
- public Class<ServiceDeployment> getVisitorType()
- {
- return ServiceDeployment.class;
- }
-
- public void deploy(DeploymentUnit unit, ServiceDeployment deployment) throws DeploymentException
- {
- try
- {
- List<ServiceMetaData> services = deployment.getServices();
- if (services == null)
- {
- Element config = deployment.getConfig();
- if (config == null)
- {
- log.debug("Service deployment has no services: " + deployment.getName());
- return;
- }
-
- ServiceMetaDataParser parser = new ServiceMetaDataParser(config);
- services = parser.parse();
- deployment.setServices(services);
- }
-
- if (services == null || services.isEmpty())
- return;
-
- for (ServiceMetaData service : services)
- addServiceComponent(unit, service);
- }
- catch (Throwable t)
- {
- throw DeploymentException.rethrowAsDeploymentException("Error deploying: " + deployment.getName(), t);
- }
- }
-
- public void undeploy(DeploymentUnit unit, ServiceDeployment deployment)
- {
- List<ServiceMetaData> services = deployment.getServices();
- if (services == null)
- return;
-
- for (ServiceMetaData service : services)
- {
- ObjectName objectName = service.getObjectName();
- String name = objectName.getCanonicalName();
- unit.removeComponent(name);
- }
- }
- }
-
- /**
- * ServiceMetaDataVisitor.
- */
- public static class ServiceMetaDataVisitor implements SimpleDeploymentVisitor<ServiceMetaData>
- {
- public Class<ServiceMetaData> getVisitorType()
- {
- return ServiceMetaData.class;
- }
-
- public void deploy(DeploymentUnit unit, ServiceMetaData deployment) throws DeploymentException
- {
- addServiceComponent(unit, deployment);
- }
-
- public void undeploy(DeploymentUnit unit, ServiceMetaData deployment)
- {
- removeServiceComponent(unit, deployment);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceDeploymentDeployer.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,78 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.deployers;
-
-import org.jboss.deployers.plugins.deployers.helpers.XSLDeployer;
-import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.system.metadata.ServiceDeployment;
-import org.jboss.system.metadata.ServiceDeploymentParser;
-import org.jboss.virtual.VirtualFile;
-import org.w3c.dom.Document;
-
-public class ServiceXSLDeployer extends XSLDeployer<ServiceDeployment>
-{
- /** The suffix */
- private String suffix;
-
- /**
- * Create a new ServiceXSLDeployer.
- */
- public ServiceXSLDeployer()
- {
- super(ServiceDeployment.class);
- }
-
- /**
- * Get the suffix.
- *
- * @return the suffix.
- */
- public String getSuffix()
- {
- return suffix;
- }
-
- /**
- * Set the suffix.
- *
- * @param suffix the suffix.
- */
- public void setSuffix(String suffix)
- {
- this.suffix = suffix;
- }
-
- protected ServiceDeployment parse(DeploymentUnit unit, VirtualFile file, Document document) throws Exception
- {
- ServiceDeploymentParser parser = new ServiceDeploymentParser(document);
- ServiceDeployment parsed = parser.parse();
- String name = file.toURI().toString();
- parsed.setName(name);
- return parsed;
- }
-
- public void deploy(DeploymentUnit unit) throws DeploymentException
- {
- createMetaData(unit, null, getSuffix());
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/deployers/ServiceXSLDeployer.java)
Copied: trunk/system-jmx/src/main/org/jboss/system/filterfactory (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory)
Deleted: trunk/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,103 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.filterfactory;
-
-import javax.management.AttributeChangeNotificationFilter;
-import javax.management.NotificationFilter;
-
-import org.jboss.system.NotificationFilterFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Factory for AttributeChangeNotificationFilter filters.
- *
- * The produced filter filters-in AttributeChangeNotifications
- * for zero or more attributes, so you need to explicitly enable
- * the attribute names you are interested in.
- *
- * The passed filterConfig xml element fragment should look like:
- *
- * <filter factory="AttributeChangeNotificationFilterFactory">
- * <enable attribute-name="State"/>
- * ...
- * </filter>
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public class AttributeChangeNotificationFilterFactory
- implements NotificationFilterFactory
-{
- // Constants -----------------------------------------------------
-
- /** the xml element and attribute supported by this factory */
- public static final String ENABLE_ELEMENT = "enable";
- public static final String ENABLE_ATTRNAME_ATTRIBUTE = "attribute-name";
-
- /**
- * Default public CTOR (necessary)
- */
- public AttributeChangeNotificationFilterFactory()
- {
- // empty
- }
-
- /**
- * The actual filter factory implementation
- */
- public NotificationFilter createNotificationFilter(Element filterConfig)
- throws Exception
- {
- // start off with a filter that does not allow any named attribute
- AttributeChangeNotificationFilter filter = new AttributeChangeNotificationFilter();
-
- // filterConfig should point to the <filter factory="..."> element,
- // we are interested in its 'enable' children to configure the filter
- NodeList filterChildren = filterConfig.getChildNodes();
-
- for (int i = 0; i < filterChildren.getLength(); i++)
- {
- Node filterChildNode = filterChildren.item(i);
-
- // check if this is an 'enable' element, ignore everything else
- if (filterChildNode.getNodeName().equals(ENABLE_ELEMENT))
- {
- // look for 'attribute-name' attribute
- if (((Element)filterChildNode).hasAttribute(ENABLE_ATTRNAME_ATTRIBUTE))
- {
- String attributeName = ((Element)filterChildNode).getAttribute(ENABLE_ATTRNAME_ATTRIBUTE);
- // enable this type in the filter
- filter.enableAttribute(attributeName);
- }
- else
- {
- throw new Exception("'" + ENABLE_ELEMENT + "' element must have a '"
- + ENABLE_ATTRNAME_ATTRIBUTE + "' attribute");
- }
- }
- }
- // we are done
- return filter;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/filterfactory/AttributeChangeNotificationFilterFactory.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,256 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.filterfactory;
-
-import java.util.Set;
-import java.util.Vector;
-
-import javax.management.Notification;
-import javax.management.NotificationFilter;
-
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.mx.util.JBossNotificationFilterSupport;
-import org.jboss.system.NotificationFilterFactory;
-import org.jboss.util.collection.CollectionsFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Factory for {@link DeploymentInfoNotificationFilter} filters.
- * (check the inner class).
- *
- * The produced filter is really meant for Notifications
- * emitted by SubDeployers. The types of interest are:
- *
- * org.jboss.deployment.SubDeployer.init
- * org.jboss.deployment.SubDeployer.create
- * org.jboss.deployment.SubDeployer.start
- * org.jboss.deployment.SubDeployer.stop
- * org.jboss.deployment.SubDeployer.destroy
- *
- * The above subdeployer notifications carry a DeploymentInfo
- * instance in their UserData. We can further filter based on
- * DeploymentInfo.shortName, but is important to explicitly
- * enable both the notification types and the desired shortNames.
- *
- * In practice, you'll be able to receive notifications when a
- * particular deployment unit (e.g. my-app.ear) gets processed
- * (e.g. started, stopped, etc.) by a subdeployer.
- *
- * The passed filterConfig xml element fragment should look like:
- *
- * <filter factory="DeploymentInfoNotificationFilterFactory">
- * <enable type="org.jboss.deployment.SubDeployer.start"/>
- * <enable type="org.jboss.deployment.SubDeployer.stop"/>
- * ...
- * <enable short-name="my-app.ear"/>
- * <enable short-name="my-service.xml"/>
- * ...
- * </filter>
- *
- * Note: org.jboss.deployment.SubDeployer yields all five
- * SubDeployer notifications.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- * @since 4.0.3
-**/
-public class DeploymentInfoNotificationFilterFactory
- implements NotificationFilterFactory
-{
- // Constants -----------------------------------------------------
-
- /** the xml element and attribute supported by this factory */
- public static final String ENABLE_ELEMENT = "enable";
- public static final String ENABLE_TYPE_ATTRIBUTE = "type";
- public static final String ENABLE_SHORTNAME_ATTRIBUTE = "short-name";
-
- /**
- * Default public CTOR (necessary)
- */
- public DeploymentInfoNotificationFilterFactory()
- {
- // empty
- }
-
- /**
- * The actual filter factory implementation
- */
- public NotificationFilter createNotificationFilter(Element filterConfig)
- throws Exception
- {
- // start off with a filter that does not allow any type
- DeploymentInfoNotificationFilter filter = new DeploymentInfoNotificationFilter();
-
- // filterConfig should point to the <filter factory="..."> element,
- // we are interested in its 'enable' children to configure the filter
- NodeList filterChildren = filterConfig.getChildNodes();
-
- for (int i = 0; i < filterChildren.getLength(); i++)
- {
- Node filterChildNode = filterChildren.item(i);
-
- // check if this is an 'enable' element, ignore everything else
- if (filterChildNode.getNodeName().equals(ENABLE_ELEMENT))
- {
- // look for 'type' attribute
- if (((Element)filterChildNode).hasAttribute(ENABLE_TYPE_ATTRIBUTE))
- {
- String type = ((Element)filterChildNode).getAttribute(ENABLE_TYPE_ATTRIBUTE);
- // enable this type in the filter
- filter.enableType(type);
- }
- else if (((Element)filterChildNode).hasAttribute(ENABLE_SHORTNAME_ATTRIBUTE))
- {
- String shortName = ((Element)filterChildNode).getAttribute(ENABLE_SHORTNAME_ATTRIBUTE);
- // enable this shortName in the filter
- filter.enableShortName(shortName);
- }
- else
- {
- throw new Exception("'" + ENABLE_ELEMENT + "' element must have a '"
- + ENABLE_TYPE_ATTRIBUTE + "' or a '" + ENABLE_SHORTNAME_ATTRIBUTE + "' attribute");
- }
- }
- }
- // we are done
- return filter;
- }
-
- /**
- * A NotificationFilter that can filter Notifications that
- * carry a DeploymentInfo payload in the UserData field.
- *
- * The Notification is filtered first on its type,
- * then on its DeploymentInfo.shortName.
- *
- * Uses copy-on-write semantics for fast unsynchronized access.
- */
- public static class DeploymentInfoNotificationFilter extends JBossNotificationFilterSupport
- {
- private static final long serialVersionUID = -5067618040005609685L;
-
- /** The short names that will pass the filter */
- private Set enabledShortNames;
-
- // Constructors -----------------------------------------------
-
- /**
- * Default CTOR.
- *
- * Create a filter that filters out all notification types/sortnames.
- */
- public DeploymentInfoNotificationFilter()
- {
- super();
- enabledShortNames = CollectionsFactory.createCopyOnWriteSet();
- }
-
- /**
- * Disable all shortNames. Rejects all notifications.
- */
- public void disableAllShortNames()
- {
- enabledShortNames.clear();
- }
-
- /**
- * Disable a shortName.
- *
- * @param name the shortName to disable.
- */
- public void disableShortName(String name)
- {
- enabledShortNames.remove(name);
- }
-
- /**
- * Enable a shortName.
- *
- * @param name the shortName to enable.
- * @exception IllegalArgumentException for a null name.
- */
- public void enableShortName(String name) throws IllegalArgumentException
- {
- if (name == null)
- {
- throw new IllegalArgumentException("null shortName");
- }
- enabledShortNames.add(name);
- }
-
- /**
- * Get all the enabled short names.<p>
- *
- * Returns a vector of enabled short names.<br>
- * An empty vector means all short names disabled.
- *
- * @return the vector of enabled short names.
- */
- public Vector getEnabledShortNames()
- {
- return new Vector(enabledShortNames);
- }
-
- /**
- * @return human readable string.
- */
- public String toString()
- {
- StringBuffer sb = new StringBuffer(100);
-
- sb.append(getClass().getName()).append(':');
- sb.append(" enabledTypes=").append(getEnabledTypes());
- sb.append(" enabledShortNames=").append(getEnabledShortNames());
-
- return sb.toString();
- }
-
- // NotificationFilter implementation ---------------------------
-
- /**
- * Test to see whether this notification is enabled
- *
- * @param notification the notification to filter
- * @return true when the notification should be sent, false otherwise
- * @exception IllegalArgumentException for null notification.
- */
- public boolean isNotificationEnabled(Notification notification)
- {
- // check if the notification type is not enabled in the super class
- if (super.isNotificationEnabled(notification) == false)
- {
- return false;
- }
-
- // Check the shortName in the payload. We assume that proper
- // filtering on notification type, ensures that the
- // notification actually carries a DeploymentInfo.
- DeploymentInfo di = (DeploymentInfo)notification.getUserData();
- String shortName = di.shortName;
-
- // Return true if the shortName is enabled, false otherwise
- return enabledShortNames.contains(shortName);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/filterfactory/DeploymentInfoNotificationFilterFactory.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,125 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.filterfactory;
-
-import javax.management.NotificationFilter;
-import javax.management.ObjectName;
-import javax.management.relation.MBeanServerNotificationFilter;
-
-import org.jboss.system.NotificationFilterFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Factory for MBeanServerNotificationFilter filters.
- *
- * The produced filter is really meant for MBeanServerNotifications
- * emitted by the "JMImplementation:type=MBeanServerDelegate" MBean.
- *
- * filters-in zero or more Notification types, and zero or more
- * ObjectNames (contained in the MBeanServerNotification), so
- * you need to explicitly enable both the types and the ObjectNames.
- *
- * In a nutshell, you'll be able to receive registration and/or unregistration
- * notifications for selected ObjectNames (i.e. MBean instances)!
- *
- * The passed filterConfig xml element fragment should look like:
- *
- * <filter factory="MBeanServerNotificationFilterFactory">
- * <enable type="JMX.mbean"/>
- * ...
- * <enable object-name="mydomain:type=mymbean"/>
- * <enable object-name="mydomain:type=myothermbean"/>
- * ...
- * </filter>
- *
- * Note: JMX.mbean yields both notifications:
- * JMX.mbean.registered
- * JMX.mbean.unregistered
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public class MBeanServerNotificationFilterFactory
- implements NotificationFilterFactory
-{
- // Constants -----------------------------------------------------
-
- /** the xml element and attribute supported by this factory */
- public static final String ENABLE_ELEMENT = "enable";
- public static final String ENABLE_TYPE_ATTRIBUTE = "type";
- public static final String ENABLE_OBJECTNAME_ATTRIBUTE = "object-name";
-
- /**
- * Default public CTOR (necessary)
- */
- public MBeanServerNotificationFilterFactory()
- {
- // empty
- }
-
- /**
- * The actual filter factory implementation
- */
- public NotificationFilter createNotificationFilter(Element filterConfig)
- throws Exception
- {
- // start off with a filter that does not allow any type/objectname
- MBeanServerNotificationFilter filter = new MBeanServerNotificationFilter();
-
- // filterConfig should point to the <filter factory="..."> element,
- // we are interested in its 'enable' children to configure the filter
- NodeList filterChildren = filterConfig.getChildNodes();
-
- for (int i = 0; i < filterChildren.getLength(); i++)
- {
- Node filterChildNode = filterChildren.item(i);
-
- // check if this is an 'enable' element, ignore everything else
- if (filterChildNode.getNodeName().equals(ENABLE_ELEMENT))
- {
- // look for 'type' attribute
- if (((Element)filterChildNode).hasAttribute(ENABLE_TYPE_ATTRIBUTE))
- {
- String type = ((Element)filterChildNode).getAttribute(ENABLE_TYPE_ATTRIBUTE);
- // enable this type in the filter
- filter.enableType(type);
- }
- else if (((Element)filterChildNode).hasAttribute(ENABLE_OBJECTNAME_ATTRIBUTE))
- {
- String objectName = ((Element)filterChildNode).getAttribute(ENABLE_OBJECTNAME_ATTRIBUTE);
- // enable this objectName in the filter
- // may throw MalformedObjectNameException
- filter.enableObjectName(new ObjectName(objectName));
- }
- else
- {
- throw new Exception("'" + ENABLE_ELEMENT + "' element must have a '"
- + ENABLE_TYPE_ATTRIBUTE + "' or a '" + ENABLE_OBJECTNAME_ATTRIBUTE + "' attribute");
- }
- }
- }
- // we are done
- return filter;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/filterfactory/MBeanServerNotificationFilterFactory.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,103 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.filterfactory;
-
-import javax.management.NotificationFilter;
-import javax.management.NotificationFilterSupport;
-
-import org.jboss.system.NotificationFilterFactory;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * Factory for NotificationFilterSupport filters.
- *
- * The produced filter filters-in zero or more Notification types,
- * so you need to explicitly enable the types you want.
- *
- * The passed filterConfig xml element fragment should look like:
- *
- * <filter factory="NotificationFilterSupportFactory">
- * <enable type="some.notification.type"/>
- * <enable type="another.notification.type"/>
- * ...
- * </filter>
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public class NotificationFilterSupportFactory
- implements NotificationFilterFactory
-{
- // Constants -----------------------------------------------------
-
- /** the xml element and attribute supported by this factory */
- public static final String ENABLE_ELEMENT = "enable";
- public static final String ENABLE_TYPE_ATTRIBUTE = "type";
-
- /**
- * Default public CTOR (necessary)
- */
- public NotificationFilterSupportFactory()
- {
- // empty
- }
-
- /**
- * The actual filter factory implementation
- */
- public NotificationFilter createNotificationFilter(Element filterConfig)
- throws Exception
- {
- // start off with a filter that does not allow any type
- NotificationFilterSupport filter = new NotificationFilterSupport();
-
- // filterConfig should point to the <filter factory="..."> element,
- // we are interested in its 'enable' children to configure the filter
- NodeList filterChildren = filterConfig.getChildNodes();
-
- for (int i = 0; i < filterChildren.getLength(); i++)
- {
- Node filterChildNode = filterChildren.item(i);
-
- // check if this is an 'enable' element, ignore everything else
- if (filterChildNode.getNodeName().equals(ENABLE_ELEMENT))
- {
- // look for 'type' attribute
- if (((Element)filterChildNode).hasAttribute(ENABLE_TYPE_ATTRIBUTE))
- {
- String type = ((Element)filterChildNode).getAttribute(ENABLE_TYPE_ATTRIBUTE);
- // enable this type in the filter
- filter.enableType(type);
- }
- else
- {
- throw new Exception("'" + ENABLE_ELEMENT + "' element must have a '"
- + ENABLE_TYPE_ATTRIBUTE + "' attribute");
- }
- }
- }
- // we are done
- return filter;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/filterfactory/NotificationFilterSupportFactory.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.Iterator;
-import java.util.Set;
-
-import org.jboss.util.collection.CollectionsFactory;
-
-/**
- * AbstractMetaDataVisitorNode.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class AbstractMetaDataVisitorNode implements ServiceMetaDataVisitorNode
-{
- public Iterator<? extends ServiceMetaDataVisitorNode> getChildren()
- {
- Set<ServiceMetaDataVisitorNode> children = CollectionsFactory.createLazySet();
- addChildren(children);
- if (children.size() == 0)
- return null;
- else
- return children.iterator();
- }
-
- public void visit(ServiceMetaDataVisitor visitor)
- {
- visitor.visit(this);
- }
-
- /**
- * Add to the children
- *
- * @param children the children
- */
- protected void addChildren(Set<ServiceMetaDataVisitorNode> children)
- {
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/AbstractMetaDataVisitorNode.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,166 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.Set;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.util.UnreachableStatementException;
-
-/**
- * ServiceAttributeMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceAttributeMetaData extends AbstractMetaDataVisitorNode
-{
- /** The attribute name */
- private String name;
-
- /** Whether to trim the value */
- private boolean trim;
-
- /** Whether to do property replacement */
- private boolean replace;
-
- /** The value */
- private ServiceValueMetaData value;
-
- /**
- * Get the name.
- *
- * @return the name.
- */
- public String getName()
- {
- return name;
- }
-
- /**
- * Set the name.
- *
- * @param name the name.
- */
- public void setName(String name)
- {
- if (name == null)
- throw new IllegalArgumentException("Null name");
- this.name = name;
- }
-
- /**
- * Get the replace.
- *
- * @return the replace.
- */
- public boolean isReplace()
- {
- return replace;
- }
-
- /**
- * Set the replace.
- *
- * @param replace the replace.
- */
- public void setReplace(boolean replace)
- {
- this.replace = replace;
- }
-
- /**
- * Get the trim.
- *
- * @return the trim.
- */
- public boolean isTrim()
- {
- return trim;
- }
-
- /**
- * Set the trim.
- *
- * @param trim the trim.
- */
- public void setTrim(boolean trim)
- {
- this.trim = trim;
- }
-
- /**
- * Get the value.
- *
- * @return the value.
- */
- public ServiceValueMetaData getValue()
- {
- return value;
- }
-
- /**
- * Set the value.
- *
- * @param value the value.
- */
- public void setValue(ServiceValueMetaData value)
- {
- if (value == null)
- throw new IllegalArgumentException("Null value");
- this.value = value;
- }
-
- /**
- * Get the value
- *
- * @param valueContext the value context
- * @return the value
- * @throws Exception for any error
- */
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- valueContext.setTrim(isTrim());
- valueContext.setReplace(isReplace());
- try
- {
- return value.getValue(valueContext);
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Error configuring attribute " + name, t);
- throw new UnreachableStatementException();
- }
- }
-
- public void visit(ServiceMetaDataVisitor visitor)
- {
- visitor.setContextState(ControllerState.CONFIGURED);
- visitor.visit(this);
- }
-
- protected void addChildren(Set<ServiceMetaDataVisitorNode> children)
- {
- children.add(value);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceAttributeMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,182 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.beans.PropertyEditor;
-import java.beans.PropertyEditorManager;
-import java.lang.reflect.Constructor;
-
-import org.jboss.system.ConfigurationException;
-import org.jboss.util.Classes;
-import org.jboss.util.StringPropertyReplacer;
-
-/**
- * ServiceConstructorMetaData.
- *
- * This class is based on the old ConstructorInfo from ServiceCreator
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceConstructorMetaData
-{
- /** An empty parameters */
- public static final Object[] EMPTY_PARAMETERS = {};
-
- /** An empty parameters list. */
- public static final String[] EMPTY_PARAMS = {};
-
- /** An signature list. */
- public static final String[] EMPTY_SIGNATURE = {};
-
- /** The constructor signature. */
- private String[] signature = EMPTY_SIGNATURE;
-
- /** The constructor parameters. */
- private String[] params = EMPTY_PARAMS;
-
- /** The real parameters */
- private Object[] parameters;
-
- /**
- * Get the params.
- *
- * @return the params.
- */
- public String[] getParams()
- {
- return params;
- }
-
- /**
- * Set the params.
- *
- * @param params the params.
- */
- public void setParams(String[] params)
- {
- if (params == null)
- throw new IllegalArgumentException("Null params");
- this.params = params;
- }
-
- /**
- * Get the signature.
- *
- * @return the signature.
- * @throws ConfigurationException if there is a problem with the signature
- */
- public String[] getSignature() throws ConfigurationException
- {
- for (String string : signature)
- {
- if (string == null || string.trim().length() == 0)
- throw new ConfigurationException("Missing or empty 'type' attribute in constructor arg");
- }
- return signature;
- }
-
- /**
- * Set the signature.
- *
- * @param signature the signature.
- */
- public void setSignature(String[] signature)
- {
- if (signature == null)
- throw new IllegalArgumentException("Null signature");
- this.signature = signature;
- }
-
- /**
- * Get the parameters
- *
- * @param cl the class loader
- * @return the parameters
- * @throws Exception for any error
- */
- public Object[] getParameters(ClassLoader cl) throws Exception
- {
- if (parameters != null)
- return parameters;
-
- if (params.length == 0)
- return EMPTY_PARAMETERS;
-
- String[] signature = getSignature();
-
- Object[] result = new Object[params.length];
- for (int i = 0; i < result.length; ++i)
- {
- if (params[i] == null)
- throw new ConfigurationException("Missing 'value' attribute in constructor arg");
-
- String value = StringPropertyReplacer.replaceProperties(params[i]);
- Object realValue = value;
-
- if (signature[i] != null)
- {
- // See if it is a primitive type first
- Class typeClass = Classes.getPrimitiveTypeForName(signature[i]);
- if (typeClass == null)
- typeClass = cl.loadClass(signature[i]);
-
- // Convert the string to the real value
- PropertyEditor editor = PropertyEditorManager.findEditor(typeClass);
- if (editor == null)
- {
- try
- {
- // See if there is a ctor(String) for the type
- Class[] sig = {String.class};
- Constructor ctor = typeClass.getConstructor(sig);
- Object[] args = {value};
- realValue = ctor.newInstance(args);
- }
- catch (Exception e)
- {
- throw new ConfigurationException("No property editor for type: " + typeClass);
- }
- }
- else
- {
- editor.setAsText(value);
- realValue = editor.getValue();
- }
- }
- result[i] = realValue;
- }
- return result;
- }
-
- /**
- * Set the parameters.
- *
- * @param parameters the parameters.
- */
- public void setParameters(Object[] parameters)
- {
- this.parameters = parameters;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceConstructorMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,173 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.system.microcontainer.LifecycleDependencyItem;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-
-/**
- * ServiceDependencyListValueMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDependencyListValueMetaData extends AbstractMetaDataVisitorNode implements ServiceValueMetaData
-{
- /** The dependencies */
- private List<String> dependencies;
-
- /** The object names */
- private List<ObjectName> objectNames;
-
- /**
- * Create a new ServiceDependencyListValueMetaData.
- */
- public ServiceDependencyListValueMetaData()
- {
- }
-
- /**
- * Create a new ServiceDependencyListValueMetaData.
- *
- * @param dependencies the dependencies
- */
- public ServiceDependencyListValueMetaData(List<String> dependencies)
- {
- setDependencies(dependencies);
- }
-
- /**
- * Get the dependencies.
- *
- * @return the dependencies.
- */
- public List<String> getDependencies()
- {
- if (dependencies == null)
- {
- List<String> result = new ArrayList<String>(objectNames.size());
- for (ObjectName objectName : objectNames)
- result.add(objectName.getCanonicalName());
- return result;
- }
- return dependencies;
- }
-
- /**
- * Set the dependencies.
- *
- * @param dependencies the dependencies.
- */
- public void setDependencies(List<String> dependencies)
- {
- if (dependencies == null)
- throw new IllegalArgumentException("Null dependencies");
- for (String dependency: dependencies)
- {
- if (dependency == null)
- throw new IllegalArgumentException("Null dependency in dependencies");
- }
-
- this.dependencies = dependencies;
- this.objectNames = null;
- }
-
- /**
- * Get the objectNames.
- *
- * @return the objectNames.
- * @throws MalformedObjectNameException if the list of string was set with an invalid object name
- */
- public List<ObjectName> getObjectNames() throws MalformedObjectNameException
- {
- if (objectNames == null)
- {
- List<ObjectName> names = new ArrayList<ObjectName>(dependencies.size());
- for (String dependency : dependencies)
- {
- if (dependency.trim().length() == 0)
- throw new MalformedObjectNameException("Missing object name in depends-list");
- ObjectName objectName = new ObjectName(dependency);
- if (objectName.isPattern())
- throw new MalformedObjectNameException("ObjectName patterns are not allowed in depends-list: " + dependency);
- names.add(objectName);
- }
- objectNames = names;
- dependencies = null;
- }
- return objectNames;
- }
-
- /**
- * Set the objectNames.
- *
- * @param objectNames the objectNames.
- */
- public void setObjectNames(List<ObjectName> objectNames)
- {
- if (objectNames == null)
- throw new IllegalArgumentException("Null objectNames");
- for (ObjectName objectName: objectNames)
- {
- if (objectName == null)
- throw new IllegalArgumentException("Null object name in objectNames");
- }
-
- this.objectNames = objectNames;
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- return getObjectNames();
- }
-
- public void visit(ServiceMetaDataVisitor visitor)
- {
- ServiceControllerContext context = visitor.getControllerContext();
- Object name = context.getName();
- List<String> list = dependencies;
- try
- {
- List<ObjectName> names = getObjectNames();
- list = new ArrayList<String>(names.size());
- for (ObjectName objectName : names)
- list.add(objectName.getCanonicalName());
- }
- catch (MalformedObjectNameException ignored)
- {
- }
- for (String other : list)
- {
- // TODO visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.CONFIGURED));
- visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.CREATE));
- visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.START));
- }
- visitor.visit(this);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyListValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,119 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.system.microcontainer.LifecycleDependencyItem;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-
-/**
- * ServiceDependencyMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDependencyMetaData extends AbstractMetaDataVisitorNode
-{
- /** The dependency */
- private String iDependOn;
-
- /** The dependency */
- private ObjectName iDependOnObjectName;
-
- /**
- * Get the iDependOn.
- *
- * @return the iDependOn.
- */
- public String getIDependOn()
- {
- if (iDependOn == null)
- return iDependOnObjectName.getCanonicalName();
- return iDependOn;
- }
-
- /**
- * Set the iDependOn.
- *
- * @param iDependOn the iDependOn.
- */
- public void setIDependOn(String iDependOn)
- {
- if (iDependOn == null)
- throw new IllegalArgumentException("Null iDependOn");
- this.iDependOn = iDependOn;
- this.iDependOnObjectName = null;
- }
-
- /**
- * Get the iDependOn.
- *
- * @return the iDependOn.
- * @throws MalformedObjectNameException if the string was set with an invalid object name
- */
- public ObjectName getIDependOnObjectName() throws MalformedObjectNameException
- {
- if (iDependOnObjectName == null)
- {
- if (iDependOn.trim().length() == 0)
- throw new MalformedObjectNameException("Missing object name in depends");
- ObjectName objectName = new ObjectName(iDependOn);
- if (objectName.isPattern())
- throw new MalformedObjectNameException("ObjectName patterns are not allowed in depends: " + iDependOn);
- iDependOnObjectName = objectName;
- iDependOn = null;
- }
- return iDependOnObjectName;
- }
-
- /**
- * Set the iDependOn.
- *
- * @param iDependOn the iDependOn.
- */
- public void setIDependOnObjectName(ObjectName iDependOn)
- {
- if (iDependOn == null)
- throw new IllegalArgumentException("Null iDependOn");
- this.iDependOnObjectName = iDependOn;
- }
-
- public void visit(ServiceMetaDataVisitor visitor)
- {
- ServiceControllerContext context = visitor.getControllerContext();
- Object name = context.getName();
- Object other = iDependOn;
- try
- {
- other = getIDependOnObjectName().getCanonicalName();
- }
- catch (MalformedObjectNameException ignored)
- {
- }
- visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.CREATE));
- visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.START));
- visitor.visit(this);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,207 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanServer;
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.system.microcontainer.LifecycleDependencyItem;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-
-/**
- * ServiceDependencyValueMetaData.
- *
- * This class is based on the old ServiceConfigurator
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDependencyValueMetaData extends AbstractMetaDataVisitorNode implements ServiceValueMetaData
-{
- /** The dependency */
- private String dependency;
-
- /** The dependency */
- private ObjectName objectName;
-
- /** The proxy type */
- private String proxyType;
-
- /**
- * Create a new ServiceDependencyValueMetaData.
- */
- public ServiceDependencyValueMetaData()
- {
- }
-
- /**
- * Create a new ServiceDependencyValueMetaData.
- *
- * @param dependency the dependents object name
- */
- public ServiceDependencyValueMetaData(String dependency)
- {
- setDependency(dependency);
- }
-
- /**
- * Create a new ServiceDependencyValueMetaData.
- *
- * @param dependency the dependents object name
- * @param proxyType the proxy type
- */
- public ServiceDependencyValueMetaData(String dependency, String proxyType)
- {
- setDependency(dependency);
- setProxyType(proxyType);
- }
-
- /**
- * Get the dependency.
- *
- * @return the dependency.
- */
- public String getDependency()
- {
- if (dependency == null)
- return objectName.getCanonicalName();
- return dependency;
- }
-
- /**
- * Set the dependency.
- *
- * @param dependency the dependency.
- */
- public void setDependency(String dependency)
- {
- if (dependency == null)
- throw new IllegalArgumentException("Null dependency");
- this.dependency = dependency;
- this.objectName = null;
- }
-
- /**
- * Get the object name.
- *
- * @return the object name.
- * @throws MalformedObjectNameException if the string was set with an invalid object name
- */
- public ObjectName getObjectName() throws MalformedObjectNameException
- {
- if (objectName == null)
- {
- if (dependency.trim().length() == 0)
- throw new MalformedObjectNameException("Missing object name in depends");
- ObjectName name = new ObjectName(dependency);
- if (name.isPattern())
- throw new MalformedObjectNameException("ObjectName patterns are not allowed in depends: " + objectName);
- objectName = new ObjectName(dependency);
- dependency = null;
- }
- return objectName;
- }
-
- /**
- * Set the object name
- *
- * @param objectName the object name
- */
- public void setObjectName(ObjectName objectName)
- {
- if (objectName == null)
- throw new IllegalArgumentException("Null objectName");
- this.objectName = objectName;
- }
-
- /**
- * Get the proxyType.
- *
- * @return the proxyType.
- */
- public String getProxyType()
- {
- return proxyType;
- }
-
- /**
- * Set the proxyType.
- *
- * @param proxyType the proxyType.
- */
- public void setProxyType(String proxyType)
- {
- this.proxyType = proxyType;
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- MBeanAttributeInfo attributeInfo = valueContext.getAttributeInfo();
- ClassLoader cl = valueContext.getClassloader();
- MBeanServer server = valueContext.getServer();
-
- ObjectName objectName = getObjectName();
-
- if (proxyType != null)
- {
- if (proxyType.equals("attribute"))
- {
- proxyType = attributeInfo.getType();
- if (proxyType == null)
- throw new DeploymentException("AttributeInfo for " + attributeInfo.getName() + " has no type");
- }
-
- Class proxyClass = cl.loadClass(proxyType);
- return MBeanProxyExt.create(proxyClass, objectName, server, true);
- }
-
- return objectName;
- }
-
- public void visit(ServiceMetaDataVisitor visitor)
- {
- ServiceControllerContext context = visitor.getControllerContext();
- Object name = context.getName();
- Object other = dependency;
- try
- {
- other = getObjectName().getCanonicalName();
- }
- catch (MalformedObjectNameException ignored)
- {
- }
- // TODO visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.CONFIGURED));
- visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.CREATE));
- visitor.addDependency(new LifecycleDependencyItem(name, other, ControllerState.START));
- visitor.visit(this);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,151 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.List;
-
-import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
-import org.w3c.dom.Element;
-
-/**
- * ServiceDeployment.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDeployment
-{
- /** The deployment name */
- private String name;
-
- /** The services */
- private List<ServiceMetaData> services;
-
- /** The config */
- private Element config;
-
- /** The loader repository config */
- private LoaderRepositoryConfig loaderRepositoryConfig;
-
- /** The classpaths */
- private List<ServiceDeploymentClassPath> classPaths;
-
- /**
- * Get the name.
- *
- * @return the name.
- */
- public String getName()
- {
- return name;
- }
-
- /**
- * Set the name.
- *
- * @param name the name.
- */
- public void setName(String name)
- {
- this.name = name;
- }
-
- /**
- * Get the services.
- *
- * @return the services.
- */
- public List<ServiceMetaData> getServices()
- {
- return services;
- }
-
- /**
- * Set the services.
- *
- * @param services the services.
- */
- public void setServices(List<ServiceMetaData> services)
- {
- this.services = services;
- }
-
- /**
- * Get the config.
- *
- * @return the config.
- */
- public Element getConfig()
- {
- return config;
- }
-
- /**
- * Set the config.
- *
- * @param config the config.
- */
- public void setConfig(Element config)
- {
- this.config = config;
- }
-
- /**
- * Get the loaderRepositoryConfig.
- *
- * @return the loaderRepositoryConfig.
- */
- public LoaderRepositoryConfig getLoaderRepositoryConfig()
- {
- return loaderRepositoryConfig;
- }
-
- /**
- * Set the loaderRepositoryConfig.
- *
- * @param loaderRepositoryConfig the loaderRepositoryConfig.
- */
- public void setLoaderRepositoryConfig(LoaderRepositoryConfig loaderRepositoryConfig)
- {
- this.loaderRepositoryConfig = loaderRepositoryConfig;
- }
-
- /**
- * Get the classPaths.
- *
- * @return the classPaths.
- */
- public List<ServiceDeploymentClassPath> getClassPaths()
- {
- return classPaths;
- }
-
- /**
- * Set the classPaths.
- *
- * @param classPaths the classPaths.
- */
- public void setClassPaths(List<ServiceDeploymentClassPath> classPaths)
- {
- this.classPaths = classPaths;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDeployment.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,95 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-/**
- * ServiceDeploymentClassPath.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDeploymentClassPath
-{
- /** The code base */
- private String codeBase;
-
- /** The archives */
- private String archives;
-
- /**
- * Create a new ServiceDeploymentClassPath.
- *
- * @param codeBase the code base
- * @param archives the archives
- * @throws IllegalArgumentException for a null codebase
- */
- public ServiceDeploymentClassPath(String codeBase, String archives)
- {
- if (codeBase == null)
- throw new IllegalArgumentException("Null codebase");
- this.codeBase = codeBase;
- this.archives = archives;
- }
-
- /**
- * Get the archives.
- *
- * @return the archives.
- */
- public String getArchives()
- {
- return archives;
- }
-
- /**
- * Set the archives.
- *
- * @param archives the archives.
- */
- public void setArchives(String archives)
- {
- this.archives = archives;
- }
-
- /**
- * Get the codeBase.
- *
- * @return the codeBase.
- */
- public String getCodeBase()
- {
- return codeBase;
- }
-
- /**
- * Set the codeBase.
- *
- * @param codeBase the codeBase.
- * @throws IllegalArgumentException for a null codebase
- */
- public void setCodeBase(String codeBase)
- {
- if (codeBase == null)
- throw new IllegalArgumentException("Null codebase");
- this.codeBase = codeBase;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentClassPath.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,156 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.loading.LoaderRepositoryFactory;
-import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
-import org.jboss.util.StringPropertyReplacer;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * ServiceDeploymentParser
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceDeploymentParser
-{
- /** The log */
- private static final Logger log = Logger.getLogger(ServiceDeploymentParser.class);
-
- /** The document */
- private Document document;
-
- /**
- * Create a new service deployment parser
- *
- * @param document the xml config
- */
- public ServiceDeploymentParser(Document document)
- {
- if (document == null)
- throw new IllegalArgumentException("Null document");
-
- this.document = document;
- }
-
- /**
- * Parse the xml
- *
- * @return the service deployment
- * @throws DeploymentException for any error
- */
- public ServiceDeployment parse() throws DeploymentException
- {
- ServiceDeployment parsed = new ServiceDeployment();
-
- List<ServiceDeploymentClassPath> classPaths = parseXMLClasspath(document);
- parsed.setClassPaths(classPaths);
-
- LoaderRepositoryConfig repository = parseLoaderRepositoryConfig(document);
- if (repository != null)
- parsed.setLoaderRepositoryConfig(repository);
-
- // We can't parse the services yet, because it requires the classloader
- parsed.setConfig(document.getDocumentElement());
- return parsed;
- }
-
- /**
- * Parse the xml classpath
- *
- * @param document the document
- * @return the list of classpaths
- * @throws DeploymentException for any error
- */
- private List<ServiceDeploymentClassPath> parseXMLClasspath(Document document) throws DeploymentException
- {
- ArrayList<ServiceDeploymentClassPath> classPaths = null;
-
- NodeList children = document.getDocumentElement().getChildNodes();
- for (int i = 0; i < children.getLength(); ++i)
- {
- if (children.item(i).getNodeType() == Node.ELEMENT_NODE)
- {
- Element classpathElement = (Element)children.item(i);
- if (classpathElement.getTagName().equals("classpath"))
- {
- log.debug("Found classpath element: " + classpathElement);
- if (classpathElement.hasAttribute("codebase") == false)
- throw new DeploymentException("Invalid classpath element missing codebase: " + classpathElement);
-
- String codebase = classpathElement.getAttribute("codebase").trim();
- codebase = StringPropertyReplacer.replaceProperties(codebase);
-
- String archives = null;
- if (classpathElement.hasAttribute("archives"))
- {
- archives = classpathElement.getAttribute("archives").trim();
- archives = StringPropertyReplacer.replaceProperties(archives);
- if ("".equals(archives))
- archives = null;
- }
-
- if (classPaths == null)
- classPaths = new ArrayList<ServiceDeploymentClassPath>();
-
- ServiceDeploymentClassPath classPath = new ServiceDeploymentClassPath(codebase, archives);
- classPaths.add(classPath);
- }
- }
- }
- return classPaths;
- }
-
- /**
- * Parse the loader repository config
- *
- * @param document the document
- * @return the config
- * @throws DeploymentException for any error
- */
- private LoaderRepositoryConfig parseLoaderRepositoryConfig(Document document) throws DeploymentException
- {
- // Check for a custom loader-repository for scoping
- NodeList loaders = document.getElementsByTagName("loader-repository");
- if( loaders.getLength() > 0 )
- {
- Element loader = (Element) loaders.item(0);
- try
- {
- return LoaderRepositoryFactory.parseRepositoryConfig(loader);
- }
- catch (Exception e)
- {
- throw DeploymentException.rethrowAsDeploymentException("Unable to parse loader repository config", e);
- }
- }
- return null;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceDeploymentParser.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,111 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.beans.PropertyEditor;
-import java.beans.PropertyEditorManager;
-
-import org.jboss.logging.Logger;
-import org.jboss.util.StringPropertyReplacer;
-import org.w3c.dom.Element;
-
-/**
- * ServiceElementValueMetaData.
- *
- * This class is based on the old ServiceConfigurator
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceElementValueMetaData extends AbstractMetaDataVisitorNode implements ServiceValueMetaData
-{
- /** The log */
- private static final Logger log = Logger.getLogger(ServiceElementValueMetaData.class);
-
- /** The element */
- private Element element;
-
- /**
- * Create a new ServiceElementValueMetaData.
- */
- public ServiceElementValueMetaData()
- {
- }
-
- /**
- * Create a new ServiceElementValueMetaData.
- *
- * @param element the element
- */
- public ServiceElementValueMetaData(Element element)
- {
- setElement(element);
- }
-
- /**
- * Get the element.
- *
- * @return the element.
- */
- public Element getElement()
- {
- return element;
- }
-
- /**
- * Set the element.
- *
- * @param element the element.
- */
- public void setElement(Element element)
- {
- if (element == null)
- throw new IllegalArgumentException("Null element");
- this.element = element;
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- // Replace any ${x} references in the element text
- if (valueContext.isReplace())
- {
- PropertyEditor editor = PropertyEditorManager.findEditor(Element.class);
- if (editor == null)
- log.warn("Cannot perform property replace on Element");
- else
- {
- editor.setValue(element);
- String text = editor.getAsText();
- text = StringPropertyReplacer.replaceProperties(text);
- editor.setAsText(text);
- return editor.getValue();
- }
- }
-
- return element;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceElementValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,189 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import org.jboss.beans.info.spi.BeanInfo;
-import org.jboss.dependency.plugins.AbstractDependencyItem;
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.dependency.spi.DependencyItem;
-import org.jboss.joinpoint.spi.TargettedJoinpoint;
-import org.jboss.kernel.spi.config.KernelConfigurator;
-import org.jboss.kernel.spi.dependency.KernelController;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-
-/**
- * ServiceInjectionValueMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceInjectionValueMetaData extends AbstractMetaDataVisitorNode implements ServiceValueMetaData
-{
- /** The dependency */
- private Object dependency;
-
- /** The property */
- private String property;
-
- /** The required state of the dependency */
- private ControllerState dependentState = ControllerState.INSTALLED;
-
- /**
- * Create a new ServiceInjectionValueMetaData.
- */
- public ServiceInjectionValueMetaData()
- {
- }
-
- /**
- * Create a new ServiceInjectionValueMetaData.
- *
- * @param dependency the dependency
- */
- public ServiceInjectionValueMetaData(Object dependency)
- {
- this(dependency, null);
- }
-
- /**
- * Create a new ServiceInjectionValueMetaData.
- *
- * @param dependency the dependency
- * @param property the property name
- */
- public ServiceInjectionValueMetaData(Object dependency, String property)
- {
- this(dependency, property, ControllerState.INSTALLED);
- }
-
- /**
- * Create a new ServiceInjectionValueMetaData.
- *
- * @param dependency the dependency
- * @param property the property name
- * @param dependentState the dependent state
- */
- public ServiceInjectionValueMetaData(Object dependency, String property, ControllerState dependentState)
- {
- setDependency(dependency);
- setProperty(property);
- setDependentState(dependentState);
- }
-
- /**
- * Get the dependency.
- *
- * @return the dependency.
- */
- public Object getDependency()
- {
- return dependency;
- }
-
- /**
- * Set the dependency.
- *
- * @param dependency the dependency.
- */
- public void setDependency(Object dependency)
- {
- if (dependency == null)
- throw new IllegalArgumentException("Null dependency");
- this.dependency = dependency;
- }
-
- /**
- * Get the property.
- *
- * @return the property.
- */
- public String getProperty()
- {
- return property;
- }
-
- /**
- * Set the property.
- *
- * @param property the property.
- */
- public void setProperty(String property)
- {
- this.property = property;
- }
-
- /**
- * Get the dependentState.
- *
- * @return the dependentState.
- */
- public ControllerState getDependentState()
- {
- return dependentState;
- }
-
- /**
- * Set the dependentState.
- *
- * @param dependentState the dependentState.
- */
- public void setDependentState(ControllerState dependentState)
- {
- this.dependentState = dependentState;
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Throwable
- {
- KernelController controller = valueContext.getController();
-
- ControllerState state = dependentState;
- if (state == null)
- state = ControllerState.INSTALLED;
-
- ControllerContext context = controller.getContext(dependency, dependentState);
- if (context == null)
- throw new Error("Should not be here - dependency failed! " + this);
- Object result = context.getTarget();
- if (result != null && property != null)
- {
- KernelConfigurator configurator = controller.getKernel().getConfigurator();
- BeanInfo beanInfo = configurator.getBeanInfo(result.getClass());
- TargettedJoinpoint joinpoint = configurator.getPropertyGetterJoinPoint(beanInfo, property);
- joinpoint.setTarget(result);
- return joinpoint.dispatch();
- }
- return result;
- }
-
- public void visit(ServiceMetaDataVisitor visitor)
- {
- ServiceControllerContext context = visitor.getControllerContext();
- Object name = context.getName();
- ControllerState whenRequired = visitor.getContextState();
-
- DependencyItem item = new AbstractDependencyItem(name, dependency, whenRequired, dependentState);
- visitor.addDependency(item);
-
- visitor.visit(this);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceInjectionValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,91 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.io.StringReader;
-
-import org.jboss.system.ServiceConfigurator;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
-import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
-import org.w3c.dom.Element;
-
-/**
- * ServiceJBXBValueMetaData.
- *
- * This class is based on the old ServiceConfigurator
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceJBXBValueMetaData extends ServiceElementValueMetaData
-{
- /**
- * Create a new ServiceJBXBValueMetaData.
- */
- public ServiceJBXBValueMetaData()
- {
- super();
- }
-
- /**
- * Create a new ServiceJBXBValueMetaData.
- *
- * @param element the element
- */
- public ServiceJBXBValueMetaData(Element element)
- {
- super(element);
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- // Get the attribute element content in a parsable form
- StringBuffer buffer = ServiceConfigurator.getElementContent(getElement());
-
- Thread current = Thread.currentThread();
- ClassLoader oldTcl = current.getContextClassLoader();
- ClassLoader cl = valueContext.getClassloader();
- if (cl != null)
- current.setContextClassLoader(cl);
- try
- {
- // Parse the attribute element content
- SchemaBindingResolver resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
- Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
- StringReader reader = new StringReader(buffer.toString());
- Object bean = unmarshaller.unmarshal(reader, resolver);
- return bean;
- }
- finally
- {
- if (cl != null)
- current.setContextClassLoader(oldTcl);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceJBXBValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,105 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.Properties;
-
-import javax.management.MBeanAttributeInfo;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.util.propertyeditor.PropertyEditors;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * ServiceJavaBeanValueMetaData.
- *
- * This class is based on the old ServiceConfigurator
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceJavaBeanValueMetaData extends ServiceElementValueMetaData
-{
- /**
- * Create a new ServiceJavaBeanValueMetaData.
- */
- public ServiceJavaBeanValueMetaData()
- {
- super();
- }
-
- /**
- * Create a new ServiceJavaBeanValueMetaData.
- *
- * @param element the element
- */
- public ServiceJavaBeanValueMetaData(Element element)
- {
- super(element);
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- MBeanAttributeInfo attributeInfo = valueContext.getAttributeInfo();
- ClassLoader cl = valueContext.getClassloader();
- boolean trim = valueContext.isTrim();
- boolean replace = valueContext.isReplace();
-
- // Extract the property elements
- Element element = getElement();
- String attributeClassName = element.getAttribute("attributeClass");
- if( attributeClassName == null || attributeClassName.length() == 0 )
- attributeClassName = attributeInfo.getType();
- if (attributeClassName == null)
- throw new DeploymentException("AttributeInfo for " + attributeInfo.getName() + " has no type");
- Class attributeClass = cl.loadClass(attributeClassName);
- // Create the bean instance
- Object bean = attributeClass.newInstance();
- // Get the JavaBean properties
- NodeList properties = element.getElementsByTagName("property");
- Properties beanProps = new Properties();
- for(int n = 0; n < properties.getLength(); n ++)
- {
- // Skip over non-element nodes
- Node node = properties.item(n);
- if (node.getNodeType() != Node.ELEMENT_NODE)
- {
- continue;
- }
- Element property = (Element) node;
- String name = property.getAttribute("name");
- String value = ServiceMetaDataParser.getElementTextContent(property, trim, replace);
- beanProps.setProperty(name, value);
- }
-
- // Apply the properties to the bean
- PropertyEditors.mapJavaBeanProperties(bean, beanProps);
- return bean;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceJavaBeanValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,312 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.Collections;
-import java.util.List;
-import java.util.Set;
-
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.ControllerMode;
-import org.w3c.dom.Element;
-
-/**
- * ServiceMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceMetaData extends AbstractMetaDataVisitorNode
-{
- /** The default XMBean class, when one is not specified */
- public static final String XMBEAN_CODE = "org.jboss.mx.modelmbean.XMBean";
-
- /** The ObjectName */
- private ObjectName objectName;
-
- /** The code */
- private String code;
-
- /** The mode */
- private ControllerMode mode;
-
- /** The interface name */
- private String interfaceName;
-
- /** The constructor */
- private ServiceConstructorMetaData constructor;
-
- /** The XMBean dds */
- private String xmbeanDD;
-
- /** The XMBean code */
- private String xmbeanCode = XMBEAN_CODE;
-
- /** The XMBean descriptor */
- private Element xmbeanDescriptor;
-
- /** The attributes */
- private List<ServiceAttributeMetaData> attributes = Collections.emptyList();
-
- /** The dependencies */
- private List<ServiceDependencyMetaData> dependencies = Collections.emptyList();
-
- /** The class loader */
- private ObjectName classLoaderName;
-
- /**
- * Get the objectName.
- *
- * @return the objectName.
- */
- public ObjectName getObjectName()
- {
- return objectName;
- }
-
- /**
- * Set the objectName.
- *
- * @param objectName the objectName.
- */
- public void setObjectName(ObjectName objectName)
- {
- if (objectName == null)
- throw new IllegalArgumentException("Null objectName");
- this.objectName = objectName;
- }
-
- /**
- * Get the code.
- *
- * @return the code.
- */
- public String getCode()
- {
- return code;
- }
-
- /**
- * Set the code.
- *
- * @param code the code.
- */
- public void setCode(String code)
- {
- if (code == null)
- throw new IllegalArgumentException("Null code");
- this.code = code;
- }
-
- /**
- * Get the mode.
- *
- * @return the mode.
- */
- public ControllerMode getMode()
- {
- return mode;
- }
-
- /**
- * Set the mode.
- *
- * @param mode the mode.
- */
- public void setMode(ControllerMode mode)
- {
- this.mode = mode;
- }
-
- /**
- * Get the constructor.
- *
- * @return the constructor.
- */
- public ServiceConstructorMetaData getConstructor()
- {
- return constructor;
- }
-
- /**
- * Set the constructor.
- *
- * @param constructor the constructor.
- */
- public void setConstructor(ServiceConstructorMetaData constructor)
- {
- this.constructor = constructor;
- }
-
- /**
- * Get the interfaceName.
- *
- * @return the interfaceName.
- */
- public String getInterfaceName()
- {
- return interfaceName;
- }
-
- /**
- * Set the interfaceName.
- *
- * @param interfaceName the interfaceName.
- */
- public void setInterfaceName(String interfaceName)
- {
- this.interfaceName = interfaceName;
- }
-
- /**
- * Get the xmbeanCode.
- *
- * @return the xmbeanCode.
- */
- public String getXMBeanCode()
- {
- return xmbeanCode;
- }
-
- /**
- * Set the xmbeanCode.
- *
- * @param xmbeanCode the xmbeanCode.
- */
- public void setXMBeanCode(String xmbeanCode)
- {
- if (xmbeanCode == null)
- throw new IllegalArgumentException("Null xmbeanCode");
- this.xmbeanCode = xmbeanCode;
- }
-
- /**
- * Get the xmbeanDD.
- *
- * @return the xmbeanDD.
- */
- public String getXMBeanDD()
- {
- return xmbeanDD;
- }
-
- /**
- * Set the xmbeanDD.
- *
- * @param xmbeanDD the xmbeanDD.
- */
- public void setXMBeanDD(String xmbeanDD)
- {
- this.xmbeanDD = xmbeanDD;
- }
-
- /**
- * Get the xmbeanDescriptor.
- *
- * @return the xmbeanDescriptor.
- */
- public Element getXMBeanDescriptor()
- {
- return xmbeanDescriptor;
- }
-
- /**
- * Set the xmbeanDescriptor.
- *
- * @param xmbeanDescriptor the xmbeanDescriptor.
- */
- public void setXMBeanDescriptor(Element xmbeanDescriptor)
- {
- this.xmbeanDescriptor = xmbeanDescriptor;
- }
-
- /**
- * Get the attributes.
- *
- * @return the attributes.
- */
- public List<ServiceAttributeMetaData> getAttributes()
- {
- return attributes;
- }
-
- /**
- * Set the attributes.
- *
- * @param attributes the attributes.
- */
- public void setAttributes(List<ServiceAttributeMetaData> attributes)
- {
- if (attributes == null)
- throw new IllegalArgumentException("Null attributes");
- this.attributes = attributes;
- }
-
- /**
- * Get the dependencies.
- *
- * @return the dependencies.
- */
- public List<ServiceDependencyMetaData> getDependencies()
- {
- return dependencies;
- }
-
- /**
- * Set the dependencies.
- *
- * @param dependencies the dependencies.
- */
- public void setDependencies(List<ServiceDependencyMetaData> dependencies)
- {
- if (dependencies == null)
- throw new IllegalArgumentException("Null dependencies");
- this.dependencies = dependencies;
- }
-
- /**
- * Get the classLoaderName.
- *
- * @return the classLoaderName.
- */
- public ObjectName getClassLoaderName()
- {
- return classLoaderName;
- }
-
- /**
- * Set the classLoaderName.
- *
- * @param classLoaderName the classLoaderName.
- */
- public void setClassLoaderName(ObjectName classLoaderName)
- {
- this.classLoaderName = classLoaderName;
- }
-
- protected void addChildren(Set<ServiceMetaDataVisitorNode> children)
- {
- children.addAll(attributes);
- children.addAll(dependencies);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,583 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.dependency.spi.ControllerMode;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.util.StringPropertyReplacer;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.Text;
-
-/**
- * ServiceMetaDataParser
- *
- * This class is based on the old ServiceConfigurator/Creator.
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceMetaDataParser
-{
- /** The log */
- private static final Logger log = Logger.getLogger(ServiceMetaDataParser.class);
-
- /** The element config */
- private Element config;
-
- /** The mode */
- private ControllerMode serverMode;
-
- /**
- * Create a new service meta data parser
- *
- * @param config the xml config
- */
- public ServiceMetaDataParser(Element config)
- {
- if (config == null)
- throw new IllegalArgumentException("Null config");
-
- this.config = config;
- }
-
- /**
- * Parse the xml
- *
- * @return the list of service meta data
- * @throws DeploymentException for any error
- */
- public List<ServiceMetaData> parse() throws DeploymentException
- {
- List<ServiceMetaData> services = new ArrayList<ServiceMetaData>();
-
- try
- {
- String tagName = config.getTagName();
- if ("mbean".equals(tagName))
- internalParse(services, config, true);
- else
- {
- if ("server".equals(tagName))
- parseServer(config);
-
- NodeList nl = config.getChildNodes();
-
- for (int i = 0; i < nl.getLength(); ++i)
- {
- if (nl.item(i).getNodeType() == Node.ELEMENT_NODE)
- {
- Element element = (Element) nl.item(i);
- if ("mbean".equals(element.getTagName()))
- {
- Element mbean = (Element) nl.item(i);
- internalParse(services, mbean, true);
- }
- }
- }
- }
- }
- catch (Throwable t)
- {
- DeploymentException.rethrowAsDeploymentException("Unable to parse service configuration", t);
- }
-
- return services;
- }
-
- /**
- * Parse the server element
- *
- * @param serverElement the server element
- * @throws Exception for any error
- */
- private void parseServer(Element serverElement) throws Exception
- {
- String modeString = serverElement.getAttribute("mode");
- if (modeString != null)
- {
- modeString = modeString.trim();
- if (modeString.length() != 0)
- serverMode = new ControllerMode(modeString);
- }
- }
-
- /**
- * Internal parse
- *
- * @param services the list of service meta data
- * @param mbeanElement the mbean configuration
- * @param replace whether to replace system properties
- * @return the ObjectName of the parsed mbean
- * @throws Exception for any error
- */
- private ObjectName internalParse(List<ServiceMetaData> services, Element mbeanElement, boolean replace) throws Exception
- {
- ServiceMetaData service = new ServiceMetaData();
-
- ObjectName mbeanName = parseObjectName(mbeanElement, replace);
- service.setObjectName(mbeanName);
-
- String code = parseCode(mbeanName, mbeanElement);
- service.setCode(code);
-
- ControllerMode mode = parseMode(mbeanName, mbeanElement);
- if (mode == null)
- mode = serverMode;
- service.setMode(mode);
-
- ServiceConstructorMetaData constructor = parseConstructor(mbeanName, mbeanElement, replace);
- service.setConstructor(constructor);
-
- String interfaceName = parseInterface(mbeanName, mbeanElement);
- service.setInterfaceName(interfaceName);
-
- String xmbeandd = parseXMBeanDD(mbeanName, mbeanElement);
- service.setXMBeanDD(xmbeandd);
-
- String xmbeanCode = parseXMBeanCode(mbeanName, mbeanElement);
- service.setXMBeanCode(xmbeanCode);
-
- if (xmbeandd != null && xmbeandd.length() == 0)
- {
- Element xmbeanDescriptor = parseXMBeanDescriptor(mbeanName, mbeanElement);
- service.setXMBeanDescriptor(xmbeanDescriptor);
- }
-
- List<ServiceAttributeMetaData> attributes = new ArrayList<ServiceAttributeMetaData>();
- List<ServiceDependencyMetaData> dependencies = new ArrayList<ServiceDependencyMetaData>();
-
- NodeList attrs = mbeanElement.getChildNodes();
- for (int j = 0; j < attrs.getLength(); j++)
- {
- // skip over non-element nodes
- if (attrs.item(j).getNodeType() != Node.ELEMENT_NODE)
- continue;
-
- Element element = (Element) attrs.item(j);
-
- boolean replaceAttribute = true;
-
- // Set attributes
- if (element.getTagName().equals("attribute"))
- {
- String attributeName = element.getAttribute("name");
- if (attributeName == null)
- throw new DeploymentException("No attribute name for " + mbeanName);
- boolean trim = true;
- String replaceAttr = element.getAttribute("replace");
- if (replaceAttr.length() > 0)
- replaceAttribute = Boolean.valueOf(replaceAttr).booleanValue();
- String trimAttr = element.getAttribute("trim");
- if (trimAttr.length() > 0)
- trim = Boolean.valueOf(trimAttr).booleanValue();
- String serialDataType = element.getAttribute("serialDataType");
-
- if (element.hasChildNodes())
- {
- // Unmarshall the attribute value based on the serialDataType
- ServiceValueMetaData value = null;
- if (serialDataType.equals("javaBean"))
- {
- value = new ServiceJavaBeanValueMetaData(element);
- }
- else if (serialDataType.equals("jbxb"))
- {
- value = new ServiceJBXBValueMetaData(element);
- }
- else
- {
- NodeList nl = element.getChildNodes();
- for (int i = 0; i < nl.getLength(); i++)
- {
- Node n = nl.item(i);
- if (n.getNodeType() == Node.ELEMENT_NODE)
- {
- Element el = (Element) n;
- String tagName = el.getTagName();
- if ("inject".equals(tagName))
- {
- String dependency = el.getAttribute("bean");
- String property = null;
- Attr attr = el.getAttributeNode("property");
- if (attr != null)
- property = attr.getValue();
- ControllerState requiredState = ControllerState.INSTALLED;
- attr = el.getAttributeNode("state");
- if (attr != null)
- requiredState = new ControllerState(attr.getValue());
- value = new ServiceInjectionValueMetaData(dependency, property, requiredState);
- }
- else
- {
- value = new ServiceElementValueMetaData((Element) n);
- }
- break;
- }
- }
- if (value == null)
- value = new ServiceTextValueMetaData(getElementTextContent(element, trim, replace));
- }
-
- ServiceAttributeMetaData attribute = new ServiceAttributeMetaData();
- attribute.setName(attributeName);
- attribute.setReplace(replaceAttribute);
- attribute.setTrim(trim);
- attribute.setValue(value);
- attributes.add(attribute);
- }
- }
- else if (element.getTagName().equals("depends"))
- {
- String mbeanRefName = element.getAttribute("optional-attribute-name");
- if ("".equals(mbeanRefName))
- mbeanRefName = null;
- else
- mbeanRefName = StringPropertyReplacer.replaceProperties(mbeanRefName);
-
- String proxyType = element.getAttribute("proxy-type");
- if ("".equals(proxyType))
- proxyType = null;
- else
- proxyType = StringPropertyReplacer.replaceProperties(proxyType);
-
- // Get the mbeanRef value
- String dependsObjectName = processDependency(mbeanName, mbeanRefName, element, services, replace);
-
- if (mbeanRefName != null)
- {
- ServiceValueMetaData value = new ServiceDependencyValueMetaData(dependsObjectName, proxyType);
- ServiceAttributeMetaData attribute = new ServiceAttributeMetaData();
- attribute.setName(mbeanRefName);
- attribute.setValue(value);
- attributes.add(attribute);
- }
- else
- {
- ServiceDependencyMetaData dependency = new ServiceDependencyMetaData();
- dependency.setIDependOn(dependsObjectName);
- dependencies.add(dependency);
- }
- }
- else if (element.getTagName().equals("depends-list"))
- {
- String dependsListName = element.getAttribute("optional-attribute-name");
- if ("".equals(dependsListName))
- dependsListName = null;
-
- NodeList dependsList = element.getChildNodes();
- ArrayList<String> dependsListNames = new ArrayList<String>();
- for (int l = 0; l < dependsList.getLength(); ++l)
- {
- if (dependsList.item(l).getNodeType() != Node.ELEMENT_NODE)
- continue;
-
- Element dependsElement = (Element) dependsList.item(l);
- if (dependsElement.getTagName().equals("depends-list-element"))
- {
- // Get the depends value
- String dependsObjectName = processDependency(mbeanName, dependsListName, dependsElement, services, replace);
- if (dependsListNames.contains(dependsObjectName) == false)
- dependsListNames.add(dependsObjectName);
-
- if (dependsListName == null)
- {
- ServiceDependencyMetaData dependency = new ServiceDependencyMetaData();
- dependency.setIDependOn(dependsObjectName);
- dependencies.add(dependency);
- }
- }
- }
- if (dependsListName != null)
- {
- ServiceValueMetaData value = new ServiceDependencyListValueMetaData(dependsListNames);
- ServiceAttributeMetaData attribute = new ServiceAttributeMetaData();
- attribute.setName(dependsListName);
- attribute.setValue(value);
- attributes.add(attribute);
- }
- }
- }
-
- service.setAttributes(attributes);
- service.setDependencies(dependencies);
-
- services.add(service);
-
- return mbeanName;
- }
-
- /**
- * Parse an object name from the given element attribute 'name'.
- *
- * @param mbeanElement the element to parse name from.
- * @return the ObjectName
- * @throws Exception for any error
- */
- private ObjectName parseObjectName(final Element mbeanElement, boolean replace) throws Exception
- {
- String name = mbeanElement.getAttribute("name");
-
- if (name == null || name.trim().length() == 0)
- throw new DeploymentException("Missing or empty 'name' attribute for mbean.");
-
- if (replace)
- name = StringPropertyReplacer.replaceProperties(name);
-
- return new ObjectName(name);
- }
-
- /**
- * Parse a class name from the given element attribute 'code'.
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @return the class name
- * @throws Exception for any error
- */
- private String parseCode(final ObjectName name, final Element mbeanElement) throws Exception
- {
- return mbeanElement.getAttribute("code");
- }
-
- /**
- * Parse the mode
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @return the mode
- * @throws Exception for any error
- */
- private ControllerMode parseMode(final ObjectName name, final Element mbeanElement) throws Exception
- {
- String modeString = mbeanElement.getAttribute("mode");
- if (modeString == null)
- return null;
- modeString = modeString.trim();
- if (modeString.length() == 0)
- return null;
- return new ControllerMode(modeString);
- }
-
- /**
- * Parse the constructor element of the given element
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @param replace whether to replace system properties
- * @return the constructor meta data
- * @throws Exception for any error
- */
- private ServiceConstructorMetaData parseConstructor(final ObjectName name, final Element mbeanElement, boolean replace) throws Exception
- {
- ServiceConstructorMetaData result = new ServiceConstructorMetaData();
-
- NodeList list = mbeanElement.getElementsByTagName("constructor");
- if (list.getLength() > 1 && list.item(0).getParentNode() == mbeanElement)
- throw new DeploymentException("only one <constructor> element may be defined for " + name);
-
- if (list.getLength() == 1)
- {
- Element element = (Element) list.item(0);
-
- // get all of the "arg" elements
- list = element.getElementsByTagName("arg");
- int length = list.getLength();
- String[] params = new String[length];
- String[] signature = new String[length];
-
- // decode the values into params & signature
- for (int j=0; j<length; ++j)
- {
- Element arg = (Element)list.item(j);
- String typeName = null;
- Attr attr = arg.getAttributeNode("type");
- if (attr != null)
- typeName = attr.getValue();
- String value = null;
- attr = arg.getAttributeNode("value");
- if (attr != null)
- value = attr.getValue();
- signature[j] = typeName;
- params[j] = value;
- }
-
- result.setParams(params);
- result.setSignature(signature);
- }
-
- return result;
- }
-
- /**
- * Parse the interface name from the given element attribute 'interface'.
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @return the class name
- * @throws Exception for any error
- */
- private String parseInterface(final ObjectName name, final Element mbeanElement) throws Exception
- {
- Attr attr = mbeanElement.getAttributeNode("interface");
- if (attr != null)
- return attr.getValue();
- else
- return null;
- }
-
- /**
- * Parse the xmbean dds from the given element attribute 'xmbean-dd'.
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @return the xmbean dds location
- * @throws Exception for any error
- */
- private String parseXMBeanDD(final ObjectName name, final Element mbeanElement) throws Exception
- {
- Attr attr = mbeanElement.getAttributeNode("xmbean-dd");
- if (attr != null)
- return attr.getValue();
- else
- return null;
- }
-
- /**
- * Parse the xmbean code from the given element attribute 'xmbean-code'.
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @return the xmbean code
- * @throws Exception for any error
- */
- private String parseXMBeanCode(final ObjectName name, final Element mbeanElement) throws Exception
- {
- Attr attr = mbeanElement.getAttributeNode("xmbean-code");
- if (attr != null)
- return attr.getValue();
- else
- return ServiceMetaData.XMBEAN_CODE;
- }
-
- /**
- * Parse the xmbean descriptor.
- *
- * @param name the mbean name
- * @param mbeanElement the element to parse name from.
- * @return the xmbean descriptor
- * @throws Exception for any error
- */
- private Element parseXMBeanDescriptor(final ObjectName name, final Element mbeanElement) throws Exception
- {
- NodeList mbeans = mbeanElement.getElementsByTagName("xmbean");
- if (mbeans.getLength() == 0)
- throw new DeploymentException("No nested mbean element given for xmbean for " + name);
- return (Element) mbeans.item(0);
- }
-
- /**
- * Process a dependency
- *
- * @param mbeanName the surronding mbean
- * @param attributeName the attribute name
- * @param element the element
- * @param services the list of services
- * @param replace whether to replace properties
- * @return the dependent object name
- * @throws Exception for any error
- */
- private String processDependency(ObjectName mbeanName, String attributeName, Element element, List<ServiceMetaData> services, boolean replace) throws Exception
- {
- String dependsObjectName = null;
-
- NodeList nl = element.getChildNodes();
- for (int i = 0; i < nl.getLength(); i++)
- {
- Node childNode = nl.item(i);
- if (childNode.getNodeType() == Node.ELEMENT_NODE)
- {
- Element child = (Element) childNode;
- String tagName = child.getTagName();
- if ("mbean".equals(tagName))
- {
- dependsObjectName = internalParse(services, child, replace).getCanonicalName();
- break;
- }
- else
- {
- if (attributeName != null)
- log.warn("Non mbean child <" + tagName + "/> in depends tag for " + mbeanName + " attribute: " + attributeName);
- else
- log.warn("Non mbean child <" + tagName + "/> in depends tag for " + mbeanName);
- }
- }
- }
-
- if (dependsObjectName == null)
- dependsObjectName = getElementTextContent(element, true, replace);
-
- return dependsObjectName;
- }
-
- /**
- * Get an elements text content
- *
- * @param element the element
- * @param trim whether to trim
- * @param replace whetehr to replace properties
- * @return the concatentation of the text nodes
- * @throws Exception for any error
- */
- public static String getElementTextContent(Element element, boolean trim, boolean replace) throws Exception
- {
- NodeList nl = element.getChildNodes();
- String attributeText = "";
- for (int i = 0; i < nl.getLength(); i++)
- {
- Node n = nl.item(i);
- if (n instanceof Text)
- {
- attributeText += ((Text) n).getData();
- }
- }
- if (trim)
- attributeText = attributeText.trim();
- if (replace)
- attributeText = StringPropertyReplacer.replaceProperties(attributeText);
- return attributeText;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataParser.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.dependency.spi.DependencyItem;
-import org.jboss.system.microcontainer.ServiceControllerContext;
-
-/**
- * ServiceMetaDataVisitor.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface ServiceMetaDataVisitor
-{
- /**
- * Get the controller context
- *
- * @return the context
- */
- ServiceControllerContext getControllerContext();
-
- /**
- * Get the context state
- *
- * @return the context state
- */
- ControllerState getContextState();
-
- /**
- * Set the context state
- *
- * @param contextState the context state
- */
- void setContextState(ControllerState contextState);
-
- /**
- * Add a dependency
- *
- * @param dependency the dependency
- */
- void addDependency(DependencyItem dependency);
-
- /**
- * Visit the node
- *
- * @param node the node
- */
- void visit(ServiceMetaDataVisitorNode node);
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitor.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,47 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.util.Iterator;
-
-/**
- * ServiceMetaDataVisitorNode.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface ServiceMetaDataVisitorNode
-{
- /**
- * Visit the node
- *
- * @param vistor the visitor
- */
- public void visit(ServiceMetaDataVisitor vistor);
-
- /**
- * Return the child nodes
- *
- * @return Iterator<MetaDataVisitorNode> or null if there aren't any
- */
- public Iterator<? extends ServiceMetaDataVisitorNode> getChildren();
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceMetaDataVisitorNode.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,136 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import java.beans.PropertyEditor;
-import java.beans.PropertyEditorManager;
-
-import javax.management.MBeanAttributeInfo;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.util.Classes;
-import org.jboss.util.propertyeditor.PropertyEditors;
-
-/**
- * ServiceTextValueMetaData.
- *
- * This class is based on the old ServiceConfigurator
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceTextValueMetaData extends AbstractMetaDataVisitorNode implements ServiceValueMetaData
-{
- static
- {
- try
- {
- PropertyEditors.init();
- }
- catch (Exception ignored)
- {
- }
- }
-
- /** The text */
- private String text;
-
- /**
- * Create a new ServiceTextValueMetaData.
- *
- * @param text the text
- */
- public ServiceTextValueMetaData(String text)
- {
- setText(text);
- }
-
- /**
- * Get the text.
- *
- * @return the text.
- */
- public String getText()
- {
- return text;
- }
-
- /**
- * Set the text.
- *
- * @param text the text.
- */
- public void setText(String text)
- {
- if (text == null)
- throw new IllegalArgumentException("Null text");
- this.text = text;
- }
-
- public Object getValue(ServiceValueContext valueContext) throws Exception
- {
- MBeanAttributeInfo attributeInfo = valueContext.getAttributeInfo();
- ClassLoader cl = valueContext.getClassloader();
-
- String typeName = attributeInfo.getType();
- if (typeName == null)
- throw new DeploymentException("AttributeInfo for " + attributeInfo.getName() + " has no type");
-
- // see if it is a primitive type first
- Class typeClass = Classes.getPrimitiveTypeForName(typeName);
- if (typeClass == null)
- {
- // nope try look up
- try
- {
- typeClass = cl.loadClass(typeName);
- }
- catch (ClassNotFoundException e)
- {
- throw new DeploymentException("Class not found for attribute: " + attributeInfo.getName(), e);
- }
- }
-
- PropertyEditor editor = PropertyEditorManager.findEditor(typeClass);
- if (editor == null)
- throw new DeploymentException("No property editor for attribute: " + attributeInfo.getName() + "; type=" + typeClass.getName());
-
- // JBAS-1709, temporarily switch the TCL so that property
- // editors have access to the actual deployment ClassLoader.
- ClassLoader tcl = Thread.currentThread().getContextClassLoader();
- Thread.currentThread().setContextClassLoader(cl);
- try
- {
- editor.setAsText(text);
- return editor.getValue();
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(tcl);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceTextValueMetaData.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,242 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanServer;
-
-import org.jboss.kernel.Kernel;
-import org.jboss.kernel.spi.dependency.KernelController;
-import org.jboss.system.ServiceController;
-
-/**
- * ServiceValueContext.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceValueContext
-{
- /** The MBeanServer */
- private MBeanServer server;
-
- /** The service controller */
- private ServiceController controller;
-
- /** The MBeanAttributeInfo */
- private MBeanAttributeInfo attributeInfo;
-
- /** The ClassLoader */
- private ClassLoader classloader;
-
- /** Whether to trim */
- private boolean trim;
-
- /** Whether to replace */
- private boolean replace;
-
- /**
- * Create a new ServiceValueContext.
- */
- public ServiceValueContext()
- {
- }
-
- /**
- * Create a new ServiceValueContext.
- *
- * @param server the server
- * @param controller the service controller
- * @param classloader the classloader
- */
- public ServiceValueContext(MBeanServer server, ServiceController controller, ClassLoader classloader)
- {
- this.server = server;
- this.controller = controller;
- this.classloader = classloader;
- }
-
- /**
- * Create a new ServiceValueContext.
- *
- * @param server the server
- * @param controller the service controller
- * @param attributeInfo the attribute info
- * @param classloader the classloader
- */
- public ServiceValueContext(MBeanServer server, ServiceController controller, MBeanAttributeInfo attributeInfo, ClassLoader classloader)
- {
- this.server = server;
- this.controller = controller;
- this.attributeInfo = attributeInfo;
- this.classloader = classloader;
- }
-
- /**
- * Get the attributeInfo.
- *
- * @return the attributeInfo.
- */
- public MBeanAttributeInfo getAttributeInfo()
- {
- return attributeInfo;
- }
-
- /**
- * Set the attributeInfo.
- *
- * @param attributeInfo the attributeInfo.
- */
- public void setAttributeInfo(MBeanAttributeInfo attributeInfo)
- {
- this.attributeInfo = attributeInfo;
- }
-
- /**
- * Get the classloader.
- *
- * @return the classloader.
- */
- public ClassLoader getClassloader()
- {
- return classloader;
- }
-
- /**
- * Set the classloader.
- *
- * @param classloader the classloader.
- */
- public void setClassloader(ClassLoader classloader)
- {
- this.classloader = classloader;
- }
-
- /**
- * Get the replace.
- *
- * @return the replace.
- */
- public boolean isReplace()
- {
- return replace;
- }
-
- /**
- * Set the replace.
- *
- * @param replace the replace.
- */
- public void setReplace(boolean replace)
- {
- this.replace = replace;
- }
-
- /**
- * Get the server.
- *
- * @return the server.
- */
- public MBeanServer getServer()
- {
- if (server == null)
- {
- if (controller == null)
- throw new IllegalStateException("No MBeanServer");
- else
- return controller.getMBeanServer();
- }
- return server;
- }
-
- /**
- * Set the server.
- *
- * @param server the server.
- */
- public void setServer(MBeanServer server)
- {
- this.server = server;
- }
-
- /**
- * Get the service controller.
- *
- * @return the controller.
- */
- public ServiceController getServiceController()
- {
- if (controller == null)
- throw new IllegalStateException("No ServiceController");
- return controller;
- }
-
- /**
- * Set the service controller.
- *
- * @param controller the controller.
- */
- public void setServiceController(ServiceController controller)
- {
- this.controller = controller;
- }
-
- /**
- * Get the trim.
- *
- * @return the trim.
- */
- public boolean isTrim()
- {
- return trim;
- }
-
- /**
- * Set the trim.
- *
- * @param trim the trim.
- */
- public void setTrim(boolean trim)
- {
- this.trim = trim;
- }
-
- /**
- * Get the kernel
- *
- * @return the kernel
- */
- public Kernel getKernel()
- {
- return getServiceController().getKernel();
- }
-
- /**
- * Get the controller
- *
- * @return the controller
- */
- public KernelController getController()
- {
- return getKernel().getController();
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceValueContext.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,40 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.metadata;
-
-/**
- * ServiceValueMetaData.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface ServiceValueMetaData extends ServiceMetaDataVisitorNode
-{
- /**
- * Get the value
- *
- * @param valueContext the value context
- * @return the value
- * @throws Throwable for any error
- */
- Object getValue(ServiceValueContext valueContext) throws Throwable;
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/metadata/ServiceValueMetaData.java)
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,73 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceBinding;
-import org.jboss.system.ServiceConfigurator;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceController;
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-
-/**
- * ConfigureAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConfigureAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- ServiceController controller = context.getServiceController();
- MBeanServer server = controller.getMBeanServer();
- ObjectName objectName = context.getObjectName();
-
- // Configure any attributes
- ServiceMetaData metaData = context.getServiceMetaData();
- if (metaData != null)
- {
- List<ServiceAttributeMetaData> attrs = metaData.getAttributes();
- if (attrs.size() > 0)
- {
- ObjectName classLoaderName = metaData.getClassLoaderName();
- ServiceConfigurator.configure(null, controller, objectName, classLoaderName, attrs);
- }
- }
-
- // If a ServiceBinding policy is plugged-in, check for overriden attributes
- ServiceBinding serviceBinding = context.getServiceController().getServiceBinding();
- if (serviceBinding != null)
- ServiceConfigurator.applyServiceConfig(server, objectName, serviceBinding);
-
- context.getServiceContext().state = ServiceContext.CONFIGURED;
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ConfigureAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,69 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.Service;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceController;
-import org.jboss.system.ServiceMBean;
-
-/**
- * CreateDestroyLifecycleAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CreateDestroyLifecycleAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- Service service = context.getServiceProxy();
- service.create();
-
- context.getServiceContext().state = ServiceContext.CREATED;
-
- ObjectName objectName = context.getObjectName();
- ServiceController serviceController = context.getServiceController();
- serviceController.sendControllerNotification(ServiceMBean.CREATE_EVENT, objectName);
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- try
- {
- Service service = context.getServiceProxy();
- service.destroy();
-
- context.getServiceContext().state = ServiceContext.DESTROYED;
-
- ObjectName objectName = context.getObjectName();
- ServiceController serviceController = context.getServiceController();
- serviceController.sendControllerNotification(ServiceMBean.DESTROY_EVENT, objectName);
- }
- catch (Throwable t)
- {
- log.debug("Error during destroy for " + context.getObjectName(), t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/CreateDestroyLifecycleAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,39 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-/**
- * DescribeAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DescribeAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/DescribeAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,39 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-/**
- * InstallAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class InstallAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/InstallAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,58 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceCreator;
-import org.jboss.system.ServiceInstance;
-import org.jboss.system.metadata.ServiceMetaData;
-
-/**
- * InstantiateAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class InstantiateAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- MBeanServer server = context.getServiceController().getMBeanServer();
- ObjectName objectName = context.getObjectName();
- ServiceMetaData metaData = context.getServiceMetaData();
- Object mbean = context.getTarget();
- ServiceInstance instance = ServiceCreator.install(server, objectName, metaData, mbean);
- context.setTarget(instance.getResource());
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- MBeanServer server = context.getServiceController().getMBeanServer();
- ObjectName objectName = context.getObjectName();
- ServiceCreator.uninstall(server, objectName);
- ServiceMetaData metaData = context.getServiceMetaData();
- if (metaData != null)
- context.setTarget(null);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/InstantiateAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,25 +0,0 @@
-package org.jboss.system.microcontainer;
-
-import org.jboss.dependency.plugins.AbstractDependencyItem;
-import org.jboss.dependency.spi.ControllerState;
-
-/**
- * A LifecycleDependencyItem.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class LifecycleDependencyItem extends AbstractDependencyItem
-{
- /**
- * Create a new LifecycleDependencyItem.
- *
- * @param name the name
- * @param dependency the dependency
- * @param state the state
- */
- public LifecycleDependencyItem(Object name, Object dependency, ControllerState state)
- {
- super(name, dependency, state, state);
- }
-}
\ No newline at end of file
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/LifecycleDependencyItem.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceCreator;
-
-/**
- * Only unregister action
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class OnlyUnregisterAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- MBeanServer server = context.getServiceController().getMBeanServer();
- ObjectName objectName = context.getObjectName();
- ServiceCreator.uninstall(server, objectName);
- context.setTarget(null);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/OnlyUnregisterAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,302 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.util.Iterator;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.dependency.plugins.AbstractControllerContext;
-import org.jboss.dependency.spi.Controller;
-import org.jboss.dependency.spi.ControllerMode;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.dependency.spi.DependencyItem;
-import org.jboss.system.Service;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceController;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataVisitor;
-import org.jboss.system.metadata.ServiceMetaDataVisitorNode;
-
-/**
- * ServiceControllerContext.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceControllerContext extends AbstractControllerContext
-{
- /** The ObjectName */
- private ObjectName objectName;
-
- /** The service controller */
- private ServiceController serviceController;
-
- /** The meta data */
- private ServiceMetaData serviceMetaData;
-
- /** The service context */
- private ServiceContext serviceContext = new ServiceContext();
-
- /**
- * Create a new ServiceControllerContext.
- *
- * @param serviceController the service controller
- * @param name the name of the context
- */
- public ServiceControllerContext(ServiceController serviceController, ObjectName name)
- {
- super(name.getCanonicalName(), ServiceControllerContextActions.getLifecycleOnly());
- this.objectName = name;
- serviceContext.objectName = objectName;
- this.serviceController = serviceController;
- setMode(ControllerMode.MANUAL);
- }
-
- /**
- * Create a new ServiceControllerContext.
- *
- * @param serviceController the service controller
- * @param metaData the meta data
- */
- public ServiceControllerContext(ServiceController serviceController, ServiceMetaData metaData)
- {
- super(metaData.getObjectName().getCanonicalName(), ServiceControllerContextActions.getInstance());
- this.objectName = metaData.getObjectName();
- serviceContext.objectName = objectName;
- this.serviceController = serviceController;
- ControllerMode mode = metaData.getMode();
- this.serviceMetaData = metaData;
- if (mode == null)
- setMode(ControllerMode.MANUAL);
- else
- setMode(mode);
- }
-
- /**
- * Create a new ServiceControllerContext.
- *
- * @param serviceController the service controller
- * @param name the name
- * @param target the target
- */
- public ServiceControllerContext(ServiceController serviceController, ObjectName name, Object target)
- {
- super(name.getCanonicalName(), ServiceControllerContextActions.getInstance());
- this.objectName = name;
- serviceContext.objectName = objectName;
- this.serviceController = serviceController;
- setTarget(target);
- setMode(ControllerMode.MANUAL);
- }
-
- /**
- * Get the ObjectName.
- *
- * @return the ObjectName.
- */
- public ObjectName getObjectName()
- {
- return objectName;
- }
-
- /**
- * Get the serviceMetaData.
- *
- * @return the serviceMetaData.
- */
- public ServiceMetaData getServiceMetaData()
- {
- return serviceMetaData;
- }
-
- /**
- * Set the serviceMetaData.
- *
- * @param serviceMetaData the serviceMetaData.
- */
- public void setServiceMetaData(ServiceMetaData serviceMetaData)
- {
- this.serviceMetaData = serviceMetaData;
- }
-
- /**
- * Get the serviceController.
- *
- * @return the serviceController.
- */
- public ServiceController getServiceController()
- {
- return serviceController;
- }
-
- /**
- * Get the service proxy
- *
- * @return the service proxy
- * @throws Exception for any error
- */
- public Service getServiceProxy() throws Exception
- {
- if (serviceContext.proxy != null)
- return serviceContext.proxy;
-
- MBeanServer server = serviceController.getMBeanServer();
- if (server != null)
- serviceContext.proxy = ServiceProxy.getServiceProxy(objectName, server);
-
- return serviceContext.proxy;
- }
-
- /**
- * Get the service context
- *
- * @return the service context
- */
- public ServiceContext getServiceContext()
- {
- try
- {
- serviceContext.proxy = getServiceProxy();
- }
- catch (Exception ignored)
- {
- }
- serviceContext.problem = getError();
- if (getState() == ControllerState.ERROR)
- serviceContext.state = ServiceContext.FAILED;
- return serviceContext;
- }
-
- // Overridden to update the service context with any failure
- public void install(ControllerState fromState, ControllerState toState) throws Throwable
- {
- try
- {
- super.install(fromState, toState);
- }
- catch (Throwable t)
- {
- serviceContext.problem = t;
- serviceContext.state = ServiceContext.FAILED;
- throw t;
- }
- }
-
- // Overridden to update the service context with the installed/not installed state
- // i.e. of the ServiceController registration
- // Not to be confused with the microcontainer's (fully) installed state
- public void setController(Controller controller)
- {
- super.setController(controller);
- if (controller != null)
- {
- preprocessMetaData();
- serviceContext.state = ServiceContext.INSTALLED;
- }
- else
- serviceContext.state = ServiceContext.NOTYETINSTALLED;
- }
-
- /**
- * Preprocess the metadata for this context
- */
- protected void preprocessMetaData()
- {
- if (serviceMetaData == null)
- return;
- PreprocessMetaDataVisitor visitor = new PreprocessMetaDataVisitor();
- AccessController.doPrivileged(visitor);
- }
-
- /**
- * A visitor for the metadata that looks for dependencies.
- */
- protected class PreprocessMetaDataVisitor implements ServiceMetaDataVisitor, PrivilegedAction<Object>
- {
- /** The current context for when the dependencies are required */
- private ControllerState contextState = ControllerState.INSTANTIATED;
-
- /**
- * Visit the bean metadata node, this is the starting point
- */
- public Object run()
- {
- serviceMetaData.visit(this);
- return null;
- }
-
- /**
- * Visit a node
- *
- * @param node the node
- */
- public void visit(ServiceMetaDataVisitorNode node)
- {
- boolean trace = log.isTraceEnabled();
- if (trace)
- log.trace("Visit node " + node);
-
- // Visit the children of this node
- Iterator<? extends ServiceMetaDataVisitorNode> children = node.getChildren();
- if (children != null)
- {
- ControllerState restoreState = contextState;
- while (children.hasNext())
- {
- ServiceMetaDataVisitorNode child = children.next();
- try
- {
- child.visit(this);
- }
- finally
- {
- contextState = restoreState;
- }
- }
- }
- }
-
- public ServiceControllerContext getControllerContext()
- {
- return ServiceControllerContext.this;
- }
-
- public ControllerState getContextState()
- {
- return contextState;
- }
-
- public void addDependency(DependencyItem dependency)
- {
- getDependencyInfo().addIDependOn(dependency);
- }
-
- public void setContextState(ControllerState contextState)
- {
- this.contextState = contextState;
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContext.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,112 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import java.security.AccessController;
-import java.security.PrivilegedAction;
-import java.security.PrivilegedActionException;
-import java.security.PrivilegedExceptionAction;
-
-import org.jboss.dependency.plugins.spi.action.ControllerContextAction;
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.logging.Logger;
-
-/**
- * ServiceControllerContextAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceControllerContextAction implements ControllerContextAction
-{
- protected Logger log = Logger.getLogger(getClass());
-
- public void install(final ControllerContext context) throws Throwable
- {
- if (System.getSecurityManager() == null || context instanceof ServiceControllerContext == false)
- installAction((ServiceControllerContext) context);
- else
- {
- PrivilegedExceptionAction<Object> action = new PrivilegedExceptionAction<Object>()
- {
- public Object run() throws Exception
- {
- try
- {
- installAction((ServiceControllerContext) context);
- return null;
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw e;
- }
- catch (Error e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- throw new RuntimeException(t);
- }
- }
- };
- try
- {
- AccessController.doPrivileged(action);
- }
- catch (PrivilegedActionException e)
- {
- throw e.getCause();
- }
- }
- }
-
- public void uninstall(final ControllerContext context)
- {
- if (System.getSecurityManager() == null || context instanceof ServiceControllerContext == false)
- uninstallAction((ServiceControllerContext) context);
- else
- {
- PrivilegedAction<Object> action = new PrivilegedAction<Object>()
- {
- public Object run()
- {
- uninstallAction((ServiceControllerContext) context);
- return null;
- }
- };
- AccessController.doPrivileged(action);
- }
- }
-
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextAction.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,93 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.jboss.dependency.plugins.AbstractControllerContextActions;
-import org.jboss.dependency.plugins.spi.action.ControllerContextAction;
-import org.jboss.dependency.spi.ControllerState;
-
-/**
- * ServiceControllerContextActions.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceControllerContextActions extends AbstractControllerContextActions
-{
- /** The single instance */
- private static ServiceControllerContextActions instance;
- /** The lifecycle instance */
- private static ServiceControllerContextActions lifecycleOnly;
-
- /**
- * Get the instance
- *
- * @return the actions
- */
- public static ServiceControllerContextActions getInstance()
- {
- if (instance == null)
- {
- Map<ControllerState, ControllerContextAction> actions = new HashMap<ControllerState, ControllerContextAction>();
- actions.put(ControllerState.DESCRIBED, new DescribeAction());
- actions.put(ControllerState.INSTANTIATED, new InstantiateAction());
- actions.put(ControllerState.CONFIGURED, new ConfigureAction());
- actions.put(ControllerState.CREATE, new CreateDestroyLifecycleAction());
- actions.put(ControllerState.START, new StartStopLifecycleAction());
- actions.put(ControllerState.INSTALLED, new InstallAction());
- instance = new ServiceControllerContextActions(actions);
- }
- return instance;
- }
-
- /**
- * Get the instance
- *
- * @return the actions
- */
- public static ServiceControllerContextActions getLifecycleOnly()
- {
- if (lifecycleOnly == null)
- {
- Map<ControllerState, ControllerContextAction> actions = new HashMap<ControllerState, ControllerContextAction>();
- actions.put(ControllerState.INSTANTIATED, new OnlyUnregisterAction());
- actions.put(ControllerState.CREATE, new CreateDestroyLifecycleAction());
- actions.put(ControllerState.START, new StartStopLifecycleAction());
- lifecycleOnly = new ServiceControllerContextActions(actions);
- }
- return lifecycleOnly;
- }
-
-
- /**
- * Create a new ServiceControllerContextActions.
- *
- * @param actions the actions
- */
- protected ServiceControllerContextActions(Map<ControllerState, ControllerContextAction> actions)
- {
- super(actions);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceControllerContextActions.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,194 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.util.HashMap;
-
-import javax.management.MBeanInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.system.Service;
-import org.jboss.system.ServiceController;
-
-/**
- * An implementation of InvocationHandler used to proxy of the Service
- * interface for mbeans. It determines which of the start/stop
- * methods of the Service interface an mbean implements by inspecting its
- * MBeanOperationInfo values. Each Service interface method that has a
- * matching operation is forwarded to the mbean by invoking the method
- * through the MBeanServer object.<p>
- *
- * This class is based on the old ServiceConfigurator
- *
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceProxy implements InvocationHandler
-{
- /**
- * A mapping from the Service interface method names to the corresponding
- * index into the ServiceProxy.hasOp array.
- */
- private static HashMap<String, Integer> serviceOpMap = new HashMap<String, Integer>();
-
- /**
- * Initialize the service operation map.
- */
- static
- {
- serviceOpMap.put("create", new Integer(0));
- serviceOpMap.put("start", new Integer(1));
- serviceOpMap.put("destroy", new Integer(2));
- serviceOpMap.put("stop", new Integer(3));
- }
-
- private boolean[] hasOp = {false, false, false, false};
- private ObjectName objectName;
- private MBeanServer server;
-
- /** Whether we have the lifecycle method */
- private boolean hasJBossInternalLifecycle;
-
- /**
- * Get the Service interface through which the mbean given by objectName will be managed.
- *
- * @param objectName the object name
- * @param server the mbean server
- * @return The Service value
- * @throws Exception for any error
- */
- public static Service getServiceProxy(ObjectName objectName, MBeanServer server) throws Exception
- {
- Service service = null;
- MBeanInfo info = server.getMBeanInfo(objectName);
- MBeanOperationInfo[] opInfo = info.getOperations();
- Class[] interfaces = { Service.class };
- InvocationHandler handler = new ServiceProxy(objectName, server, opInfo);
- service = (Service) Proxy.newProxyInstance(Service.class.getClassLoader(), interfaces, handler);
-
- return service;
- }
-
- /**
- * Go through the opInfo array and for each operation that matches on of
- * the Service interface methods set the corresponding hasOp array value
- * to true.
- *
- * @param objectName the object name
- * @param server the mbean server
- * @param opInfo the MBean operation info
- */
- public ServiceProxy(ObjectName objectName, MBeanServer server, MBeanOperationInfo[] opInfo)
- {
- this.server = server;
- this.objectName = objectName;
-
- for (int op = 0; op < opInfo.length; op++)
- {
- MBeanOperationInfo info = opInfo[op];
- String name = info.getName();
-
- if (name.equals(ServiceController.JBOSS_INTERNAL_LIFECYCLE))
- {
- hasJBossInternalLifecycle = true;
- continue;
- }
-
- Integer opID = serviceOpMap.get(name);
- if (opID == null)
- {
- continue;
- }
-
- // Validate that is a no-arg void return type method
- if (info.getReturnType().equals("void") == false)
- {
- continue;
- }
- if (info.getSignature().length != 0)
- {
- continue;
- }
-
- hasOp[opID.intValue()] = true;
- }
- }
-
- /**
- * Map the method name to a Service interface method index and if the
- * corresponding hasOp array element is true, dispatch the method to the
- * mbean we are proxying.
- *
- * @param proxy
- * @param method
- * @param args
- * @return Always null.
- * @throws Throwable
- */
- public Object invoke(Object proxy, Method method, Object[] args)
- throws Throwable
- {
- String name = method.getName();
-
- if (hasJBossInternalLifecycle)
- {
- try
- {
- server.invoke(objectName, ServiceController.JBOSS_INTERNAL_LIFECYCLE, new Object[] { name }, ServiceController.JBOSS_INTERNAL_LIFECYCLE_SIG);
- return null;
- }
- catch (Exception e)
- {
- throw JMXExceptionDecoder.decode(e);
- }
- }
-
- Integer opID = serviceOpMap.get(name);
-
- if (opID != null && hasOp[opID.intValue()] == true)
- {
- // deal with those pesky JMX exceptions
- try
- {
- String[] sig = {};
- server.invoke(objectName, name, args, sig);
- }
- catch (Exception e)
- {
- throw JMXExceptionDecoder.decode(e);
- }
- }
-
- return null;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/ServiceProxy.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,69 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.microcontainer;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.Service;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceController;
-import org.jboss.system.ServiceMBean;
-
-/**
- * StartStopLifecycleAction.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class StartStopLifecycleAction extends ServiceControllerContextAction
-{
- public void installAction(ServiceControllerContext context) throws Throwable
- {
- Service service = context.getServiceProxy();
- service.start();
-
- context.getServiceContext().state = ServiceContext.RUNNING;
-
- ObjectName objectName = context.getObjectName();
- ServiceController serviceController = context.getServiceController();
- serviceController.sendControllerNotification(ServiceMBean.START_EVENT, objectName);
- }
-
- public void uninstallAction(ServiceControllerContext context)
- {
- try
- {
- Service service = context.getServiceProxy();
- service.stop();
-
- context.getServiceContext().state = ServiceContext.STOPPED;
-
- ObjectName objectName = context.getObjectName();
- ServiceController serviceController = context.getServiceController();
- serviceController.sendControllerNotification(ServiceMBean.STOP_EVENT, objectName);
- }
- catch (Throwable t)
- {
- log.debug("Error during stop for " + context.getObjectName(), t);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/microcontainer/StartStopLifecycleAction.java)
Copied: trunk/system-jmx/src/main/org/jboss/system/pm (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm)
Deleted: trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,292 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.pm;
-
-import org.jboss.mx.persistence.AttributePersistenceManager;
-import org.jboss.system.ServiceMBean;
-import org.jboss.system.ServiceMBeanSupport;
-import org.w3c.dom.Element;
-
-/**
- * AttributePersistenceService
- *
- * Works in conjuction with
- * org.jboss.mx.persistence.DelegatingPersistenceManager
- * that upon creation, consults this service for an
- * implementations of the interface
- * org.jboss.mx.persistence.AttributePersistenceManager
- *
- * The service will instantiate and initialize the actual
- * persistence manager and return it whenever asked.
- *
- * It also introduces the notion of a 'version', when
- * creating the persistent manager, so that persisted
- * data from different versions are kept separately.
- *
- * The service can be stopped, the version can be changed
- * and the service re-started, resulting in a new
- * persistent manager being instantiated and all
- * XMBeans created thereafter using this instead.
- *
- * So the goal is really to have a way to plug-in
- * external and manageable persistent managers that
- * that support versioning, too.
- *
- * @jmx:mbean
- * extends="org.jboss.system.ServiceMBean"
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public class AttributePersistenceService
- extends ServiceMBeanSupport
- implements AttributePersistenceServiceMBean
-{
- // Constants -----------------------------------------------------
-
- /** The default AttributePersistenceManager implementation */
- public static final String DEFAULT_APM = "org.jboss.system.pm.XMLAttributePersistenceManager";
-
- /** The default behaviour for destroying the APM when stopping */
- public static final boolean DEFAULT_DESTROY_APM_ON_STOP = false;
-
- // Private Data --------------------------------------------------
-
- /** the actual AttributePersistenceManager (APM) implementation */
- private AttributePersistenceManager apm = null;
-
- /** the APM XML configuration */
- private Element apmConfig = null;
-
- /** the name of the APM implementation class */
- private String apmClass = DEFAULT_APM;
-
- /** whether to destroy() the APM upon stop, or leave it servicing XMBeans that use it */
- private boolean apmDestroyOnStop = DEFAULT_DESTROY_APM_ON_STOP;
-
- /** indicate the active version configured to the APM */
- private String versionTag = null;
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs a <tt>AttributePersistenceService</tt>.
- */
- public AttributePersistenceService()
- {
- // setup logger
- super(AttributePersistenceService.class);
- }
-
- // Attributes ----------------------------------------------------
-
- /**
- * @jmx:managed-attribute
- * @return Returns the versionTag.
- */
- public String getVersionTag()
- {
- return versionTag;
- }
-
- /**
- * @jmx:managed-attribute
- * @param versionTag The versionTag to set.
- */
- public void setVersionTag(String versionTag)
- {
- checkNotStarted();
- this.versionTag = versionTag;
- }
-
- /**
- * @jmx:managed-attribute
- * @return Returns the apmClass.
- */
- public String getAttributePersistenceManagerClass()
- {
- return apmClass;
- }
-
- /**
- * @jmx:managed-attribute
- * @param apmClass The apmClass to set.
- */
- public void setAttributePersistenceManagerClass(String apmClass)
- {
- checkNotStarted();
- this.apmClass = apmClass;
- }
-
- /**
- * @jmx:managed-attribute
- * @return Returns the apmConfig.
- */
- public Element getAttributePersistenceManagerConfig()
- {
- return apmConfig;
- }
-
- /**
- * @jmx:managed-attribute
- * @param apmConfig The apmConfig to set.
- */
- public void setAttributePersistenceManagerConfig(Element apmConfig)
- {
- checkNotStarted();
- this.apmConfig = apmConfig;
- }
-
- /**
- * @jmx:managed-attribute
- * @return Returns the apmDestroyOnStop.
- */
- public boolean getApmDestroyOnServiceStop()
- {
- return apmDestroyOnStop;
- }
- /**
- * @jmx:managed-attribute
- * @param apmDestroyOnStop The apmDestroyOnStop to set.
- */
- public void setApmDestroyOnServiceStop(boolean apmDestroyOnStop)
- {
- checkNotStarted();
- this.apmDestroyOnStop = apmDestroyOnStop;
- }
-
- // ServiceMBeanSupport overrides ---------------------------------
-
- public void startService()
- throws Exception
- {
- // Instantiate the APM trough the MBeanServer
- this.apm = (AttributePersistenceManager)this.getServer().instantiate(this.apmClass);
-
- // Initialize it
- this.apm.create(this.versionTag, this.apmConfig);
- }
-
- public void stopService()
- {
- // if we destroy it non can be used it
- if (this.apmDestroyOnStop) {
- this.apm.destroy();
- }
-
- // forget about this apm
- this.apm = null;
- }
-
- // Operations ----------------------------------------------------
-
- /**
- * @jmx:managed-operation
- */
- public AttributePersistenceManager apmCreate()
- {
- checkStarted();
-
- return this.apm;
- }
-
- /**
- * @jmx:managed-operation
- */
- public boolean apmExists(String id)
- throws Exception
- {
- checkStarted();
-
- return this.apm.exists(id);
- }
-
- /**
- * @jmx:managed-operation
- */
- public void apmRemove(String id)
- throws Exception
- {
- checkStarted();
-
- this.apm.remove(id);
- }
-
- /**
- * @jmx:managed-operation
- */
- public void apmRemoveAll()
- throws Exception
- {
- checkStarted();
-
- this.apm.removeAll();
- }
-
- /**
- * @jmx:managed-operation
- */
- public String[] apmListAll()
- throws Exception
- {
- checkStarted();
-
- return this.apm.listAll();
- }
-
- /**
- * @jmx:managed-operation
- */
- public String apmListAllAsString()
- throws Exception
- {
- checkStarted();
-
- StringBuffer sbuf = new StringBuffer(1024);
- String[] list = this.apm.listAll();
-
- for (int i = 0; i < list.length; i++) {
- sbuf.append(list[i]).append("\n");
- }
- return sbuf.toString();
- }
-
- // Private -------------------------------------------------------
-
- private void checkStarted()
- {
- int state = this.getState();
-
- if (state != ServiceMBean.STARTED) {
- throw new IllegalStateException("Cannot perform operations unless service is started");
- }
- }
-
- private void checkNotStarted()
- {
- int state = this.getState();
-
- if (state == ServiceMBean.STARTING || state == ServiceMBean.STARTED) {
- throw new IllegalStateException("Cannot modify attributes while service is started");
- }
- }
-}
\ No newline at end of file
Copied: trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceService.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,57 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.pm;
-
-/**
- * MBean interface.
- */
-public interface AttributePersistenceServiceMBean extends org.jboss.system.ServiceMBean {
-
- java.lang.String getVersionTag() ;
-
- void setVersionTag(java.lang.String versionTag) ;
-
- java.lang.String getAttributePersistenceManagerClass() ;
-
- void setAttributePersistenceManagerClass(java.lang.String apmClass) ;
-
- org.w3c.dom.Element getAttributePersistenceManagerConfig() ;
-
- void setAttributePersistenceManagerConfig(org.w3c.dom.Element apmConfig) ;
-
- boolean getApmDestroyOnServiceStop() ;
-
- void setApmDestroyOnServiceStop(boolean apmDestroyOnStop) ;
-
- org.jboss.mx.persistence.AttributePersistenceManager apmCreate() ;
-
- boolean apmExists(java.lang.String id) throws java.lang.Exception;
-
- void apmRemove(java.lang.String id) throws java.lang.Exception;
-
- void apmRemoveAll() throws java.lang.Exception;
-
- java.lang.String[] apmListAll() throws java.lang.Exception;
-
- java.lang.String apmListAllAsString() throws java.lang.Exception;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/pm/AttributePersistenceServiceMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,91 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.pm;
-
-import javax.management.AttributeList;
-import org.jboss.mx.persistence.AttributePersistenceManager;
-import org.w3c.dom.Element;
-/**
- * NullAttributePersistenceManager.
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public class NullAttributePersistenceManager
- implements AttributePersistenceManager
-{
- private boolean isCreated = false;
-
- public void create(String version, Element config)
- throws Exception
- {
- isCreated = true;
- }
-
- public boolean getState()
- {
- return isCreated;
- }
-
- public void destroy()
- {
- isCreated = false;
- }
-
- // AttributePersistenceManager Persistence -----------------------
-
- public boolean exists(String id)
- throws Exception
- {
- return false;
- }
-
- public AttributeList load(String id)
- throws Exception
- {
- return null;
- }
-
- public void store(String id, AttributeList attrs)
- throws Exception
- {
- // empty
- }
-
- public void remove(String id)
- throws Exception
- {
- // empty
- }
-
- public void removeAll()
- throws Exception
- {
- // empty
- }
-
- public String[] listAll()
- throws Exception
- {
- return new String[0];
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/pm/NullAttributePersistenceManager.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,950 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.pm;
-
-import java.beans.PropertyEditor;
-import java.beans.PropertyEditorManager;
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.FilenameFilter;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.io.OutputStream;
-import java.io.Serializable;
-import java.net.URL;
-import java.text.SimpleDateFormat;
-import java.util.Collections;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.Map;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.transform.OutputKeys;
-import javax.xml.transform.Result;
-import javax.xml.transform.Source;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.jboss.logging.Logger;
-import org.jboss.mx.persistence.AttributePersistenceManager;
-import org.jboss.system.server.ServerConfigLocator;
-import org.jboss.util.file.Files;
-import org.w3c.dom.Comment;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.Text;
-
-/**
- * XMLAttributePersistenceManager
- *
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
-**/
-public class XMLAttributePersistenceManager
- implements AttributePersistenceManager
-{
- // Constants -----------------------------------------------------
-
- /** The XML configuration element */
- public static final String DATA_DIR_ELEMENT = "data-directory";
-
- /** Default base directory if one not specified */
- public static final String DEFAULT_BASE_DIR = "data/xmbean-attrs";
-
- /** The XML attribute-list elements and attributes */
- public static final String AL_ROOT_ELEMENT = "attribute-list";
- public static final String AL_ID_ATTRIBUTE = "id";
- public static final String AL_DATE_ATTRIBUTE = "date";
- public static final String AL_ATTRIBUTE_ELEMENT = "attribute";
- public static final String AL_NAME_ATTRIBUTE = "name";
- public static final String AL_TYPE_ATTRIBUTE = "type";
- public static final String AL_NULL_ATTRIBUTE = "null";
- public static final String AL_SERIALIZED_ATTRIBUTE = "serialized";
- public static final String AL_TRUE_VALUE = "true";
- public static final String AL_FALSE_VALUE = "false";
-
- // Private Data --------------------------------------------------
-
- /** Logger object */
- private static final Logger log = Logger.getLogger(XMLAttributePersistenceManager.class);
-
- /** used for formating timestamps (date attribute) */
- private static final SimpleDateFormat dateFormat = new SimpleDateFormat("yyyyMMddHHmmss");
-
- /** for byte-to-hex conversions */
- private static final char[] hexDigits = new char[]
- { '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F' };
-
- /** directory as used internally */
- private File dataDir;
-
- /** enable status */
- private boolean state;
-
- /** id to filename cache */
- private Map idMap;
-
- // Constructors -------------------------------------------------
-
- /**
- * Constructs a <tt>FileAttributePersistenceManager</tt>.
- **/
- public XMLAttributePersistenceManager()
- {
- log.debug("Constructed");
- }
-
- // AttributePersistenceManager Lifecycle -------------------------
-
- /**
- * Initializes the AttributePersistenceManager using
- * the supplied configuration element CONFIG_ELEMENT
- * whose content will be probably different for each
- * particular implementation.
- *
- * The version string is a tag that must be used by the
- * AttributePersistenceManager implementation to make
- * sure that data saved/loaded under different version
- * tags are partitioned.
- *
- * Once created, the configuration of the implementation
- * object cannot change.
- *
- * Calling any other method before create() is executed
- * will result in a IllegalStateException
- *
- * Finally, the implementation should be prepared to
- * receive multiple concurrent calls.
- *
- * @param version a tag to identify the version
- * @param config XML Element to load arbitrary config
- * @throws Exception when any error occurs during create
- */
- public void create(String version, Element config)
- throws Exception
- {
- // ignore if already active
- if (getState()) {
- return;
- }
-
- // Decide on the base data directory to use
- String baseDir = null;
-
- if (config == null) {
- baseDir = DEFAULT_BASE_DIR;
- }
- else {
- if (!config.getTagName().equals(DATA_DIR_ELEMENT)) {
- throw new Exception("expected '" + DATA_DIR_ELEMENT +
- "' XML configuration element, got '" +
- config.getTagName() + "'");
- }
- else {
- baseDir = getElementContent(config);
- }
- }
-
- // Initialize the data dir
- this.dataDir = initDataDir(baseDir, version);
-
- log.debug("Using data directory: " + this.dataDir.getCanonicalPath());
-
- // initialize id cache
- this.idMap = Collections.synchronizedMap(new HashMap());
-
- // mark active status
- setState(true);
- }
-
- /**
- * Returns true if the AttributePersistenceManager
- * is "in-service" state, i.e. after create() and
- * before destroy() has been called, false otherwise.
- *
- * @return true if in operational state
- */
- public boolean getState()
- {
- return this.state;
- }
-
- /**
- * Releases resources and destroys the AttributePersistenceManager.
- * The object is unusable after destroy() has been called.
- *
- * Any call to any method will result to an
- * IllegalStateException.
- *
- */
- public void destroy()
- {
- setState(false);
-
- // instance can't be use anymore
- this.dataDir = null;
- this.idMap = null;
- }
-
- // AttributePersistenceManager Persistence -----------------------
-
- /**
- * Uses the specified id to retrieve a previously persisted
- * AttributeList. If no data can be found under the specified
- * id, a null will be returned.
- *
- * @param id the key for retrieving the data
- * @return the data, or null
- * @throws Exception when an error occurs
- */
- public void store(String id, AttributeList attrs)
- throws Exception
- {
- log.debug("store(" + id + ") attrs=" + attrs);
-
- // make sure we are active
- checkActiveState();
-
- // map to filename - keep the original for storing
- String origId = id;
- id = mapId(id);
-
- if (attrs == null)
- throw new Exception("store() called with null AttributeList");
-
- // will throw an exception if file not r/w or it is a directory
- File file = checkFileForWrite(id);
-
- // build the XML in memory using DOM
- DocumentBuilder builder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
- Document doc = builder.newDocument();
-
- // Add a comment
- Comment comment = doc.createComment(" automatically produced by XMLAttributePersistenceManager ");
- doc.appendChild(comment);
-
- // Insert root element
- Element root = doc.createElement(AL_ROOT_ELEMENT);
- root.setAttribute(AL_ID_ATTRIBUTE, origId);
- root.setAttribute(AL_DATE_ATTRIBUTE, dateFormat.format(new Date()));
- doc.appendChild(root);
-
- // iterate over the AttributeList
- for (int i = 0; i < attrs.size(); i++) {
-
- Attribute attr = (Attribute)attrs.get(i);
-
- String name = attr.getName();
- Object value = attr.getValue();
-
- // create the Element and decide how to fill it in
- Element element = doc.createElement(AL_ATTRIBUTE_ELEMENT);
- element.setAttribute(AL_NAME_ATTRIBUTE, name);
-
- if (value == null) {
- // (a) null value - mark it as null
- element.setAttribute(AL_NULL_ATTRIBUTE, AL_TRUE_VALUE);
-
- // append the attribute to the attribute-list
- root.appendChild(element);
- }
- else if (value instanceof org.w3c.dom.Element) {
- // (b) XML Element - mark the type and append a copy of it
- element.setAttribute(AL_TYPE_ATTRIBUTE, "org.w3c.dom.Element");
-
- Node copy = doc.importNode((org.w3c.dom.Element)value, true);
- element.appendChild(copy);
-
- // append the attribute to the attribute-list
- root.appendChild(element);
- }
- else {
- Class clazz = value.getClass();
- String type = clazz.getName();
- PropertyEditor peditor = PropertyEditorManager.findEditor(clazz);
-
- if (peditor != null) {
- // (c) use a PropertyEditor - mark the type and append the value as string
- peditor.setValue(value);
-
- element.setAttribute(AL_TYPE_ATTRIBUTE, type);
- element.appendChild(doc.createTextNode(peditor.getAsText()));
-
- // append the attribute to the attribute-list
- root.appendChild(element);
- }
- else if (value instanceof Serializable) {
- // (d) serialize the object - mark type and serialized attribute
- // - encode the value as stringfied sequence of hex
- String encoded = encodeAsHexString((Serializable)value);
-
- if (encoded != null) {
- element.setAttribute(AL_TYPE_ATTRIBUTE, type);
- element.setAttribute(AL_SERIALIZED_ATTRIBUTE, AL_TRUE_VALUE);
- element.appendChild(doc.createTextNode(encoded));
-
- // append the attribute to the attribute-list
- root.appendChild(element);
- }
- else {
- // could not serialize the object - write and log a warning
- root.appendChild(doc.createComment(
- " WARN <attribute name=\"" + name + "\" type=\"" + type +
- "\"/> could not be serialized "));
-
- log.warn("Could not serialize attribute '" + name +
- "' of type '" + type + "' and value: " + value);
- }
- }
- else {
- // (e) could not find a way to persist - record and log a warning
- root.appendChild(doc.createComment(
- " WARN <attribute name=\"" + name + "\" type=\"" + type +
- "\"/> could not be persisted "));
-
- log.warn("Could not find a way to persist attribute '" + name +
- "' of type '" + type + "' and value: " + value);
- }
- }
- }
-
- // DOM document ready - save it
- try {
- outputXmlFile(doc, file);
- }
- catch (Exception e) {
- log.warn("Cannot persist AttributeList to: \"" + id + "\"", e);
- throw e;
- }
- }
-
- /**
- * Persists an AttributeList (name/value pair list),
- * under a specified id. The id can be used to retrieve the
- * AttributeList later on. The actual mechanism will differ
- * among implementations.
- *
- * @param id the key for retrieving the data later on, not null
- * @param attrs the data to be persisted, not null
- * @throws Exception when data cannot be persisted
- */
- public AttributeList load(String id)
- throws Exception
- {
- log.debug("load(" + id + ")");
-
- // make sure we are active
- checkActiveState();
-
- // map to filename
- id = mapId(id);
-
- if (!getState())
- return null;
-
- // Real stuff starts here
- AttributeList attrs = null;
-
- // returns null to indicate file does not exist
- File file = checkFileForRead(id);
-
- if (file != null) {
- // parse the saved XML doc
- Document doc = parseXmlFile(file);
-
- // top level - look for AL_ROOT_ELEMENT
- NodeList docList = doc.getChildNodes();
- Element root = null;
-
- for (int i = 0; i < docList.getLength(); i++) {
- Node node = docList.item(i);
-
- if (node.getNodeType() == Node.ELEMENT_NODE &&
- node.getNodeName().equals(AL_ROOT_ELEMENT)) {
-
- root = (Element)node;
- break; // found
- }
- }
-
- // root element must be there
- if (root == null) {
- throw new Exception("Expected XML element: " + AL_ROOT_ELEMENT);
- }
- else {
- // proceed iterating over AL_ATTRIBUTE_ELEMENT elements
- // and fill the AttributeList
- attrs = new AttributeList();
-
- NodeList rootList = root.getChildNodes();
-
- for (int i = 0; i < rootList.getLength(); i++) {
- Node node = rootList.item(i);
-
- // only interested in ELEMENT nodes
- if (node.getNodeType() == Node.ELEMENT_NODE &&
- node.getNodeName().equals(AL_ATTRIBUTE_ELEMENT)) {
-
- Element element = (Element)node;
-
- // name attribute must always be there
- String name = element.getAttribute(AL_NAME_ATTRIBUTE);
-
- if (!(name.length() > 0)) {
- throw new Exception("Attribute '" + AL_NAME_ATTRIBUTE +
- "' must be specified for element '" + AL_ATTRIBUTE_ELEMENT + "'");
- }
-
- // Process the attribute depending on how the attributes are set
-
- if (element.getAttribute(AL_NULL_ATTRIBUTE).toLowerCase().equals(AL_TRUE_VALUE)) {
-
- // (a) null value - just add it to the AttributeList
- attrs.add(new Attribute(name, null));
- }
- else if (element.getAttribute(AL_SERIALIZED_ATTRIBUTE).toLowerCase().equals(AL_TRUE_VALUE)) {
-
- // (b) serialized value - decode the HexString
- String hexStr = getElementContent(element);
- Serializable obj = decodeFromHexString(hexStr);
-
- if (obj == null) {
- throw new Exception("Failed to deserialize attribute '" + name + "'");
- }
- else {
- attrs.add(new Attribute(name, obj));
- }
- }
- else {
- String type = element.getAttribute(AL_TYPE_ATTRIBUTE);
-
- // type must be specified
- if (!(type.length() > 0)) {
- throw new Exception("Attribute '" + AL_TYPE_ATTRIBUTE +
- "' must be specified for name='" + name + "'");
- }
-
- if (type.equals("org.w3c.dom.Element")) {
-
- // (c) org.w3c.dom.Element - deep copy first Element child node found
-
- NodeList nlist = element.getChildNodes();
- Element el = null;
-
- for (int j = 0; j < nlist.getLength(); j++) {
-
- Node n = nlist.item(j);
- if (n.getNodeType() == Node.ELEMENT_NODE)
- {
- el = (Element)n;
- break;
- }
- }
-
- if (el != null) {
- attrs.add(new Attribute(name, el.cloneNode(true)));
- }
- else {
- attrs.add(new Attribute(name, null));
- }
- }
- else {
- // Get the classloader for loading attribute classes.
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- Class clazz = null;
-
- try {
- clazz = cl.loadClass(type);
- }
- catch (ClassNotFoundException e) {
- throw new Exception("Class not found for attribute '" + name +
- "' of type '" + type + "'");
- }
-
- PropertyEditor peditor = PropertyEditorManager.findEditor(clazz);
-
- if (peditor != null) {
-
- // (d) use a PropertyEditor - extract the value
-
- String value = getElementContent(element);
- peditor.setAsText(value);
-
- attrs.add(new Attribute(name, peditor.getValue()));
- }
- else {
- throw new Exception("Cannot find a way to load attribute '" + name +
- "' of type '" + type + "'");
- }
- }
- }
- }
- } // end for()
- }
- }
- log.debug("load() returns with: " + attrs);
-
- // will be null if a persistent file was not found
- return attrs;
- }
-
- // Administrative Functions --------------------------------------
-
- /**
- * Checks if a persistened AttributeList for this particular
- * id exists
- *
- * @param id the key of the image
- * @return true if an image exists; false otherwise
- * @throws Exception on any error
- */
- public boolean exists(String id)
- throws Exception
- {
- // make sure we are active
- checkActiveState();
-
- return (new File(this.dataDir, mapId(id))).isFile();
- }
-
- /**
- * Removes the persisted AttributeList, if exists
- *
- * @param id the key of the image
- * @throws Exception when any error occurs
- */
- public void remove(String id)
- throws Exception
- {
- // make sure we are active
- checkActiveState();
-
- (new File(this.dataDir, mapId(id))).delete();
- }
-
- /**
- * Removes all the persisted data stored under
- * the configured version tag.
- *
- * @throws Exception when any error occurs
- */
- public void removeAll()
- throws Exception
- {
- // make sure we are active
- checkActiveState();
-
- String[] files = this.dataDir.list(new XMLFilter());
-
- if (files != null) {
- for (int i = 0; i < files.length; i++) {
- (new File(this.dataDir, files[i])).delete();
- }
- }
- }
-
- /**
- * Returns a String array with all the saved ids
- * under the configured version tag.
- *
- * @return array with all persisted ids
- * @throws Exception when any error occurs
- */
- public String[] listAll()
- throws Exception
- {
- // make sure we are active
- checkActiveState();
-
- String[] files = this.dataDir.list(new XMLFilter());
- String[] result = null;
-
- if (files != null) {
- result = new String[files.length];
-
- for (int i = 0; i < files.length; i++) {
- result[i] = mapFile(files[i]);
- }
- }
- return result;
- }
-
- // Private -------------------------------------------------------
-
- /**
- * Private status setter
- *
- * lifecycle is controlled by create() and destroy()
- */
- private void setState(boolean state)
- {
- this.state = state;
- }
-
- /**
- * Create/check/point to the data directory.
- *
- * Process the base dir first and append the versionTag dir
- * if specified.
- *
- * Only a base dir relative to ServerHomeDir is created.
- * External base dirs are only used (i.e. they must exist
- * and we must read/write permission)
- */
- private File initDataDir(String baseDir, String versionTag)
- throws Exception
- {
- File dir = null;
-
- // Process the base directory first
-
- // baseDir must be valid URL pointing to r/w dir
- try {
- URL fileURL = new URL(baseDir);
-
- File file = new File(fileURL.getFile());
-
- if(file.isDirectory() && file.canRead() && file.canWrite()) {
- dir = file;
- }
- }
- catch(Exception e) {
- // Otherwise, try to make it inside the jboss directory hierarchy
-
- File homeDir = ServerConfigLocator.locate().getServerHomeDir();
-
- dir = new File(homeDir, baseDir);
-
- dir.mkdirs();
-
- if (!dir.isDirectory())
- throw new Exception("The base directory is not valid: "
- + dir.getCanonicalPath());
- }
-
- // Now add the versionTag dir, if specified
- if (versionTag != null && !versionTag.equals("")) {
- dir = new File(dir, versionTag);
-
- dir.mkdirs();
-
- if (!dir.isDirectory())
- throw new Exception("The data directory is not valid: "
- + dir.getCanonicalPath());
- }
- return dir;
- }
-
- /**
- * Serialize an object as a Hex string so it can be saved as text
- *
- * The length of the encoded object is twice it's byte image
- *
- * Returns null if serialization fails
- */
- private String encodeAsHexString(Serializable obj)
- {
- String retn = null;
-
- if (obj != null) {
- try {
- ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
- ObjectOutputStream oos = new ObjectOutputStream(baos);
-
- oos.writeObject(obj);
- byte[] bytes = baos.toByteArray();
-
- StringBuffer sbuf = new StringBuffer(1024);
-
- for (int i = 0; i < bytes.length; i++) {
- sbuf.append(hexDigits[ (bytes[i] >> 4) & 0xF ]); // high order digit
- sbuf.append(hexDigits[ (bytes[i] ) & 0xF ]); // low order digit
- }
-
- retn = sbuf.toString();
- }
- catch (IOException e) {
- // will return null
- }
- }
- return retn;
- }
-
- /**
- * Deserialize an object from its hex encoded string representation
- *
- * Returns null if deserialization fails
- */
- private Serializable decodeFromHexString(String hexStr)
- {
- // hexStr must not contain white space!
- int len = hexStr.length() / 2;
- byte[] bytes = new byte[len];
-
- for (int i = 0; i < len; i++) {
-
- char h1 = hexStr.charAt(i * 2); // high order hex digit
- char h2 = hexStr.charAt(i * 2 + 1); // low order hex digit
-
- // convert hex digits to integers
- int d1 = (h1 >= 'a') ? (10 + h1 - 'a')
- : ((h1 >= 'A') ? (10 + h1 - 'A')
- : (h1 - '0'));
-
- int d2 = (h2 >= 'a') ? (10 + h2 - 'a')
- : ((h2 >= 'A') ? (10 + h2 - 'A')
- : (h2 - '0'));
-
- bytes[i] = (byte)(d1 * 16 + d2); // 255 max
- }
-
- Serializable retn = null;
-
- try {
- ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
- ObjectInputStream ois = new ObjectInputStream(bais);
-
- retn = (Serializable)ois.readObject();
- }
- catch (IOException e) {
- log.warn("Cannot deserialize object", e); }
- catch (ClassNotFoundException e) {
- log.warn("Cannot deserialize object", e);
- }
-
- return retn;
- }
-
- /**
- * Just output a DOM Document to a file with
- * indentation true
- */
- private void outputXmlFile(Document doc, File file)
- throws Exception
- {
- // Prepare the DOM document for writing
- Source source = new DOMSource(doc);
-
- // Use an OutputStream rather than a File
- OutputStream out = new FileOutputStream(file);
-
- // Prepare the output
- Result result = new StreamResult(out);
-
- // Write the DOM document to the file
- Transformer xformer = TransformerFactory.newInstance().newTransformer();
-
- // Enable indentation
- xformer.setOutputProperty(OutputKeys.INDENT, "yes");
-
- try
- {
- xformer.transform(source, result);
- }
- finally
- {
- // Cleanup
- out.close();
- }
- }
-
- /**
- * Parse an XML file into a DOM Document
- * with validation set to false
- */
- private Document parseXmlFile(File file)
- throws Exception
- {
- // Create a builder factory
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
-
- // do not request validation against DTD
- // no DTD specified in the saved document
- factory.setValidating(false);
-
- // The builder and document to return
- DocumentBuilder builder = factory.newDocumentBuilder();
- Document doc;
-
- // Use an InputStreamer rather than a File when parsing,
- // to avoid pathname encoding problems, like spaces in
- // the pathname encoded as %20
- InputStream in = new FileInputStream(file);
- try
- {
- // Parse the file
- doc = builder.parse(in);
- }
- finally
- {
- // close anyways
- in.close();
- }
- // Return the parsed document
- return doc;
- }
-
- /**
- * Makes sure we can write to this file
- */
- private File checkFileForWrite(String filename)
- throws Exception
- {
- File file = new File(this.dataDir, filename);
-
- if (file.isFile()) {
- if (file.canRead() && file.canWrite()) {
- return file; // everything fine
- }
- else {
- throw new Exception("file '" + filename + "' is not r/w"); // oops
- }
- }
- else if (file.isDirectory()) {
- throw new Exception(filename + " is a directory!"); // oops
- }
- else {
- return file; // not found - ok
- }
- }
-
- /**
- * Makes sure we can read from this file.
- *
- * Returns null if not found
- */
- private File checkFileForRead(String filename)
- throws Exception
- {
- File file = new File(this.dataDir, filename);
-
- if (file.isFile()) {
- if (file.canRead() && file.canWrite()) {
- return file; // everything fine
- }
- else {
- throw new Exception("file '" + filename + "' is not r/w"); // oops
- }
- }
- else if (file.isDirectory()) {
- throw new Exception(filename + " is a directory!"); // oops
- }
- else {
- return null; // not found
- }
- }
-
- /**
- * Returns the concatenated content of all
- * children TEXT nodes of this element
- */
- private String getElementContent(Element element)
- {
- NodeList nlist = element.getChildNodes();
-
- StringBuffer sbuf = new StringBuffer(1024);
-
- // concatenate Text nodes
- for (int i = 0; i < nlist.getLength(); i++) {
- Node node = nlist.item(i);
-
- if (node.getNodeType() == Node.TEXT_NODE) {
- sbuf.append(((Text)node).getData());
- }
- }
- return sbuf.toString();
- }
-
- /**
- * Make sure we are active before processing a call
- */
- private void checkActiveState()
- {
- if (!getState()) {
- throw new IllegalStateException("AttributePersistenceManager not active");
- }
- }
-
- /**
- * Simple filter for .xml files in a directory listing
- */
- private class XMLFilter
- implements FilenameFilter
- {
- public boolean accept(File dir, String name)
- {
- return name.endsWith(".xml");
- }
- }
-
- /**
- * Map the id to a filename and cache it
- *
- * A null id results in an exception thrown
- */
- private String mapId(String id)
- throws Exception
- {
- if (id == null) {
- throw new Exception("called with null id");
- }
- else {
- // check the cache
- String file = (String)this.idMap.get(id);
-
- // if not in cache encode, and cache it
- if (file == null) {
- file = Files.encodeFileName(id) + ".xml";
- this.idMap.put(id, file);
- }
- return file;
- }
- }
-
- /**
- * Do the reverse mapping file to id
- */
- private String mapFile(String file)
- {
- if (file == null) {
- return null;
- }
- else {
- // remove .xml suffix
- file = file.substring(0, file.length() - 4);
-
- return Files.decodeFileName(file);
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/pm/XMLAttributePersistenceManager.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/system-jmx/src/main/org/jboss/system/server (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server)
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,190 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server;
-
-import java.io.File;
-import java.net.URL;
-
-/**
- * An mbean wrapper for the BaseServerConfig that exposes the config as the
- * legacy ServerConfigImplMBean.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class ServerConfigImpl
- implements ServerConfigImplMBean
-{
- private ServerConfig config;
-
- /**
- * Construct a ServerConfigImpl with the ServerConfig pojo which will be used
- * as the delegate for the ServerConfigImplMBean ops.
- *
- * @param config - the ServerConfig pojo to expose as a ServerConfigImplMBean
- */
- public ServerConfigImpl(ServerConfig config)
- {
- this.config = config;
- }
-
- public ServerConfig getConfig()
- {
- return config;
- }
-
- public boolean equals(Object obj)
- {
- return config.equals(obj);
- }
-
- public boolean getBlockingShutdown()
- {
- return config.getBlockingShutdown();
- }
-
- public boolean getExitOnShutdown()
- {
- return config.getExitOnShutdown();
- }
-
- public File getHomeDir()
- {
- return config.getHomeDir();
- }
-
- public URL getHomeURL()
- {
- return config.getHomeURL();
- }
-
- public URL getLibraryURL()
- {
- return config.getLibraryURL();
- }
-
- public URL getPatchURL()
- {
- return config.getPatchURL();
- }
-
- public boolean getPlatformMBeanServer()
- {
- return config.getPlatformMBeanServer();
- }
-
- public boolean getRequireJBossURLStreamHandlerFactory()
- {
- return config.getRequireJBossURLStreamHandlerFactory();
- }
-
- public String getRootDeploymentFilename()
- {
- return config.getRootDeploymentFilename();
- }
-
- public File getServerBaseDir()
- {
- return config.getServerBaseDir();
- }
-
- public URL getServerBaseURL()
- {
- return config.getServerBaseURL();
- }
-
- public URL getServerConfigURL()
- {
- return config.getServerConfigURL();
- }
-
- public File getServerDataDir()
- {
- return config.getServerDataDir();
- }
-
- public File getServerHomeDir()
- {
- return config.getServerHomeDir();
- }
-
- public URL getServerHomeURL()
- {
- return config.getServerHomeURL();
- }
-
- public URL getServerLibraryURL()
- {
- return config.getServerLibraryURL();
- }
-
- public File getServerLogDir()
- {
- return config.getServerLogDir();
- }
-
- public String getServerName()
- {
- return config.getServerName();
- }
-
- public File getServerNativeDir()
- {
- return config.getServerNativeDir();
- }
-
- public File getServerTempDeployDir()
- {
- return config.getServerTempDeployDir();
- }
-
- public File getServerTempDir()
- {
- return config.getServerTempDir();
- }
-
- public int hashCode()
- {
- return config.hashCode();
- }
-
- public void setBlockingShutdown(boolean flag)
- {
- config.setBlockingShutdown(flag);
- }
-
- public void setExitOnShutdown(boolean flag)
- {
- config.setExitOnShutdown(flag);
- }
-
- public void setRequireJBossURLStreamHandlerFactory(boolean flag)
- {
- config.setRequireJBossURLStreamHandlerFactory(flag);
- }
-
- public void setRootDeploymentFilename(String filename)
- {
- config.setRootDeploymentFilename(filename);
- }
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImpl.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,190 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server;
-
-import java.io.File;
-import java.net.URL;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface ServerConfigImplMBean
-{
- /** Default ObjectName */
- static final ObjectName OBJECT_NAME =
- ObjectNameFactory.create("jboss.system:type=ServerConfig");
-
- /**
- * Get the local home directory which the server is running from.
- */
- File getHomeDir();
-
- /**
- * Get the home URL which the server is running from.
- */
- URL getHomeURL();
-
- /**
- * Get the home URL which the server is running from.
- */
- URL getLibraryURL();
-
- /**
- * Get the patch URL for the server.
- */
- URL getPatchURL();
-
- /**
- * Get the name of the server.
- */
- String getServerName();
-
- /**
- * Get the base directory for calculating server home directories.
- */
- File getServerBaseDir();
-
- /**
- * Get the server home directory.
- */
- File getServerHomeDir();
-
- /**
- * Get the directory where log files will be stored.
- * @return the writable log directory
- */
- java.io.File getServerLogDir();
-
- /**
- * Get the directory where temporary files will be stored.
- */
- File getServerTempDir();
-
- /**
- * Get the directory where local data will be stored.
- */
- File getServerDataDir();
-
- /**
- * Get the base directory for calculating server home URLs.
- */
- URL getServerBaseURL();
-
- /**
- * Get the server home URL.
- */
- URL getServerHomeURL();
-
- /**
- * Get the server library URL.
- */
- URL getServerLibraryURL();
-
- /**
- * Get the server configuration URL.
- */
- URL getServerConfigURL();
-
- /**
- * Get the current value of the flag that indicates if we are
- * using the platform MBeanServer as the main jboss server.
- * Both the {@link ServerConfig.PLATFORM_MBEANSERVER}
- * property must be set, and the jvm must be jdk1.5+
- */
- boolean getPlatformMBeanServer();
-
- /**
- * Enable or disable exiting the JVM when {@link Server#shutdown}
- * is called. If enabled, then shutdown calls {@link Server#exit}.
- * If disabled, then only the shutdown hook will be run.
- * @param flag True to enable calling exit on shutdown.
- */
- void setExitOnShutdown(boolean flag);
-
- /**
- * Get the current value of the exit on shutdown flag.
- * @return The current value of the exit on shutdown flag.
- */
- boolean getExitOnShutdown();
-
- /**
- * Enable or disable blocking when {@link Server#shutdown} is called.
- * If enabled, then shutdown will be called in the current thread.
- * If disabled, then the shutdown hook will be run ansynchronously
- * in a separate thread.
- * @param flag True to enable blocking shutdown.
- */
- void setBlockingShutdown(boolean flag);
-
- /**
- * Get the current value of the blocking shutdown flag.
- * @return The current value of the blocking shutdown flag.
- */
- boolean getBlockingShutdown();
-
- /**
- * Set the RequireJBossURLStreamHandlerFactory flag. if false,
- * exceptions when setting the URLStreamHandlerFactory will
- * be logged and ignored.
- * @param flag True to enable blocking shutdown.
- */
- void setRequireJBossURLStreamHandlerFactory(boolean flag);
-
- /**
- * Get the current value of the requireJBossURLStreamHandlerFactory flag.
- * @return The current value of the requireJBossURLStreamHandlerFactory flag.
- */
- boolean getRequireJBossURLStreamHandlerFactory();
-
- /**
- * Set the filename of the root deployable that will be used to
- * finalize the bootstrap process.
- * @param filename The filename of the root deployable.
- */
- void setRootDeploymentFilename(String filename);
-
- /**
- * Get the filename of the root deployable that will be used to
- * finalize the bootstrap process.
- * @return The filename of the root deployable.
- */
- String getRootDeploymentFilename();
-
- /**
- * Get the native dir for unpacking
- *
- * @return the directory
- */
- File getServerNativeDir() ;
-
- /**
- * Get the temporary deployment dir for unpacking
- *
- * @return the directory
- */
- File getServerTempDeployDir() ;
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigImplMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,47 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server;
-
-import org.jboss.mx.util.MBeanProxyExt;
-
-/**
- * A helper for locating the {@link ServerConfig} instance
- * for the running server.
- *
- * @version <tt>$Revision$</tt>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- */
-public class ServerConfigLocator
-{
- private static volatile ServerConfig instance = null;
-
- public static ServerConfig locate()
- {
- if (instance == null) {
- instance = (ServerConfig)
- MBeanProxyExt.create(ServerConfig.class,
- ServerConfigImplMBean.OBJECT_NAME);
- }
-
- return instance;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/server/ServerConfigLocator.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/ServerImpl.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/ServerImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,1114 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system.server;
-
-import java.io.File;
-import java.lang.reflect.Method;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Properties;
-import java.util.logging.LogManager;
-
-import javax.management.Attribute;
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanServer;
-import javax.management.MBeanServerFactory;
-import javax.management.Notification;
-import javax.management.NotificationEmitter;
-import javax.management.NotificationFilter;
-import javax.management.NotificationListener;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-
-import org.jboss.Version;
-import org.jboss.deployment.IncompleteDeploymentException;
-import org.jboss.deployment.MainDeployerMBean;
-import org.jboss.logging.JBossJDKLogManager;
-import org.jboss.logging.Logger;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.mx.util.MBeanServerLocator;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.net.protocol.URLStreamHandlerFactory;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.system.server.jmx.LazyMBeanServer;
-import org.jboss.util.StopWatch;
-import org.jboss.util.file.FileSuffixFilter;
-import org.jboss.util.file.Files;
-
-/**
- * The main container component of a JBoss server instance.
- *
- * <h3>Concurrency</h3>
- * This class is <b>not</b> thread-safe.
- *
- * @jmx:mbean name="jboss.system:type=Server"
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision$
- */
-public class ServerImpl
- implements Server, ServerImplMBean, NotificationEmitter
-{
- private final static ObjectName DEFAULT_LOADER_NAME =
- ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
-
- /** Instance logger. */
- private Logger log;
-
- /** Container for version information. */
- private final Version version = Version.getInstance();
-
- /** Package information for org.jboss */
- private final Package jbossPackage = Package.getPackage("org.jboss");
-
- /** The basic configuration for the server. */
- private ServerConfigImpl config;
-
- /** The JMX MBeanServer which will serve as our communication bus. */
- private MBeanServer server;
-
- /** When the server was started. */
- private Date startDate;
-
- /** Flag to indicate if we are started. */
- private boolean started;
-
- /** The JVM shutdown hook */
- private ShutdownHook shutdownHook;
-
- /** The JBoss Life Thread */
- private LifeThread lifeThread;
-
- /** The NotificationBroadcaster implementation delegate */
- private JBossNotificationBroadcasterSupport broadcasterSupport;
-
- /** The bootstrap UCL class loader ObjectName */
- private ObjectName bootstrapUCLName;
- /** A flag indicating if shutdown has been called */
- private boolean isInShutdown;
-
- /**
- * No-arg constructor for {@link ServerLoader}.
- */
- public ServerImpl()
- {
- }
-
- /**
- * Initialize the Server instance.
- *
- * @param props The configuration properties for the server.
- *
- * @throws IllegalStateException Already initialized.
- * @throws Exception Failed to initialize.
- */
- public void init(final Properties props) throws IllegalStateException, Exception
- {
- if (props == null)
- throw new IllegalArgumentException("props is null");
- if (config != null)
- throw new IllegalStateException("already initialized");
-
- ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
-
- try
- {
- Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
- doInit(props);
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(oldCL);
- }
- }
-
- /** Actually does the init'ing... */
- private void doInit(final Properties props) throws Exception
- {
- // Create a new config object from the give properties
- BaseServerConfig baseConfig = new BaseServerConfig(props);
- this.config = new ServerConfigImpl(baseConfig);
-
- /* Initialize the logging layer using the Server.class. The server log
- directory is initialized prior to this to ensure the jboss.server.log.dir
- system property is set in case its used by the logging configs.
- */
- config.getServerLogDir();
- log = Logger.getLogger(Server.class);
-
- // Create the NotificationBroadcaster delegate
- broadcasterSupport = new JBossNotificationBroadcasterSupport();
-
- // Set the VM temp directory to the server tmp dir
- boolean overrideTmpDir = Boolean.getBoolean("jboss.server.temp.dir.overrideJavaTmpDir");
- if( overrideTmpDir )
- {
- File serverTmpDir = config.getServerTempDir();
- System.setProperty("java.io.tmpdir", serverTmpDir.getCanonicalPath());
- }
-
- // Setup URL handlers - do this before initializing the ServerConfig
- initURLHandlers();
- baseConfig.initURLs();
-
- log.info("Starting JBoss (MX MicroKernel)...");
-
- if (jbossPackage != null)
- {
- // Show what release this is...
- log.info("Release ID: " +
- jbossPackage.getImplementationTitle() + " " +
- jbossPackage.getImplementationVersion());
- }
- else
- {
- log.warn("could not get package info to display release, either the " +
- "jar manifest in jboss-system.jar has been mangled or you're " +
- "running unit tests from ant outside of JBoss itself.");
- }
-
- log.debug("Using config: " + config);
-
- // make sure our impl type is exposed
- log.debug("Server type: " + getClass());
-
- // log the boot classloader
- ClassLoader cl = getClass().getClassLoader();
- log.debug("Server loaded through: " + cl.getClass().getName());
-
- // log the boot URLs
- if (cl instanceof NoAnnotationURLClassLoader)
- {
- NoAnnotationURLClassLoader nacl = (NoAnnotationURLClassLoader)cl;
- URL[] bootURLs = nacl.getAllURLs();
- log.debug("Boot URLs:");
- for (int i = 0; i < bootURLs.length; i++)
- {
- log.debug(" " + bootURLs[i]);
- }
- }
-
- // Log the basic configuration elements
- log.info("Home Dir: " + config.getHomeDir());
- log.info("Home URL: " + config.getHomeURL());
- log.debug("Library URL: " + config.getLibraryURL());
- log.info("Patch URL: " + config.getPatchURL());
- log.info("Server Name: " + config.getServerName());
- log.info("Server Home Dir: " + config.getServerHomeDir());
- log.info("Server Home URL: " + config.getServerHomeURL());
- log.debug("Server Data Dir: " + config.getServerDataDir());
- log.info("Server Temp Dir: " + config.getServerTempDir());
- log.debug("Server Config URL: " + config.getServerConfigURL());
- log.debug("Server Library URL: " + config.getServerLibraryURL());
- log.info("Root Deployment Filename: " + config.getRootDeploymentFilename());
- }
-
- /**
- * The <code>initURLHandlers</code> method calls
- * internalInitURLHandlers. if requireJBossURLStreamHandlers is
- * false, any exceptions are logged and ignored.
- *
- */
- private void initURLHandlers()
- {
- if (config.getRequireJBossURLStreamHandlerFactory())
- {
- internalInitURLHandlers();
- } // end of if ()
- else
- {
- try
- {
- internalInitURLHandlers();
- }
- catch (SecurityException e)
- {
- log.warn("You do not have permissions to set URLStreamHandlerFactory", e);
- } // end of try-catch
- catch (Error e)
- {
- log.warn("URLStreamHandlerFactory already set", e);
- } // end of catch
- } // end of else
- }
-
- /**
- * Set up our only URLStreamHandlerFactory.
- * This is needed to ensure Sun's version is not used (as it leaves files
- * locked on Win2K/WinXP platforms.
- */
- private void internalInitURLHandlers()
- {
- try
- {
- // Install a URLStreamHandlerFactory that uses the TCL
- URL.setURLStreamHandlerFactory(new URLStreamHandlerFactory());
-
- // Preload JBoss URL handlers
- URLStreamHandlerFactory.preload();
- }
- catch (Error error)
- { //very naughty but we HAVE to do this or
- //we'll fail if we ever try to do this again
- log.warn("Caught Throwable Error, this probably means " +
- "we've already set the URLStreamHAndlerFactory before");
- //Sys.out because we don't have logging yet
- }
-
- // Include the default JBoss protocol handler package
- String handlerPkgs = System.getProperty("java.protocol.handler.pkgs");
- if (handlerPkgs != null)
- {
- handlerPkgs += "|org.jboss.net.protocol";
- }
- else
- {
- handlerPkgs = "org.jboss.net.protocol";
- }
- System.setProperty("java.protocol.handler.pkgs", handlerPkgs);
- }
-
- /**
- * Get the typed server configuration object which the
- * server has been initalized to use.
- *
- * @return Typed server configuration object.
- *
- * @throws IllegalStateException Not initialized.
- */
- public ServerConfig getConfig() throws IllegalStateException
- {
- if (config == null)
- throw new IllegalStateException("not initialized");
-
- return config.getConfig();
- }
-
- /**
- * Check if the server is started.
- *
- * @return True if the server is started, else false.
- * @jmx:managed-attribute
- */
- public boolean isStarted()
- {
- return started;
- }
-
- /**
- Check if the shutdown operation has been called/is in progress.
-
- @return true if shutdown has been called, false otherwise
- */
- public boolean isInShutdown()
- {
- return isInShutdown;
- }
-
- /**
- * Start the Server instance.
- *
- * @throws IllegalStateException Already started or not initialized.
- * @throws Exception Failed to start.
- */
- public void start() throws IllegalStateException, Exception
- {
- // make sure we are initialized
- getConfig();
-
- // make sure we aren't started yet
- if (started)
- throw new IllegalStateException("already started");
-
- ClassLoader oldCL = Thread.currentThread().getContextClassLoader();
-
- try
- {
- Thread.currentThread().setContextClassLoader(getClass().getClassLoader());
-
- // Deal with those pesky JMX throwables
- try
- {
- doStart();
- }
- catch (Exception e)
- {
- JMXExceptionDecoder.rethrow(e);
- }
- }
- catch (Throwable t)
- {
- log.debug("Failed to start", t);
-
- if (t instanceof Exception)
- throw (Exception)t;
- if (t instanceof Error)
- throw (Error)t;
-
- throw new org.jboss.util.UnexpectedThrowable(t);
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(oldCL);
- }
- }
-
- /** Actually does the starting... */
- private void doStart() throws Exception
- {
- // See how long it takes us to start up
- StopWatch watch = new StopWatch(true);
-
- // remeber when we we started
- startDate = new Date();
-
- log.debug("Starting General Purpose Architecture (GPA)...");
-
- // Create the MBeanServer
- String builder = System.getProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY,
- ServerConstants.DEFAULT_MBEAN_SERVER_BUILDER_CLASS);
- System.setProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY, builder);
-
- // Check if we'll use the platform MBeanServer or instantiate our own
- if (config.getPlatformMBeanServer() == true)
- {
- // jdk1.5+
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- Class clazz = cl.loadClass("java.lang.management.ManagementFactory");
- Method method = clazz.getMethod("getPlatformMBeanServer", null);
- server = (MBeanServer)method.invoke(null, null);
- // Tell the MBeanServerLocator to point to this server
- MBeanServerLocator.setJBoss(server);
- /* If the LazyMBeanServer was used, we need to reset to the jboss
- MBeanServer to use our implementation for the jboss services.
- */
- server = LazyMBeanServer.resetToJBossServer(server);
- }
- else
- {
- // Create our own MBeanServer
- server = MBeanServerFactory.createMBeanServer("jboss");
- }
- log.debug("Created MBeanServer: " + server);
-
- // Register server components
- server.registerMBean(this, ServerImplMBean.OBJECT_NAME);
- server.registerMBean(config, ServerConfigImplMBean.OBJECT_NAME);
-
- // Initialize spine boot libraries
- RepositoryClassLoader ucl = initBootLibraries();
- bootstrapUCLName = ucl.getObjectName();
- server.registerMBean(ucl, bootstrapUCLName);
-
- // Set ServiceClassLoader as classloader for the construction of
- // the basic system
- Thread.currentThread().setContextClassLoader(ucl);
-
- // General Purpose Architecture information
- createMBean("org.jboss.system.server.ServerInfo",
- "jboss.system:type=ServerInfo");
-
- // Service Controller
- ObjectName controller = createMBean("org.jboss.system.ServiceController",
- "jboss.system:service=ServiceController");
-
- // Main Deployer
- ObjectName mainDeployer = startBootService(controller,
- "org.jboss.deployment.MainDeployer", "jboss.system:service=MainDeployer");
- server.setAttribute(mainDeployer,
- new Attribute("ServiceController", controller));
-
- // Install the shutdown hook
- shutdownHook = new ShutdownHook(controller, mainDeployer);
- shutdownHook.setDaemon(true);
-
- try
- {
- Runtime.getRuntime().addShutdownHook(shutdownHook);
- log.debug("Shutdown hook added");
- }
- catch (Exception e)
- {
- log.warn("Failed to add shutdown hook; ignoring", e);
- }
-
- // JARDeployer, required to process <classpath>
- startBootService(controller, "org.jboss.deployment.JARDeployer",
- "jboss.system:service=JARDeployer");
-
- // SARDeployer, required to process *-service.xml
- startBootService(controller, "org.jboss.deployment.SARDeployer",
- "jboss.system:service=ServiceDeployer");
-
- log.info("Core system initialized");
-
- // Ok, now deploy the root deployable to finish the job
-
- MainDeployerMBean md = (MainDeployerMBean)
- MBeanProxyExt.create(MainDeployerMBean.class, mainDeployer, server);
-
- try
- {
- md.deploy(config.getServerConfigURL() + config.getRootDeploymentFilename());
- }
- catch (IncompleteDeploymentException e)
- {
- log.error("Root deployment has missing dependencies; continuing", e);
- }
-
- lifeThread = new LifeThread();
- lifeThread.start();
-
- started = true;
-
- // Send a notification that the startup is complete
- Notification msg = new Notification(START_NOTIFICATION_TYPE, this, 1);
- msg.setUserData(new Long(watch.getLapTime()));
- sendNotification(msg);
-
- watch.stop();
-
- if (jbossPackage != null)
- {
- // Tell the world how fast it was =)
- log.info("JBoss (MX MicroKernel) [" + jbossPackage.getImplementationVersion() +
- "] Started in " + watch);
- }
- else
- {
- log.warn("could not get package info to display release, either the " +
- "jar manifest in jboss-boot.jar has been mangled or you're " +
- "running unit tests from ant outside of JBoss itself.");
- }
- }
-
- /**
- * Instantiate and register a service for the given classname into the MBean server.
- */
- private ObjectName createMBean(final String classname, String name)
- throws Exception
- {
- ObjectName mbeanName = null;
- if( name != null )
- mbeanName = new ObjectName(name);
- try
- {
- // See if there is an xmbean descriptor for the bootstrap mbean
- URL xmbeanDD = new URL("resource:xmdesc/"+classname+"-xmbean.xml");
- Object resource = server.instantiate(classname);
- // Create the XMBean
- Object[] args = {resource, xmbeanDD};
- String[] sig = {Object.class.getName(), URL.class.getName()};
- ObjectInstance instance = server.createMBean("org.jboss.mx.modelmbean.XMBean",
- mbeanName,
- bootstrapUCLName,
- args,
- sig);
- mbeanName = instance.getObjectName();
- log.debug("Created system XMBean: "+mbeanName);
- }
- catch(Exception e)
- {
- log.debug("Failed to create xmbean for: "+classname);
- mbeanName = server.createMBean(classname, mbeanName).getObjectName();
- log.debug("Created system MBean: " + mbeanName);
- }
-
- return mbeanName;
- }
-
- /**
- * Instantiate/register, create and start a service for the given classname.
- */
- private ObjectName startBootService(final ObjectName controllerName,
- final String classname, final String name)
- throws Exception
- {
- ObjectName mbeanName = createMBean(classname, name);
-
- // now go through the create/start sequence on the new service
-
- Object[] args = { mbeanName };
- String[] sig = { ObjectName.class.getName() };
-
- server.invoke(controllerName, "create", args, sig);
- server.invoke(controllerName, "start", args, sig);
-
- return mbeanName;
- }
-
- /**
- * Initialize the boot libraries.
- */
- private RepositoryClassLoader initBootLibraries() throws Exception
- {
- // Build the list of URL for the spine to boot
- List list = new ArrayList();
-
- // Add the patch URL. If the url protocol is file, then
- // add the contents of the directory it points to
- URL patchURL = config.getPatchURL();
- if (patchURL != null)
- {
- if (patchURL.getProtocol().equals("file"))
- {
- File dir = new File(patchURL.getFile());
- if (dir.exists())
- {
- // Add the local file patch directory
- list.add(dir.toURL());
-
- // Add the contents of the directory too
- File[] jars = dir.listFiles(new FileSuffixFilter(new String[] { ".jar", ".zip" }, true));
-
- for (int j = 0; jars != null && j < jars.length; j++)
- {
- list.add(jars[j].getCanonicalFile().toURL());
- }
- }
- }
- else
- {
- list.add(patchURL);
- }
- }
-
- // Add the server configuration directory to be able to load config files as resources
- list.add(config.getServerConfigURL());
-
- // Not needed, ServerImpl will have the basics on its classpath from ServerLoader
- // may want to bring this back at some point if we want to have reloadable core
- // components...
-
- // URL libraryURL = config.getLibraryURL();
- // list.add(new URL(libraryURL, "jboss-spine.jar"));
-
- log.debug("Boot url list: " + list);
-
- // Create loaders for each URL
- RepositoryClassLoader loader = null;
- for (Iterator iter = list.iterator(); iter.hasNext();)
- {
- URL url = (URL)iter.next();
- log.debug("Creating loader for URL: " + url);
-
- // This is a boot URL, so key it on itself.
- Object[] args = {url, Boolean.TRUE};
- String[] sig = {"java.net.URL", "boolean"};
- loader = (RepositoryClassLoader) server.invoke(DEFAULT_LOADER_NAME, "newClassLoader", args, sig);
- }
- return loader;
- }
-
- /**
- * Shutdown the Server instance and run shutdown hooks.
- *
- * <p>If the exit on shutdown flag is true, then {@link #exit}
- * is called, else only the shutdown hook is run.
- *
- * @jmx:managed-operation
- *
- * @throws IllegalStateException No started.
- */
- public void shutdown() throws IllegalStateException
- {
- if (log.isTraceEnabled())
- log.trace("Shutdown caller:", new Throwable("Here"));
-
- if (!started)
- throw new IllegalStateException("Server not started");
-
- isInShutdown = true;
- boolean exitOnShutdown = config.getExitOnShutdown();
- boolean blockingShutdown = config.getBlockingShutdown();
- log.info("Shutting down the server, blockingShutdown: " + blockingShutdown);
-
- if (exitOnShutdown)
- {
- exit(0);
- }
- else
- {
- // signal lifethread to exit; if no non-daemon threads
- // remain, the JVM will eventually exit
- lifeThread.interrupt();
-
- if (blockingShutdown)
- {
- shutdownHook.shutdown();
- }
- else
- {
- // start in new thread to give positive
- // feedback to requesting client of success.
- new Thread()
- {
- public void run()
- {
- // just run the hook, don't call System.exit, as we may
- // be embeded in a vm that would not like that very much
- shutdownHook.shutdown();
- }
- }.start();
- }
- }
- }
-
- /**
- * Exit the JVM, run shutdown hooks, shutdown the server.
- *
- * @jmx:managed-operation
- *
- * @param exitcode The exit code returned to the operating system.
- */
- public void exit(final int exitcode)
- {
- // exit() in new thread so that we might have a chance to give positive
- // feed back to requesting client of success.
- new Thread()
- {
- public void run()
- {
- log.info("Server exit(" + exitcode + ") called");
-
- // Set exit code in the shutdown hook, in case halt is enabled
- shutdownHook.setHaltExitCode(exitcode);
-
- // Initiate exiting, shutdown hook will be called
- Runtime.getRuntime().exit(exitcode);
- }
- }.start();
- }
-
- /**
- * Exit the JVM with code 1, run shutdown hooks, shutdown the server.
- *
- * @jmx:managed-operation
- */
- public void exit()
- {
- exit(1);
- }
-
- /**
- * Forcibly terminates the currently running Java virtual machine.
- *
- * @param exitcode The exit code returned to the operating system.
- *
- * @jmx:managed-operation
- */
- public void halt(final int exitcode)
- {
- // halt() in new thread so that we might have a chance to give positive
- // feed back to requesting client of success.
- new Thread()
- {
- public void run()
- {
- System.err.println("Server halt(" + exitcode + ") called, halting the JVM now!");
- Runtime.getRuntime().halt(exitcode);
- }
- }.start();
- }
-
- /**
- * Forcibly terminates the currently running Java virtual machine.
- * Halts with code 1.
- *
- * @jmx:managed-operation
- */
- public void halt()
- {
- halt(1);
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // Runtime Access //
- ///////////////////////////////////////////////////////////////////////////
-
- /** A simple helper used to log the Runtime memory information. */
- private void logMemoryUsage(final Runtime rt)
- {
- log.info("Total/free memory: " + rt.totalMemory() + "/" + rt.freeMemory());
- }
-
- /**
- * Hint to the JVM to run the garbage collector.
- *
- * @jmx:managed-operation
- */
- public void runGarbageCollector()
- {
- Runtime rt = Runtime.getRuntime();
-
- logMemoryUsage(rt);
- rt.gc();
- log.info("Hinted to the JVM to run garbage collection");
- logMemoryUsage(rt);
- }
-
- /**
- * Hint to the JVM to run any pending object finailizations.
- *
- * @jmx:managed-operation
- */
- public void runFinalization()
- {
- Runtime.getRuntime().runFinalization();
- log.info("Hinted to the JVM to run any pending object finalizations");
- }
-
- /**
- * Enable or disable tracing method calls at the Runtime level.
- *
- * @jmx:managed-operation
- */
- public void traceMethodCalls(final Boolean flag)
- {
- Runtime.getRuntime().traceMethodCalls(flag.booleanValue());
- }
-
- /**
- * Enable or disable tracing instructions the Runtime level.
- *
- * @jmx:managed-operation
- */
- public void traceInstructions(final Boolean flag)
- {
- Runtime.getRuntime().traceInstructions(flag.booleanValue());
- }
-
-
- ///////////////////////////////////////////////////////////////////////////
- // Server Information //
- ///////////////////////////////////////////////////////////////////////////
-
- /**
- * @jmx:managed-attribute
- */
- public Date getStartDate()
- {
- return startDate;
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getVersion()
- {
- return version.toString();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getVersionName()
- {
- return version.getName();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildNumber()
- {
- return version.getBuildNumber();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildJVM()
- {
- return version.getBuildJVM();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildOS()
- {
- return version.getBuildOS();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildID()
- {
- return version.getBuildID();
- }
-
- /**
- * @jmx:managed-attribute
- */
- public String getBuildDate()
- {
- return version.getBuildDate();
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // NotificationEmitter //
- ///////////////////////////////////////////////////////////////////////////
-
- public void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
- {
- broadcasterSupport.addNotificationListener(listener, filter, handback);
- }
-
- public void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException
- {
- broadcasterSupport.removeNotificationListener(listener);
- }
-
- public void removeNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
- throws ListenerNotFoundException
- {
- broadcasterSupport.removeNotificationListener(listener, filter, handback);
- }
-
- public MBeanNotificationInfo[] getNotificationInfo()
- {
- return broadcasterSupport.getNotificationInfo();
- }
-
- public void sendNotification(Notification notification)
- {
- broadcasterSupport.sendNotification(notification);
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // Lifecycle Thread //
- ///////////////////////////////////////////////////////////////////////////
-
- /** A simple thread that keeps the vm alive in the event there are no
- * other threads started.
- */
- private class LifeThread
- extends Thread
- {
- Object lock = new Object();
- LifeThread()
- {
- super("JBossLifeThread");
- }
- public void run()
- {
- synchronized (lock)
- {
- try
- {
- lock.wait();
- }
- catch (InterruptedException ignore)
- {
- }
- }
- log.debug("LifeThread.run() exits!");
- }
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // Shutdown Hook //
- ///////////////////////////////////////////////////////////////////////////
-
- private class ShutdownHook
- extends Thread
- {
- /** The ServiceController which we will ask to shut things down with. */
- private ObjectName controller;
-
- /** The MainDeployer which we will ask to undeploy everything. */
- private ObjectName mainDeployer;
-
- /** Whether to halt the JMV at the end of the shutdown hook */
- private boolean forceHalt = true;
-
- /** The exit code to use if forceHalt is enabled */
- private int haltExitCode;
-
- /** Mark when shutdown has been performed */
- private boolean shutdownCalled;
-
- public ShutdownHook(final ObjectName controller, final ObjectName mainDeployer)
- {
- super("JBoss Shutdown Hook");
-
- this.controller = controller;
- this.mainDeployer = mainDeployer;
-
- String value = System.getProperty("jboss.shutdown.forceHalt", null);
- if (value != null)
- {
- forceHalt = new Boolean(value).booleanValue();
- }
- }
-
- public void setHaltExitCode(int haltExitCode)
- {
- this.haltExitCode = haltExitCode;
- }
-
- public void run()
- {
- log.info("Runtime shutdown hook called, forceHalt: " + forceHalt);
-
- // shutdown the server
- shutdown();
-
- // Execute the jdk JBossJDKLogManager doReset
- LogManager lm = LogManager.getLogManager();
- if (lm instanceof JBossJDKLogManager)
- {
- JBossJDKLogManager jbosslm = (JBossJDKLogManager)lm;
- jbosslm.doReset();
- }
-
- // later bitch - other shutdown hooks may be killed
- if (forceHalt)
- {
- System.out.println("Halting VM");
- Runtime.getRuntime().halt(haltExitCode);
- }
- }
-
- public void shutdown()
- {
- if (log.isTraceEnabled())
- log.trace("Shutdown caller:", new Throwable("Here"));
-
- // avoid entering twice; may happen when called directly
- // from ServerImpl.shutdown(), then called again when all
- // non-daemon threads have exited and the ShutdownHook runs.
- if (shutdownCalled)
- return;
- else
- shutdownCalled = true;
-
- // Send a notification that server stop is initiated
- Notification msg = new Notification(STOP_NOTIFICATION_TYPE, this, 2);
- sendNotification(msg);
-
- // MainDeployer.shutdown()
- log.info("JBoss SHUTDOWN: Undeploying all packages");
- shutdownDeployments();
-
- // ServiceController.shutdown()
- log.debug("Shutting down all services");
- shutdownServices();
-
- // Make sure all mbeans are unregistered
- removeMBeans();
-
- // Cleanup tmp/deploy dir
- log.debug("Deleting server tmp/deploy directory");
- File tmp = config.getServerTempDir();
- File tmpDeploy = new File(tmp, "deploy");
- Files.delete(tmpDeploy);
-
- // Done
- log.info("Shutdown complete");
- System.out.println("Shutdown complete");
- }
-
- protected void shutdownDeployments()
- {
- try
- {
- // get the deployed objects from ServiceController
- server.invoke(mainDeployer,
- "shutdown",
- new Object[0],
- new String[0]);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to shutdown deployer", t);
- }
- }
-
- /**
- * The <code>shutdownServices</code> method calls the one and only
- * ServiceController to shut down all the mbeans registered with it.
- */
- protected void shutdownServices()
- {
- try
- {
- // get the deployed objects from ServiceController
- server.invoke(controller,
- "shutdown",
- new Object[0],
- new String[0]);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to shutdown services", t);
- }
- }
-
- /**
- * The <code>removeMBeans</code> method uses the mbean server to unregister
- * all the mbeans registered here.
- */
- protected void removeMBeans()
- {
- try
- {
- server.unregisterMBean(ServiceControllerMBean.OBJECT_NAME);
- server.unregisterMBean(ServerConfigImplMBean.OBJECT_NAME);
- server.unregisterMBean(ServerImplMBean.OBJECT_NAME);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to unregister mbeans", t);
- }
- try
- {
- MBeanServer registeredServer = server;
- if (config.getPlatformMBeanServer() == true)
- registeredServer = LazyMBeanServer.getRegisteredMBeanServer(server);
- MBeanServerFactory.releaseMBeanServer(registeredServer);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to release mbean server", t);
- }
- }
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/ServerImpl.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerImpl.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/server/ServerImpl.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,58 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system.server;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * MBean interface.
- */
-public interface ServerImplMBean extends Server
-{
- /** The default object name */
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.system:type=Server");
-
- // Attributes ----------------------------------------------------
-
- /**
- * Hint to the JVM to run the garbage collector.
- */
- void runGarbageCollector();
-
- /**
- * Hint to the JVM to run any pending object finailizations.
- */
- void runFinalization();
-
- /**
- * Enable or disable tracing method calls at the Runtime level.
- */
- void traceMethodCalls(Boolean flag);
-
- /**
- * Enable or disable tracing instructions the Runtime level.
- */
- void traceInstructions(Boolean flag);
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java)
Property changes on: trunk/system-jmx/src/main/org/jboss/system/server/ServerImplMBean.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Copied: trunk/system-jmx/src/main/org/jboss/system/server/jmx (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx)
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,520 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system.server.jmx;
-
-import java.io.File;
-import java.lang.reflect.Method;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Properties;
-import java.util.logging.LogManager;
-
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanNotificationInfo;
-import javax.management.MBeanServer;
-import javax.management.MBeanServerFactory;
-import javax.management.NotificationEmitter;
-import javax.management.NotificationFilter;
-import javax.management.NotificationListener;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-
-import org.jboss.kernel.Kernel;
-import org.jboss.logging.JBossJDKLogManager;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.MBeanServerLocator;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceController;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.system.server.Server;
-import org.jboss.system.server.ServerConfig;
-import org.jboss.system.server.ServerConfigImpl;
-import org.jboss.system.server.ServerConfigImplMBean;
-import org.jboss.system.server.ServerImplMBean;
-import org.jboss.util.JBossObject;
-import org.jboss.util.file.FileSuffixFilter;
-
-/**
- * A pojo that creates a legacy jmx kernel ala the jboss-4.x server bootstrap.
- * This is used to support the SARDeployer and mbean integration.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision:$
- */
-public class JMXKernel extends JBossObject
- implements JMXKernelMBean, NotificationEmitter
-{
- private final static ObjectName DEFAULT_LOADER_NAME =
- ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
-
- /** The JMX MBeanServer which will serve as our communication bus. */
- private MBeanServer mbeanServer;
- private Server serverImpl;
- private ServiceController controller;
- private ServerConfig serverConfig;
- private ServerConfigImplMBean serverConfigMBean;
- /** The kernel */
- private Kernel kernel;
- /** The serverImpl cast as an emitter */
- private NotificationEmitter notificationEmitter;
-
- /** The bootstrap UCL class loader ObjectName */
- private ObjectName bootstrapUCLName;
- private boolean started;
- /** A flag indicating if shutdown has been called */
- private boolean isInShutdown;
-
- public Server getServerImpl()
- {
- return serverImpl;
- }
- public void setServerImpl(Server serverImpl)
- {
- this.serverImpl = serverImpl;
- this.notificationEmitter = (NotificationEmitter) serverImpl;
- }
-
- public ServiceControllerMBean getServiceController()
- {
- return this.controller;
- }
- public MBeanServer getMbeanServer()
- {
- return mbeanServer;
- }
-
- /**
- * Set the kernel.
- *
- * @param kernel the kernel.
- */
- public void setKernel(Kernel kernel)
- {
- this.kernel = kernel;
- }
-
- public void start() throws Exception
- {
- ClassLoader tcl = Thread.currentThread().getContextClassLoader();
- // Create the MBeanServer
- String builder = System.getProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY,
- ServerConstants.DEFAULT_MBEAN_SERVER_BUILDER_CLASS);
- System.setProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY, builder);
-
- serverConfig = serverImpl.getConfig();
- serverConfigMBean = new ServerConfigImpl(serverConfig);
- // Check if we'll use the platform MBeanServer or instantiate our own
- if (serverConfig.getPlatformMBeanServer() == true)
- {
- // jdk1.5+
- ClassLoader cl = Thread.currentThread().getContextClassLoader();
- Class clazz = cl.loadClass("java.lang.management.ManagementFactory");
- Class[] sig = null;
- Method method = clazz.getMethod("getPlatformMBeanServer", sig);
- Object[] args = null;
- mbeanServer = (MBeanServer) method.invoke(null, args);
- // Tell the MBeanServerLocator to point to this mbeanServer
- MBeanServerLocator.setJBoss(mbeanServer);
- /* If the LazyMBeanServer was used, we need to reset to the jboss
- MBeanServer to use our implementation for the jboss services.
- */
- mbeanServer = LazyMBeanServer.resetToJBossServer(mbeanServer);
- }
- else
- {
- // Create our own MBeanServer
- mbeanServer = MBeanServerFactory.createMBeanServer("jboss");
- }
- log.debug("Created MBeanServer: " + mbeanServer);
-
- // Register mbeanServer components
- mbeanServer.registerMBean(this, ServerImplMBean.OBJECT_NAME);
- mbeanServer.registerMBean(serverConfigMBean, ServerConfigImplMBean.OBJECT_NAME);
-
- // Initialize spine boot libraries
- RepositoryClassLoader ucl = initBootLibraries();
- bootstrapUCLName = ucl.getObjectName();
- mbeanServer.registerMBean(ucl, bootstrapUCLName);
-
- // Set ServiceClassLoader as classloader for the construction of
- // the basic system
- try
- {
- Thread.currentThread().setContextClassLoader(ucl);
-
- // General Purpose Architecture information
- createMBean("org.jboss.system.server.ServerInfo",
- "jboss.system:type=ServerInfo");
-
- // Service Controller
- controller = new ServiceController();
- controller.setKernel(kernel);
- controller.setMBeanServer(mbeanServer);
- mbeanServer.registerMBean(controller, new ObjectName("jboss.system:service=ServiceController"));
-
- log.info("Legacy JMX core initialized");
- started = true;
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(tcl);
- }
- }
-
- /**
- * Stop the mbeans
- *
- * @throws IllegalStateException - if not started.
- */
- public void stop() throws IllegalStateException
- {
- if (log.isTraceEnabled())
- log.trace("stop caller:", new Throwable("Here"));
-
- if (!started)
- throw new IllegalStateException("Server not started");
-
- isInShutdown = true;
- // start in new thread to give positive
- // feedback to requesting client of success.
- new Thread()
- {
- public void run()
- {
- // just run the hook, don't call System.exit, as we may
- // be embeded in a vm that would not like that very much
- shutdown();
- }
- }.start();
- }
-
- ///////////////////////////////////////////////////////////////////////////
- // NotificationEmitter //
- ///////////////////////////////////////////////////////////////////////////
-
- public void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
- {
- notificationEmitter.addNotificationListener(listener, filter, handback);
- }
-
- public void removeNotificationListener(NotificationListener listener) throws ListenerNotFoundException
- {
- notificationEmitter.removeNotificationListener(listener);
- }
-
- public void removeNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
- throws ListenerNotFoundException
- {
- notificationEmitter.removeNotificationListener(listener, filter, handback);
- }
-
- public MBeanNotificationInfo[] getNotificationInfo()
- {
- return notificationEmitter.getNotificationInfo();
- }
-
- // ServerImplMBean delegation
- public void init(Properties props) throws Exception
- {
- serverImpl.init(props);
- }
-
- public void exit()
- {
- serverImpl.exit();
- }
-
- public void exit(int exitcode)
- {
- serverImpl.exit(exitcode);
- }
-
- public ServerConfig getConfig()
- {
- return serverConfig;
- }
- public String getBuildDate()
- {
- return serverImpl.getBuildDate();
- }
-
- public String getBuildID()
- {
- return serverImpl.getBuildID();
- }
-
- public String getBuildJVM()
- {
- return serverImpl.getBuildJVM();
- }
-
- public String getBuildNumber()
- {
- return serverImpl.getBuildNumber();
- }
-
- public String getBuildOS()
- {
- return serverImpl.getBuildOS();
- }
-
- public Date getStartDate()
- {
- return serverImpl.getStartDate();
- }
-
- public String getVersion()
- {
- return serverImpl.getVersion();
- }
-
- public String getVersionName()
- {
- return serverImpl.getVersionName();
- }
-
- public void halt()
- {
- serverImpl.halt();
- }
-
- public void halt(int exitcode)
- {
- serverImpl.halt(exitcode);
- }
-
- public boolean isInShutdown()
- {
- return serverImpl.isInShutdown();
- }
-
- public boolean isStarted()
- {
- return serverImpl.isStarted();
- }
-
- public void runFinalization()
- {
-
- }
-
- public void runGarbageCollector()
- {
-
- }
-
- public void traceInstructions(Boolean flag)
- {
-
- }
-
- public void traceMethodCalls(Boolean flag)
- {
-
- }
-
- public void shutdown()
- {
- if (log.isTraceEnabled())
- log.trace("Shutdown caller:", new Throwable("Here"));
-
- // Execute the jdk JBossJDKLogManager doReset
- LogManager lm = LogManager.getLogManager();
- if (lm instanceof JBossJDKLogManager)
- {
- JBossJDKLogManager jbosslm = (JBossJDKLogManager)lm;
- jbosslm.doReset();
- }
-
- // avoid entering twice; may happen when called directly
- // from ServerImpl.shutdown(), then called again when all
- // non-daemon threads have exited and the ShutdownHook runs.
- if (isInShutdown)
- return;
- else
- isInShutdown = true;
-
- // ServiceController.shutdown()
- log.debug("Shutting down all services");
- shutdownServices();
-
- // Make sure all mbeans are unregistered
- removeMBeans();
-
- // Done
- log.info("Legacy kernel shutdown complete");
- System.out.println("Legacy kernel shutdown complete");
- }
-
- /**
- * The <code>shutdownServices</code> method calls the one and only
- * ServiceController to shut down all the mbeans registered with it.
- */
- protected void shutdownServices()
- {
- try
- {
- // get the deployed objects from ServiceController
- controller.shutdown();
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to shutdown services", t);
- }
- }
-
- /**
- * The <code>removeMBeans</code> method uses the mbean mbeanServer to unregister
- * all the mbeans registered here.
- */
- protected void removeMBeans()
- {
- try
- {
- mbeanServer.unregisterMBean(ServiceControllerMBean.OBJECT_NAME);
- mbeanServer.unregisterMBean(ServerConfigImplMBean.OBJECT_NAME);
- mbeanServer.unregisterMBean(ServerImplMBean.OBJECT_NAME);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to unregister mbeans", t);
- }
- try
- {
- MBeanServer registeredServer = mbeanServer;
- if (serverConfig.getPlatformMBeanServer() == true)
- registeredServer = LazyMBeanServer.getRegisteredMBeanServer(mbeanServer);
- MBeanServerFactory.releaseMBeanServer(registeredServer);
- }
- catch (Exception e)
- {
- Throwable t = JMXExceptionDecoder.decode(e);
- log.error("Failed to release mbean mbeanServer", t);
- }
- }
-
-
- /**
- * Initialize the boot libraries.
- *
- * @return the classloader
- * @throws Exception for any error
- */
- private RepositoryClassLoader initBootLibraries() throws Exception
- {
- // Build the list of URL for the spine to boot
- List<URL> list = new ArrayList<URL>();
-
- // Add the patch URL. If the url protocol is file, then
- // add the contents of the directory it points to
- URL patchURL = serverConfig.getPatchURL();
- if (patchURL != null)
- {
- if (patchURL.getProtocol().equals("file"))
- {
- File dir = new File(patchURL.getFile());
- if (dir.exists())
- {
- // Add the local file patch directory
- list.add(dir.toURL());
-
- // Add the contents of the directory too
- File[] jars = dir.listFiles(new FileSuffixFilter(new String[] { ".jar", ".zip" }, true));
-
- for (int j = 0; jars != null && j < jars.length; j++)
- {
- list.add(jars[j].getCanonicalFile().toURL());
- }
- }
- }
- else
- {
- list.add(patchURL);
- }
- }
-
- // Add the mbeanServer configuration directory to be able to load serverConfig files as resources
- list.add(serverConfig.getServerConfigURL());
- log.debug("Boot url list: " + list);
-
- // Create loaders for each URL
- RepositoryClassLoader loader = null;
- for (Iterator iter = list.iterator(); iter.hasNext();)
- {
- URL url = (URL)iter.next();
- log.debug("Creating loader for URL: " + url);
-
- // This is a boot URL, so key it on itself.
- Object[] args = {url, Boolean.TRUE};
- String[] sig = {"java.net.URL", "boolean"};
- loader = (RepositoryClassLoader) mbeanServer.invoke(DEFAULT_LOADER_NAME, "newClassLoader", args, sig);
- }
- return loader;
- }
-
- /**
- * Instantiate and register a service for the given classname into the MBean mbeanServer.
- *
- * @param classname the mbean class name
- * @param name the obejct name
- * @return the object name
- * @throws Exception for any error
- */
- private ObjectName createMBean(final String classname, String name)
- throws Exception
- {
- ObjectName mbeanName = null;
- if( name != null )
- mbeanName = new ObjectName(name);
- try
- {
- // See if there is an xmbean descriptor for the bootstrap mbean
- URL xmbeanDD = new URL("resource:xmdesc/"+classname+"-xmbean.xml");
- Object resource = mbeanServer.instantiate(classname);
- // Create the XMBean
- Object[] args = {resource, xmbeanDD};
- String[] sig = {Object.class.getName(), URL.class.getName()};
- ObjectInstance instance = mbeanServer.createMBean("org.jboss.mx.modelmbean.XMBean",
- mbeanName,
- bootstrapUCLName,
- args,
- sig);
- mbeanName = instance.getObjectName();
- log.debug("Created system XMBean: "+mbeanName);
- }
- catch(Exception e)
- {
- log.debug("Failed to create xmbean for: "+classname);
- mbeanName = mbeanServer.createMBean(classname, mbeanName).getObjectName();
- log.debug("Created system MBean: " + mbeanName);
- }
-
- return mbeanName;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,29 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.system.server.jmx;
-
-import org.jboss.system.server.ServerImplMBean;
-
-public interface JMXKernelMBean extends ServerImplMBean
-{
-
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernelMBean.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,460 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server.jmx;
-
-import java.io.ObjectInputStream;
-import java.lang.reflect.Constructor;
-import java.util.Set;
-import java.util.HashSet;
-import java.util.Collections;
-import javax.management.MBeanServer;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-import javax.management.InstanceAlreadyExistsException;
-import javax.management.MBeanRegistrationException;
-import javax.management.MBeanException;
-import javax.management.NotCompliantMBeanException;
-import javax.management.InstanceNotFoundException;
-import javax.management.QueryExp;
-import javax.management.AttributeNotFoundException;
-import javax.management.AttributeList;
-import javax.management.Attribute;
-import javax.management.InvalidAttributeValueException;
-import javax.management.NotificationListener;
-import javax.management.NotificationFilter;
-import javax.management.ListenerNotFoundException;
-import javax.management.MBeanInfo;
-import javax.management.IntrospectionException;
-import javax.management.OperationsException;
-import javax.management.MBeanServerDelegate;
-import javax.management.loading.ClassLoaderRepository;
-
-/**
- * An MBeanServer implementation that bridges between the platform MBeanServer
- * and the jboss implementation. This is used by the @{link MBeanServerBuilderImpl}
- * to bridge the period from the vm startup until the jboss server is loaded
- * and the jboss MBeanServer is available.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision: 46137 $
- */
-public class LazyMBeanServer
- implements MBeanServer
-{
- private static MBeanServer registeredServer;
- private static MBeanServer theServer;
- private static MBeanServer platformServer;
- private static String defaultDomain;
- private static MBeanServerDelegate theDelegate;
- /** A HashSet<String> of the jmx domain prefixes that need to be
- * handled by the platform server
- */
- private static Set platformServerDomains = Collections.synchronizedSet(new HashSet());
- /** A HashSet<String> of the jmx domain prefixes that need to be
- * handled by the jboss server
- */
- private static Set serverDomains = Collections.synchronizedSet(new HashSet());
-
- /**
- * Called by the ServerImpl to reset theServer implementation to the jboss
- * version so that our xmbean and the like function correctly.
- *
- * @param server - the existing MBeanServer
- * @return org.jboss.mx.server.MBeanServerImp
- * @throws Exception
- */
- public static MBeanServer resetToJBossServer(MBeanServer server)
- throws Exception
- {
- MBeanServer coreServer = server;
- if( theDelegate != null )
- {
- Class[] sig = {String.class, MBeanServer.class, MBeanServerDelegate.class};
- Object[] args = {defaultDomain, null, theDelegate};
- ClassLoader loader = Thread.currentThread().getContextClassLoader();
- Class c = loader.loadClass("org.jboss.mx.server.MBeanServerImpl");
- Constructor ctor = c.getConstructor(sig);
- theServer = (MBeanServer) ctor.newInstance(args);
- coreServer = theServer;
- String[] domains = theServer.getDomains();
- for(int n = 0; n < domains.length; n ++)
- {
- serverDomains.add(domains[n]);
- }
- }
- return coreServer;
- }
- /**
- * Provide access to the original MBeanServer that was registered so that
- * it can be removed on shutdown for example.
- *
- * @param server - the ServerImple MBeanServer
- * @return either the argument, or the last LazyMBeanServer created
- */
- public static MBeanServer getRegisteredMBeanServer(MBeanServer server)
- {
- MBeanServer outerServer = server;
- if( registeredServer != null )
- outerServer = registeredServer;
- return outerServer;
- }
-
- /**
- * Updates the platformServerDomains and serverDomains sets of jmx
- * domain names.
- */
- public static synchronized void reloadDomains()
- {
- // Initialize the platform server domains
- String[] domains = platformServer.getDomains();
- for(int n = 0; n < domains.length; n ++)
- {
- platformServerDomains.add(domains[n]);
- }
- domains = theServer.getDomains();
- for(int n = 0; n < domains.length; n ++)
- {
- serverDomains.add(domains[n]);
- }
- }
- LazyMBeanServer(String domain, MBeanServer outer,
- MBeanServerDelegate delegate)
- {
- defaultDomain = domain;
- platformServer = outer;
- theServer = outer;
- registeredServer = this;
- theDelegate = delegate;
- // Initialize the platform server domains
- String[] domains = platformServer.getDomains();
- for(int n = 0; n < domains.length; n ++)
- {
- platformServerDomains.add(domains[n]);
- }
- }
-
- public ObjectInstance createMBean(String className, ObjectName name)
- throws ReflectionException, InstanceAlreadyExistsException,
- MBeanRegistrationException, MBeanException,
- NotCompliantMBeanException
- {
- try
- {
- return createMBean(className, name, null);
- }
- catch (InstanceNotFoundException e)
- {
- throw new MBeanException(e);
- }
- }
-
- public ObjectInstance createMBean(String className, ObjectName name,
- ObjectName loaderName)
- throws ReflectionException, InstanceAlreadyExistsException,
- MBeanRegistrationException, MBeanException,
- NotCompliantMBeanException, InstanceNotFoundException
- {
- return getServer(name).createMBean(className, name, loaderName);
- }
-
- public ObjectInstance createMBean(String className, ObjectName name,
- Object params[], String signature[])
- throws ReflectionException, InstanceAlreadyExistsException,
- MBeanRegistrationException, MBeanException,
- NotCompliantMBeanException
- {
- return getServer(name).createMBean(className, name, params, signature);
- }
-
- public ObjectInstance createMBean(String className, ObjectName name,
- ObjectName loaderName, Object params[],
- String signature[])
- throws ReflectionException, InstanceAlreadyExistsException,
- MBeanRegistrationException, MBeanException,
- NotCompliantMBeanException, InstanceNotFoundException
- {
- return getServer(name).createMBean(className, name, loaderName, params, signature);
- }
-
- public ObjectInstance registerMBean(Object object, ObjectName name)
- throws InstanceAlreadyExistsException, MBeanRegistrationException,
- NotCompliantMBeanException
- {
- return theServer.registerMBean(object, name);
- }
-
- public void unregisterMBean(ObjectName name)
- throws InstanceNotFoundException, MBeanRegistrationException
- {
- theServer.unregisterMBean(name);
- }
-
- public ObjectInstance getObjectInstance(ObjectName name)
- throws InstanceNotFoundException
- {
- ObjectInstance oi = getServer(name).getObjectInstance(name);
- return oi;
- }
-
- public Set queryMBeans(ObjectName name, QueryExp query)
- {
- // query both servers
- Set beans = platformServer.queryMBeans(name, query);
- Set beans2 = theServer.queryMBeans(name, query);
- beans.addAll(beans2);
- return beans;
- }
-
- public Set queryNames(ObjectName name, QueryExp query)
- {
- Set names = platformServer.queryNames(name, query);
- Set names2 = theServer.queryNames(name, query);
- names.addAll(names2);
- return names;
- }
-
- public boolean isRegistered(ObjectName name)
- {
- return getServer(name).isRegistered(name);
- }
-
- public Integer getMBeanCount()
- {
- return theServer.getMBeanCount();
- }
-
- public Object getAttribute(ObjectName name, String attribute)
- throws MBeanException, AttributeNotFoundException,
- InstanceNotFoundException, ReflectionException
- {
- return getServer(name).getAttribute(name, attribute);
- }
-
- public AttributeList getAttributes(ObjectName name, String[] attributes)
- throws InstanceNotFoundException, ReflectionException
- {
- return getServer(name).getAttributes(name, attributes);
- }
-
- public void setAttribute(ObjectName name, Attribute attribute)
- throws InstanceNotFoundException, AttributeNotFoundException,
- InvalidAttributeValueException, MBeanException,
- ReflectionException
- {
- getServer(name).setAttribute(name, attribute);
- }
-
- public AttributeList setAttributes(ObjectName name,
- AttributeList attributes)
- throws InstanceNotFoundException, ReflectionException
- {
- return getServer(name).setAttributes(name, attributes);
- }
-
- public Object invoke(ObjectName name, String operationName,
- Object params[], String signature[])
- throws InstanceNotFoundException, MBeanException,
- ReflectionException
- {
- Object value = getServer(name).invoke(name, operationName, params, signature);
- return value;
- }
-
- public String getDefaultDomain()
- {
- return theServer.getDefaultDomain();
- }
-
- public String[] getDomains()
- {
- return theServer.getDomains();
- }
-
- public void addNotificationListener(ObjectName name,
- NotificationListener listener,
- NotificationFilter filter,
- Object handback)
- throws InstanceNotFoundException
- {
- getServer(name).addNotificationListener(name, listener, filter, handback);
- }
-
- public void addNotificationListener(ObjectName name,
- ObjectName listener,
- NotificationFilter filter,
- Object handback)
- throws InstanceNotFoundException
- {
- getServer(name).addNotificationListener(name, listener, filter, handback);
- }
-
- public void removeNotificationListener(ObjectName name,
- ObjectName listener)
- throws InstanceNotFoundException, ListenerNotFoundException
- {
- getServer(name).removeNotificationListener(name, listener);
- }
-
- public void removeNotificationListener(ObjectName name,
- ObjectName listener,
- NotificationFilter filter,
- Object handback)
- throws InstanceNotFoundException, ListenerNotFoundException
- {
- getServer(name).removeNotificationListener(name, listener, filter, handback);
- }
-
- public void removeNotificationListener(ObjectName name,
- NotificationListener listener)
- throws InstanceNotFoundException, ListenerNotFoundException
- {
- getServer(name).removeNotificationListener(name, listener);
- }
-
- public void removeNotificationListener(ObjectName name,
- NotificationListener listener,
- NotificationFilter filter,
- Object handback)
- throws InstanceNotFoundException, ListenerNotFoundException
- {
- getServer(name).removeNotificationListener(name, listener, filter, handback);
- }
-
- /**
- * Obtains the MBeanInfo for the given ObjectName. In the event of an
- * InstanceNotFoundException, the jmx domain to server sets are reloaded
- * by calling reloadDomains(), and the lookup retried.
- * @param name
- * @return
- * @throws InstanceNotFoundException
- * @throws IntrospectionException
- * @throws ReflectionException
- */
- public MBeanInfo getMBeanInfo(ObjectName name)
- throws InstanceNotFoundException, IntrospectionException,
- ReflectionException
- {
- MBeanInfo info = null;
- try
- {
- info = getServer(name).getMBeanInfo(name);
- }
- catch(InstanceNotFoundException e)
- {
- reloadDomains();
- info = getServer(name).getMBeanInfo(name);
- }
- return info;
- }
-
- public boolean isInstanceOf(ObjectName name, String className)
- throws InstanceNotFoundException
- {
- return getServer(name).isInstanceOf(name, className);
- }
-
- public Object instantiate(String className)
- throws ReflectionException, MBeanException
- {
- return theServer.instantiate(className);
- }
-
- public Object instantiate(String className, ObjectName loaderName)
- throws ReflectionException, MBeanException,
- InstanceNotFoundException
- {
- return theServer.instantiate(className, loaderName);
- }
-
- public Object instantiate(String className, Object params[],
- String signature[])
- throws ReflectionException, MBeanException
- {
- return theServer.instantiate(className, params, signature);
- }
-
- public Object instantiate(String className, ObjectName loaderName,
- Object params[], String signature[])
- throws ReflectionException, MBeanException,
- InstanceNotFoundException
- {
- return theServer.instantiate(className, loaderName, params, signature);
- }
-
- public ObjectInputStream deserialize(ObjectName name, byte[] data)
- throws InstanceNotFoundException, OperationsException
- {
- return getServer(name).deserialize(name, data);
- }
-
- public ObjectInputStream deserialize(String className, byte[] data)
- throws OperationsException, ReflectionException
- {
- return theServer.deserialize(className, data);
- }
-
- public ObjectInputStream deserialize(String className,
- ObjectName loaderName,
- byte[] data)
- throws InstanceNotFoundException, OperationsException,
- ReflectionException
- {
- return theServer.deserialize(className, loaderName, data);
- }
-
- public ClassLoader getClassLoaderFor(ObjectName mbeanName)
- throws InstanceNotFoundException
- {
- return getServer(mbeanName).getClassLoaderFor(mbeanName);
- }
-
- public ClassLoader getClassLoader(ObjectName loaderName)
- throws InstanceNotFoundException
- {
- return getServer(loaderName).getClassLoader(loaderName);
- }
-
- public ClassLoaderRepository getClassLoaderRepository()
- {
- return theServer.getClassLoaderRepository();
- }
-
- /**
- * Choose the MBeanServer based on the ObjectName domain. If the serverDomain
- * contains the domain of the name, theServer is returned. If the
- * platformServerDomains set contains the domain of the name, the
- * platformServer is returned. For an unknown domain theServer is returned.
- *
- * @param name
- * @return Either the platform MBeanServer, or the jboss MBeanServer
- */
- private MBeanServer getServer(ObjectName name)
- {
- String domain = name != null ? name.getDomain() : "";
- if( serverDomains.contains(domain) )
- return theServer;
- if( platformServerDomains.contains(domain) )
- return platformServer;
- return theServer;
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java)
Deleted: trunk/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.system.server.jmx;
-
-import javax.management.MBeanServerBuilder;
-import javax.management.MBeanServerDelegate;
-import javax.management.MBeanServer;
-
-/**
- * An @link{MBeanServerBuilder} that creates a LazyMBeanServer instance to allow
- * the jboss MBeanServerImpl to be created when the ServerImpl is loaded and
- * the jboss jmx classes are available. It can be used at startup using
- * -Djavax.management.builder.initial=org.jboss.system.server.jmx.MBeanServerBuilderImpl
- * This is needed when enabling the jdk5 jconsole remote adaptor since this
- * adaptor initializes the platform MBeanServer before the jboss ServerImpl
- * is loaded.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision: 37459 $
- */
-public class MBeanServerBuilderImpl
- extends MBeanServerBuilder
-{
- /**
- *
- * @return @{link MBeanServerDelegate}
- */
- public MBeanServerDelegate newMBeanServerDelegate()
- {
- return new MBeanServerDelegate();
- }
-
- /**
- * Creates a @{link LazyMBeanServer} as the MBeanServer. If the outer
- * parameter is null, the outer passed to the LazyMBeanServer is the
- * platform mbean server as obtained from
- * super.newMBeanServer(defaultDomain, outer, delegate).
- *
- * @param defaultDomain
- * @param outer
- * @param delegate
- * @return LazyMBeanServer
- */
- public MBeanServer newMBeanServer(String defaultDomain, MBeanServer outer,
- MBeanServerDelegate delegate)
- {
- if( outer == null )
- outer = super.newMBeanServer(defaultDomain, outer, delegate);
- return new LazyMBeanServer(defaultDomain, outer, delegate);
- }
-}
Copied: trunk/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/main/org/jboss/system/server/jmx/MBeanServerBuilderImpl.java)
Copied: trunk/system-jmx/src/resources (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources)
Copied: trunk/system-jmx/src/resources/tests (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests)
Copied: trunk/system-jmx/src/resources/tests/org (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org)
Copied: trunk/system-jmx/src/resources/tests/org/jboss (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/classloading)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar1.jar
===================================================================
(Binary files differ)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar1.jar (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/classloading/jar1.jar)
Property changes on: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar1.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2.jar
===================================================================
(Binary files differ)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2.jar (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2.jar)
Property changes on: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2CPjar1.jar
===================================================================
(Binary files differ)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2CPjar1.jar (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2CPjar1.jar)
Property changes on: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar2CPjar1.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar3.jar
===================================================================
(Binary files differ)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar3.jar (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/classloading/jar3.jar)
Property changes on: trunk/system-jmx/src/resources/tests/org/jboss/test/classloading/jar3.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/Basic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/basic/test/DoubleInstall.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=BrokenDynamicMBeanAttributes" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributes">
- <attribute name="Dummy">dummy</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenGetAttributes_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="BrokenAttribute">value1</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeBrokenSetAttribute_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="">value1</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyName_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Attribute1"></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeEmptyValue_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute>value1</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoName_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Attribute1"/>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNoValue_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNone_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AttributeDoesNotExist">value1</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Attribute1">value1</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOne_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Attribute1">value1</attribute>
- <attribute name="Attribute2">value2</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTwo_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="BrokenObjectNameAttribute">jboss.test:type=depends1</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeBrokenSetAttribute_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1"></depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeEmptyValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1">INVALIDOBJECTNAME</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeInvalidValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1">
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- </depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNested_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1"/>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNoValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNone_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="AttributeDoesNotExist">jboss.test:type=depends1</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1">jboss.test:type=depends1</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOne_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1">*:*</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributePatternValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1">jboss.test:type=depends1</depends>
- <depends optional-attribute-name="ObjectNameAttribute2">jboss.test:type=depends2</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- <mbean name="jboss.test:type=depends2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTwo_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectNameAttribute1"><unknown/></depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeUnknownElement_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="BrokenObjectNamesAttribute">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeBrokenSetAttribute_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element></depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeEmptyValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element>INVALIDOBJECTNAME</depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeInvalidValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- <depends-list-element>jboss.test:type=depends2</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- <mbean name="jboss.test:type=depends2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeMultiple_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element>
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- </depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNested_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element/>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNoValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNone_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="AttributeDoesNotExist">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOne_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element>*:*</depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributePatternValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,15 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- </depends-list>
- <depends-list optional-attribute-name="ObjectNamesAttribute2">
- <depends-list-element>jboss.test:type=depends2</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- <mbean name="jboss.test:type=depends2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTwo_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNamesAttribute1">
- <depends-list-element><unknown/></depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeUnknownElement_bad.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Attribute1">fromxml</attribute>
- <attribute name="Attribute2">fromxml</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingError_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Attribute1">fromxml</attribute>
- <attribute name="Attribute2">fromxml</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBinding_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINPROPERTY</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterError_good.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributeInfoTypeNotFound">
- <depends optional-attribute-name="Name" proxy-type="attribute">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/AttributeInfoTypeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="BrokenObjectNameAttribute">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/BrokenSetAttribute_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName">
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
- </depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyNested_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/Dependency_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName"></depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/EmptyValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="Proxy" proxy-type="org.jboss.test.system.controller.support.SimpleStandardMBeanInterface">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleStandardMBeanInterface"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ExplicitProxyType_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="Proxy" proxy-type="attribute">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleStandardMBeanInterface"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ImplicitProxyType_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName">INVALIDOBJECTNAME</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/InvalidValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanNoAttributeInfoType">
- <depends optional-attribute-name="Name" proxy-type="attribute">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoAttributeInfoType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName"/>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/NoValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName">*:*</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/PatternValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="Proxy" proxy-type="TYPEDOESNOTEXIST">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="Proxy" proxy-type="org.jboss.test.system.controller.support.Simple">jboss.test:type=depends</depends>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/ProxyTypeNotInterface_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName"><unknown/></depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/depends/test/UnknownElement_bad.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="BrokenObjectNamesAttribute">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/BrokenSetAttribute_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element></depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/EmptyValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>INVALIDOBJECTNAME</depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/InvalidValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- </depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Nested_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element/>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/NoValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/None_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/One_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>*:*</depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/PatternValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>jboss.test:type=depends1</depends-list-element>
- <depends-list-element>jboss.test:type=depends2</depends-list-element>
- </depends-list>
- </mbean>
-
- <mbean name="jboss.test:type=depends1" code="org.jboss.test.system.controller.support.Simple"/>
- <mbean name="jboss.test:type=depends2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/Two_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element><unknown/></depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/dependslist/test/UnknownElement_bad.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Element"><dummy/></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/element/test/Element_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Simple"><inject bean=""/></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionBeanEmpty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Simple"><inject/></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNoBean_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Simple"><inject bean="DOESNOTEXIST"/></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Simple"><inject bean="jboss.test:type=depends" property="DOESNOTEXIST"/></attribute>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString"><inject bean="jboss.test:type=depends" property="AString" state="Instantiated"/></attribute>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.String" value="Instantiated"/>
- </constructor>
-
- <!-- Used to stop the dependency moving to the configured state -->
- <attribute name="AString"><inject bean="DOESNOTEXIST"/></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyState_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Simple"><inject bean="jboss.test:type=depends" property="AString"/></attribute>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">Wrong</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionPropertyWrongType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString"><inject bean="jboss.test:type=depends" property="AString"/></attribute>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">PropertyInjection</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionProperty_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString"><inject bean="jboss.test:type=depends"/></attribute>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/InjectionWrongType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Simple"><inject bean="jboss.test:type=depends"/></attribute>
- </mbean>
-
- <mbean name="jboss.test:type=depends" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/inject/test/Injection_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean"
- attributeClass="org.jboss.test.system.controller.support.SimpleMBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AbstractAttributeClass_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean"
- attributeClass="TYPEDOESNOTEXIST">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeClassNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=BrokenDynamicMBeanAttributeInfoTypeNotFound" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributeInfoTypeNotFound">
- <attribute name="Name"
- serialDataType="javaBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/AttributeInfoTypeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean">
- <property name="">property1</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/EmptyPropertyName_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean"
- attributeClass="org.jboss.test.system.controller.support.JavaBeanErrorConstructor">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInConstructor_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean"
- attributeClass="org.jboss.test.system.controller.support.JavaBeanErrorConstructor">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ErrorInProperty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean"
- attributeClass="org.jboss.test.system.controller.support.JavaBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ExplicitClass_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/ImplicitClass_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=BrokenDynamicMBeanNoAttributeInfoType" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanNoAttributeInfoType">
- <attribute name="Name"
- serialDataType="javaBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoAttributeInfoType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean">
- <property name="property3">property3</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyEditor_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean">
- <property>property1</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyName_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean">
- <property name="property1"></property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/NoPropertyValue_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean"
- serialDataType="javaBean">
- <property name="DOESNOTEXIST">property1</property>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/javabean/test/PropertyNotFound_bad.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.SimpleMBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/AbstractClass_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBean">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/Basic_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="TYPEDOESNOTEXIST">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ClassNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBean">
- <property name="">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/EmptyPropertyName_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBeanErrorConstructor">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInConstructor_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBeanErrorProperty">
- <property name="property1">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/ErrorInProperty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBean">
- <property name="property3">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyEditor_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBean">
- <property>property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyName_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBean">
- <property name="property1"></property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/NoPropertyValue_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,13 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="JavaBean" serialDataType="jbxb">
- <javabean xmlns="urn:jboss:javabean:1.0"
- class="org.jboss.test.system.controller.support.JavaBean">
- <property name="DOESNOTEXIST">property1</property>
- <property name="property2">10</property>
- </javabean>
- </attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/jbxb/test/PropertyNotFound_bad.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=BrokenDynamicMBeanAttributeInfoTypeNotFound" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributeInfoTypeNotFound">
- <attribute name="Name">Value</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/AttributeInfoTypeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=BrokenDynamicMBeanNoAttributeInfoType" code="org.jboss.test.system.controller.support.BrokenDynamicMBeanNoAttributeInfoType">
- <attribute name="Name">Value</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoAttributeInfoType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="Object">Value</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/NoPropertyEditor_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,24 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">StringValue</attribute>
- <attribute name="AByte">12</attribute>
- <attribute name="ABoolean">true</attribute>
- <attribute name="AShort">123</attribute>
- <attribute name="AnInt">1234</attribute>
- <attribute name="ALong">12345</attribute>
- <attribute name="AFloat">3.14</attribute>
- <attribute name="ADouble">3.14e12</attribute>
- <attribute name="ADate">Mon Jan 01 00:00:00 CET 2001</attribute>
- <attribute name="ABigDecimal">12e4</attribute>
- <!--attribute name="ABigInteger">123456</attribute-->
- <attribute name="Abyte">12</attribute>
- <attribute name="Aboolean">true</attribute>
- <attribute name="Ashort">123</attribute>
- <attribute name="Anint">1234</attribute>
- <attribute name="Along">12345</attribute>
- <attribute name="Afloat">3.14</attribute>
- <attribute name="Adouble">3.14e12</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/configure/value/text/test/PropertyEditors_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.AbstractSimple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanAbstractClass_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="THIS_CLASS_DOES_NOT_EXIST"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeClassNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code=""/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeEmpty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanCodeMissing_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.String" value="error"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.String" value="exception"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorException_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.Object" value="unused"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="int" value="INVALID"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorInvalidValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="THIS_CLASS_DOES_NOT_EXIST" value="unused"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanConstructorTypeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=BrokenDynamicMBean" code="org.jboss.test.system.controller.support.BrokenDynamicMBean"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanGetMBeanInfoError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="java.lang.Object"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNotMBean_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=PostDeregisterError" code="org.jboss.test.system.controller.support.PostDeregisterError"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostDeregisterError_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=PostRegisterError" code="org.jboss.test.system.controller.support.PostRegisterError"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPostRegisterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=PreDeregisterError" code="org.jboss.test.system.controller.support.PreDeregisterError"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreDeregisterError_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=PreRegisterError" code="org.jboss.test.system.controller.support.PreRegisterError"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanPreRegisterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.String" value="error"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterError_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBean_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.AbstractSimple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanAbstractClass_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="THIS_CLASS_DOES_NOT_EXIST"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeClassNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code=""
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeEmpty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code=""
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanCodeMissing_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="java.lang.String" value="error"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="java.lang.String" value="exception"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorException_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="java.lang.Object" value="unused"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidType_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="int" value="INVALID"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorInvalidValue_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="THIS_CLASS_DOES_NOT_EXIST" value="unused"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanConstructorTypeNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="THIS_CLASS_DOES_NOT_EXIST">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotFound_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.NotSimpleStandardMBeanInterface">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterfaceNotImplemented_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleStandardMBeanInterface">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanInterface_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
-
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="java.lang.String" value="error"/>
- </constructor>
- </mbean>
-
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterError_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBean_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="" value="dummy"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeEmpty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg value="dummy"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgTypeMissing_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.Integer"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanArgValueMissing_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanNoArg_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="int" value="5"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanOneArg_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="int" value="5"/>
- <arg type="float" value="3.14"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/PlainMBeanTwoArg_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="" value="dummy"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeEmpty_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg value="dummy"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgTypeMissing_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="java.lang.Integer"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanArgValueMissing_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanNoArg_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="int" value="5"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanOneArg_install.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"
- interface="org.jboss.test.system.controller.support.SimpleMBean">
- <constructor>
- <arg type="int" value="5"/>
- <arg type="float" value="3.14"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/instantiate/test/StandardMBeanTwoArg_install.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean"/>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="SimpleBean"><inject bean="Test"/></attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean">
- <property name="simple"><inject bean="jboss.test:type=test"/></property>
- </bean>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean">
- <create method="create">
- <parameter class="org.jboss.test.system.controller.support.Simple">
- <inject bean="jboss.test:type=test"/>
- </parameter>
- </create>
- </bean>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean">
- <install method="install">
- <parameter class="org.jboss.test.system.controller.support.Simple">
- <inject bean="jboss.test:type=test"/>
- </parameter>
- </install>
- </bean>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean">
- <constructor>
- <parameter class="org.jboss.test.system.controller.support.Simple">
- <inject bean="jboss.test:type=test"/>
- </parameter>
- </constructor>
- </bean>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean"/>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <depends>Test</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean">
- <depends>jboss.test:type=test</depends>
- </bean>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<deployment xmlns="urn:jboss:bean-deployer:2.0">
- <bean name="Test" class="org.jboss.test.system.controller.integration.support.SimpleBean">
- <start method="start">
- <parameter class="org.jboss.test.system.controller.support.Simple">
- <inject bean="jboss.test:type=test"/>
- </parameter>
- </start>
- </bean>
-</deployment>
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase-mc.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends-list>
- <depends-list-element>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
- </depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNested_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends-list>
- <depends-list-element>test:name=2</depends-list-element>
- </depends-list>
- </mbean>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsList_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
- </depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNested_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,11 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
- </depends-list-element>
- </depends-list>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNested_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends-list optional-attribute-name="ObjectNames">
- <depends-list-element>test:name=2</depends-list-element>
- </depends-list>
- </mbean>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeList_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName">
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
- </depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNested_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends optional-attribute-name="ObjectName">test:name=2</depends>
- </mbean>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttribute_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=2</depends>
- </mbean>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDepends_NotAutomatic.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycle_NotAutomatic.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINPROPERTY</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigure_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINCREATE</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreate_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <constructor>
- <arg type="java.lang.String" value="error"/>
- </constructor>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiate_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINSTART</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStart_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple" mode="On Demand"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_1.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependency_2.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server mode="On Demand">
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_1.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependency_2.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=1" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_1.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="test:name=2" code="org.jboss.test.system.controller.support.Simple">
- <depends>test:name=1</depends>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDepends_2.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.ContainedMBeanService">
- <attribute name="AString">ERRORINSTART</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.ContainedMBeanService">
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInContainedStartRedeployAfterError_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINCREATE</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInCreateRedeployAfterError_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINDESTROY</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInDestroyRedeployAfterError_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINSTART</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStartRedeployAfterError_good.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple">
- <attribute name="AString">ERRORINSTOP</attribute>
- </mbean>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_bad.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="jboss.test:type=test" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/lifecycle/test/ErrorInStopRedeployAfterError_good.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameEmpty.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean name="InvalidObjectName" code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameInvalid.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<server>
- <mbean code="org.jboss.test.system.controller.support.Simple"/>
-</server>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/controller/parse/test/NameMissing.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeEmptyValue.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute" replace="false">value</attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoReplace.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute" trim="false">value</attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoTrim.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"/>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNoValue.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeNone.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute">value</attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeOne.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute1">value1</attribute>
- <attribute name="Attribute2">value2</attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeTwo.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute">test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDepends.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute">
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueDependsList.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><dummy/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueElement.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><inject bean="bean" property="property"/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueInject.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute" serialDataType="jbxb"><dummy/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJBXB.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute" serialDataType="javaBean"><dummy/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueJavaBean.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute">value</attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueText.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="">test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoName.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute"/>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNoValue.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeNone.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute">test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeOne.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute1">test:test=1</depends>
- <depends optional-attribute-name="Attribute2">test:test=2</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeTwo.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute"></depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeEmptyValue.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="">
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoName.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute"/>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNoValue.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeNone.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute">
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeOne.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,10 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute1">
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
- <depends-list optional-attribute-name="Attribute2">
- <depends-list-element>test:test=2</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeTwo.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBean.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="" code="BasicMBeanCode"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanEmptyName.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode" interface="BasicMBeanInterface"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInterface.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="INVALID" code="BasicMBeanCode"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanInvalidName.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode" mode="On Demand"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanMode.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean code="BasicMBeanCode"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanNoName.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <constructor/>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorDefault.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <constructor>
- <arg type="signature1" value=""/>
- </constructor>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorEmptyValue.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <constructor>
- <arg type="signature1" value="param1"/>
- </constructor>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorOneArg.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <constructor>
- <arg type="signature1" value="param1"/>
- <arg type="signature2" value="param2"/>
- </constructor>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/constructor/test/ConstructorTwoArgs.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list>
- <depends-list-element>
- <mbean name="test:test=1" code="NestedMBeanCode"/>
- </depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNestedMBean.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list/>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListNone.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list>
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOne.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="AttributeName">
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttribute.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="AttributeName">
- <depends-list-element>
- <mbean name="test:test=1" code="NestedMBeanCode"/>
- </depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListOptionalAttributeNestedMBean.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list>
- <depends-list-element>test:test=1</depends-list-element>
- <depends-list-element>test:test=2</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsListTwo.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends>
- <mbean name="test:test=1" code="NestedMBeanCode"/>
- </depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNestedMBean.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,3 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode"/>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsNone.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends>test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOne.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="AttributeName">test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttribute.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="AttributeName">
- <mbean name="test:test=1" code="NestedMBeanCode"/>
- </depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeNestedMBean.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,6 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends>test:test=1</depends>
- <depends>test:test=2</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/depends/test/DependsTwo.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute">test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/Dependency.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute">
- <mbean name="test:test=1" code="Nested"/>
- </depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyNested.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends optional-attribute-name="Attribute" proxy-type="ProxyType">test:test=1</depends>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/depends/test/DependencyProxyType.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,9 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute">
- <depends-list-element>
- <mbean name="test:test=1" code="Nested"/>
- </depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNested.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute"/>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListNone.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute">
- <depends-list-element>test:test=1</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListOne.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,8 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <depends-list optional-attribute-name="Attribute">
- <depends-list-element>test:test=1</depends-list-element>
- <depends-list-element>test:test=2</depends-list-element>
- </depends-list>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListTwo.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><dummy/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/element/test/Element.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><inject bean="bean"/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/Injection.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><inject bean=""/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionEmpty.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><inject bean="bean" property="property"/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionProperty.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><inject bean="bean" property="property" state="Instantiated"/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionPropertyState.xml)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute"><inject bean="bean" state="Instantiated"/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/inject/test/InjectionState.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute" serialDataType="javaBean"><dummy/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBean.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute" serialDataType="jbxb"><dummy/></attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXB.xml)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text)
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test)
Deleted: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,5 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<mbean name="jboss.test:type=BasicMBeanName" code="BasicMBeanCode">
- <attribute name="Attribute">value</attribute>
-</mbean>
\ No newline at end of file
Copied: trunk/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests/org/jboss/test/system/metadata/value/text/test/Text.xml)
Copied: trunk/system-jmx/src/resources/tests-support (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests-support)
Copied: trunk/system-jmx/src/resources/tests-support/jar1 (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests-support/jar1)
Deleted: trunk/system-jmx/src/resources/tests-support/jar1/resource1.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests-support/jar1/resource1.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests-support/jar1/resource1.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1 +0,0 @@
-<root version="1.0.0" />
Copied: trunk/system-jmx/src/resources/tests-support/jar1/resource1.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests-support/jar1/resource1.xml)
Copied: trunk/system-jmx/src/resources/tests-support/jar2 (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests-support/jar2)
Deleted: trunk/system-jmx/src/resources/tests-support/jar2/resource1.xml
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/resources/tests-support/jar2/resource1.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/resources/tests-support/jar2/resource1.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1 +0,0 @@
-<root version="2.0.0" />
Copied: trunk/system-jmx/src/resources/tests-support/jar2/resource1.xml (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/resources/tests-support/jar2/resource1.xml)
Copied: trunk/system-jmx/src/tests (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests)
Copied: trunk/system-jmx/src/tests/org (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org)
Copied: trunk/system-jmx/src/tests/org/jboss (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss)
Copied: trunk/system-jmx/src/tests/org/jboss/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,96 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test;
-
-import org.jboss.logging.Logger;
-import org.jboss.util.UnexpectedThrowable;
-
-/**
- * A SystemTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.2 $
- */
-public abstract class AbstractSystemTest extends AbstractTestCaseWithSetup
-{
- private static Logger staticLog = Logger.getLogger(AbstractSystemTest.class);
-
- // @fixme move to AbstractTestCase
- public static void checkThrowableDeep(Class<? extends Throwable> expected, Throwable throwable) throws Exception
- {
- assertNotNull(expected);
- assertNotNull(throwable);
-
- Throwable original = throwable;
-
- while (throwable.getCause() != null)
- throwable = throwable.getCause();
-
- if (expected.equals(throwable.getClass()) == false)
- {
- if (original instanceof Exception)
- throw (Exception) original;
- else if (original instanceof Error)
- throw (Error) original;
- else
- throw new UnexpectedThrowable("UnexpectedThrowable", original);
- }
- else
- {
- staticLog.debug("Got expected " + expected.getName() + "(" + throwable + ")");
- }
- }
-
- // @fixme move to AbstractTestCase
- public static <T> T assertInstanceOf(Class<T> expected, Object object) throws Exception
- {
- if (object == null)
- return null;
- assertTrue(object.getClass(). getName() + " is not an instance of " + expected.getName(), expected.isInstance(object));
- return expected.cast(object);
- }
-
-
- /**
- * Create a new ContainerTest.
- *
- * @param name the test name
- */
- public AbstractSystemTest(String name)
- {
- super(name);
- }
-
- /**
- * Default setup with security manager enabled
- *
- * @param clazz the class
- * @return the delegate
- * @throws Exception for any error
- */
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- AbstractTestDelegate delegate = new AbstractTestDelegate(clazz);
- delegate.enableSecurity = true;
- return delegate;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/AbstractSystemTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,51 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test;
-
-import org.jboss.test.system.SystemTestSuite;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * All Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class SystemAllTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("All Tests");
-
- suite.addTest(SystemTestSuite.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/SystemAllTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/classloading (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/classloading)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,347 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.classloading;
-
-import java.net.URL;
-import java.net.URLClassLoader;
-import java.security.ProtectionDomain;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Enumeration;
-
-import org.jboss.test.AbstractSystemTest;
-import org.jboss.mx.loading.DomainClassLoaderUCLImpl;
-import org.jboss.mx.loading.UnifiedLoaderRepositoryDCL;
-
-/**
- * Test of the legacy UCL class loader as a DomainClassLoader.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision:$
- */
-public class UCLDomainClassLoaderTest extends AbstractSystemTest
-{
- // Classes that should not be found in the unit test classpath
- static String[] SUPPORT_CLASSES = {
- "org.jboss.test.support.jar1.simple1.Bean1",
- "org.jboss.test.support.jar1.simple1.ISimpleBean",
- "org.jboss.test.support.jar2.simple1.Jar1Consumer"
- };
- // Resources that should not be found in the unit test classpath
- static String[] SUPPORT_RESOURCES = {
- "resource1.xml"
- };
-
- public UCLDomainClassLoaderTest(String name)
- {
- super(name);
- }
-
-
- /**
- * Validate that SUPPORT_CLASSES are not on the unit test classpath
- */
- @Override
- protected void setUp() throws Exception
- {
- super.setUp();
- // Assert that Bean1 is not visible to this test class loader
- ClassLoader tcl = Thread.currentThread().getContextClassLoader();
- for(String name : SUPPORT_CLASSES)
- {
- try
- {
- Class beanClass = tcl.loadClass(name);
- fail("Was able to find "+name+", "+beanClass.getProtectionDomain());
- }
- catch(ClassNotFoundException e)
- {
- getLog().debug(name+" is not on unit test classpath");
- }
- }
- for(String name : SUPPORT_RESOURCES)
- {
- URL resURL = tcl.getResource(name);
- if( resURL != null )
- fail("Was able to find "+name+", "+resURL);
- else
- getLog().debug(name+" is not on unit test classpath");
- }
- }
-
-
- /**
- * Basic test of loading classes from /simple1.jar
- * @throws Exception
- */
- public void testSimple1Jar()
- throws Exception
- {
- String beanClassName = "org.jboss.test.support.jar1.simple1.Bean1";
-
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp = buildClasspath("/jar1.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp));
- DomainClassLoaderUCLImpl loader = new DomainClassLoaderUCLImpl(cp, repository);
- Class beanClass = repository.loadClass(beanClassName);
- assertNotNull(beanClass);
- ProtectionDomain pd = beanClass.getProtectionDomain();
- getLog().info(beanClass+", PD: "+pd);
- String path = pd.getCodeSource().getLocation().getPath();
- assertTrue("Bean1.PD ends with jar1.jar", path.endsWith("jar1.jar"));
- Object bean = beanClass.newInstance();
- assertSame(loader, bean.getClass().getClassLoader());
- }
-
- /**
- * Basic test of loading classes in /jar2.jar which has a Class-Path
- * manifest entry pointing to /jar1.jar
- *
- * @throws Exception
- */
- public void testSimple2JarWithManifestCP()
- throws Exception
- {
- String beanClassName = "org.jboss.test.support.jar2.Jar1Consumer";
-
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp = buildClasspath("/jar2CPjar1.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp));
- DomainClassLoaderUCLImpl loader = new DomainClassLoaderUCLImpl(cp, repository);
- Class beanClass = repository.loadClass(beanClassName);
- assertNotNull(beanClass);
- ProtectionDomain pd = beanClass.getProtectionDomain();
- getLog().info(beanClass+", PD: "+pd);
- String path = pd.getCodeSource().getLocation().getPath();
- assertTrue("Jar1Consumer.PD ends with jar2CPjar1.jar", path.endsWith("jar2CPjar1.jar"));
- Object bean = beanClass.newInstance();
- assertSame(loader, bean.getClass().getClassLoader());
-
- Class beanClass2 = repository.loadClass("org.jboss.test.support.jar1.simple1.ISimpleBean");
- assertNotNull(beanClass2);
- pd = beanClass2.getProtectionDomain();
- getLog().info(beanClass2+", PD: "+pd);
- path = pd.getCodeSource().getLocation().getPath();
- assertTrue("ISimpleBean.PD ends with jar1.jar", path.endsWith("jar1.jar"));
- assertSame(loader, beanClass2.getClassLoader());
- }
-
- /**
- * Test that multiple independent jars can be combined to form a classpath
- * @throws Exception
- */
- public void testMulitipleJars()
- throws Exception
- {
- String beanClassName = "org.jboss.test.support.jar2.Jar1Consumer";
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp = buildClasspath("/jar1.jar", "/jar2.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp));
- DomainClassLoaderUCLImpl loader = new DomainClassLoaderUCLImpl(cp, repository);
- Class beanClass = repository.loadClass(beanClassName);
- assertNotNull(beanClass);
- ProtectionDomain pd = beanClass.getProtectionDomain();
- getLog().info(beanClass+", PD: "+pd);
- String path = pd.getCodeSource().getLocation().getPath();
- assertTrue("Jar1Consumer.PD ends with jar2.jar", path.endsWith("jar2.jar"));
- Object bean = beanClass.newInstance();
- assertSame(loader, bean.getClass().getClassLoader());
-
- Class beanClass2 = repository.loadClass("org.jboss.test.support.jar1.simple1.ISimpleBean");
- assertNotNull(beanClass);
- pd = beanClass2.getProtectionDomain();
- getLog().info(beanClass2+", PD: "+pd);
- path = pd.getCodeSource().getLocation().getPath();
- assertTrue("ISimpleBean.PD ends with jar1.jar", path.endsWith("jar1.jar"));
- assertSame(loader, beanClass2.getClassLoader());
- }
-
- /**
- * Test that multiple class loaders combine to form a uniform repository
- * @throws Exception
- */
- public void testMutipleClassLoaders()
- throws Exception
- {
- String beanClassName = "org.jboss.test.support.jar2.Jar1Consumer";
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp1 = buildClasspath("/jar1.jar");
- URL[] cp2 = buildClasspath("/jar2.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp1));
- DomainClassLoaderUCLImpl loader1 = new DomainClassLoaderUCLImpl(cp1, repository);
- loader1.getURLs();
- getLog().info("Using classpath: "+Arrays.asList(cp2));
- DomainClassLoaderUCLImpl loader2 = new DomainClassLoaderUCLImpl(cp2, repository);
- Class beanClass = loader1.loadClass(beanClassName);
- assertNotNull(beanClass);
- ProtectionDomain pd = beanClass.getProtectionDomain();
- getLog().info(beanClass+", PD: "+pd);
- String path = pd.getCodeSource().getLocation().getPath();
- assertTrue("Jar1Consumer.PD ends with jar2.jar", path.endsWith("jar2.jar"));
- Object bean = beanClass.newInstance();
- assertSame(loader2, bean.getClass().getClassLoader());
-
- Class beanClass2 = repository.loadClass("org.jboss.test.support.jar1.simple1.ISimpleBean");
- assertNotNull(beanClass);
- pd = beanClass2.getProtectionDomain();
- getLog().info(beanClass2+", PD: "+pd);
- path = pd.getCodeSource().getLocation().getPath();
- assertTrue("ISimpleBean.PD ends with jar1.jar", path.endsWith("jar1.jar"));
- assertSame(loader1, beanClass2.getClassLoader());
- }
-
- /**
- * Test finding resources in a single jar
- * @throws Exception
- */
- public void testSimple1Resource()
- throws Exception
- {
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp = buildClasspath("/jar1.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp));
- DomainClassLoaderUCLImpl loader = new DomainClassLoaderUCLImpl(cp, repository);
- URL resURL = repository.getResource("resource1.xml", loader);
- assertNotNull(resURL);
- getLog().info(resURL);
- String path = resURL.getPath();
- assertTrue("res path contains jar1.jar", path.indexOf("jar1.jar") > 0);
-
- Enumeration<URL> resURLs = repository.findResources("resource1.xml");
- int count = 0;
- while( resURLs.hasMoreElements() )
- {
- getLog().info(resURLs.nextElement());
- count ++;
- }
- assertEquals("1 resource1.xml", 1, count);
- }
-
- /**
- * Basic test of finding resources in /jar2.jar which has a Class-Path
- * manifest entry pointing to /jar1.jar
- *
- * @throws Exception
- */
- public void testSimple2ResourcesWithManifestCP()
- throws Exception
- {
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp = buildClasspath("/jar2CPjar1.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp));
- DomainClassLoaderUCLImpl loader = new DomainClassLoaderUCLImpl(cp, repository);
- URL resURL = repository.getResource("resource1.xml", loader);
- assertNotNull(resURL);
- getLog().info(resURL);
- String path = resURL.getPath();
- assertTrue("res path contains jar1.jar", path.indexOf("jar1.jar") > 0);
-
- Enumeration<URL> resURLs = repository.findResources("resource1.xml");
- int count = 0;
- while( resURLs.hasMoreElements() )
- {
- getLog().info(resURLs.nextElement());
- count ++;
- }
- assertEquals("1 resource1.xml", 1, count);
- }
-
- /**
- * Test that multiple independent jars can be combined to form a resource path
- * @throws Exception
- */
- public void testMulitipleJarsResource()
- throws Exception
- {
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp = buildClasspath("/jar1.jar", "/jar2.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp));
- DomainClassLoaderUCLImpl loader = new DomainClassLoaderUCLImpl(cp, repository);
- URL resURL = repository.getResource("resource1.xml", loader);
- assertNotNull(resURL);
- getLog().info(resURL);
- String path = resURL.getPath();
- assertTrue("res path contains jar1.jar", path.indexOf("jar1.jar") > 0);
-
- Enumeration<URL> resURLs = repository.findResources("resource1.xml");
- int count = 0;
- while( resURLs.hasMoreElements() )
- {
- getLog().info(resURLs.nextElement());
- count ++;
- }
- assertEquals("2 resource1.xml", 2, count);
- }
-
- /**
- * Test that multiple class loaders combine to form a uniform repository
- * for resources
- * @throws Exception
- */
- public void testMutipleClassLoadersResource()
- throws Exception
- {
- UnifiedLoaderRepositoryDCL repository = new UnifiedLoaderRepositoryDCL();
- URL[] cp1 = buildClasspath("/jar1.jar");
- URL[] cp2 = buildClasspath("/jar2.jar");
- getLog().info("Using classpath: "+Arrays.asList(cp1));
- DomainClassLoaderUCLImpl loader1 = new DomainClassLoaderUCLImpl(cp1, repository);
- loader1.getURLs();
- getLog().info("Using classpath: "+Arrays.asList(cp2));
- DomainClassLoaderUCLImpl loader2 = new DomainClassLoaderUCLImpl(cp2, repository);
- URL resURL = repository.getResource("resource1.xml", loader1);
- assertNotNull(resURL);
- getLog().info(resURL);
- String path = resURL.getPath();
- assertTrue("res path contains jar1.jar", path.indexOf("jar1.jar") > 0);
- resURL = repository.getResource("resource1.xml", loader2);
- assertNotNull(resURL);
- getLog().info(resURL);
- path = resURL.getPath();
- assertTrue("res path contains jar2.jar", path.indexOf("jar2.jar") > 0);
-
- Enumeration<URL> resURLs = repository.findResources("resource1.xml");
- int count = 0;
- while( resURLs.hasMoreElements() )
- {
- getLog().info(resURLs.nextElement());
- count ++;
- }
- assertEquals("2 resource1.xml", 2, count);
- }
-
- private URL[] buildClasspath(String... jars)
- {
- ArrayList<URL> cp = new ArrayList<URL>();
- for(String jar : jars)
- {
- // This needs to use the fully pathname syntax
- URL jarURL = super.getResource("/org/jboss/test/classloading/" + jar);
- if( jarURL == null )
- fail("Failed to find resource for jar: "+jar);
- cp.add(jarURL);
- }
- URL[] tmp = new URL[cp.size()];
- cp.toArray(tmp);
- return tmp;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/classloading/UCLDomainClassLoaderTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,53 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.system.controller.test.ControllerTestSuite;
-import org.jboss.test.system.metadata.test.MetaDataTestSuite;
-
-/**
- * System Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class SystemTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("System Tests");
-
- suite.addTest(MetaDataTestSuite.suite());
- suite.addTest(ControllerTestSuite.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/SystemTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,384 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-import java.io.IOException;
-import java.net.URL;
-import java.util.Collections;
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.AbstractSystemTest;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.Order;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * A Controller Test.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.2 $
- */
-public abstract class AbstractControllerTest extends AbstractSystemTest
-{
- public static boolean OLD_NOT_REGISTERED = false;
- public static boolean OLD_REGISTERED = true;
-
- /**
- * Create a new ContainerTest.
- *
- * @param name the test name
- */
- public AbstractControllerTest(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getNewControllerDelegate(Class clazz) throws Exception
- {
- ControllerTestDelegate delegate = new NewControllerTestDelegate(clazz);
- // @todo delegate.enableSecurity = true;
- return delegate;
- }
-
- public static AbstractTestDelegate getOldControllerDelegate(Class clazz) throws Exception
- {
- ControllerTestDelegate delegate = new OldControllerTestDelegate(clazz);
- // @todo delegate.enableSecurity = true;
- return delegate;
- }
-
- protected void setUp() throws Exception
- {
- super.setUp();
- Order.reset();
- }
-
- protected void tearDown() throws Exception
- {
- getControllerDelegate().uninstallTemporary();
- super.tearDown();
- }
-
- protected ControllerTestDelegate getControllerDelegate()
- {
- return (ControllerTestDelegate) getDelegate();
- }
-
- protected MBeanServer getServer()
- {
- return getControllerDelegate().getServer();
- }
-
- protected ServiceControllerMBean getController()
- {
- return getControllerDelegate().getController();
- }
-
- protected List<ObjectName> deploy(URL url) throws Exception
- {
- return getControllerDelegate().deploy(url, true);
- }
-
- protected List<ObjectName> deploy(String resource) throws Exception
- {
- URL url = getResourceURL(resource);
- return deploy(url);
- }
-
- protected void undeploy(List<ObjectName> objectNames)
- {
- getControllerDelegate().undeploy(objectNames);
- }
-
- protected List<ObjectName> install(String resource) throws Exception
- {
- URL url = getResourceURL(resource);
- return install(url);
- }
-
- protected List<ObjectName> install(URL url) throws Exception
- {
- return getControllerDelegate().install(url);
- }
-
- protected void uninstall(List<ObjectName> objectNames)
- {
- getControllerDelegate().uninstall(objectNames);
- }
-
- protected void assertInstall(ObjectName name) throws Exception
- {
-
- String resource = getName();
- resource = resource.substring(4) + "_install.xml";
- install(resource);
-
- assertServiceConfigured(name);
- assertRegistered(name);
- }
-
- protected void assertUninstall(ObjectName name) throws Exception
- {
- uninstall(Collections.singletonList(name));
- assertNoService(name);
- assertNotRegistered(name);
- }
-
- protected List<ObjectName> assertDeploy(ObjectName name) throws Exception
- {
-
- String resource = getName();
- resource = resource.substring(4) + "_install.xml";
- List<ObjectName> result = deploy(resource);
-
- assertServiceRunning(name);
- assertRegistered(name);
-
- return result;
- }
-
- protected void assertUndeploy(ObjectName name) throws Exception
- {
- assertUndeploy(name, Collections.singletonList(name));
- }
-
- protected void assertUndeploy(ObjectName name, List<ObjectName> names) throws Exception
- {
- uninstall(names);
- assertNoService(name);
- assertNotRegistered(name);
- }
-
- protected void validate() throws Exception
- {
- getControllerDelegate().validate();
- }
-
- protected void assertInvalidDeployments() throws Exception
- {
- getControllerDelegate().assertInvalidDeployments();
- }
-
- protected void assertInitialDeployFailure(String resource, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- URL url = getResourceURL(resource);
- getControllerDelegate().assertInitialDeployFailure(url, name, expected);
- }
-
- protected List<ObjectName> assertDeployFailure(ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- return assertDeployFailure(name, ServiceContext.FAILED, expected);
- }
-
- protected List<ObjectName> assertDeployFailure(ObjectName name, int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- String resource = getName();
- resource = resource.substring(4) + "_bad.xml";
- return assertDeployFailure(resource, name, expectedState, expected);
- }
-
- protected List<ObjectName> assertDeployFailure(String resource, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- return assertDeployFailure(resource, name, ServiceContext.FAILED, expected);
- }
-
- protected List<ObjectName> assertDeployFailure(String resource, ObjectName name, int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- URL url = getResourceURL(resource);
- List<ObjectName> result = getControllerDelegate().assertDeployFailure(url, name, expected);
- if (expectedState == ServiceContext.FAILED)
- assertServiceFailed(name, OLD_REGISTERED);
- else
- assertServiceState(name, expectedState);
- return result;
- }
-
- protected void redeployAfterDeployFailure(ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- String root = getName();
- root = root.substring(4);
-
- List<ObjectName> names = assertDeployFailure(root + "_bad.xml", SimpleMBean.OBJECT_NAME, expected);
- undeploy(names);
- deploy(root + "_good.xml");
- assertServiceRunning(name);
- }
-
- protected void redeployAfterUndeployFailure(ObjectName name) throws Exception
- {
- String root = getName();
- root = root.substring(4);
-
- List<ObjectName> names = deploy(root + "_bad.xml");
- assertServiceRunning(name);
- undeploy(names);
- deploy(root + "_good.xml");
- assertServiceRunning(name);
- }
-
- protected List<ObjectName> assertMaybeDeployFailure(ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- String resource = getName();
- resource = resource.substring(4) + "_bad.xml";
- return assertMaybeDeployFailure(resource, name, expected);
- }
-
- protected List<ObjectName> assertMaybeDeployFailure(String resource, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- URL url = getResourceURL(resource);
- List<ObjectName> result = getControllerDelegate().assertMaybeDeployFailure(url, name, expected);
- assertServiceFailed(name, OLD_NOT_REGISTERED);
- return result;
- }
-
- protected void redeployAfterMaybeDeployFailure(ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- String root = getName();
- root = root.substring(4);
-
- List<ObjectName> names = assertMaybeDeployFailure(root + "_bad.xml", SimpleMBean.OBJECT_NAME, expected);
- undeploy(names);
- deploy(root + "_good.xml");
- assertServiceRunning(name);
- }
-
- protected void assertMaybeParseFailure(ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- String resource = getName();
- resource = resource.substring(4) + "_bad.xml";
- assertMaybeParseFailure(resource, name, expected);
- }
-
- protected void assertMaybeParseFailure(String resource, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- URL url = getResourceURL(resource);
- getControllerDelegate().assertMaybeParseFailure(url, name, expected);
- assertServiceFailed(name, OLD_NOT_REGISTERED);
- }
-
- protected ServiceContext getServiceContext(ObjectName name) throws Exception
- {
- assertNotNull(name);
- return getControllerDelegate().getServiceContext(name);
- }
-
- protected void assertServiceFailed(ObjectName name) throws Exception
- {
- assertServiceFailed(name, OLD_REGISTERED);
- }
-
- protected void assertServiceFailed(ObjectName name, boolean registered) throws Exception
- {
- getControllerDelegate().assertServiceFailed(name, registered);
- }
-
- protected void assertServiceInstalled(ObjectName name) throws Exception
- {
- assertServiceState(name, ServiceContext.INSTALLED, true);
- }
-
- protected void assertServiceConfigured(ObjectName name) throws Exception
- {
- assertServiceState(name, ServiceContext.CONFIGURED, true);
- }
-
- protected void assertServiceCreated(ObjectName name) throws Exception
- {
- assertServiceState(name, ServiceContext.CREATED, true);
- }
-
- protected void assertServiceRunning(ObjectName name) throws Exception
- {
- assertServiceState(name, ServiceContext.RUNNING, true);
- }
-
- protected void assertServiceStopped(ObjectName name) throws Exception
- {
- assertServiceState(name, ServiceContext.STOPPED, true);
- }
-
- protected void assertServiceDestroyed(ObjectName name) throws Exception
- {
- assertServiceState(name, ServiceContext.DESTROYED, true);
- }
-
- protected void assertServiceState(ObjectName name, int expectedState) throws Exception
- {
- ServiceContext ctx = getServiceContext(name);
- assertTrue("Incorrect state for " + name + " expected " + ServiceContext.getStateString(expectedState) + " got " + ctx.getStateString(), expectedState == ctx.state);
- }
-
- protected void assertServiceState(ObjectName name, int expectedState, boolean registered) throws Exception
- {
- getControllerDelegate().assertServiceState(name, expectedState, registered);
- }
-
- protected void assertNoService(ObjectName name) throws Exception
- {
- ServiceContext ctx = getServiceContext(name);
- assertNull("Should not be a service context for " + name, ctx);
- }
-
- protected URL getResourceURL(String resource) throws Exception
- {
- URL url = getClass().getResource(resource);
- if (url == null)
- throw new IOException(resource + " not found");
- return url;
- }
-
- protected void assertRegistered(ObjectName name) throws Exception
- {
- MBeanServer server = getServer();
- assertTrue(name + " should be registered in the MBeanServer", server.isRegistered(name));
- }
-
- protected void assertNotRegistered(ObjectName name) throws Exception
- {
- MBeanServer server = getServer();
- assertFalse(name + " should NOT be registered in the MBeanServer", server.isRegistered(name));
- }
-
- protected <T> T getMBean(Class<T> expected, ObjectName name, String attribute) throws Exception
- {
- MBeanServer server = getServer();
- Object object = server.getAttribute(name, attribute);
- assertNotNull(object);
- return assertInstanceOf(expected, object);
- }
-
- protected Simple getSimple() throws Exception
- {
- return getMBean(Simple.class, SimpleMBean.OBJECT_NAME, "Instance");
- }
-
- protected void FAILS_IN_OLD()
- {
- getLog().debug("This test fails with the old service controller, ignoring.");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/AbstractControllerTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,307 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-import java.lang.reflect.UndeclaredThrowableException;
-import java.net.URL;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.MBeanServerFactory;
-import javax.management.ObjectName;
-
-import junit.framework.AssertionFailedError;
-
-import org.jboss.deployment.IncompleteDeploymentException;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.AbstractSystemTest;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.Order;
-
-/**
- * ControllerTestDelegate.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ControllerTestDelegate extends AbstractTestDelegate
-{
- private MBeanServer server;
-
- private ServiceControllerMBean serviceController;
-
- private SimpleSARDeployer deployer;
-
- public ControllerTestDelegate(Class clazz)
- {
- super(clazz);
- }
-
- public MBeanServer getServer()
- {
- return server;
- }
-
- public ServiceControllerMBean getController()
- {
- return serviceController;
- }
-
- public void setUp() throws Exception
- {
- super.setUp();
-
- System.setProperty(ServerConstants.MBEAN_SERVER_BUILDER_CLASS_PROPERTY, ServerConstants.DEFAULT_MBEAN_SERVER_BUILDER_CLASS);
- server = MBeanServerFactory.newMBeanServer("jboss");
- serviceController = createServiceController();
- server.registerMBean(serviceController, ServiceControllerMBean.OBJECT_NAME);
-
- deployer = new SimpleSARDeployer(server, serviceController);
-
- Order.reset();
-
- deploy();
-
- if (isValidateAtSetUp())
- validate();
- }
-
- // TODO Temporary until the IncompleteDeploymentDescription is integrated
- protected boolean isValidateAtSetUp()
- {
- return true;
- }
-
- public abstract ServiceControllerMBean createServiceController() throws Exception;
-
- public void tearDown() throws Exception
- {
- deployer.uninstall();
- super.tearDown();
- }
-
- protected void uninstallTemporary() throws Exception
- {
- deployer.uninstallTemporary();
- }
-
- protected void validate() throws Exception
- {
- Collection<ServiceContext> waitingForClasses = new HashSet<ServiceContext>();
- Collection<ServiceContext> waitingForDepends = serviceController.listIncompletelyDeployed();
- Collection<ServiceContext> allServices = serviceController.listDeployed();
-
- // Weed services that are waiting for other deployments
- Collection<ServiceContext> rootCause = new HashSet<ServiceContext>(waitingForDepends);
- Collection<ServiceContext> missing = new HashSet<ServiceContext>();
- for (Iterator i = rootCause.iterator(); i.hasNext();)
- {
- ServiceContext ctx = (ServiceContext) i.next();
- for (Iterator j = ctx.iDependOn.iterator(); j.hasNext(); )
- {
- ServiceContext dependee = (ServiceContext) j.next();
- if (dependee.state != ServiceContext.RUNNING)
- {
- // Add missing mbean
- if (allServices.contains(dependee) == false)
- missing.add(dependee);
- // We are not a root cause
- i.remove();
- break;
- }
- }
- }
- // Add missing mbeans to the root cause
- rootCause.addAll(missing);
-
- IncompleteDeploymentException ide = new IncompleteDeploymentException(
- waitingForClasses,
- waitingForDepends,
- rootCause,
- Collections.emptyList(),
- Collections.emptyList());
-
- if (ide.isEmpty() == false)
- throw ide;
- }
-
- protected void deploy() throws Exception
- {
- String testName = clazz.getName();
- testName = testName.replace('.', '/');
-
- int index = testName.indexOf("NewUnitTestCase");
- if (index != -1)
- testName = testName.substring(0, index);
- index = testName.indexOf("OldUnitTestCase");
- if (index != -1)
- testName = testName.substring(0, index);
-
- testName += ".xml";
-
- URL url = clazz.getClassLoader().getResource(testName);
- if (url != null)
- deploy(url, false);
- else
- log.debug("No test specific deployment " + testName);
- }
-
- protected List<ObjectName> deploy(URL url, boolean temporary) throws Exception
- {
- return deployer.deploy(url, temporary);
- }
-
- protected void undeploy(List<ObjectName> objectNames)
- {
- deployer.undeploy(objectNames);
- }
-
- protected List<ObjectName> install(URL url) throws Exception
- {
- return deployer.install(url);
- }
-
- protected void uninstall(List<ObjectName> objectNames)
- {
- deployer.uninstall(objectNames);
- }
-
- public abstract void assertMBeanFailed(ObjectName name, boolean registered) throws Exception;
-
- protected IncompleteDeploymentException assertInvalidDeployments() throws Exception
- {
- try
- {
- validate();
- throw new AssertionFailedError("Deployments should not be valid!");
- }
- catch (IncompleteDeploymentException expected)
- {
- log.debug("Got expected " + expected.getClass().getName());
- return expected;
- }
- }
-
- protected void assertInitialDeployFailure(URL url, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- try
- {
- deploy(url, true);
- throw new AssertionFailedError("Should have got a " + expected.getName());
- }
- catch (Throwable t)
- {
- AbstractSystemTest.checkThrowableDeep(expected, t);
- }
- if (name != null)
- assertNoService(name);
- }
-
- public List<ObjectName> assertDeployFailure(URL url, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- List<ObjectName> result = deploy(url, true);
- IncompleteDeploymentException e = assertInvalidDeployments();
- checkIncomplete(e, name, expected);
- return result;
- }
-
- public List<ObjectName> assertMaybeDeployFailure(URL url, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- return assertDeployFailure(url, name, expected);
- }
-
- public void assertMaybeParseFailure(URL url, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- assertDeployFailure(url, name, expected);
- assertServiceFailed(name);
- }
-
- protected void checkIncomplete(IncompleteDeploymentException e, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- Collection incomplete = e.getMbeansWaitingForDepends();
- for (Iterator i = incomplete.iterator(); i.hasNext();)
- {
- ServiceContext ctx = (ServiceContext) i.next();
- if (name.equals(ctx.objectName))
- {
- if (e != null || expected != null)
- {
- if (expected != null && ctx.problem == null)
- throw new AssertionFailedError("Did not get expected " + expected.getName() + " for " + ctx);
- if (expected == null && ctx.problem != null)
- {
- if (ctx.problem instanceof Exception)
- throw (Exception) ctx.problem;
- if (ctx.problem instanceof Error)
- throw (Error) ctx.problem;
- throw new UndeclaredThrowableException(ctx.problem);
- }
- if (expected != null)
- AbstractSystemTest.checkThrowableDeep(expected, ctx.problem);
- }
- return;
- }
- }
-
- throw new AssertionFailedError("Did not find " + name + " in incomplete deployments " + incomplete);
- }
-
- protected ServiceContext getServiceContext(ObjectName name) throws Exception
- {
- return getController().getServiceContext(name);
- }
-
- protected void assertNoService(ObjectName name) throws Exception
- {
- ServiceContext ctx = getServiceContext(name);
- if (ctx != null && ctx.state != ServiceContext.NOTYETINSTALLED)
- throw new AssertionFailedError("Should not be a service context for " + ctx);
- }
-
- protected void assertServiceFailed(ObjectName name) throws Exception
- {
- assertServiceFailed(name, AbstractControllerTest.OLD_REGISTERED);
- }
-
- protected void assertServiceFailed(ObjectName name, boolean registered) throws Exception
- {
- assertServiceState(name, ServiceContext.FAILED, registered);
- assertMBeanFailed(name, registered);
- }
-
- protected void assertServiceState(ObjectName name, int expectedState, boolean registered) throws Exception
- {
- ServiceContext ctx = getServiceContext(name);
- if (registered == false && ctx == null)
- return;
- if (ctx == null)
- throw new AssertionFailedError("Incorrect state for " + name + " expected " + ServiceContext.getStateString(expectedState) + " but there is no context/state");
- if (expectedState != ctx.state)
- throw new AssertionFailedError("Incorrect state for " + name + " expected " + ServiceContext.getStateString(expectedState) + " got " + ctx.getStateString());
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/ControllerTestDelegate.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceController;
-import org.jboss.system.ServiceControllerMBean;
-
-import junit.framework.AssertionFailedError;
-
-/**
- * ControllerTestDelegate.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class NewControllerTestDelegate extends ControllerTestDelegate
-{
- public NewControllerTestDelegate(Class clazz)
- {
- super(clazz);
- }
-
- public ServiceControllerMBean createServiceController() throws Exception
- {
- return new ServiceController();
- }
-
- public void assertMBeanFailed(ObjectName name, boolean registered) throws Exception
- {
- MBeanServer server = getServer();
- if (server.isRegistered(name))
- throw new AssertionFailedError(name + " should not be registered after a failure");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/NewControllerTestDelegate.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,89 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-import java.net.URL;
-import java.util.Collections;
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import junit.framework.AssertionFailedError;
-
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.AbstractSystemTest;
-import org.jboss.test.system.controller.legacy.OldServiceController;
-
-/**
- * ControllerTestDelegate.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class OldControllerTestDelegate extends ControllerTestDelegate
-{
- public OldControllerTestDelegate(Class clazz)
- {
- super(clazz);
- }
-
- public ServiceControllerMBean createServiceController()
- {
- return new OldServiceController();
- }
-
- public void assertMBeanFailed(ObjectName name, boolean registered) throws Exception
- {
- MBeanServer server = getServer();
- if (registered == false && server.isRegistered(name))
- throw new AssertionFailedError(name + " should not be registered after a failure");
- if (registered && server.isRegistered(name) == false)
- throw new AssertionFailedError(name + " should be registered after a failure");
- }
-
- public List<ObjectName> assertMaybeDeployFailure(URL url, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- if (expected != null)
- {
- try
- {
- deploy(url, true);
- throw new AssertionFailedError("Should have got a " + expected.getName());
- }
- catch (Throwable throwable)
- {
- AbstractSystemTest.checkThrowableDeep(expected, throwable);
- return Collections.emptyList();
- }
- }
- else
- {
- return super.assertMaybeDeployFailure(url, name, expected);
- }
- }
-
- public void assertMaybeParseFailure(URL url, ObjectName name, Class<? extends Throwable> expected) throws Exception
- {
- assertInitialDeployFailure(url, name, expected);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/OldControllerTestDelegate.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,235 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-import java.io.InputStream;
-import java.net.URL;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.concurrent.CopyOnWriteArrayList;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.util.xml.JBossEntityResolver;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.xml.sax.InputSource;
-
-/**
- * SimpleSARDeployer.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SimpleSARDeployer
-{
- private static Logger log = Logger.getLogger(SimpleSARDeployer.class);
-
- public static ObjectName classLoaderObjectName = ObjectNameFactory.create("test:classloader=test");
-
- private ServiceControllerMBean serviceController;
-
- private List<ObjectName> deployed = new CopyOnWriteArrayList<ObjectName>();
-
- private List<ObjectName> tempDeployed = new CopyOnWriteArrayList<ObjectName>();
-
- private DocumentBuilder parser;
-
- public SimpleSARDeployer(MBeanServer server, ServiceControllerMBean serviceController) throws Exception
- {
- this.serviceController = serviceController;
-
- TestClassLoader classLoader = new TestClassLoader();
- server.registerMBean(classLoader, classLoaderObjectName);
-
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- parser = factory.newDocumentBuilder();
- }
-
- public List<ObjectName> deploy(URL url, boolean temporary) throws Exception
- {
- long start = System.currentTimeMillis();
-
- List<ObjectName> result = doInstall(url, temporary);
-
- try
- {
- create(result);
- try
- {
- start(result);
- }
- catch (Throwable t)
- {
- stop(result);
- throw t;
- }
- }
- catch (Throwable t)
- {
- destroy(result);
- remove(result);
- DeploymentException.rethrowAsDeploymentException("Error", t);
- }
-
- log.debug("Deployed " + url + " took " + (System.currentTimeMillis() - start) + "ms");
- return result;
- }
-
- public void uninstall()
- {
- undeploy(deployed);
- }
-
- public void uninstallTemporary()
- {
- undeploy(tempDeployed);
- }
-
- public void undeploy(List<ObjectName> objectNames)
- {
- stop(objectNames);
- destroy(objectNames);
- remove(objectNames);
- }
-
- public void create(List<ObjectName> services) throws Exception
- {
- for (ObjectName name: services)
- serviceController.create(name);
- }
-
- public void start(List<ObjectName> services) throws Exception
- {
- for (ObjectName name: services)
- serviceController.start(name);
- }
-
- public void stop(List<ObjectName> services)
- {
- for (ListIterator<ObjectName> i = services.listIterator(services.size()); i.hasPrevious();)
- {
- ObjectName name = i.previous();
- try
- {
- serviceController.stop(name);
- }
- catch (Throwable ignored)
- {
- log.debug("Ignored", ignored);
- }
- }
- }
-
- public void destroy(List<ObjectName> services)
- {
- for (ListIterator<ObjectName> i = services.listIterator(services.size()); i.hasPrevious();)
- {
- ObjectName name = i.previous();
- try
- {
- serviceController.destroy(name);
- }
- catch (Throwable ignored)
- {
- log.debug("Ignored", ignored);
- }
- }
- }
-
- public void remove(List<ObjectName> services)
- {
- for (ObjectName name: services)
- {
- deployed.remove(name);
- tempDeployed.remove(name);
- try
- {
- serviceController.remove(name);
- }
- catch (Throwable ignored)
- {
- log.debug("Ignored", ignored);
- }
- }
- }
-
- public List<ObjectName> install(URL url) throws Exception
- {
- long start = System.currentTimeMillis();
-
- List<ObjectName> result = doInstall(url, true);
-
- log.debug("Deployed " + url + " took " + (System.currentTimeMillis() - start) + "ms");
- return result;
- }
-
- public void uninstall(List<ObjectName> services)
- {
- remove(services);
- }
-
- protected List<ObjectName> doInstall(URL url, boolean temporary) throws Exception
- {
- List<ObjectName> result = null;
-
- Element element = null;
-
- try
- {
- InputStream stream = url.openStream();
- try
- {
- InputSource is = new InputSource(stream);
- is.setSystemId(url.toString());
- parser.setEntityResolver(new JBossEntityResolver());
-
- Document document = parser.parse(is);
- element = document.getDocumentElement();
- }
- finally
- {
- stream.close();
- }
-
- result = serviceController.install(element, classLoaderObjectName);
-
- deployed.addAll(result);
- if (temporary)
- tempDeployed.addAll(result);
- }
- catch (Exception e)
- {
- log.debug("Error deploying: " + url + ": " + e);
- throw e;
- }
-
- return result;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/SimpleSARDeployer.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,39 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-import java.net.URL;
-import java.net.URLClassLoader;
-
-/**
- * TestClassLoader.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class TestClassLoader extends URLClassLoader implements TestClassLoaderMBean
-{
- public TestClassLoader()
- {
- super(new URL[0], Thread.currentThread().getContextClassLoader());
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoader.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,26 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller;
-
-public interface TestClassLoaderMBean
-{
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/TestClassLoaderMBean.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicNewUnitTestCase extends BasicTest
-{
- public static Test suite()
- {
- return suite(BasicNewUnitTestCase.class);
- }
-
- public BasicNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicOldUnitTestCase extends BasicTest
-{
- public static Test suite()
- {
- return suite(BasicOldUnitTestCase.class);
- }
-
- public BasicOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import javax.management.MBeanServer;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * BasicTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class BasicTest extends AbstractControllerTest
-{
- public BasicTest(String name)
- {
- super(name);
- }
-
- public void testBasics() throws Exception
- {
- assertServiceRunning(SimpleMBean.OBJECT_NAME);
-
- MBeanServer server = getServer();
- Simple test = (Simple) server.getAttribute(SimpleMBean.OBJECT_NAME, "Instance");
- assertEquals("()", test.constructorUsed);
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(0, test.stopOrder);
- assertEquals(0, test.destroyOrder);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/BasicTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,52 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * Controller Basic Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerBasicTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Basic Tests");
-
- suite.addTest(BasicOldUnitTestCase.suite());
- suite.addTest(BasicNewUnitTestCase.suite());
- suite.addTest(DoubleInstallOldUnitTestCase.suite());
- suite.addTest(DoubleInstallNewUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/ControllerBasicTestSuite.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DoubleInstallNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DoubleInstallNewUnitTestCase extends DoubleInstallTest
-{
- public static Test suite()
- {
- return suite(DoubleInstallNewUnitTestCase.class);
- }
-
- public DoubleInstallNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DoubleInstallOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DoubleInstallOldUnitTestCase extends DoubleInstallTest
-{
- public static Test suite()
- {
- return suite(DoubleInstallOldUnitTestCase.class);
- }
-
- public DoubleInstallOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,54 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.basic.test;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DoubleInstallTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DoubleInstallTest extends AbstractControllerTest
-{
- public DoubleInstallTest(String name)
- {
- super(name);
- }
-
- public void testDoubleInstall() throws Exception
- {
- try
- {
- deploy("DoubleInstall.xml");
- fail("Should not be able to deploy twice");
- }
- catch (Throwable t)
- {
- checkThrowable(DeploymentException.class, t);
- }
- assertServiceRunning(SimpleMBean.OBJECT_NAME);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/basic/test/DoubleInstallTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * AttributeNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class AttributeNewUnitTestCase extends AttributeTest
-{
- public static Test suite()
- {
- return suite(AttributeNewUnitTestCase.class);
- }
-
- public AttributeNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * AttributeOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class AttributeOldUnitTestCase extends AttributeTest
-{
- public static Test suite()
- {
- return suite(AttributeOldUnitTestCase.class);
- }
-
- public AttributeOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,149 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributes;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * AttributeTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class AttributeTest extends AbstractControllerTest
-{
- public AttributeTest(String name)
- {
- super(name);
- }
-
- public void testAttributeNone() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertNull(simple.getAttribute1());
- assertNull(simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testAttributeOne() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals("value1", simple.getAttribute1());
- assertNull(simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testAttributeTwo() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals("value1", simple.getAttribute1());
- assertEquals("value2", simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testAttributeNoValue() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertNull(simple.getAttribute1());
- assertNull(simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testAttributeEmptyValue() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertNull(simple.getAttribute1());
- assertNull(simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testAttributeNoName() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testAttributeEmptyName() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testAttributeBrokenGetAttributes() throws Exception
- {
- assertDeployFailure(BrokenDynamicMBeanAttributes.OBJECT_NAME, Error.class);
- }
-
- public void testAttributeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testAttributeBrokenSetAttribute() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/AttributeTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsAttributeNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsAttributeNewUnitTestCase extends DependsAttributeTest
-{
- public static Test suite()
- {
- return suite(DependsAttributeNewUnitTestCase.class);
- }
-
- public DependsAttributeNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,84 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import javax.management.AttributeNotFoundException;
-
-import junit.framework.Test;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependsAttributeOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsAttributeOldUnitTestCase extends DependsAttributeTest
-{
- public static Test suite()
- {
- return suite(DependsAttributeOldUnitTestCase.class);
- }
-
- public DependsAttributeOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testDependsAttributeNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsAttributeEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsAttributeInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testDependsAttributeUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsAttributePatternValue() throws Exception
- {
- FAILS_IN_OLD();
- }
-
- public void testDependsAttributeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, AttributeNotFoundException.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,147 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependsAttributeTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsAttributeTest extends AbstractControllerTest
-{
- static ObjectName DEPENDS1 = ObjectNameFactory.create("jboss.test:type=depends1");
- static ObjectName DEPENDS2 = ObjectNameFactory.create("jboss.test:type=depends2");
-
- public DependsAttributeTest(String name)
- {
- super(name);
- }
-
- public void testDependsAttributeNone() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertNull(simple.getObjectNameAttribute1());
- assertNull(simple.getObjectNameAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsAttributeOne() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDS1, simple.getObjectNameAttribute1());
- assertNull(simple.getObjectNameAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsAttributeTwo() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDS1, simple.getObjectNameAttribute1());
- assertEquals(DEPENDS2, simple.getObjectNameAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsAttributeNested() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDS1, simple.getObjectNameAttribute1());
- assertNull(simple.getObjectNameAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsAttributeNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsAttributeEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsAttributeInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsAttributeUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsAttributePatternValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsAttributeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsAttributeBrokenSetAttribute() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsAttributeTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsListAttributeNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsListAttributeNewUnitTestCase extends DependsListAttributeTest
-{
- public static Test suite()
- {
- return suite(DependsListAttributeNewUnitTestCase.class);
- }
-
- public DependsListAttributeNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,84 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import javax.management.AttributeNotFoundException;
-
-import junit.framework.Test;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependsListAttributeOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsListAttributeOldUnitTestCase extends DependsListAttributeTest
-{
- public static Test suite()
- {
- return suite(DependsListAttributeOldUnitTestCase.class);
- }
-
- public DependsListAttributeOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testDependsListAttributeNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsListAttributeEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsListAttributeInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testDependsListAttributeUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsListAttributePatternValue() throws Exception
- {
- FAILS_IN_OLD();
- }
-
- public void testDependsListAttributeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, AttributeNotFoundException.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,176 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.attribute.test;
-
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.List;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependsAttributeTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsListAttributeTest extends AbstractControllerTest
-{
- static ObjectName DEPENDS1 = ObjectNameFactory.create("jboss.test:type=depends1");
- static ObjectName[] DEPENDSLIST1 = new ObjectName[] { DEPENDS1 };
- static ObjectName DEPENDS2 = ObjectNameFactory.create("jboss.test:type=depends2");
- static ObjectName[] DEPENDSLIST2 = new ObjectName[] { DEPENDS2 };
- static ObjectName[] DEPENDSLIST = new ObjectName[] { DEPENDS1, DEPENDS2 };
-
- public DependsListAttributeTest(String name)
- {
- super(name);
- }
-
- protected void assertEquals(ObjectName[] expected, Collection<ObjectName> actual)
- {
- List<ObjectName> expectedList = Arrays.asList(expected);
- assertEquals(expectedList, actual);
- }
-
- public void testDependsListAttributeNone() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertNull(simple.getObjectNamesAttribute1());
- assertNull(simple.getObjectNamesAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsListAttributeOne() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST1, simple.getObjectNamesAttribute1());
- assertNull(simple.getObjectNamesAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsListAttributeTwo() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST1, simple.getObjectNamesAttribute1());
- assertEquals(DEPENDSLIST2, simple.getObjectNamesAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsListAttributeMultiple() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST, simple.getObjectNamesAttribute1());
- assertNull(simple.getObjectNamesAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsListAttributeNested() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST1, simple.getObjectNamesAttribute1());
- assertNull(simple.getObjectNamesAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependsListAttributeNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsListAttributeEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsListAttributeInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsListAttributeUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsListAttributePatternValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testDependsListAttributeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testDependsListAttributeBrokenSetAttribute() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/attribute/test/DependsListAttributeTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.binding.support;
-
-import javax.management.Attribute;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceBinding;
-
-/**
- * TestServiceBinding.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class TestServiceBinding implements ServiceBinding
-{
- private MBeanServer server;
- private boolean error;
- private ObjectName invoked;
-
- public TestServiceBinding(MBeanServer server, boolean error)
- {
- this.server = server;
- this.error = error;
- }
-
- public ObjectName getInvoked()
- {
- return invoked;
- }
-
- public void applyServiceConfig(ObjectName serviceName) throws Exception
- {
- this.invoked = serviceName;
-
- if (error)
- throw new RuntimeException("Throwing error as required by test");
-
- Attribute attribute = new Attribute("Attribute2", "frombinding");
- server.setAttribute(serviceName, attribute);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/support/TestServiceBinding.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.binding.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ServiceBindingNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceBindingNewUnitTestCase extends ServiceBindingTest
-{
- public static Test suite()
- {
- return suite(ServiceBindingNewUnitTestCase.class);
- }
-
- public ServiceBindingNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.binding.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ServiceBindingOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ServiceBindingOldUnitTestCase extends ServiceBindingTest
-{
- public static Test suite()
- {
- return suite(ServiceBindingOldUnitTestCase.class);
- }
-
- public ServiceBindingOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,120 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.binding.test;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.configure.binding.support.TestServiceBinding;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * ServiceBindingTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ServiceBindingTest extends AbstractControllerTest
-{
- public ServiceBindingTest(String name)
- {
- super(name);
- }
-
- public void testServiceBinding() throws Exception
- {
- TestServiceBinding binding = setServiceBinding(false);
- try
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- assertEquals(name, binding.getInvoked());
-
- Simple simple = getSimple();
- assertEquals("fromxml", simple.getAttribute1());
- assertEquals("frombinding", simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
- finally
- {
- unsetServiceBinding();
- }
- }
-
- public void testServiceBindingError() throws Exception
- {
- TestServiceBinding binding = setServiceBinding(true);
- try
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- assertEquals(name, binding.getInvoked());
-
- Simple simple = getSimple();
- assertEquals("fromxml", simple.getAttribute1());
- assertEquals("fromxml", simple.getAttribute2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
- finally
- {
- unsetServiceBinding();
- }
- }
-
- protected Simple getSimple() throws Exception
- {
- MBeanServer server = getServer();
- Simple simple = (Simple) server.getAttribute(SimpleMBean.OBJECT_NAME, "Instance");
- assertNotNull(simple);
- return simple;
- }
-
- protected TestServiceBinding setServiceBinding(boolean error)
- {
- MBeanServer server = getServer();
- ServiceControllerMBean controller = getController();
- TestServiceBinding serviceBinding = new TestServiceBinding(server, error);
- controller.setServiceBinding(serviceBinding);
- return serviceBinding;
- }
-
- protected void unsetServiceBinding()
- {
- ServiceControllerMBean controller = getController();
- controller.setServiceBinding(null);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/binding/test/ServiceBindingTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ConfigureRedeployAfterErrorNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConfigureRedeployAfterErrorNewUnitTestCase extends ConfigureRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(ConfigureRedeployAfterErrorNewUnitTestCase.class);
- }
-
- public ConfigureRedeployAfterErrorNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ConfigureRedeployAfterErrorOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConfigureRedeployAfterErrorOldUnitTestCase extends ConfigureRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(ConfigureRedeployAfterErrorOldUnitTestCase.class);
- }
-
- public ConfigureRedeployAfterErrorOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.test;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * ConfigureRedeployAfterErrorTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ConfigureRedeployAfterErrorTest extends AbstractControllerTest
-{
- public ConfigureRedeployAfterErrorTest(String name)
- {
- super(name);
- }
-
- public void testConfigureRedeployAfterError() throws Exception
- {
- redeployAfterDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ConfigureRedeployAfterErrorTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,69 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.system.controller.configure.attribute.test.AttributeNewUnitTestCase;
-import org.jboss.test.system.controller.configure.attribute.test.AttributeOldUnitTestCase;
-import org.jboss.test.system.controller.configure.attribute.test.DependsAttributeNewUnitTestCase;
-import org.jboss.test.system.controller.configure.attribute.test.DependsAttributeOldUnitTestCase;
-import org.jboss.test.system.controller.configure.attribute.test.DependsListAttributeNewUnitTestCase;
-import org.jboss.test.system.controller.configure.attribute.test.DependsListAttributeOldUnitTestCase;
-import org.jboss.test.system.controller.configure.binding.test.ServiceBindingNewUnitTestCase;
-import org.jboss.test.system.controller.configure.binding.test.ServiceBindingOldUnitTestCase;
-import org.jboss.test.system.controller.configure.value.ControllerConfigureValueTestSuite;
-
-/**
- * Controller Configure Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerConfigureTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Configure Tests");
-
- suite.addTest(AttributeOldUnitTestCase.suite());
- suite.addTest(AttributeNewUnitTestCase.suite());
- suite.addTest(DependsAttributeOldUnitTestCase.suite());
- suite.addTest(DependsAttributeNewUnitTestCase.suite());
- suite.addTest(DependsListAttributeOldUnitTestCase.suite());
- suite.addTest(DependsListAttributeNewUnitTestCase.suite());
- suite.addTest(ServiceBindingOldUnitTestCase.suite());
- suite.addTest(ServiceBindingNewUnitTestCase.suite());
- suite.addTest(ControllerConfigureValueTestSuite.suite());
- suite.addTest(ConfigureRedeployAfterErrorOldUnitTestCase.suite());
- suite.addTest(ConfigureRedeployAfterErrorNewUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/test/ControllerConfigureTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,75 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value;
-
-import org.jboss.test.system.controller.configure.value.depends.test.DependencyValueNewUnitTestCase;
-import org.jboss.test.system.controller.configure.value.depends.test.DependencyValueOldUnitTestCase;
-import org.jboss.test.system.controller.configure.value.dependslist.test.DependencyListValueNewUnitTestCase;
-import org.jboss.test.system.controller.configure.value.dependslist.test.DependencyListValueOldUnitTestCase;
-import org.jboss.test.system.controller.configure.value.element.test.ElementValueNewUnitTestCase;
-import org.jboss.test.system.controller.configure.value.element.test.ElementValueOldUnitTestCase;
-import org.jboss.test.system.controller.configure.value.inject.test.NewInjectionValueUnitTestCase;
-import org.jboss.test.system.controller.configure.value.javabean.test.JavaBeanValueNewUnitTestCase;
-import org.jboss.test.system.controller.configure.value.javabean.test.JavaBeanValueOldUnitTestCase;
-import org.jboss.test.system.controller.configure.value.jbxb.test.JBXBValueNewUnitTestCase;
-import org.jboss.test.system.controller.configure.value.jbxb.test.JBXBValueOldUnitTestCase;
-import org.jboss.test.system.controller.configure.value.text.test.TextValueNewUnitTestCase;
-import org.jboss.test.system.controller.configure.value.text.test.TextValueOldUnitTestCase;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * Controller Configure Value Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerConfigureValueTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Configure Value Tests");
-
- suite.addTest(TextValueOldUnitTestCase.suite());
- suite.addTest(TextValueNewUnitTestCase.suite());
- suite.addTest(DependencyValueOldUnitTestCase.suite());
- suite.addTest(DependencyValueNewUnitTestCase.suite());
- suite.addTest(DependencyListValueOldUnitTestCase.suite());
- suite.addTest(DependencyListValueNewUnitTestCase.suite());
- suite.addTest(ElementValueOldUnitTestCase.suite());
- suite.addTest(ElementValueNewUnitTestCase.suite());
- suite.addTest(JavaBeanValueOldUnitTestCase.suite());
- suite.addTest(JavaBeanValueNewUnitTestCase.suite());
- suite.addTest(JBXBValueOldUnitTestCase.suite());
- suite.addTest(JBXBValueNewUnitTestCase.suite());
- suite.addTest(NewInjectionValueUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/ControllerConfigureValueTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.depends.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependencyValueNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependencyValueNewUnitTestCase extends DependencyValueTest
-{
- public static Test suite()
- {
- return suite(DependencyValueNewUnitTestCase.class);
- }
-
- public DependencyValueNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,82 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.depends.test;
-
-import junit.framework.Test;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependencyValueOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependencyValueOldUnitTestCase extends DependencyValueTest
-{
- public static Test suite()
- {
- return suite(DependencyValueOldUnitTestCase.class);
- }
-
- public DependencyValueOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testPatternValue() throws Exception
- {
- FAILS_IN_OLD();
- }
-
- public void testNoAttributeInfoType() throws Exception
- {
- FAILS_IN_OLD();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,165 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.depends.test;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependencyValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependencyValueTest extends AbstractControllerTest
-{
- static ObjectName DEPENDS = ObjectNameFactory.create("jboss.test:type=depends");
-
- public DependencyValueTest(String name)
- {
- super(name);
- }
-
- public void testDependency() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDS, simple.getObjectName());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testDependencyNested() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDS, simple.getObjectName());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testExplicitProxyType() throws Exception
- {
- proxyTest();
- }
-
- public void testImplicitProxyType() throws Exception
- {
- proxyTest();
- }
-
- public void testNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testPatternValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testBrokenSetAttribute() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testNoAttributeInfoType() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testAttributeInfoTypeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testProxyTypeNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testProxyTypeNotInterface() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IllegalArgumentException.class);
- }
-
- protected void proxyTest() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- Simple dependency = getMBean(Simple.class, DEPENDS, "Instance");
-
- assertFalse(simple.isTouched());
- assertFalse(dependency.isTouched());
-
- simple.touchProxy();
-
- assertFalse(simple.isTouched());
- assertTrue(dependency.isTouched());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- protected Simple getDependency() throws Exception
- {
- return getMBean(Simple.class, DEPENDS, "Instance");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/depends/test/DependencyValueTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.dependslist.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependencyListValueNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependencyListValueNewUnitTestCase extends DependencyListValueTest
-{
- public static Test suite()
- {
- return suite(DependencyListValueNewUnitTestCase.class);
- }
-
- public DependencyListValueNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,77 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.dependslist.test;
-
-import junit.framework.Test;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependencyListValueOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependencyListValueOldUnitTestCase extends DependencyListValueTest
-{
- public static Test suite()
- {
- return suite(DependencyListValueOldUnitTestCase.class);
- }
-
- public DependencyListValueOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testPatternValue() throws Exception
- {
- FAILS_IN_OLD();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,149 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.dependslist.test;
-
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.List;
-
-import javax.management.MalformedObjectNameException;
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * DependencyListValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependencyListValueTest extends AbstractControllerTest
-{
- static ObjectName DEPENDS1 = ObjectNameFactory.create("jboss.test:type=depends1");
- static ObjectName[] DEPENDSLIST1 = new ObjectName[] { DEPENDS1 };
- static ObjectName DEPENDS2 = ObjectNameFactory.create("jboss.test:type=depends2");
- static ObjectName[] DEPENDSLIST2 = new ObjectName[] { DEPENDS1, DEPENDS2 };
-
- public DependencyListValueTest(String name)
- {
- super(name);
- }
-
- protected void assertEquals(ObjectName[] expected, Collection<ObjectName> actual)
- {
- List<ObjectName> expectedList = Arrays.asList(expected);
- assertEquals(expectedList, actual);
- }
-
- public void testNone() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(new ObjectName[0], simple.getObjectNames());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testOne() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST1, simple.getObjectNames());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testTwo() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST2, simple.getObjectNames());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testNested() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- try
- {
- Simple simple = getSimple();
- assertEquals(DEPENDSLIST1, simple.getObjectNames());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testNoValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testEmptyValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testInvalidValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testUnknownElement() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testPatternValue() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, MalformedObjectNameException.class);
- }
-
- public void testBrokenSetAttribute() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/dependslist/test/DependencyListValueTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.element.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ElementValueNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ElementValueNewUnitTestCase extends ElementValueTest
-{
- public static Test suite()
- {
- return suite(ElementValueNewUnitTestCase.class);
- }
-
- public ElementValueNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.element.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ElementValueOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ElementValueOldUnitTestCase extends ElementValueTest
-{
- public static Test suite()
- {
- return suite(ElementValueOldUnitTestCase.class);
- }
-
- public ElementValueOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,66 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.element.test;
-
-import javax.management.ObjectName;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-import org.w3c.dom.Element;
-
-/**
- * TextValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ElementValueTest extends AbstractControllerTest
-{
- public ElementValueTest(String name)
- {
- super(name);
- }
-
- public void testElement() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- assertInstall(name);
- try
- {
- Simple test = getSimple();
-
- Element element = test.getElement();
- assertNotNull(element);
-
- String tagName = element.getTagName();
- assertNotNull(tagName);
-
- assertEquals("dummy", tagName);
- }
- finally
- {
- assertUninstall(name);
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/element/test/ElementValueTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,145 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.inject.test;
-
-import java.util.List;
-
-import javax.management.InvalidAttributeValueException;
-import javax.management.ObjectName;
-
-import junit.framework.Test;
-
-import org.jboss.joinpoint.spi.JoinpointException;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceContext;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * NewInjectionValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class NewInjectionValueUnitTestCase extends AbstractControllerTest
-{
- private static ObjectName OTHER = ObjectNameFactory.create("jboss.test:type=depends");
-
- public static Test suite()
- {
- return suite(NewInjectionValueUnitTestCase.class);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-
- public NewInjectionValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testInjection() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- List<ObjectName> names = assertDeploy(name);
- try
- {
- Simple test = getSimple();
- Simple other = getMBean(Simple.class, OTHER, "Instance");
-
- assertEquals(other, test.getSimple());
- }
- finally
- {
- assertUndeploy(name, names);
- }
- }
-
- public void testInjectionNoBean() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ServiceContext.INSTALLED, null);
- }
-
- public void testInjectionBeanEmpty() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ServiceContext.INSTALLED, null);
- }
-
- public void testInjectionNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ServiceContext.INSTALLED, null);
- }
-
- public void testInjectionWrongType() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, InvalidAttributeValueException.class);
- }
-
- public void testInjectionProperty() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- List<ObjectName> names = assertDeploy(name);
- try
- {
- Simple test = getSimple();
-
- assertEquals("PropertyInjection", test.getAString());
- }
- finally
- {
- assertUndeploy(name, names);
- }
- }
-
- public void testInjectionPropertyState() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- List<ObjectName> names = assertDeploy(name);
- try
- {
- Simple test = getSimple();
-
- assertEquals("Instantiated", test.getAString());
- }
- finally
- {
- assertUndeploy(name, names);
- }
- }
-
- public void testInjectionPropertyNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, JoinpointException.class);
- }
-
- public void testInjectionPropertyWrongType() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, InvalidAttributeValueException.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/inject/test/NewInjectionValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.javabean.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * JavaBeanValueNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JavaBeanValueNewUnitTestCase extends JavaBeanValueTest
-{
- public static Test suite()
- {
- return suite(JavaBeanValueNewUnitTestCase.class);
- }
-
- public JavaBeanValueNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.javabean.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * JavaBeanValueOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JavaBeanValueOldUnitTestCase extends JavaBeanValueTest
-{
- public static Test suite()
- {
- return suite(JavaBeanValueOldUnitTestCase.class);
- }
-
- public JavaBeanValueOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testNoAttributeInfoType() throws Exception
- {
- FAILS_IN_OLD();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,149 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.javabean.test;
-
-import java.beans.IntrospectionException;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributeInfoTypeNotFound;
-import org.jboss.test.system.controller.support.BrokenDynamicMBeanNoAttributeInfoType;
-import org.jboss.test.system.controller.support.JavaBean;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * JavaBeanValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class JavaBeanValueTest extends AbstractControllerTest
-{
- public JavaBeanValueTest(String name)
- {
- super(name);
- }
-
- public void testExplicitClass() throws Exception
- {
- javaBean();
- }
-
- public void testImplicitClass() throws Exception
- {
- javaBean();
- }
-
- public void testAttributeClassNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testAbstractAttributeClass() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, InstantiationException.class);
- }
-
- public void testErrorInConstructor() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testNoAttributeInfoType() throws Exception
- {
- assertDeployFailure(BrokenDynamicMBeanNoAttributeInfoType.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testAttributeInfoTypeNotFound() throws Exception
- {
- assertDeployFailure(BrokenDynamicMBeanAttributeInfoTypeNotFound.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testNoPropertyName() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IntrospectionException.class);
- }
-
- public void testEmptyPropertyName() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IntrospectionException.class);
- }
-
- public void testPropertyNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IntrospectionException.class);
- }
-
- public void testNoPropertyEditor() throws Exception
- {
- /* TODO testNoPropertyEditor
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IntrospectionException.class);
- */
- }
-
- public void testNoPropertyValue() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- assertInstall(name);
- try
- {
- Simple test = getSimple();
-
- JavaBean bean = test.getJavaBean();
- assertNotNull(bean);
- assertEquals("", bean.getProperty1());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testErrorInProperty() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- protected void javaBean() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- assertInstall(name);
- try
- {
- Simple test = getSimple();
-
- JavaBean bean = test.getJavaBean();
- assertNotNull(bean);
- assertEquals("property1", bean.getProperty1());
- assertEquals(new Integer(10), bean.getProperty2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/javabean/test/JavaBeanValueTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.jbxb.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * JBXBValueNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JBXBValueNewUnitTestCase extends JBXBValueTest
-{
- public static Test suite()
- {
- return suite(JBXBValueNewUnitTestCase.class);
- }
-
- public JBXBValueNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.jbxb.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * JBXBValueOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JBXBValueOldUnitTestCase extends JBXBValueTest
-{
- public static Test suite()
- {
- return suite(JBXBValueOldUnitTestCase.class);
- }
-
- public JBXBValueOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,127 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.jbxb.test;
-
-import javax.management.ObjectName;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.JavaBean;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * JBXBValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class JBXBValueTest extends AbstractControllerTest
-{
- public JBXBValueTest(String name)
- {
- super(name);
- }
-
- public void testBasic() throws Exception
- {
- javaBean();
- }
-
- public void testClassNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testAbstractClass() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IllegalArgumentException.class);
- }
-
- public void testErrorInConstructor() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testNoPropertyName() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IllegalArgumentException.class);
- }
-
- public void testEmptyPropertyName() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IllegalArgumentException.class);
- }
-
- public void testPropertyNotFound() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IllegalArgumentException.class);
- }
-
- public void testNoPropertyEditor() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, IllegalArgumentException.class);
- }
-
- public void testNoPropertyValue() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- assertInstall(name);
- try
- {
- Simple test = getSimple();
-
- JavaBean bean = test.getJavaBean();
- assertNotNull(bean);
- assertNull(bean.getProperty1());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testErrorInProperty() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- protected void javaBean() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- assertInstall(name);
- try
- {
- Simple test = getSimple();
-
- JavaBean bean = test.getJavaBean();
- assertNotNull(bean);
- assertEquals("property1", bean.getProperty1());
- assertEquals(new Integer(10), bean.getProperty2());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/jbxb/test/JBXBValueTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.text.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * TextValueNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class TextValueNewUnitTestCase extends TextValueTest
-{
- public static Test suite()
- {
- return suite(TextValueNewUnitTestCase.class);
- }
-
- public TextValueNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.text.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * TextValueOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class TextValueOldUnitTestCase extends TextValueTest
-{
- public static Test suite()
- {
- return suite(TextValueOldUnitTestCase.class);
- }
-
- public TextValueOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testNoAttributeInfoType() throws Exception
- {
- FAILS_IN_OLD();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,133 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.configure.value.text.test;
-
-import java.math.BigDecimal;
-import java.text.DateFormat;
-import java.text.SimpleDateFormat;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.BrokenDynamicMBeanAttributeInfoTypeNotFound;
-import org.jboss.test.system.controller.support.BrokenDynamicMBeanNoAttributeInfoType;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-import org.jboss.util.NestedRuntimeException;
-
-/**
- * TextValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class TextValueTest extends AbstractControllerTest
-{
- private static final DateFormat dateFormat = new SimpleDateFormat("EEE MMM d HH:mm:ss z yyyy");
-
- private static final String stringValue = new String("StringValue");
- private static final Byte byteValue = new Byte("12");
- private static final Boolean booleanValue = Boolean.TRUE;
- // TODO character
- // private static final Character characterValue = new Character('a');
- private static final Short shortValue = new Short("123");
- private static final Integer integerValue = new Integer("1234");
- private static final Long longValue = new Long("12345");
- private static final Float floatValue = new Float("3.14");
- private static final Double doubleValue = new Double("3.14e12");
- private static final Date dateValue = createDate("Mon Jan 01 00:00:00 CET 2001");
- private static final BigDecimal bigDecimalValue = new BigDecimal("12e4");
- //private static final BigInteger bigIntegerValue = new BigInteger("123456");
-
- public TextValueTest(String name)
- {
- super(name);
- }
-
- public void testPropertyEditors() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- assertInstall(name);
- try
- {
- Simple test = getSimple();
-
- assertEquals(stringValue, test.getAString());
- assertEquals(byteValue, test.getAByte());
- assertEquals(booleanValue, test.getABoolean());
- // TODO character
- // assertEquals(characterValue, test.getACharacter());
- assertEquals(shortValue, test.getAShort());
- assertEquals(integerValue, test.getAnInt());
- assertEquals(longValue, test.getALong());
- assertEquals(floatValue, test.getAFloat());
- assertEquals(doubleValue, test.getADouble());
- assertEquals(dateValue, test.getADate());
- assertEquals(bigDecimalValue, test.getABigDecimal());
- // TODO BigInteger
- //assertEquals(bigIntegerValue, test.getABigInteger());
- assertEquals(byteValue.byteValue(), test.getAbyte());
- assertEquals(booleanValue.booleanValue(), test.isAboolean());
- // TODO character
- // assertEquals(characterValue.charValue(), test.getAchar());
- assertEquals(shortValue.shortValue(), test.getAshort());
- assertEquals(integerValue.intValue(), test.getAnint());
- assertEquals(longValue.longValue(), test.getAlong());
- assertEquals(floatValue.floatValue(), test.getAfloat());
- assertEquals(doubleValue.doubleValue(), test.getAdouble());
- }
- finally
- {
- assertUninstall(name);
- }
- }
-
- public void testNoPropertyEditor() throws Exception
- {
- assertDeployFailure(SimpleMBean.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testNoAttributeInfoType() throws Exception
- {
- assertDeployFailure(BrokenDynamicMBeanNoAttributeInfoType.OBJECT_NAME, DeploymentException.class);
- }
-
- public void testAttributeInfoTypeNotFound() throws Exception
- {
- assertDeployFailure(BrokenDynamicMBeanAttributeInfoTypeNotFound.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- private static Date createDate(String date)
- {
- try
- {
- return dateFormat.parse(date);
- }
- catch (Exception e)
- {
- throw new NestedRuntimeException(e);
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/configure/value/text/test/TextValueTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.plain.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * PlainMBeanNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PlainMBeanNewUnitTestCase extends PlainMBeanRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(PlainMBeanNewUnitTestCase.class);
- }
-
- public PlainMBeanNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.plain.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * PlainMBeanOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PlainMBeanOldUnitTestCase extends PlainMBeanTest
-{
- public static Test suite()
- {
- return suite(PlainMBeanOldUnitTestCase.class);
- }
-
- public PlainMBeanOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.plain.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * PlainMBeanNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PlainMBeanRedeployAfterErrorNewUnitTestCase extends PlainMBeanTest
-{
- public static Test suite()
- {
- return suite(PlainMBeanRedeployAfterErrorNewUnitTestCase.class);
- }
-
- public PlainMBeanRedeployAfterErrorNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.plain.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * PlainMBeanRedeployAfterErrorOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PlainMBeanRedeployAfterErrorOldUnitTestCase extends PlainMBeanRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(PlainMBeanRedeployAfterErrorOldUnitTestCase.class);
- }
-
- public PlainMBeanRedeployAfterErrorOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.plain.test;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * PlainMBeanRedeployAfterErrorTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class PlainMBeanRedeployAfterErrorTest extends AbstractControllerTest
-{
- public PlainMBeanRedeployAfterErrorTest(String name)
- {
- super(name);
- }
-
- public void testPlainMBeanRedeployAfterError() throws Exception
- {
- redeployAfterMaybeDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanRedeployAfterErrorTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,138 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.plain.test;
-
-import java.util.Collections;
-
-import javax.management.NotCompliantMBeanException;
-import javax.management.ObjectName;
-
-import org.jboss.system.ConfigurationException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.BrokenDynamicMBean;
-import org.jboss.test.system.controller.support.PostDeregisterError;
-import org.jboss.test.system.controller.support.PostRegisterError;
-import org.jboss.test.system.controller.support.PreDeregisterError;
-import org.jboss.test.system.controller.support.PreRegisterError;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * PlainMBeanTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class PlainMBeanTest extends AbstractControllerTest
-{
- public PlainMBeanTest(String name)
- {
- super(name);
- }
-
- public void testPlainMBean() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- assertUninstall(name);
- }
-
- public void testPlainMBeanCodeMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testPlainMBeanCodeEmpty() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testPlainMBeanCodeClassNotFound() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testPlainMBeanNotMBean() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, NotCompliantMBeanException.class);
- }
-
- public void testPlainMBeanAbstractClass() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, NotCompliantMBeanException.class);
- }
-
- public void testPlainMBeanConstructorError() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testPlainMBeanConstructorException() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, RuntimeException.class);
- }
-
- public void testPlainMBeanConstructorTypeNotFound() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testPlainMBeanConstructorInvalidType() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testPlainMBeanConstructorInvalidValue() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, NumberFormatException.class);
- }
-
- public void testPlainMBeanGetMBeanInfoError() throws Exception
- {
- assertMaybeDeployFailure(BrokenDynamicMBean.OBJECT_NAME, Error.class);
- }
-
- public void testPlainMBeanPreRegisterError() throws Exception
- {
- assertMaybeDeployFailure(PreRegisterError.OBJECT_NAME, Error.class);
- }
-
- public void testPlainMBeanPostRegisterError() throws Exception
- {
- assertMaybeDeployFailure(PostRegisterError.OBJECT_NAME, Error.class);
- }
-
- public void testPlainMBeanPreDeregisterError() throws Exception
- {
- ObjectName name = PreDeregisterError.OBJECT_NAME;
- assertInstall(name);
- uninstall(Collections.singletonList(name));
- assertNoService(name);
- assertRegistered(name);
- }
-
- public void testPlainMBeanPostDeregisterError() throws Exception
- {
- ObjectName name = PostDeregisterError.OBJECT_NAME;
- assertInstall(name);
- assertUninstall(name);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/plain/test/PlainMBeanTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.standard.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * StandardMBeanNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class StandardMBeanNewUnitTestCase extends StandardMBeanTest
-{
- public static Test suite()
- {
- return suite(StandardMBeanNewUnitTestCase.class);
- }
-
- public StandardMBeanNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.standard.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * StandardMBeanOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class StandardMBeanOldUnitTestCase extends StandardMBeanTest
-{
- public static Test suite()
- {
- return suite(StandardMBeanOldUnitTestCase.class);
- }
-
- public StandardMBeanOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.standard.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * StandardMBeanNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class StandardMBeanRedeployAfterErrorNewUnitTestCase extends StandardMBeanRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(StandardMBeanRedeployAfterErrorNewUnitTestCase.class);
- }
-
- public StandardMBeanRedeployAfterErrorNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.standard.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * StandardMBeanRedeployAfterErrorOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class StandardMBeanRedeployAfterErrorOldUnitTestCase extends StandardMBeanRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(StandardMBeanRedeployAfterErrorOldUnitTestCase.class);
- }
-
- public StandardMBeanRedeployAfterErrorOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,44 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.standard.test;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * StandardMBeanRedeployAfterErrorTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class StandardMBeanRedeployAfterErrorTest extends AbstractControllerTest
-{
- public StandardMBeanRedeployAfterErrorTest(String name)
- {
- super(name);
- }
-
- public void testStandardMBeanRedeployAfterError() throws Exception
- {
- redeployAfterMaybeDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanRedeployAfterErrorTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,114 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.standard.test;
-
-import javax.management.NotCompliantMBeanException;
-import javax.management.ObjectName;
-
-import org.jboss.system.ConfigurationException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * StandardMBeanTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class StandardMBeanTest extends AbstractControllerTest
-{
- public StandardMBeanTest(String name)
- {
- super(name);
- }
-
- public void testStandardMBean() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- assertUninstall(name);
- }
-
- public void testStandardMBeanInterface() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- assertInstall(name);
- String result = (String) getServer().invoke(name, "echoReverse", new Object[] { "12345" }, new String[] { String.class.getName() });
- assertEquals("54321", result);
- assertUninstall(name);
- }
-
- public void testStandardMBeanInterfaceNotFound() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testStandardMBeanInterfaceNotImplemented() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, NotCompliantMBeanException.class);
- }
-
- public void testStandardMBeanCodeMissing() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testStandardMBeanCodeEmpty() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testStandardMBeanCodeClassNotFound() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testStandardMBeanAbstractClass() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, InstantiationException.class);
- }
-
- public void testStandardMBeanConstructorError() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testStandardMBeanConstructorException() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, RuntimeException.class);
- }
-
- public void testStandardMBeanConstructorTypeNotFound() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testStandardMBeanConstructorInvalidType() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testStandardMBeanConstructorInvalidValue() throws Exception
- {
- assertMaybeDeployFailure(SimpleMBean.OBJECT_NAME, NumberFormatException.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/standard/test/StandardMBeanTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ConstructorArgsErrorNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConstructorArgsErrorNewUnitTestCase extends ConstructorArgsErrorTest
-{
- public static Test suite()
- {
- return suite(ConstructorArgsErrorNewUnitTestCase.class);
- }
-
- public ConstructorArgsErrorNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,81 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * ConstructorArgsErrorOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConstructorArgsErrorOldUnitTestCase extends ConstructorArgsErrorTest
-{
- public static Test suite()
- {
- return suite(ConstructorArgsErrorOldUnitTestCase.class);
- }
-
- public ConstructorArgsErrorOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testPlainMBeanArgTypeMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testPlainMBeanArgTypeEmpty() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testPlainMBeanArgValueMissing() throws Exception
- {
- FAILS_IN_OLD();
- }
-
- public void testStandardMBeanArgTypeMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testStandardMBeanArgTypeEmpty() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ClassNotFoundException.class);
- }
-
- public void testStandardMBeanArgValueMissing() throws Exception
- {
- FAILS_IN_OLD();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import org.jboss.system.ConfigurationException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * ConstructorArgsErrorTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ConstructorArgsErrorTest extends AbstractControllerTest
-{
- public ConstructorArgsErrorTest(String name)
- {
- super(name);
- }
-
- public void testPlainMBeanArgTypeMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testPlainMBeanArgTypeEmpty() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testPlainMBeanArgValueMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testStandardMBeanArgTypeMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testStandardMBeanArgTypeEmpty() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-
- public void testStandardMBeanArgValueMissing() throws Exception
- {
- assertMaybeParseFailure(SimpleMBean.OBJECT_NAME, ConfigurationException.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsErrorTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ConstructorArgsNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConstructorArgsNewUnitTestCase extends ConstructorArgsTest
-{
- public static Test suite()
- {
- return suite(ConstructorArgsNewUnitTestCase.class);
- }
-
- public ConstructorArgsNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ConstructorArgsOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConstructorArgsOldUnitTestCase extends ConstructorArgsTest
-{
- public static Test suite()
- {
- return suite(ConstructorArgsOldUnitTestCase.class);
- }
-
- public ConstructorArgsOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,118 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import javax.management.MBeanServer;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * ConstructorArgsTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ConstructorArgsTest extends AbstractControllerTest
-{
- public ConstructorArgsTest(String name)
- {
- super(name);
- }
-
- public void testPlainMBeanNoArg() throws Exception
- {
- noArg();
- }
-
- public void testPlainMBeanOneArg() throws Exception
- {
- oneArg();
- }
-
- public void testPlainMBeanTwoArg() throws Exception
- {
- twoArg();
- }
-
- public void testStandardMBeanNoArg() throws Exception
- {
- noArg();
- }
-
- public void testStandardMBeanOneArg() throws Exception
- {
- oneArg();
- }
-
- public void testStandardMBeanTwoArg() throws Exception
- {
- twoArg();
- }
-
- protected void noArg() throws Exception
- {
- Simple simple = getSimple();
- assertEquals("()", simple.constructorUsed);
- }
-
- protected void oneArg() throws Exception
- {
- Simple simple = getSimple();
- assertEquals("(int)", simple.constructorUsed);
- assertEquals(5, simple.getAnint());
- }
-
- protected void twoArg() throws Exception
- {
- Simple simple = getSimple();
- assertEquals("(int,float)", simple.constructorUsed);
- assertEquals(5, simple.getAnint());
- assertEquals(3.14f, simple.getAfloat());
- }
-
- protected void setUp() throws Exception
- {
- super.setUp();
-
- assertInstall(SimpleMBean.OBJECT_NAME);
- }
-
- protected void tearDown() throws Exception
- {
- try
- {
- assertUninstall(SimpleMBean.OBJECT_NAME);
- }
- finally
- {
- super.tearDown();
- }
- }
-
- protected Simple getSimple() throws Exception
- {
- MBeanServer server = getServer();
- return (Simple) server.getAttribute(SimpleMBean.OBJECT_NAME, "Instance");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ConstructorArgsTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import org.jboss.test.system.controller.instantiate.plain.test.PlainMBeanNewUnitTestCase;
-import org.jboss.test.system.controller.instantiate.plain.test.PlainMBeanOldUnitTestCase;
-import org.jboss.test.system.controller.instantiate.plain.test.PlainMBeanRedeployAfterErrorNewUnitTestCase;
-import org.jboss.test.system.controller.instantiate.plain.test.PlainMBeanRedeployAfterErrorOldUnitTestCase;
-import org.jboss.test.system.controller.instantiate.standard.test.StandardMBeanNewUnitTestCase;
-import org.jboss.test.system.controller.instantiate.standard.test.StandardMBeanOldUnitTestCase;
-import org.jboss.test.system.controller.instantiate.standard.test.StandardMBeanRedeployAfterErrorNewUnitTestCase;
-import org.jboss.test.system.controller.instantiate.standard.test.StandardMBeanRedeployAfterErrorOldUnitTestCase;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * Controller Instantiate Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerInstantiateTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Instantiate Tests");
-
- suite.addTest(NewNoMetaDataInstantiateUnitTestCase.suite());
- suite.addTest(ConstructorArgsOldUnitTestCase.suite());
- suite.addTest(ConstructorArgsNewUnitTestCase.suite());
- suite.addTest(PlainMBeanOldUnitTestCase.suite());
- suite.addTest(PlainMBeanNewUnitTestCase.suite());
- suite.addTest(PlainMBeanRedeployAfterErrorOldUnitTestCase.suite());
- suite.addTest(PlainMBeanRedeployAfterErrorNewUnitTestCase.suite());
- suite.addTest(StandardMBeanOldUnitTestCase.suite());
- suite.addTest(StandardMBeanNewUnitTestCase.suite());
- suite.addTest(StandardMBeanRedeployAfterErrorOldUnitTestCase.suite());
- suite.addTest(StandardMBeanRedeployAfterErrorNewUnitTestCase.suite());
- suite.addTest(ConstructorArgsErrorOldUnitTestCase.suite());
- suite.addTest(ConstructorArgsErrorNewUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/ControllerInstantiateTestSuite.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,119 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.instantiate.test;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import junit.framework.Test;
-
-import org.jboss.system.ServiceController;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * NewNoMetaDataInstantiateUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class NewNoMetaDataInstantiateUnitTestCase extends AbstractControllerTest
-{
- public static Test suite()
- {
- return suite(NewNoMetaDataInstantiateUnitTestCase.class);
- }
-
- public NewNoMetaDataInstantiateUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-
- public void testNoMetaData() throws Throwable
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- Simple test = new Simple();
-
- ServiceController serviceController = (ServiceController) getController();
- serviceController.install(name, test);
- try
- {
- assertServiceConfigured(name);
-
- MBeanServer server = getServer();
- Object instance = server.getAttribute(name, "Instance");
- assertNotNull(instance);
- assertTrue(test == instance);
- }
- finally
- {
- try
- {
- serviceController.remove(name);
- }
- catch (Exception ignored)
- {
- }
- }
- }
-
- public void testNoMetaDataNoName() throws Throwable
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- Simple test = new Simple();
-
- ServiceController serviceController = (ServiceController) getController();
- try
- {
- serviceController.install(null, test);
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
-
- assertNoService(name);
- }
-
- public void testNoMetaDataNoObject() throws Throwable
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
-
- ServiceController serviceController = (ServiceController) getController();
- try
- {
- serviceController.install(name, null);
- }
- catch (Throwable t)
- {
- checkThrowableDeep(IllegalArgumentException.class, t);
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/instantiate/test/NewNoMetaDataInstantiateUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/support)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,106 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.support;
-
-import org.jboss.test.system.controller.support.Order;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * SimpleBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SimpleBean
-{
- /** Injection */
- private Simple simple;
-
- public int createOrder;
- public int startOrder;
- public int stopOrder;
- public int destroyOrder;
-
- /**
- * Create a new SimpleBean.
- */
- public SimpleBean()
- {
- }
-
- /**
- * Create a new SimpleBean.
- *
- * @param simple the simple object
- */
- public SimpleBean(Simple simple)
- {
- this.simple = simple;
- }
-
- /**
- * Get the simple.
- *
- * @return the simple.
- */
- public Simple getSimple()
- {
- return simple;
- }
-
- /**
- * Set the simple.
- *
- * @param simple the simple.
- */
- public void setSimple(Simple simple)
- {
- this.simple = simple;
- }
-
- public void create()
- {
- createOrder = Order.getOrder();
- }
-
- public void start()
- {
- startOrder = Order.getOrder();
- }
-
- public void create(Simple simple)
- {
- this.simple = simple;
- createOrder = Order.getOrder();
- }
-
- public void start(Simple simple)
- {
- this.simple = simple;
- startOrder = Order.getOrder();
- }
-
- public void install(Simple simple)
- {
- this.simple = simple;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/support/SimpleBean.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,171 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import java.net.URL;
-
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.kernel.spi.deployment.KernelDeployment;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.AbstractControllerTest;
-
-/**
- * An integration Test.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.2 $
- */
-public abstract class AbstractIntegrationTest extends AbstractControllerTest
-{
- /**
- * Create a new integration test.
- *
- * @param name the test name
- */
- public AbstractIntegrationTest(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- IntegrationTestDelegate delegate = new IntegrationTestDelegate(clazz);
- // @todo delegate.enableSecurity = true;
- return delegate;
- }
-
- /**
- * Get a bean
- *
- * @param name the bean name
- * @return the bean
- * @throws IllegalStateException when the bean does not exist
- */
- protected Object getBean(Object name)
- {
- return getBean(name, ControllerState.INSTALLED);
- }
-
- /**
- * Get a bean
- *
- * @param name the name of the bean
- * @param state the state of the bean
- * @return the bean
- * @throws IllegalStateException when the bean does not exist at that state
- */
- protected Object getBean(Object name, ControllerState state)
- {
- return getIntegrationDelegate().getBean(name, state);
- }
-
- /**
- * Get a context
- *
- * @param name the bean name
- * @return the context
- * @throws IllegalStateException when the context does not exist
- */
- protected ControllerContext getControllerContext(Object name)
- {
- return getControllerContext(name, ControllerState.INSTALLED);
- }
-
- /**
- * Get a context
- *
- * @param name the name of the bean
- * @param state the state of the bean
- * @return the context
- * @throws IllegalStateException when the context does not exist at that state
- */
- protected ControllerContext getControllerContext(Object name, ControllerState state)
- {
- return getIntegrationDelegate().getControllerContext(name, state);
- }
-
- /**
- * Deploy a url
- *
- * @param url the deployment url
- * @return the deployment
- * @throws Throwable for any error
- */
- protected KernelDeployment deployMC(URL url) throws Exception
- {
- return getIntegrationDelegate().deployMC(url);
- }
-
- /**
- * Deploy a resource
- *
- * @param resource the deployment resource
- * @return the deployment
- * @throws Throwable for any error
- */
- protected KernelDeployment deployMC(String resource) throws Exception
- {
- URL url = getClass().getResource(resource);
- if (url == null)
- throw new IllegalArgumentException("Resource not found: " + resource);
- return getIntegrationDelegate().deployMC(url);
- }
-
- /**
- * Undeploy a deployment
- *
- * @param deployment the deployment
- */
- protected void undeployMC(KernelDeployment deployment)
- {
- getIntegrationDelegate().undeployMC(deployment);
- }
-
- /**
- * Undeploy a deployment
- *
- * @param resource the url
- */
- protected void undeployMC(String resource)
- {
- URL url = getClass().getResource(resource);
- if (url == null)
- throw new IllegalArgumentException("Resource not found: " + resource);
- getIntegrationDelegate().undeployMC(url);
- }
-
- /**
- * Validate
- *
- * @throws Exception for any error
- */
- protected void validateMC() throws Exception
- {
- getIntegrationDelegate().validateMC();
- }
-
- protected IntegrationTestDelegate getIntegrationDelegate()
- {
- return (IntegrationTestDelegate) getDelegate();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/AbstractIntegrationTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-/**
- * ConfigureJMXFromMCUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConfigureJMXFromMCUnitTestCase extends InjectJMXFromMCTest
-{
- public static Test suite()
- {
- return suite(ConfigureJMXFromMCUnitTestCase.class);
- }
-
- public ConfigureJMXFromMCUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testConfigureJMXFromMC() throws Throwable
- {
- checkInject();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureJMXFromMCUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-/**
- * ConfigureMCFromJMXUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConfigureMCFromJMXUnitTestCase extends InjectMCFromJMXTest
-{
- public static Test suite()
- {
- return suite(ConfigureMCFromJMXUnitTestCase.class);
- }
-
- public ConfigureMCFromJMXUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testConfigureMCFromJMX() throws Throwable
- {
- checkInject();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/ConfigureMCFromJMXUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-/**
- * CreateMCFromJMXUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class CreateMCFromJMXUnitTestCase extends InjectMCFromJMXTest
-{
- public static Test suite()
- {
- return suite(CreateMCFromJMXUnitTestCase.class);
- }
-
- public CreateMCFromJMXUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testCreateMCFromJMX() throws Throwable
- {
- checkInject();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/CreateMCFromJMXUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.test.system.controller.integration.support.SimpleBean;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * InjectJMXFromMCTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class InjectJMXFromMCTest extends AbstractIntegrationTest
-{
- public InjectJMXFromMCTest(String name)
- {
- super(name);
- }
-
- public void checkInject() throws Throwable
- {
- Simple simple = getSimple();
-
- ControllerContext beanContext = getControllerContext("Test");
- assertNotNull(beanContext);
- Object bean = beanContext.getTarget();
- assertNotNull(bean);
- assertTrue(bean instanceof SimpleBean);
-
- Object injected = simple.getSimpleBean();
-
- assertTrue("Bean was not injected: ", bean == injected);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectJMXFromMCTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,59 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.test.system.controller.integration.support.SimpleBean;
-
-/**
- * InjectMCFromJMXTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class InjectMCFromJMXTest extends AbstractIntegrationTest
-{
- public InjectMCFromJMXTest(String name)
- {
- super(name);
- }
-
- public void checkInject() throws Throwable
- {
- ControllerContext mbeanContext = getControllerContext("jboss.test:type=test");
- assertNotNull(mbeanContext);
- Object mbean = mbeanContext.getTarget();
- assertNotNull(mbean);
-
- ControllerContext beanContext = getControllerContext("Test");
- assertNotNull(beanContext);
- Object bean = beanContext.getTarget();
- assertNotNull(bean);
- assertTrue(bean instanceof SimpleBean);
-
- SimpleBean simpleBean = (SimpleBean) bean;
-
- Object injected = simpleBean.getSimple();
-
- assertTrue("MBean was not injected: ", mbean == injected);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InjectMCFromJMXTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-/**
- * InstallMCFromJMXUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class InstallMCFromJMXUnitTestCase extends InjectMCFromJMXTest
-{
- public static Test suite()
- {
- return suite(InstallMCFromJMXUnitTestCase.class);
- }
-
- public InstallMCFromJMXUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testInstallMCFromJMX() throws Throwable
- {
- checkInject();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstallMCFromJMXUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-/**
- * InstantiateMCFromJMXUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class InstantiateMCFromJMXUnitTestCase extends InjectMCFromJMXTest
-{
- public static Test suite()
- {
- return suite(InstantiateMCFromJMXUnitTestCase.class);
- }
-
- public InstantiateMCFromJMXUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testInstantiateMCFromJMX() throws Throwable
- {
- checkInject();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/InstantiateMCFromJMXUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,298 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import java.net.URL;
-
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.kernel.Kernel;
-import org.jboss.kernel.plugins.bootstrap.AbstractBootstrap;
-import org.jboss.kernel.plugins.bootstrap.basic.BasicBootstrap;
-import org.jboss.kernel.plugins.deployment.xml.BasicXMLDeployer;
-import org.jboss.kernel.spi.dependency.KernelController;
-import org.jboss.kernel.spi.deployment.KernelDeployment;
-import org.jboss.system.ServiceController;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.system.controller.NewControllerTestDelegate;
-
-/**
- * IntegrationTestDelegate.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class IntegrationTestDelegate extends NewControllerTestDelegate
-{
- /** The kernel */
- protected Kernel kernel;
-
- /** The deployer */
- protected BasicXMLDeployer beanDeployer;
-
- public IntegrationTestDelegate(Class clazz)
- {
- super(clazz);
- }
-
- public void setUp() throws Exception
- {
- super.setUp();
-
- try
- {
- // Create the deployer
- beanDeployer = new BasicXMLDeployer(kernel);
-
- // Deploy
- deployMC();
-
- validateMC();
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw e;
- }
- catch (Error e)
- {
- throw e;
- }
- catch (Throwable e)
- {
- throw new RuntimeException(e);
- }
- }
-
- // TODO Temporary
- protected boolean isValidateAtSetUp()
- {
- return false;
- }
-
- public ServiceControllerMBean createServiceController() throws Exception
- {
- try
- {
- // Bootstrap the kernel
- AbstractBootstrap bootstrap = getBootstrap();
- bootstrap.run();
- kernel = bootstrap.getKernel();
-
- // Create the service controller
- ServiceController result = new ServiceController();
- result.setKernel(kernel);
- return result;
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw e;
- }
- catch (Error e)
- {
- throw e;
- }
- catch (Throwable e)
- {
- throw new RuntimeException(e);
- }
- }
-
- public void tearDown() throws Exception
- {
- undeployMC();
- super.tearDown();
- }
-
- /**
- * Get the kernel bootstrap
- *
- * @return the bootstrap
- */
- protected AbstractBootstrap getBootstrap() throws Exception
- {
- return new BasicBootstrap();
- }
-
- /**
- * Get a bean
- *
- * @param name the name of the bean
- * @param state the state of the bean
- * @return the bean
- * @throws IllegalStateException when the bean does not exist at that state
- */
- protected Object getBean(final Object name, final ControllerState state)
- {
- ControllerContext context = getControllerContext(name, state);
- return context.getTarget();
- }
-
- /**
- * Get a context
- *
- * @param name the name of the bean
- * @param state the state of the bean
- * @return the context
- * @throws IllegalStateException when the context does not exist at that state
- */
- protected ControllerContext getControllerContext(final Object name, final ControllerState state)
- {
- KernelController controller = kernel.getController();
- ControllerContext context = controller.getContext(name, state);
- if (context == null)
- throw new IllegalStateException("Context not found: " + name);
- return context;
- }
-
- /**
- * Validate
- */
- protected void validateMC() throws Exception
- {
- try
- {
- beanDeployer.validate();
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw e;
- }
- catch (Error e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- throw new RuntimeException(t);
- }
- }
-
- /**
- * Deploy a url
- *
- * @param url the deployment url
- * @return the deployment
- * @throws Throwable for any error
- */
- protected KernelDeployment deployMC(URL url) throws Exception
- {
- try
- {
- log.debug("Deploying " + url);
- KernelDeployment deployment = beanDeployer.deploy(url);
- log.trace("Deployed " + url);
- return deployment;
- }
- catch (RuntimeException e)
- {
- throw e;
- }
- catch (Exception e)
- {
- throw e;
- }
- catch (Error e)
- {
- throw e;
- }
- catch (Throwable t)
- {
- throw new RuntimeException(t);
- }
- }
-
- /**
- * Undeploy a deployment
- *
- * @param url the url
- */
- protected void undeployMC(URL url)
- {
- log.debug("Undeploying " + url);
- try
- {
- beanDeployer.undeploy(url);
- log.trace("Undeployed " + url);
- }
- catch (Throwable t)
- {
- log.warn("Error during undeployment: " + url, t);
- }
- }
-
- /**
- * Undeploy a deployment
- *
- * @param deployment the deployment
- */
- protected void undeployMC(KernelDeployment deployment)
- {
- log.debug("Undeploying " + deployment.getName());
- try
- {
- beanDeployer.undeploy(deployment);
- log.trace("Undeployed " + deployment.getName());
- }
- catch (Throwable t)
- {
- log.warn("Error during undeployment: " + deployment.getName(), t);
- }
- }
-
- /**
- * Deploy the beans
- *
- * @throws Exception for any error
- */
- protected void deployMC() throws Exception
- {
- String testName = clazz.getName();
- testName = testName.replace('.', '/') + "-mc.xml";
- URL url = clazz.getClassLoader().getResource(testName);
- if (url != null)
- deployMC(url);
- else
- log.debug("No test specific deployment " + testName);
- }
-
- /**
- * Undeploy all
- */
- protected void undeployMC()
- {
- log.debug("Undeploying " + beanDeployer.getDeploymentNames());
- beanDeployer.shutdown();
- }
-
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestDelegate.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * IntegrationTestSuite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class IntegrationTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Integration Tests");
-
- suite.addTest(InstantiateMCFromJMXUnitTestCase.suite());
- suite.addTest(ConfigureMCFromJMXUnitTestCase.suite());
- suite.addTest(CreateMCFromJMXUnitTestCase.suite());
- suite.addTest(StartMCFromJMXUnitTestCase.suite());
- suite.addTest(InstallMCFromJMXUnitTestCase.suite());
- suite.addTest(ConfigureJMXFromMCUnitTestCase.suite());
- suite.addTest(MCDependsJMXUnitTestCase.suite());
- suite.addTest(JMXDependsMCUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/IntegrationTestSuite.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,67 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.test.system.controller.integration.support.SimpleBean;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * JMXDependsMCUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JMXDependsMCUnitTestCase extends AbstractIntegrationTest
-{
- public static Test suite()
- {
- return suite(JMXDependsMCUnitTestCase.class);
- }
-
- public JMXDependsMCUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testMCDependsJMX() throws Throwable
- {
- ControllerContext mbeanContext = getControllerContext("jboss.test:type=test");
- assertNotNull(mbeanContext);
- Object mbean = mbeanContext.getTarget();
- assertNotNull(mbean);
- Simple simple = assertInstanceOf(Simple.class, mbean);
-
- ControllerContext beanContext = getControllerContext("Test");
- assertNotNull(beanContext);
- Object bean = beanContext.getTarget();
- assertNotNull(bean);
- SimpleBean simpleBean = assertInstanceOf(SimpleBean.class, bean);
-
- assertEquals(2, simple.createOrder);
- assertEquals(4, simple.startOrder);
- assertEquals(1, simpleBean.createOrder);
- assertEquals(3, simpleBean.startOrder);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/JMXDependsMCUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,67 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-import org.jboss.dependency.spi.ControllerContext;
-import org.jboss.test.system.controller.integration.support.SimpleBean;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * MCDependsJMXUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MCDependsJMXUnitTestCase extends AbstractIntegrationTest
-{
- public static Test suite()
- {
- return suite(MCDependsJMXUnitTestCase.class);
- }
-
- public MCDependsJMXUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testMCDependsJMX() throws Throwable
- {
- ControllerContext mbeanContext = getControllerContext("jboss.test:type=test");
- assertNotNull(mbeanContext);
- Object mbean = mbeanContext.getTarget();
- assertNotNull(mbean);
- Simple simple = assertInstanceOf(Simple.class, mbean);
-
- ControllerContext beanContext = getControllerContext("Test");
- assertNotNull(beanContext);
- Object bean = beanContext.getTarget();
- assertNotNull(bean);
- SimpleBean simpleBean = assertInstanceOf(SimpleBean.class, bean);
-
- assertEquals(1, simple.createOrder);
- assertEquals(2, simple.startOrder);
- assertEquals(3, simpleBean.createOrder);
- assertEquals(4, simpleBean.startOrder);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/MCDependsJMXUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.integration.test;
-
-import junit.framework.Test;
-
-/**
- * StartMCFromJMXUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class StartMCFromJMXUnitTestCase extends InjectMCFromJMXTest
-{
- public static Test suite()
- {
- return suite(StartMCFromJMXUnitTestCase.class);
- }
-
- public StartMCFromJMXUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testStartMCFromJMX() throws Throwable
- {
- checkInject();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/integration/test/StartMCFromJMXUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,849 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.system.controller.legacy;
-
-import java.beans.PropertyEditor;
-import java.beans.PropertyEditorManager;
-import java.io.IOException;
-import java.io.StringReader;
-import java.io.StringWriter;
-import java.io.Writer;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Properties;
-
-import javax.management.Attribute;
-import javax.management.InstanceNotFoundException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanInfo;
-import javax.management.MBeanServer;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.transform.Transformer;
-import javax.xml.transform.TransformerException;
-import javax.xml.transform.TransformerFactory;
-import javax.xml.transform.dom.DOMSource;
-import javax.xml.transform.stream.StreamResult;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.MBeanProxyExt;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ConfigurationException;
-import org.jboss.system.ServiceBinding;
-import org.jboss.system.ServiceContext;
-import org.jboss.util.Classes;
-import org.jboss.util.StringPropertyReplacer;
-import org.jboss.util.propertyeditor.PropertyEditors;
-import org.jboss.util.xml.DOMWriter;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
-import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.Text;
-
-/**
- * Service configuration helper.
- * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:hiram at jboss.org">Hiram Chirino</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version <tt>$Revision: 1.45 $</tt>
- */
-public class OldServiceConfigurator
-{
- /**
- * Augment the PropertyEditorManager search path to incorporate the JBoss
- * specific editors. This simply references the PropertyEditors.class to
- * invoke its static initialization block.
- */
- static
- {
- PropertyEditors.init();
- }
-
- // Private Data --------------------------------------------------
-
- /** The MBean server which this service is registered in. */
- private final MBeanServer server;
-
- /** The parent service controller */
- private final OldServiceController serviceController;
-
- /** The ServiceCreator */
- private final OldServiceCreator serviceCreator;
-
- /** The ServiceBinding plugin policy */
- private ServiceBinding serviceBinding;
-
- /**
- * The instance logger.
- */
- private final Logger log = Logger.getLogger(getClass());
-
- // Constructor ---------------------------------------------------
-
- /**
- * Constructor
- *
- * @param server
- * @param serviceController
- * @param serviceCreator
- */
- public OldServiceConfigurator(MBeanServer server,
- OldServiceController serviceController, OldServiceCreator serviceCreator)
- {
- this.server = server;
- this.serviceController = serviceController;
- this.serviceCreator = serviceCreator;
- this.serviceBinding = null;
- }
-
- // Public --------------------------------------------------------
-
- /**
- * Dynamically plug-in a ServiceBinding policy
- * to possibly override the configuration of a service.
- *
- * @param serviceBinding policy
- */
- public void setServiceBinding(ServiceBinding serviceBinding)
- {
- this.serviceBinding = serviceBinding;
- }
-
- /**
- * The <code>install</code> method iterates through the mbean tags in the
- * supplied xml configuration and creates and configures the mbeans shown.
- * The mbean configuration can be nested.
- * @param config the xml <code>Element</code> containing the configuration of
- * the mbeans to create and configure.
- * @param loaderName the class loader
- * @return a <code>List</code> of ObjectNames of created mbeans.
- * @throws DeploymentException if an error occurs
- */
- public List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException
- {
- List<ObjectName> mbeans = new ArrayList<ObjectName>();
- try
- {
- if (config.getTagName().equals("mbean"))
- {
- internalInstall(config, mbeans, loaderName, true);
- }
- else
- {
- NodeList nl = config.getChildNodes();
-
- for (int i = 0; i < nl.getLength(); i++)
- {
- if (nl.item(i).getNodeType() == Node.ELEMENT_NODE)
- {
- Element element = (Element) nl.item(i);
- if (element.getTagName().equals("mbean"))
- {
- Element mbean = (Element) nl.item(i);
- internalInstall(mbean, mbeans, loaderName, true);
- } // end of if ()
- } // end of if ()
- }//end of for
- } //end of else
- return mbeans;
- }
- catch (Exception e)
- {
- for (ListIterator li = mbeans.listIterator(mbeans.size()); li.hasPrevious();)
- {
- ObjectName mbean = (ObjectName) li.previous();
- try
- {
- serviceCreator.remove(mbean);
- }
- catch (Exception n)
- {
- log.error("exception removing mbean after failed deployment: " + mbean, n);
- }
- }
-
- if (e instanceof DeploymentException)
- throw (DeploymentException) e;
-
- throw new DeploymentException(e);
- }
- }
-
- /**
- * Builds a string that consists of the configuration elements of the
- * currently running MBeans registered in the server.
- *
- * @param objectNames the object names
- * @return the xml string
- * @throws Exception Failed to construct configuration.
- * @todo replace with more sophisticated mbean persistence mechanism.
- */
- public String getConfiguration(ObjectName[] objectNames)
- throws Exception
- {
- Writer out = new StringWriter();
-
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- DocumentBuilder builder = factory.newDocumentBuilder();
- Document doc = builder.newDocument();
-
- Element serverElement = doc.createElement("server");
-
- // Store attributes as XML
- for (int j = 0; j < objectNames.length; j++)
- {
- Element mbeanElement = internalGetConfiguration(doc, objectNames[j]);
- serverElement.appendChild(mbeanElement);
- }
-
- doc.appendChild(serverElement);
-
- // Write configuration
- new DOMWriter(out).setPrettyprint(true).print(doc);
-
- out.close();
-
- // Return configuration
- return out.toString();
- }
-
- // Protected -----------------------------------------------------
-
- /**
- * The <code>configure</code> method configures an mbean based on the xml
- * element configuration passed in. Three formats are supported:
- * <attribute name="(name)">(value)</attribute> <depends
- * optional-attribute-name="(name)">(object name of mbean
- * referenced)</depends> <depends-list optional-attribute-name="(name)">
- * [list of] </depends-list-element>(object name)</depends-list-element>
- * </depends-list>
- *
- * The last two can include nested mbean configurations or ObjectNames.
- * SIDE-EFFECT: adds all mbeans this one depends on to the ServiceContext
- * structures.
- * @param mbeanElement an <code>Element</code> value
- * @throws Exception if an error occurs
- */
- protected void configure(ObjectName objectName, ObjectName loaderName,
- Element mbeanElement, List<ObjectName> mbeans)
- throws Exception
- {
- // Set configuration to MBeans from XML
-
- MBeanInfo info;
- try
- {
- info = server.getMBeanInfo(objectName);
- }
- catch (InstanceNotFoundException e)
- {
- // The MBean is no longer available
- throw new DeploymentException("trying to configure nonexistent mbean: " + objectName);
- }
- catch (Exception e)
- {
- throw new DeploymentException("Could not get mbeanInfo", JMXExceptionDecoder.decode(e));
- } // end of catch
-
- if (info == null)
- {
- throw new DeploymentException("MBeanInfo is null for mbean: " + objectName);
- } // end of if ()
-
- // Get the classloader for loading attribute classes.
- ClassLoader cl = server.getClassLoader(loaderName);
- // Initialize the mbean using the configuration supplied defaults
- MBeanAttributeInfo[] attributes = info.getAttributes();
- HashMap<String, MBeanAttributeInfo> attributeMap = new HashMap<String, MBeanAttributeInfo>();
- for (int i = 0; i < attributes.length; i++)
- {
- MBeanAttributeInfo attr = attributes[i];
- attributeMap.put(attr.getName(), attr);
- }
-
- NodeList attrs = mbeanElement.getChildNodes();
- for (int j = 0; j < attrs.getLength(); j++)
- {
- // skip over non-element nodes
- if (attrs.item(j).getNodeType() != Node.ELEMENT_NODE)
- {
- continue;
- }
-
- Element element = (Element) attrs.item(j);
-
- boolean replace = true;
-
- // Set attributes
- if (element.getTagName().equals("attribute"))
- {
- String attributeName = element.getAttribute("name");
- boolean trim = true;
- String replaceAttr = element.getAttribute("replace");
- if (replaceAttr.length() > 0)
- replace = Boolean.valueOf(replaceAttr).booleanValue();
- String trimAttr = element.getAttribute("trim");
- if (trimAttr.length() > 0)
- trim = Boolean.valueOf(trimAttr).booleanValue();
- String serialDataType = element.getAttribute("serialDataType");
-
- // Get the MBeanAttributeInfo
- MBeanAttributeInfo attr = attributeMap.get(attributeName);
- if (attr == null)
- throw new DeploymentException("No Attribute found with name: " + attributeName);
-
- if (element.hasChildNodes())
- {
- Object value = null;
- // Unmarshall the attribute value based on the serialDataType
- if (serialDataType.equals("javaBean"))
- value = parseJavaBeanSerialData(attr, cl, element, replace, trim);
- else if (serialDataType.equals("jbxb"))
- value = parseJbxbSerialData(attr, cl, element, replace, trim);
- else
- value = parseTextSerialData(attr, cl, element, replace, trim);
-
- log.debug(attributeName + " set to " + value + " in " + objectName);
- setAttribute(objectName, new Attribute(attributeName, value));
- }//if has children
-
- }
- //end of "attribute
- else if (element.getTagName().equals("depends"))
- {
- if (!element.hasChildNodes())
- {
- throw new DeploymentException("No ObjectName supplied for depends in " + objectName);
- }
-
- String mbeanRefName = element.getAttribute("optional-attribute-name");
- if ("".equals(mbeanRefName))
- mbeanRefName = null;
- else
- mbeanRefName = StringPropertyReplacer.replaceProperties(mbeanRefName);
-
- String proxyType = element.getAttribute("proxy-type");
- if ("".equals(proxyType))
- proxyType = null;
- else
- proxyType = StringPropertyReplacer.replaceProperties(proxyType);
-
- // Get the mbeanRef value
- ObjectName dependsObjectName = processDependency(objectName, loaderName, element, mbeans, replace);
- log.debug("considering " + ((mbeanRefName == null) ? "<anonymous>" : mbeanRefName.toString()) + " with object name " + dependsObjectName);
-
- if (mbeanRefName != null)
- {
- Object attribute = dependsObjectName;
- if (proxyType != null)
- {
- if (mbeanRefName == null)
- throw new DeploymentException("You cannot use a proxy-type without an optional-attribute-name");
- if (proxyType.equals("attribute"))
- {
- MBeanAttributeInfo attr = attributeMap.get(mbeanRefName);
- if (attr == null)
- throw new DeploymentException("No Attribute found with name: " + mbeanRefName);
- proxyType = attr.getType();
- }
- Class proxyClass = cl.loadClass(proxyType);
- attribute = MBeanProxyExt.create(proxyClass, dependsObjectName,
- server, true);
- }
-
- //if if doesn't exist or has wrong type, we'll get an exception
- setAttribute(objectName, new Attribute(mbeanRefName, attribute));
- } // end of if ()
- }
- //end of depends
- else if (element.getTagName().equals("depends-list"))
- {
- String dependsListName = element.getAttribute("optional-attribute-name");
- if ("".equals(dependsListName))
- {
- dependsListName = null;
- } // end of if ()
-
- NodeList dependsList = element.getChildNodes();
- ArrayList<ObjectName> dependsListNames = new ArrayList<ObjectName>();
- for (int l = 0; l < dependsList.getLength(); l++)
- {
- if (dependsList.item(l).getNodeType() != Node.ELEMENT_NODE)
- {
- continue;
- }
-
- Element dependsElement = (Element) dependsList.item(l);
- if (dependsElement.getTagName().equals("depends-list-element"))
- {
- if (!dependsElement.hasChildNodes())
- {
- throw new DeploymentException("Empty depends-list-element!");
- } // end of if ()
-
- // Get the depends value
- ObjectName dependsObjectName = processDependency(objectName, loaderName, dependsElement, mbeans, replace);
- if (!dependsListNames.contains(dependsObjectName))
- {
- dependsListNames.add(dependsObjectName);
- } // end of if ()
- }
-
- } // end of for ()
- if (dependsListName != null)
- {
- setAttribute(objectName, new Attribute(dependsListName, dependsListNames));
- } // end of if ()
- }//end of depends-list
- }
-
- // If a ServiceBinding policy is plugged-in, check for overriden attributes
- if (serviceBinding != null)
- {
- try
- {
- serviceBinding.applyServiceConfig(objectName);
- }
- catch (Exception e)
- {
- // serviceBinding is most probably a dynamic mbean proxy
- Throwable t = JMXExceptionDecoder.decode(e);
- log.warn("Failed to apply service binding override", t);
- }
- }
- }
-
- // Private -------------------------------------------------------
-
- private ObjectName internalInstall(Element mbeanElement, List<ObjectName> mbeans,
- ObjectName loaderName, boolean replace) throws Exception
- {
- ObjectInstance instance = null;
- ObjectName mbeanName = parseObjectName(mbeanElement, replace);
-
- instance = serviceCreator.install(mbeanName, loaderName, mbeanElement);
-
- // just in case it changed...
- mbeanName = instance.getObjectName();
-
- mbeans.add(mbeanName);
- if (mbeanName != null)
- {
- ServiceContext ctx = serviceController.createServiceContext(mbeanName);
- try
- {
- configure(mbeanName, loaderName, mbeanElement, mbeans);
- ctx.state = ServiceContext.CONFIGURED;
- ctx.problem = null;
- }
- catch (Throwable e) // TODO Backport to JBoss4!!!!
- {
- ctx.state = ServiceContext.FAILED;
- ctx.problem = e;
- log.info("Problem configuring service " + mbeanName, e);
- //throw e;
- }
- }
-
- return mbeanName;
- }
-
- /**
- * Configure the mbean attribute using the element text and PropertyEditor for the
- * attribute type.
- * @param attr - the mbean attribute
- * @param cl - the class loader to use
- * @param element - the mbean attribute element from the jboss-service descriptor
- * @param replace - flag indicating if ${x} system property refs should be replaced
- * @param trim - flag indicating if the element text shold be trimmed
- * @return the configured attribute value
- * @throws Exception
- */
- private Object parseTextSerialData(MBeanAttributeInfo attr, ClassLoader cl,
- Element element, boolean replace, boolean trim)
- throws Exception
- {
- // Get the attribute value
- String attributeName = attr.getName();
- String attributeText = getElementContent(element, trim, replace);
- String typeName = attr.getType();
-
- // see if it is a primitive type first
- Class typeClass = Classes.getPrimitiveTypeForName(typeName);
- if (typeClass == null)
- {
- // nope try look up
- try
- {
- typeClass = cl.loadClass(typeName);
- }
- catch (ClassNotFoundException e)
- {
- throw new DeploymentException
- ("Class not found for attribute: " + attributeName, e);
- }
- }
-
- Object value = null;
-
- /* Attributes of type Element are passed as is after optionally
- performing system property replacement
- */
- if (typeClass.equals(Element.class))
- {
- // Use the first child Element of this element as the value
- NodeList nl = element.getChildNodes();
- for (int i = 0; i < nl.getLength(); i++)
- {
- Node n = nl.item(i);
- if (n.getNodeType() == Node.ELEMENT_NODE)
- {
- value = n;
- break;
- }
- }
- // Replace any ${x} references in the element text
- if (replace)
- {
- PropertyEditor editor = PropertyEditorManager.findEditor(typeClass);
- if (editor == null)
- {
- log.warn("Cannot perform property replace on Element");
- }
- else
- {
- editor.setValue(value);
- String text = editor.getAsText();
- text = StringPropertyReplacer.replaceProperties(text);
- editor.setAsText(text);
- value = editor.getValue();
- }
- }
- }
-
- if (value == null)
- {
- PropertyEditor editor = PropertyEditorManager.findEditor(typeClass);
- if (editor == null)
- {
- throw new DeploymentException
- ("No property editor for attribute: " + attributeName +
- "; type=" + typeClass);
- }
-
- // JBAS-1709, temporarily switch the TCL so that property
- // editors have access to the actual deployment ClassLoader.
- ClassLoader tcl = Thread.currentThread().getContextClassLoader();
- Thread.currentThread().setContextClassLoader(cl);
- try
- {
- editor.setAsText(attributeText);
- value = editor.getValue();
- }
- finally
- {
- Thread.currentThread().setContextClassLoader(tcl);
- }
- }
- return value;
- }
-
- /**
- * Configure the mbean attribute as a javabean with the bean properties given by
- * nested property elements.
- * @param attr - the mbean attribute
- * @param cl - the class loader to use
- * @param element - the mbean attribute element from the jboss-service descriptor
- * @param replace - flag indicating if ${x} system property refs should be replaced
- * @param trim - flag indicating if the element text shold be trimmed
- * @return the configured attribute java bean
- * @throws Exception
- */
- private Object parseJavaBeanSerialData(MBeanAttributeInfo attr, ClassLoader cl,
- Element element, boolean replace, boolean trim)
- throws Exception
- {
- // Extract the property elements
- String attributeClassName = element.getAttribute("attributeClass");
- if( attributeClassName == null || attributeClassName.length() == 0 )
- attributeClassName = attr.getType();
- Class attributeClass = cl.loadClass(attributeClassName);
- // Create the bean instance
- Object bean = attributeClass.newInstance();
- // Get the JavaBean properties
- NodeList properties = element.getElementsByTagName("property");
- Properties beanProps = new Properties();
- for(int n = 0; n < properties.getLength(); n ++)
- {
- // Skip over non-element nodes
- Node node = properties.item(n);
- if (node.getNodeType() != Node.ELEMENT_NODE)
- {
- continue;
- }
- Element property = (Element) node;
- String name = property.getAttribute("name");
- String value = getElementContent(property, trim, replace);
- beanProps.setProperty(name, value);
- }
-
- // Apply the properties to the bean
- PropertyEditors.mapJavaBeanProperties(bean, beanProps);
- return bean;
- }
-
- /**
- * Configure the mbean attribute as a bean with the bean unmarshalled from
- * the attribute xml contents using the JBossXB unmarshaller.
- *
- * @param attr - the mbean attribute
- * @param cl - the class loader to use
- * @param element - the mbean attribute element from the jboss-service descriptor
- * @param replace - ignored
- * @param trim - ignored
- * @return the configured attribute bean
- * @throws Exception
- */
- private Object parseJbxbSerialData(MBeanAttributeInfo attr, ClassLoader cl,
- Element element, boolean replace, boolean trim)
- throws Exception
- {
- // Get the attribute element content in a parsable form
- StringBuffer buffer = getElementContent(element);
-
- // Parse the attribute element content
- SchemaBindingResolver resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
- Unmarshaller unmarshaller = UnmarshallerFactory.newInstance().newUnmarshaller();
- StringReader reader = new StringReader(buffer.toString());
- Object bean = unmarshaller.unmarshal(reader, resolver);
- return bean;
- }
-
- private ObjectName processDependency(ObjectName container, ObjectName loaderName,
- Element element, List<ObjectName> mbeans, boolean replace)
- throws Exception
- {
- ObjectName dependsObjectName = null;
- NodeList nl = element.getChildNodes();
- for (int i = 0; i < nl.getLength(); i++)
- {
- Node childNode = nl.item(i);
- if (childNode.getNodeType() == Node.ELEMENT_NODE)
- {
- Element child = (Element) childNode;
- if (child.getTagName().equals("mbean"))
- {
- dependsObjectName = internalInstall(child, mbeans, loaderName, replace);
- break;
- }
- else
- {
- throw new DeploymentException("Non mbean child element in depends tag: " + child);
- } // end of else
- } // end of if ()
- } // end of for ()
-
- if (dependsObjectName == null)
- {
- String name = getElementContent(element, true, replace);
- dependsObjectName = ObjectNameFactory.create(name);
- }
- if (dependsObjectName == null)
- {
- throw new DeploymentException("No object name found for attribute!");
- } // end of if ()
-
- serviceController.registerDependency(container, dependsObjectName);
-
- return dependsObjectName;
- }
-
- /**
- * A helper to deal with those pesky JMX exceptions.
- */
- private void setAttribute(ObjectName name, Attribute attr)
- throws Exception
- {
- try
- {
- server.setAttribute(name, attr);
- }
- catch (Exception e)
- {
- throw new DeploymentException("Exception setting attribute " +
- attr + " on mbean " + name, JMXExceptionDecoder.decode(e));
- }
- }
-
- private Element internalGetConfiguration(Document doc, ObjectName name)
- throws Exception
- {
- Element mbeanElement = doc.createElement("mbean");
- mbeanElement.setAttribute("name", name.toString());
-
- MBeanInfo info = server.getMBeanInfo(name);
- mbeanElement.setAttribute("code", info.getClassName());
- MBeanAttributeInfo[] attributes = info.getAttributes();
- boolean trace = log.isTraceEnabled();
- for (int i = 0; i < attributes.length; i++)
- {
- if (trace)
- log.trace("considering attribute: " + attributes[i]);
- if (attributes[i].isReadable() && attributes[i].isWritable())
- {
- Element attributeElement = null;
- if (attributes[i].getType().equals("javax.management.ObjectName"))
- {
- attributeElement = doc.createElement("depends");
- attributeElement.setAttribute("optional-attribute-name", attributes[i].getName());
- }
- else
- {
- attributeElement = doc.createElement("attribute");
- attributeElement.setAttribute("name", attributes[i].getName());
- }
- Object value = server.getAttribute(name, attributes[i].getName());
-
- if (value != null)
- {
- if (value instanceof Element)
- {
- attributeElement.appendChild(doc.importNode((Element) value, true));
- }
- else
- {
- attributeElement.appendChild(doc.createTextNode(value.toString()));
- }
- }
- mbeanElement.appendChild(attributeElement);
- }
- }
-
- ServiceContext sc = serviceController.getServiceContext(name);
- for (Iterator i = sc.iDependOn.iterator(); i.hasNext();)
- {
- ServiceContext needs = (ServiceContext) i.next();
- Element dependsElement = doc.createElement("depends");
- dependsElement.appendChild(doc.createTextNode(needs.objectName.toString()));
- mbeanElement.appendChild(dependsElement);
- }
-
- return mbeanElement;
- }
-
- /**
- * Parse an object name from the given element attribute 'name'.
- * @param element Element to parse name from.
- * @return Object name.
- * @throws ConfigurationException Missing attribute 'name' (thrown if 'name'
- * is null or "").
- * @throws Exception
- */
- private ObjectName parseObjectName(final Element element, boolean replace)
- throws Exception
- {
- String name = element.getAttribute("name");
-
- if (name == null || name.trim().equals(""))
- {
- throw new DeploymentException("MBean attribute 'name' must be given.");
- }
-
- if (replace)
- name = StringPropertyReplacer.replaceProperties(name);
-
- return new ObjectName(name);
- }
-
- private String getElementContent(Element element, boolean trim, boolean replace)
- throws Exception
- {
- NodeList nl = element.getChildNodes();
- String attributeText = "";
- for (int i = 0; i < nl.getLength(); i++)
- {
- Node n = nl.item(i);
- if (n instanceof Text)
- {
- attributeText += ((Text) n).getData();
- }
- } // end of for ()
- if (trim)
- attributeText = attributeText.trim();
- if (replace)
- attributeText = StringPropertyReplacer.replaceProperties(attributeText);
- return attributeText;
- }
-
- /**
- * A utility method that transforms the contents of the argument element into
- * a StringBuffer representation that can be reparsed.
- *
- * [FIXME] This is not a general DOMUtils method because of its funny contract. It does not
- * support multiple child elements neither can it deal with text content.
- *
- * @param element - the parent dom element whose contents are to be extracted as an xml document string.
- * @return the xml document string.
- * @throws IOException for an IO problem
- * @throws TransformerException for an error during the transformation
- */
- public static StringBuffer getElementContent(Element element) throws IOException, TransformerException
- {
- NodeList children = element.getChildNodes();
- Element content = null;
- for (int n = 0; n < children.getLength(); n++)
- {
- Node node = children.item(n);
- if (node.getNodeType() == Node.ELEMENT_NODE)
- {
- content = (Element)node;
- break;
- }
- }
- if (content == null)
- return null;
-
- // Get a parsable representation of this elements content
- DOMSource source = new DOMSource(content);
- TransformerFactory tFactory = TransformerFactory.newInstance();
- Transformer transformer = tFactory.newTransformer();
- StringWriter sw = new StringWriter();
- StreamResult result = new StreamResult(sw);
- transformer.transform(source, result);
- sw.close();
- return sw.getBuffer();
- }
-}
\ No newline at end of file
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceConfigurator.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,901 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.system.controller.legacy;
-
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-
-import javax.management.JMException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanOperationInfo;
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.Notification;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.DeploymentState;
-import org.jboss.logging.Logger;
-import org.jboss.mx.server.ServerConstants;
-import org.jboss.mx.util.JBossNotificationBroadcasterSupport;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.Service;
-import org.jboss.system.ServiceBinding;
-import org.jboss.system.ServiceContext;
-import org.jboss.system.ServiceFactory;
-import org.jboss.system.ServiceMBean;
-import org.w3c.dom.Element;
-
-/**
- * This is the main Service Controller. A controller can deploy a service to a
- * jboss.system It installs by delegating, it configures by delegating
- *
- * @see org.jboss.system.Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
- * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $Revision: 1.61 $
- */
-public class OldServiceController extends JBossNotificationBroadcasterSupport
- implements OldServiceControllerMBean, MBeanRegistration
-{
- /** The ObjectName of the default loader repository */
- public static final ObjectName DEFAULT_LOADER_REPOSITORY = ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
-
- /** The operation name for lifecycle */
- public static final String JBOSS_INTERNAL_LIFECYCLE = "jbossInternalLifecycle";
-
- /** The signature for lifecycle operations */
- public static final String[] JBOSS_INTERNAL_LIFECYCLE_SIG = new String[] { String.class.getName() };
-
- /** Class logger. */
- private static final Logger log = Logger.getLogger(OldServiceController.class);
-
- /** A callback to the JMX MBeanServer */
- protected MBeanServer server;
-
- /** Creator, helper class to instantiate MBeans **/
- protected OldServiceCreator creator;
-
- /** Configurator, helper class to configure MBeans **/
- protected OldServiceConfigurator configurator;
-
- /** ObjectName to ServiceContext map **/
- protected Map<ObjectName, ServiceContext> nameToServiceMap = Collections.synchronizedMap(new HashMap<ObjectName, ServiceContext>());
-
- /** A linked list of services in the order they were created **/
- protected List<ServiceContext> installedServices = new LinkedList<ServiceContext>();
-
- /**
- * Plugin a ServiceBinding policy
- *
- * @param serviceBinding policy
- */
- public void setServiceBinding(ServiceBinding serviceBinding)
- {
- if (configurator != null)
- {
- configurator.setServiceBinding(serviceBinding);
- }
- }
-
- public List<ServiceContext> listDeployed()
- {
- return new ArrayList<ServiceContext>(installedServices);
- }
-
- public List<ServiceContext> listIncompletelyDeployed()
- {
- List<ServiceContext> id = new ArrayList<ServiceContext>();
- for (Iterator<ServiceContext> i = installedServices.iterator(); i.hasNext();)
- {
- ServiceContext sc = i.next();
- if ( sc.state != ServiceContext.CREATED &&
- sc.state != ServiceContext.RUNNING &&
- sc.state != ServiceContext.STOPPED &&
- sc.state != ServiceContext.DESTROYED )
- {
- id.add(sc);
- }
- }
- return id;
- }
-
- public List<ObjectName> listDeployedNames()
- {
- List<ObjectName> names = new ArrayList<ObjectName>(installedServices.size());
- for (Iterator<ServiceContext> i = installedServices.iterator(); i.hasNext();)
- {
- ServiceContext ctx = i.next();
- names.add(ctx.objectName);
- }
-
- return names;
- }
-
- public String listConfiguration(ObjectName[] objectNames) throws Exception
- {
- return configurator.getConfiguration(objectNames);
- }
-
- public void validateDeploymentState(DeploymentInfo di, DeploymentState state)
- {
- ArrayList<ObjectName> mbeans = new ArrayList<ObjectName>(di.mbeans);
- if (di.deployedObject != null)
- mbeans.add(di.deployedObject);
- boolean mbeansStateIsValid = true;
- for (int m = 0; m < mbeans.size(); m++)
- {
- ObjectName serviceName = mbeans.get(m);
- ServiceContext ctx = this.getServiceContext(serviceName);
- if (ctx != null && state == DeploymentState.STARTED)
- mbeansStateIsValid &= ctx.state == ServiceContext.RUNNING;
- }
- if (mbeansStateIsValid == true)
- di.state = state;
- }
-
- public synchronized List<ObjectName> install(Element config, ObjectName loaderName) throws DeploymentException
- {
- List<ObjectName> mbeans = configurator.install(config, loaderName);
- for (Iterator<ObjectName> i = mbeans.iterator(); i.hasNext();)
- {
- ObjectName mbean = i.next();
- installedServices.add(createServiceContext(mbean));
- }
- return mbeans;
- }
-
- public synchronized void register(ObjectName serviceName) throws Exception
- {
- register(serviceName, null);
- }
-
- public synchronized void register(ObjectName serviceName, Collection<ObjectName> depends)
- throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to register null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("Registering service " + serviceName);
- ServiceContext ctx = createServiceContext(serviceName);
-
- register(ctx, depends);
- }
-
- public synchronized void create(ObjectName serviceName) throws Exception
- {
- create(serviceName, null);
- }
-
- public synchronized void create(ObjectName serviceName, Collection<ObjectName> depends)
- throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to create null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("Creating service " + serviceName);
- ServiceContext ctx = createServiceContext(serviceName);
-
- // Register the context and its dependencies if necessary
- register(ctx, depends);
-
- // If we are already created (can happen in dependencies) or failed just return
- if (ctx.state == ServiceContext.CREATED
- || ctx.state == ServiceContext.RUNNING
- || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring create request for service: " + ctx.objectName);
- return;
- }
-
- // JSR 77, and to avoid circular dependencies
- int oldState = ctx.state;
- ctx.state = ServiceContext.CREATED;
-
- // Are all the mbeans I depend on created? if not just return
- for (Iterator iterator = ctx.iDependOn.iterator(); iterator.hasNext();)
- {
- ServiceContext sc = (ServiceContext) iterator.next();
- int state = sc.state;
-
- // A dependent is not created or running
- if (!(state == ServiceContext.CREATED || state == ServiceContext.RUNNING))
- {
- log.debug("waiting in create of " + serviceName +
- " waiting on " + sc.objectName);
- ctx.state = oldState;
- return;
- }
- }
-
- // Call create on the service Proxy
- try
- {
- ctx.proxy.create();
- sendControllerNotification(ServiceMBean.CREATE_EVENT, serviceName);
- }
- catch (Throwable e)
- {
- ctx.state = ServiceContext.FAILED;
- ctx.problem = e;
- log.warn("Problem creating service " + serviceName, e);
- return;
- }
-
- // Those that depend on me are waiting for my creation, recursively create them
- log.debug("Creating dependent components for: " + serviceName
- + " dependents are: " + ctx.dependsOnMe);
- ArrayList<ServiceContext> tmp = new ArrayList<ServiceContext>(ctx.dependsOnMe);
- for (int n = 0; n < tmp.size(); n++)
- {
- // marcf fixme circular dependencies?
- ServiceContext ctx2 = tmp.get(n);
- create(ctx2.objectName);
- }
- tmp.clear();
- }
-
- public synchronized void start(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to start null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("starting service " + serviceName);
-
- ServiceContext ctx = createServiceContext(serviceName);
-
- if (!installedServices.contains(ctx))
- installedServices.add(ctx);
-
- // If we are already started (can happen in dependencies) just return
- if (ctx.state == ServiceContext.RUNNING || ctx.state == ServiceContext.FAILED)
- {
- log.debug("Ignoring start request for service: " + ctx.objectName);
- return;
- }
-
- // Start() is called before create(), so call create() to compensate
- if (ctx.state != ServiceContext.CREATED && ctx.state != ServiceContext.STOPPED)
- {
- log.debug("Start requested before create, calling create now for service: " + serviceName);
- create(serviceName);
- }
-
- // Get the fancy service proxy (for the lifecycle API)
- if (ctx.proxy == null)
- ctx.proxy = getServiceProxy(ctx.objectName, null);
-
- // JSR 77, and to avoid circular dependencies
- int oldState = ctx.state;
- ctx.state = ServiceContext.RUNNING;
-
- // Are all the mbeans I depend on started? if not just return
- for (Iterator iterator = ctx.iDependOn.iterator(); iterator.hasNext();)
- {
- ServiceContext sctx = (ServiceContext) iterator.next();
-
- int state = sctx.state;
-
- // A dependent is not running
- if (!(state == ServiceContext.RUNNING))
- {
- log.debug("waiting in start " + serviceName + " on " + sctx.objectName);
- ctx.state = oldState;
- return;
- }
- }
-
- // Call start on the service Proxy
- try
- {
- ctx.proxy.start();
- sendControllerNotification(ServiceMBean.START_EVENT, serviceName);
- }
- catch (Throwable e)
- {
- ctx.state = ServiceContext.FAILED;
- ctx.problem = e;
- log.warn("Problem starting service " + serviceName, e);
- return;
- }
- // Those that depend on me are waiting for my start, recursively start them
- log.debug("Starting dependent components for: " + serviceName
- + " dependent components: " + ctx.dependsOnMe);
- ArrayList<ServiceContext> tmp = new ArrayList<ServiceContext>(ctx.dependsOnMe);
- for (int n = 0; n < tmp.size(); n++)
- {
- // marcf fixme circular dependencies?
- ServiceContext ctx2 = tmp.get(n);
- start(ctx2.objectName);
- }
- tmp.clear();
- }
-
- public void restart(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to restart null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- log.debug("restarting service " + serviceName);
- stop(serviceName);
- start(serviceName);
- }
-
- public void stop(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to stop null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- ServiceContext ctx = nameToServiceMap.get(serviceName);
- log.debug("stopping service: " + serviceName);
-
- if (ctx == null)
- {
- log.warn("Ignoring request to stop nonexistent service: " + serviceName);
- return;
- }
-
- // If we are already stopped (can happen in dependencies) just return
- if (ctx.state != ServiceContext.RUNNING) return;
-
- // JSR 77 and to avoid circular dependencies
- ctx.state = ServiceContext.STOPPED;
-
- log.debug("stopping dependent services for: " + serviceName
- + " dependent services are: " + ctx.dependsOnMe);
-
- ArrayList<ServiceContext> tmp = new ArrayList<ServiceContext>(ctx.dependsOnMe);
- for (int n = 0; n < tmp.size(); n++)
- {
- // stop all the mbeans that depend on me
- ServiceContext ctx2 = tmp.get(n);
- ObjectName other = ctx2.objectName;
- stop(other);
- }
- tmp.clear();
-
- // Call stop on the service Proxy
- if (ctx.proxy != null)
- {
- try
- {
- ctx.proxy.stop();
- sendControllerNotification(ServiceMBean.STOP_EVENT, serviceName);
- }
- catch (Throwable e)
- {
- ctx.state = ServiceContext.FAILED;
- ctx.problem = e;
- log.warn("Problem stopping service " + serviceName, e);
- }
- }
- }
-
- public void destroy(ObjectName serviceName) throws Exception
- {
- if (serviceName == null)
- {
- log.warn("Ignoring request to destroy null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- ServiceContext ctx = nameToServiceMap.get(serviceName);
- log.debug("destroying service: " + serviceName);
-
- if (ctx == null)
- {
- log.warn("Ignoring request to destroy nonexistent service: " + serviceName);
- return;
- }
-
- // If we are already destroyed (can happen in dependencies) just return
- if (ctx.state == ServiceContext.DESTROYED ||
- ctx.state == ServiceContext.NOTYETINSTALLED)
- return;
-
- // If we are still running, stop service first
- if (ctx.state == ServiceContext.RUNNING)
- {
- log.debug("Destroy requested before stop, calling stop now for service: " + serviceName);
- stop(serviceName);
- }
-
- // JSR 77, and to avoid circular dependencies
- ctx.state = ServiceContext.DESTROYED;
-
- log.debug("destroying dependent services for: " + serviceName
- + " dependent services are: " + ctx.dependsOnMe);
-
- ArrayList<ServiceContext> tmp = new ArrayList<ServiceContext>(ctx.dependsOnMe);
- for (int n = 0; n < tmp.size(); n++)
- {
- // destroy all the mbeans that depend on me
- ServiceContext ctx2 = tmp.get(n);
- ObjectName other = ctx2.objectName;
- destroy(other);
- }
- tmp.clear();
-
- // Call destroy on the service Proxy
- if (ctx.proxy != null)
- {
- try
- {
- ctx.proxy.destroy();
- sendControllerNotification(ServiceMBean.DESTROY_EVENT, serviceName);
- }
- catch (Throwable e)
- {
- ctx.state = ServiceContext.FAILED;
- ctx.problem = e;
- log.warn("Problem destroying service " + serviceName, e);
- }
- }
- }
-
- public void remove(ObjectName objectName) throws Exception
- {
- if (objectName == null)
- {
- log.warn("Ignoring request to remove null service: ", new Exception("STACKTRACE"));
- return;
- }
-
- ServiceContext ctx = nameToServiceMap.get(objectName);
- if (ctx == null)
- {
- log.debug("Ignoring request to remove nonexistent service: " + objectName);
- return;
- }
- log.debug("removing service: " + objectName);
-
- // Notify those that think I depend on them
- Iterator iterator = ctx.iDependOn.iterator();
- while (iterator.hasNext())
- {
- ServiceContext iDependOnContext = (ServiceContext) iterator.next();
- iDependOnContext.dependsOnMe.remove(ctx);
-
- // Remove any context whose only reason for existence is that
- // we depend on it, i.e. it otherwise unknown to the system
- if (iDependOnContext.state == ServiceContext.NOTYETINSTALLED
- && iDependOnContext.dependsOnMe.size() == 0)
- {
- nameToServiceMap.remove(iDependOnContext.objectName);
- log.debug("Removing context for nonexistent service it is " +
- "no longer recording dependencies: " + iDependOnContext);
- }
- }
- //We remove all traces of our dependency configuration, since we
- //don't know what will show up the next time we are deployed.
- ctx.iDependOn.clear();
-
- // Do we have a deployed MBean?
- if (server.isRegistered(objectName))
- {
- log.debug("removing " + objectName + " from server");
-
- // Remove the context, unless it is still recording dependencies
- if (ctx.dependsOnMe.size() == 0)
- nameToServiceMap.remove(objectName);
- else
- {
- log.debug("Context not removed, it is recording " +
- "dependencies: " + ctx);
- ctx.proxy = null;
- }
-
- // remove the mbean from the instaled ones
- installedServices.remove(ctx);
- creator.remove(objectName);
- }
- else
- {
- // Remove the context, unless it is still recording dependencies
- installedServices.remove(ctx);
- if (ctx.dependsOnMe.size() == 0)
- {
- log.debug("removing already unregistered " + objectName + " from server");
- nameToServiceMap.remove(objectName);
- }
- else
- {
- log.debug("no need to remove " + objectName + " from server");
- ctx.proxy = null;
- }
- }
- // This context is no longer installed, but it may still exist
- // to record dependent services
- ctx.state = ServiceContext.NOTYETINSTALLED;
- }
-
- /**
- * Lookup the ServiceContext for the given serviceName
- *
- * @jmx.managed-operation
- */
- public ServiceContext getServiceContext(ObjectName serviceName)
- {
- ServiceContext ctx = nameToServiceMap.get(serviceName);
- return ctx;
- }
-
- public void shutdown()
- {
- log.debug("Stopping " + nameToServiceMap.size() + " services");
-
- List<ServiceContext> servicesCopy = new ArrayList<ServiceContext>(installedServices);
-
- int serviceCounter = 0;
- ObjectName name = null;
-
- ListIterator i = servicesCopy.listIterator(servicesCopy.size());
- while (i.hasPrevious())
- {
- ServiceContext ctx = (ServiceContext) i.previous();
- name = ctx.objectName;
-
- // Go through the full stop/destroy cycle
- try
- {
- stop(name);
- }
- catch (Throwable e)
- {
- log.error("Could not stop mbean: " + name, e);
- }
- try
- {
- destroy(name);
- }
- catch (Throwable e)
- {
- log.error("Could not destroy mbean: " + name, e);
- }
- try
- {
- remove(name);
- serviceCounter++;
- }
- catch (Throwable e)
- {
- log.error("Could not remove mbean: " + name, e);
- }
- }
- log.debug("Stopped " + serviceCounter + " services");
- }
-
- // MBeanRegistration implementation ----------------------------------------
-
- /**
- * #Description of the Method
- *
- * @param server Description of Parameter
- * @param name Description of Parameter
- * @return Description of the Returned Value
- * @exception Exception Description of Exception
- */
- public ObjectName preRegister(MBeanServer server, ObjectName name)
- throws Exception
- {
- this.server = server;
-
- creator = new OldServiceCreator(server);
- configurator = new OldServiceConfigurator(server, this, creator);
-
- // Register the ServiceController as a running service
- ServiceContext sc = this.createServiceContext(name);
- sc.state = ServiceContext.RUNNING;
-
- log.debug("Controller MBean online");
- return name == null ? OBJECT_NAME : name;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- if (!registrationDone.booleanValue())
- {
- log.info("Registration of ServiceController failed");
- }
- }
-
- public void preDeregister()
- throws Exception
- {
- }
-
- public void postDeregister()
- {
- nameToServiceMap.clear();
- installedServices.clear();
- creator.shutdown();
- creator = null;
- configurator = null;
- server = null;
- }
-
- // Package Protected ---------------------------------------------
-
- // Create a Service Context for the service, or get one if it exists
- synchronized ServiceContext createServiceContext(ObjectName objectName)
- {
- // If it is already there just return it
- if (nameToServiceMap.containsKey(objectName))
- return nameToServiceMap.get(objectName);
-
- // If not create it, add it and return it
- ServiceContext ctx = new ServiceContext();
- ctx.objectName = objectName;
-
- // we keep track of these here
- nameToServiceMap.put(objectName, ctx);
-
- return ctx;
- }
-
- void registerDependency(ObjectName needs, ObjectName used)
- {
- log.debug("recording that " + needs + " depends on " + used);
- ServiceContext needsCtx = createServiceContext(needs);
- ServiceContext usedCtx = createServiceContext(used);
-
-
- if (!needsCtx.iDependOn.contains(usedCtx))
- {
- // needsCtx depends on usedCtx
- needsCtx.iDependOn.add(usedCtx);
- // UsedCtx needs to know I depend on him
- usedCtx.dependsOnMe.add(needsCtx);
- }
- }
-
- // Private -------------------------------------------------------
-
- /**
- * Register the service context and its dependencies against the microkernel.
- * If the context is already registered it does nothing.
- *
- * @param ctx the ServiceContext to register
- * @param depends a collection of ObjectNames of services the registered service depends on
- */
- private void register(ServiceContext ctx, Collection depends) throws Exception
- {
- if (!installedServices.contains(ctx))
- installedServices.add(ctx);
-
- if (depends != null)
- {
- log.debug("adding depends in ServiceController.register: " + depends);
- for (Iterator i = depends.iterator(); i.hasNext();)
- {
- registerDependency(ctx.objectName, (ObjectName) i.next());
- }
- }
-
- // Get the fancy service proxy (for the lifecycle API), if needed
- if (ctx.proxy == null)
- ctx.proxy = getServiceProxy(ctx.objectName, null);
- }
-
- /**
- * Get the Service interface through which the mbean given by objectName
- * will be managed.
- *
- * @param objectName
- * @param serviceFactory
- * @return The Service value
- *
- * @throws ClassNotFoundException
- * @throws InstantiationException
- * @throws IllegalAccessException
- */
- private Service getServiceProxy(ObjectName objectName, String serviceFactory)
- throws ClassNotFoundException, InstantiationException,
- IllegalAccessException, JMException
- {
- Service service = null;
- ClassLoader loader = Thread.currentThread().getContextClassLoader();
- if (serviceFactory != null && serviceFactory.length() > 0)
- {
- Class clazz = loader.loadClass(serviceFactory);
- ServiceFactory factory = (ServiceFactory) clazz.newInstance();
- service = factory.createService(server, objectName);
- }
- else
- {
- MBeanInfo info = server.getMBeanInfo(objectName);
- MBeanOperationInfo[] opInfo = info.getOperations();
- Class[] interfaces = {Service.class};
- InvocationHandler handler = new ServiceProxy(objectName, opInfo);
- service = (Service) Proxy.newProxyInstance(Service.class.getClassLoader(), interfaces, handler);
- }
-
- return service;
- }
-
- /**
- * Sends outs controller notifications about service lifecycle events
- */
- private void sendControllerNotification(String type, ObjectName serviceName)
- {
- Notification notification = new Notification(type, this, super.nextNotificationSequenceNumber());
- notification.setUserData(serviceName);
- sendNotification(notification);
- }
-
- // Inner classes -------------------------------------------------
-
- /**
- * A mapping from the Service interface method names to the corresponding
- * index into the ServiceProxy.hasOp array.
- */
- private static HashMap<String, Integer> serviceOpMap = new HashMap<String, Integer>();
-
- /**
- * An implementation of InvocationHandler used to proxy of the Service
- * interface for mbeans. It determines which of the start/stop
- * methods of the Service interface an mbean implements by inspecting its
- * MBeanOperationInfo values. Each Service interface method that has a
- * matching operation is forwarded to the mbean by invoking the method
- * through the MBeanServer object.
- */
- public class ServiceProxy implements InvocationHandler
- {
- private boolean[] hasOp = {false, false, false, false};
- private ObjectName objectName;
-
- /** Whether we have the lifecycle method */
- private boolean hasJBossInternalLifecycle;
-
- /**
- * Go through the opInfo array and for each operation that matches on of
- * the Service interface methods set the corresponding hasOp array value
- * to true.
- *
- * @param objectName
- * @param opInfo
- */
- public ServiceProxy(ObjectName objectName, MBeanOperationInfo[] opInfo)
- {
- this.objectName = objectName;
-
- for (int op = 0; op < opInfo.length; op++)
- {
- MBeanOperationInfo info = opInfo[op];
- String name = info.getName();
-
- if (name.equals(JBOSS_INTERNAL_LIFECYCLE))
- {
- hasJBossInternalLifecycle = true;
- continue;
- }
-
- Integer opID = serviceOpMap.get(name);
- if (opID == null)
- {
- continue;
- }
-
- // Validate that is a no-arg void return type method
- if (info.getReturnType().equals("void") == false)
- {
- continue;
- }
- if (info.getSignature().length != 0)
- {
- continue;
- }
-
- hasOp[opID.intValue()] = true;
- }
- }
-
- /**
- * Map the method name to a Service interface method index and if the
- * corresponding hasOp array element is true, dispatch the method to the
- * mbean we are proxying.
- *
- * @param proxy
- * @param method
- * @param args
- * @return Always null.
- * @throws Throwable
- */
- public Object invoke(Object proxy, Method method, Object[] args)
- throws Throwable
- {
- String name = method.getName();
-
- if (hasJBossInternalLifecycle)
- {
- try
- {
- server.invoke(objectName, JBOSS_INTERNAL_LIFECYCLE, new Object[] { name }, JBOSS_INTERNAL_LIFECYCLE_SIG);
- return null;
- }
- catch (Exception e)
- {
- throw JMXExceptionDecoder.decode(e);
- }
- }
-
- Integer opID = serviceOpMap.get(name);
-
- if (opID != null && hasOp[opID.intValue()] == true)
- {
- // deal with those pesky JMX exceptions
- try
- {
- String[] sig = {};
- server.invoke(objectName, name, args, sig);
- }
- catch (Exception e)
- {
- throw JMXExceptionDecoder.decode(e);
- }
- }
-
- return null;
- }
- }
-
- /**
- * Initialize the service operation map.
- */
- static
- {
- serviceOpMap.put("create", new Integer(0));
- serviceOpMap.put("start", new Integer(1));
- serviceOpMap.put("destroy", new Integer(2));
- serviceOpMap.put("stop", new Integer(3));
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceController.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,33 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.system.controller.legacy;
-
-import org.jboss.system.ServiceControllerMBean;
-
-/**
- * ServiceController MBean interface.
- *
- * @see org.jboss.system.Service
- */
-public interface OldServiceControllerMBean extends ServiceControllerMBean
-{
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceControllerMBean.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,380 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.system.controller.legacy;
-
-import java.beans.PropertyEditor;
-import java.beans.PropertyEditorManager;
-import java.lang.reflect.Constructor;
-import java.lang.reflect.UndeclaredThrowableException;
-import java.net.URL;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectInstance;
-import javax.management.ObjectName;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.mx.service.ServiceConstants;
-import org.jboss.mx.util.JMXExceptionDecoder;
-import org.jboss.system.ConfigurationException;
-import org.jboss.util.Classes;
-import org.jboss.util.StringPropertyReplacer;
-import org.w3c.dom.Attr;
-import org.w3c.dom.Element;
-import org.w3c.dom.NodeList;
-
-/**
- * A helper class for the controller.
- *
- * @see org.jboss.system.Service
- *
- * @author <a href="mailto:marc.fleury at jboss.org">Marc Fleury</a>
- * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
- * @version $Revision: 1.22 $
- */
-public class OldServiceCreator
-{
- // Static --------------------------------------------------------
-
- /** The default XMBean class, when one is not specified */
- private static final String XMBEAN_CODE = "org.jboss.mx.modelmbean.XMBean";
-
- /** Instance logger. */
- private static final Logger log = Logger.getLogger(OldServiceCreator.class);
-
- // Attributes ----------------------------------------------------
-
- /** The server */
- private MBeanServer server;
-
- // Constructors --------------------------------------------------
-
- /**
- * CTOR
- *
- * @param server the MBeanServer
- */
- public OldServiceCreator(final MBeanServer server)
- {
- this.server = server;
- }
-
- // Public --------------------------------------------------------
-
- /**
- * Clean shutdown
- */
- public void shutdown()
- {
- this.server = null;
- }
-
- /**
- * Parses the given configuration document and creates MBean
- * instances in the current MBean server.
- *
- * @param mbeanName the object name
- * @param loaderName the classloader
- * @param mbeanElement the config
- * @return the created object instance
- * @throws Exception for any error
- */
- public ObjectInstance install(ObjectName mbeanName, ObjectName loaderName,
- Element mbeanElement) throws Exception
- {
- if (server.isRegistered(mbeanName))
- {
- throw new DeploymentException("Trying to install an already registered mbean: " + mbeanName);
- }
- // If class is given, instantiate it
- String code = mbeanElement.getAttribute("code");
- if ( code == null || "".equals(code))
- {
- throw new ConfigurationException("missing 'code' attribute");
- }
-
- // get the constructor params/sig to use
- ConstructorInfo constructor = ConstructorInfo.create(mbeanElement);
-
- // Check for xmbean specific attributes
- String xmbeandd = null;
- Attr xmbeanddAttr = mbeanElement.getAttributeNode("xmbean-dd");
- if( xmbeanddAttr != null )
- xmbeandd = xmbeanddAttr.getValue();
- String xmbeanCode = mbeanElement.getAttribute("xmbean-code");
- if( xmbeanCode.length() == 0 )
- xmbeanCode = XMBEAN_CODE;
-
- // Create the mbean instance
- ObjectInstance instance = null;
- try
- {
- if ( xmbeandd == null )
- {
- // Check for the explicit management interface in case of a standard MBean
- Attr itfAttr = mbeanElement.getAttributeNode("interface");
- if (itfAttr != null)
- {
- // Get the good class loader
- ClassLoader classLoader = server.getClassLoader(loaderName);
-
- // Load interface class
- String itf = itfAttr.getValue();
- Class itfClass = classLoader.loadClass(itf);
- log.debug("About to create bean resource: " + mbeanName + " with code: " + code);
- Object resource = server.instantiate(code,
- loaderName,
- constructor.params,
- constructor.signature);
- //
- log.debug("About to register StandardMBean : " + mbeanName);
- instance = server.createMBean("javax.management.StandardMBean",
- mbeanName,
- loaderName,
- new Object[]{resource,itfClass},
- new String[]{Object.class.getName(),Class.class.getName()});
- }
- else
- {
- // This is a standard or dynamic mbean
- log.debug("About to create bean: " + mbeanName + " with code: " + code);
- instance = server.createMBean(code,
- mbeanName,
- loaderName,
- constructor.params,
- constructor.signature);
- }
- } // end of if ()
- else if( xmbeandd.length() == 0 )
- {
- // This is an xmbean with an embedded mbean descriptor
- log.debug("About to create xmbean object: " + mbeanName
- + " with code: " + code + " with embedded descriptor");
- //xmbean: construct object first.
- Object resource = server.instantiate(code, loaderName,
- constructor.params, constructor.signature);
-
- NodeList mbeans = mbeanElement.getElementsByTagName("xmbean");
- if( mbeans.getLength() == 0 )
- throw new ConfigurationException("No nested mbean element given for xmbean");
- Element mbeanDescriptor = (Element) mbeans.item(0);
- Object[] args = {resource, mbeanDescriptor,
- ServiceConstants.PUBLIC_JBOSSMX_XMBEAN_DTD_1_0};
- String[] sig = {Object.class.getName(), Element.class.getName(),
- String.class.getName()};
- instance = server.createMBean(xmbeanCode,
- mbeanName,
- loaderName,
- args,
- sig);
- }
- else
- {
- // This is an xmbean with an external descriptor
- log.debug("About to create xmbean object: " + mbeanName
- + " with code: " + code + " with descriptor: "+xmbeandd);
- //xmbean: construct object first.
- Object resource = server.instantiate(code, loaderName,
- constructor.params, constructor.signature);
- // Try to find the dd first as a resource then as a URL
- URL xmbeanddUrl = null;
- try
- {
- xmbeanddUrl = resource.getClass().getClassLoader().getResource(xmbeandd);
- }
- catch (Exception e)
- {
- } // end of try-catch
- if (xmbeanddUrl == null)
- {
- xmbeanddUrl = new URL(xmbeandd);
- } // end of if ()
-
- //now create the mbean
- Object[] args = {resource, xmbeanddUrl};
- String[] sig = {Object.class.getName(), URL.class.getName()};
- instance = server.createMBean(xmbeanCode,
- mbeanName,
- loaderName,
- args,
- sig);
- } // end of else
- }
- catch (Throwable e)
- {
- Throwable newE = JMXExceptionDecoder.decode(e);
-
- // didn't work, unregister in case the jmx agent is screwed.
- try
- {
- server.unregisterMBean(mbeanName);
- }
- catch (Throwable ignore)
- {
- }
-
- if (newE instanceof Exception)
- {
- throw (Exception)newE;
- } // end of if ()
- throw new UndeclaredThrowableException(newE);
- }
-
- log.debug("Created bean: "+mbeanName);
- return instance;
- }
-
- public void remove(ObjectName name) throws Exception
- {
- // add defaut domain if there isn't one in this name
- String domain = name.getDomain();
- if (domain == null || "".equals(domain))
- {
- name = new ObjectName(server.getDefaultDomain() + name);
- }
-
- // Remove the MBean from the MBeanServer
- server.unregisterMBean(name);
- }
-
- // Inner Class --------------------------------------------------
-
- /**
- * Provides a wrapper around the information about which constructor
- * that MBeanServer should use to construct a MBean.
- * Please note that only basic datatypes (type is then the same as
- * you use to declare it "short", "int", "float" etc.) and any class
- * having a constructor taking a single "String" as only parameter.
- *
- * <p>XML syntax for contructor:
- * <pre>
- * <constructor>
- * <arg type="xxx" value="yyy"/>
- * ...
- * <arg type="xxx" value="yyy"/>
- * </constructor>
- * </pre>
- */
- private static class ConstructorInfo
- {
- /** An empty parameters list. */
- public static final Object EMPTY_PARAMS[] = {};
-
- /** An signature list. */
- public static final String EMPTY_SIGNATURE[] = {};
-
- /** The constructor signature. */
- public String[] signature = EMPTY_SIGNATURE;
-
- /** The constructor parameters. */
- public Object[] params = EMPTY_PARAMS;
-
- /**
- * Create a ConstructorInfo object for the given configuration.
- *
- * @param element The element to build info for.
- * @return A constructor information object.
- *
- * @throws ConfigurationException Failed to create info object.
- */
- public static ConstructorInfo create(Element element)
- throws ConfigurationException
- {
- ConstructorInfo info = new ConstructorInfo();
- NodeList list = element.getElementsByTagName("constructor");
- if (list.getLength() > 1 && list.item(0).getParentNode() == element)
- {
- throw new ConfigurationException
- ("only one <constructor> element may be defined");
- }
- else if (list.getLength() == 1)
- {
- element = (Element)list.item(0);
-
- // get all of the "arg" elements
- list = element.getElementsByTagName("arg");
- int length = list.getLength();
- info.params = new Object[length];
- info.signature = new String[length];
- ClassLoader loader = Thread.currentThread().getContextClassLoader();
-
- // decode the values into params & signature
- for (int j=0; j<length; j++)
- {
- Element arg = (Element)list.item(j);
- String signature = arg.getAttribute("type");
- String value = arg.getAttribute("value");
- // Allow for system property reference replacement
- value = StringPropertyReplacer.replaceProperties(arg.getAttribute("value"));
- Object realValue = value;
-
- if( signature != null )
- {
- // See if it is a primitive type first
- Class typeClass = Classes.getPrimitiveTypeForName(signature);
- if (typeClass == null)
- {
- // Try to load the class
- try
- {
- typeClass = loader.loadClass(signature);
- }
- catch (ClassNotFoundException e)
- {
- throw new ConfigurationException
- ("Class not found for type: " + signature, e);
- }
- }
-
- // Convert the string to the real value
- PropertyEditor editor = PropertyEditorManager.findEditor(typeClass);
- if (editor == null)
- {
- try
- {
- // See if there is a ctor(String) for the type
- Class[] sig = {String.class};
- Constructor ctor = typeClass.getConstructor(sig);
- Object[] args = {value};
- realValue = ctor.newInstance(args);
- }
- catch (Exception e)
- {
- throw new ConfigurationException("No property editor for type: " + typeClass);
- }
- }
- else
- {
- editor.setAsText(value);
- realValue = editor.getValue();
- }
- }
- info.signature[j] = signature;
- info.params[j] = realValue;
- }
- }
-
- return info;
- }
- }
-
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/legacy/OldServiceCreator.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsListNestedNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsListNestedNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsListNestedNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsListNestedNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsListNestedOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsListNestedOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsListNestedOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsListNestedOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNestedOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsListNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsListNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsListNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsListNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsListOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsListOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsListOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsListOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsListOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsNestedNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsNestedNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsNestedNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsNestedNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsNestedOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsNestedOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsNestedOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsNestedOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNestedOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeListNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeListNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeListNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeListNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeListOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeListOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeListOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeListOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeListOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeNewUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeNewUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicDependencyDependsOptionalAttributeOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicDependencyDependsOptionalAttributeOldUnitTestCase extends BasicDependencyTest
-{
- public static Test suite()
- {
- return suite(BasicDependencyDependsOptionalAttributeOldUnitTestCase.class);
- }
-
- public BasicDependencyDependsOptionalAttributeOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyDependsOptionalAttributeOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,390 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * BasicLifecycleTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class BasicDependencyTest extends AbstractControllerTest
-{
- private static ObjectName NAME_ONE = ObjectNameFactory.create("test:name=1");
- private static ObjectName NAME_TWO = ObjectNameFactory.create("test:name=2");
-
- private String resourceName;
-
- public BasicDependencyTest(String name)
- {
- super(name);
-
- resourceName = getClass().getName();
- int index= resourceName.lastIndexOf('.');
- if (index != -1)
- resourceName= resourceName.substring(index + 1, resourceName.length());
- index = resourceName.indexOf("NewUnitTestCase");
- if (index != -1)
- resourceName = resourceName.substring(0, index);
- index = resourceName.indexOf("OldUnitTestCase");
- if (index != -1)
- resourceName = resourceName.substring(0, index);
-
- resourceName = resourceName + "_NotAutomatic.xml";
- }
-
- public void testBasicDependency() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans = deploy(resourceName);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(5, test1.stopOrder);
- assertEquals(7, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(6, test2.stopOrder);
- assertEquals(8, test2.destroyOrder);
- }
- }
- }
-
- public void testBasicRedeploy() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans = deploy(resourceName);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(5, test1.stopOrder);
- assertEquals(7, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(6, test2.stopOrder);
- assertEquals(8, test2.destroyOrder);
- }
- }
-
- mbeans = deploy(resourceName);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(10, test1.createOrder);
- assertEquals(12, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(9, test2.createOrder);
- assertEquals(11, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(10, test1.createOrder);
- assertEquals(12, test1.startOrder);
- assertEquals(13, test1.stopOrder);
- assertEquals(15, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(9, test2.createOrder);
- assertEquals(11, test2.startOrder);
- assertEquals(14, test2.stopOrder);
- assertEquals(16, test2.destroyOrder);
- }
- }
- }
-
- public void testBasicDependencyManualLifecycle() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans = deploy(resourceName);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- ServiceControllerMBean controller = getController();
-
- controller.stop(NAME_ONE);
- assertServiceStopped(NAME_ONE);
- assertServiceRunning(NAME_TWO);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(5, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- controller.destroy(NAME_ONE);
- assertServiceDestroyed(NAME_ONE);
- assertServiceRunning(NAME_TWO);
- assertEquals(2, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(5, test1.stopOrder);
- assertEquals(6, test1.destroyOrder);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- controller.create(NAME_ONE);
- assertServiceCreated(NAME_ONE);
- assertServiceRunning(NAME_TWO);
- assertEquals(7, test1.createOrder);
- assertEquals(4, test1.startOrder);
- assertEquals(5, test1.stopOrder);
- assertEquals(6, test1.destroyOrder);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- controller.start(NAME_ONE);
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
- assertEquals(7, test1.createOrder);
- assertEquals(8, test1.startOrder);
- assertEquals(5, test1.stopOrder);
- assertEquals(6, test1.destroyOrder);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- controller.stop(NAME_TWO);
- assertServiceStopped(NAME_ONE);
- assertServiceStopped(NAME_TWO);
- assertEquals(7, test1.createOrder);
- assertEquals(8, test1.startOrder);
- assertEquals(9, test1.stopOrder);
- assertEquals(6, test1.destroyOrder);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(10, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- controller.destroy(NAME_TWO);
- assertServiceDestroyed(NAME_ONE);
- assertServiceDestroyed(NAME_TWO);
- assertEquals(7, test1.createOrder);
- assertEquals(8, test1.startOrder);
- assertEquals(9, test1.stopOrder);
- assertEquals(11, test1.destroyOrder);
- assertEquals(1, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(10, test2.stopOrder);
- assertEquals(12, test2.destroyOrder);
-
- controller.create(NAME_TWO);
- assertServiceCreated(NAME_ONE);
- assertServiceCreated(NAME_TWO);
- assertEquals(14, test1.createOrder);
- assertEquals(8, test1.startOrder);
- assertEquals(9, test1.stopOrder);
- assertEquals(11, test1.destroyOrder);
- assertEquals(13, test2.createOrder);
- assertEquals(3, test2.startOrder);
- assertEquals(10, test2.stopOrder);
- assertEquals(12, test2.destroyOrder);
-
- controller.start(NAME_TWO);
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
- assertEquals(14, test1.createOrder);
- assertEquals(16, test1.startOrder);
- assertEquals(9, test1.stopOrder);
- assertEquals(11, test1.destroyOrder);
- assertEquals(13, test2.createOrder);
- assertEquals(15, test2.startOrder);
- assertEquals(10, test2.stopOrder);
- assertEquals(12, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(14, test1.createOrder);
- assertEquals(16, test1.startOrder);
- assertEquals(17, test1.stopOrder);
- assertEquals(19, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(13, test2.createOrder);
- assertEquals(15, test2.startOrder);
- assertEquals(18, test2.stopOrder);
- assertEquals(20, test2.destroyOrder);
- }
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicDependencyTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicLifecycleNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicLifecycleNewUnitTestCase extends BasicLifecycleTest
-{
- public static Test suite()
- {
- return suite(BasicLifecycleNewUnitTestCase.class);
- }
-
- public BasicLifecycleNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * BasicLifecycleOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicLifecycleOldUnitTestCase extends BasicLifecycleTest
-{
- public static Test suite()
- {
- return suite(BasicLifecycleOldUnitTestCase.class);
- }
-
- public BasicLifecycleOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,236 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceControllerMBean;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * BasicLifecycleTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class BasicLifecycleTest extends AbstractControllerTest
-{
- public BasicLifecycleTest(String name)
- {
- super(name);
- }
-
- public void testBasicLifecyle() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- Simple test = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans = deploy("BasicLifecycle_NotAutomatic.xml");
- try
- {
- assertServiceRunning(name);
-
- MBeanServer server = getServer();
- test = (Simple) server.getAttribute(name, "Instance");
- assertEquals("()", test.constructorUsed);
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(0, test.stopOrder);
- assertEquals(0, test.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(name);
- assertNotRegistered(name);
-
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(3, test.stopOrder);
- assertEquals(4, test.destroyOrder);
- }
- }
- }
-
- public void testBasicRedeploy() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- Simple test = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans = deploy("BasicLifecycle_NotAutomatic.xml");
- try
- {
- assertServiceRunning(name);
-
- MBeanServer server = getServer();
- test = (Simple) server.getAttribute(name, "Instance");
- assertEquals("()", test.constructorUsed);
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(0, test.stopOrder);
- assertEquals(0, test.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(name);
- assertNotRegistered(name);
-
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(3, test.stopOrder);
- assertEquals(4, test.destroyOrder);
- }
- }
-
- mbeans = deploy("BasicLifecycle_NotAutomatic.xml");
- try
- {
- assertServiceRunning(name);
-
- MBeanServer server = getServer();
- test = (Simple) server.getAttribute(name, "Instance");
- assertEquals("()", test.constructorUsed);
- assertEquals(5, test.createOrder);
- assertEquals(6, test.startOrder);
- assertEquals(0, test.stopOrder);
- assertEquals(0, test.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(name);
- assertNotRegistered(name);
-
- assertEquals(5, test.createOrder);
- assertEquals(6, test.startOrder);
- assertEquals(7, test.stopOrder);
- assertEquals(8, test.destroyOrder);
- }
- }
- }
-
- public void testBasicManualLifecycle() throws Exception
- {
- ObjectName name = SimpleMBean.OBJECT_NAME;
- Simple test = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans = deploy("BasicLifecycle_NotAutomatic.xml");
- try
- {
- assertServiceRunning(name);
-
- MBeanServer server = getServer();
- test = (Simple) server.getAttribute(name, "Instance");
- assertEquals("()", test.constructorUsed);
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(0, test.stopOrder);
- assertEquals(0, test.destroyOrder);
-
- ServiceControllerMBean controller = getController();
-
- controller.stop(name);
- assertServiceStopped(name);
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(3, test.stopOrder);
- assertEquals(0, test.destroyOrder);
-
- controller.destroy(name);
- assertServiceDestroyed(name);
- assertEquals(1, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(3, test.stopOrder);
- assertEquals(4, test.destroyOrder);
-
- controller.create(name);
- assertServiceCreated(name);
- assertEquals(5, test.createOrder);
- assertEquals(2, test.startOrder);
- assertEquals(3, test.stopOrder);
- assertEquals(4, test.destroyOrder);
-
- controller.start(name);
- assertServiceRunning(name);
- assertEquals(5, test.createOrder);
- assertEquals(6, test.startOrder);
- assertEquals(3, test.stopOrder);
- assertEquals(4, test.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans);
-
- if (error == false)
- {
- assertNoService(name);
- assertNotRegistered(name);
-
- assertEquals(5, test.createOrder);
- assertEquals(6, test.startOrder);
- assertEquals(7, test.stopOrder);
- assertEquals(8, test.destroyOrder);
- }
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/BasicLifecycleTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,66 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.basic.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * Controller Lifecycle Basic Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerLifecycleBasicTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Lifecycle Basic Tests");
-
- suite.addTest(BasicLifecycleOldUnitTestCase.suite());
- suite.addTest(BasicLifecycleNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsNestedOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsNestedNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsListOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsListNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsListNestedOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsListNestedNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeNestedOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeNestedNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeListOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeListNewUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeListNestedOldUnitTestCase.suite());
- suite.addTest(BasicDependencyDependsOptionalAttributeListNestedNewUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/basic/test/ControllerLifecycleBasicTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,60 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * Controller Lifecycle Seperated Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerLifecycleSeperatedTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Lifecycle Seperated Tests");
-
- suite.addTest(SeperatedDependencyDependsOldUnitTestCase.suite());
- suite.addTest(SeperatedDependencyDependsNewUnitTestCase.suite());
- suite.addTest(DependsBrokenInstantiateOldUnitTestCase.suite());
- suite.addTest(DependsBrokenInstantiateNewUnitTestCase.suite());
- suite.addTest(DependsBrokenConfigureOldUnitTestCase.suite());
- suite.addTest(DependsBrokenConfigureNewUnitTestCase.suite());
- suite.addTest(DependsBrokenCreateOldUnitTestCase.suite());
- suite.addTest(DependsBrokenCreateNewUnitTestCase.suite());
- suite.addTest(DependsBrokenStartOldUnitTestCase.suite());
- suite.addTest(DependsBrokenStartNewUnitTestCase.suite());
- suite.addTest(NewOnDemandDependencyUnitTestCase.suite());
- suite.addTest(NewOnDemandServerDependencyUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/ControllerLifecycleSeperatedTestSuite.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenConfigureNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenConfigureNewUnitTestCase extends DependsBrokenConfigureTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenConfigureNewUnitTestCase.class);
- }
-
- public DependsBrokenConfigureNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,57 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.system.ServiceContext;
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenConfigureOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenConfigureOldUnitTestCase extends DependsBrokenConfigureTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenConfigureOldUnitTestCase.class);
- }
-
- public DependsBrokenConfigureOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- // FIXME This is rubbish
- public void testBrokenConfigureSecond() throws Exception
- {
- deployBrokenSecondDeployFailure(ServiceContext.CONFIGURED, ServiceContext.DESTROYED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import org.jboss.system.ServiceContext;
-
-/**
- * DependsBrokenConfigureTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsBrokenConfigureTest extends DependsBrokenTest
-{
- public DependsBrokenConfigureTest(String name)
- {
- super(name);
- }
-
- public void testBrokenConfigureFirst() throws Exception
- {
- deployBrokenFirstDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-
- public void testBrokenConfigureSecond() throws Exception
- {
- deployBrokenSecondDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenConfigureTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenCreateNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenCreateNewUnitTestCase extends DependsBrokenCreateTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenCreateNewUnitTestCase.class);
- }
-
- public DependsBrokenCreateNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,57 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.system.ServiceContext;
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenCreateOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenCreateOldUnitTestCase extends DependsBrokenCreateTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenCreateOldUnitTestCase.class);
- }
-
- public DependsBrokenCreateOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- // FIXME This is rubbish
- public void testBrokenCreateSecond() throws Exception
- {
- deployBrokenSecondDeployFailure(ServiceContext.CONFIGURED, ServiceContext.DESTROYED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import org.jboss.system.ServiceContext;
-
-/**
- * DependsBrokenCreateTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsBrokenCreateTest extends DependsBrokenTest
-{
- public DependsBrokenCreateTest(String name)
- {
- super(name);
- }
-
- public void testBrokenCreateFirst() throws Exception
- {
- deployBrokenFirstDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-
- public void testBrokenCreateSecond() throws Exception
- {
- deployBrokenSecondDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenCreateTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenInstantiateNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenInstantiateNewUnitTestCase extends DependsBrokenInstantiateTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenInstantiateNewUnitTestCase.class);
- }
-
- public DependsBrokenInstantiateNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.system.ServiceContext;
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenInstantiateOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenInstantiateOldUnitTestCase extends DependsBrokenInstantiateTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenInstantiateOldUnitTestCase.class);
- }
-
- public DependsBrokenInstantiateOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- public void testBrokenInstantiateSecond() throws Exception
- {
- deployBrokenSecondInitialDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import org.jboss.system.ServiceContext;
-
-/**
- * DependsBrokenInstantiateTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsBrokenInstantiateTest extends DependsBrokenTest
-{
- public DependsBrokenInstantiateTest(String name)
- {
- super(name);
- }
-
- public void testBrokenInstantiateFirst() throws Exception
- {
- deployBrokenFirstMaybeDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-
- public void testBrokenInstantiateSecond() throws Exception
- {
- deployBrokenSecondMaybeDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenInstantiateTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenStartNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenStartNewUnitTestCase extends DependsBrokenStartTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenStartNewUnitTestCase.class);
- }
-
- public DependsBrokenStartNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,57 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.system.ServiceContext;
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * DependsBrokenStartOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsBrokenStartOldUnitTestCase extends DependsBrokenStartTest
-{
- public static Test suite()
- {
- return suite(DependsBrokenStartOldUnitTestCase.class);
- }
-
- public DependsBrokenStartOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-
- // FIXME This is rubbish
- public void testBrokenStartSecond() throws Exception
- {
- deployBrokenSecondDeployFailure(ServiceContext.CONFIGURED, ServiceContext.CREATED, ServiceContext.DESTROYED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,48 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import org.jboss.system.ServiceContext;
-
-/**
- * DependsBrokenStartTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsBrokenStartTest extends DependsBrokenTest
-{
- public DependsBrokenStartTest(String name)
- {
- super(name);
- }
-
- public void testBrokenStartFirst() throws Exception
- {
- deployBrokenFirstDeployFailure(ServiceContext.CONFIGURED, Error.class);
- }
-
- public void testBrokenStartSecond() throws Exception
- {
- deployBrokenSecondDeployFailure(ServiceContext.CONFIGURED, ServiceContext.DESTROYED, ServiceContext.DESTROYED, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenStartTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,368 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.system.controller.AbstractControllerTest;
-
-/**
- * DependsBrokenTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class DependsBrokenTest extends AbstractControllerTest
-{
- private static ObjectName NAME_ONE = ObjectNameFactory.create("test:name=1");
- private static ObjectName NAME_TWO = ObjectNameFactory.create("test:name=2");
-
- private String resourceName1;
- private String resourceName2;
-
- public DependsBrokenTest(String name)
- {
- super(name);
-
- String resourceName = getClass().getName();
- int index= resourceName.lastIndexOf('.');
- if (index != -1)
- resourceName= resourceName.substring(index + 1, resourceName.length());
- index = resourceName.indexOf("NewUnitTestCase");
- if (index != -1)
- resourceName = resourceName.substring(0, index);
- index = resourceName.indexOf("OldUnitTestCase");
- if (index != -1)
- resourceName = resourceName.substring(0, index);
-
- resourceName1 = resourceName + "_bad.xml";
- resourceName2 = resourceName + "_good.xml";
- }
-
- public void deployBrokenFirstMaybeDeployFailure(int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- boolean error = false;
-
- List<ObjectName> mbeans1 = assertMaybeDeployFailure(resourceName1, NAME_ONE, expected);
- try
- {
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceState(NAME_TWO, expectedState);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
-
- public void deployBrokenSecondMaybeDeployFailure(int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- boolean error = false;
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceState(NAME_TWO, expectedState);
- assertRegistered(NAME_TWO);
-
- List<ObjectName> mbeans1 = assertMaybeDeployFailure(resourceName1, NAME_ONE, expected);
- try
- {
- assertServiceState(NAME_TWO, expectedState);
- assertRegistered(NAME_TWO);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertServiceState(NAME_TWO, expectedState);
- assertRegistered(NAME_TWO);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
-
- public void deployBrokenFirstDeployFailure(int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- boolean error = false;
-
- List<ObjectName> mbeans1 = assertDeployFailure(resourceName1, NAME_ONE, expected);
- try
- {
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceState(NAME_TWO, expectedState);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
-
- public void deployBrokenSecondDeployFailure(int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- deployBrokenSecondDeployFailure(expectedState, expectedState, expectedState, expected);
- }
-
- public void deployBrokenSecondDeployFailure(int expectedState, int brokenExpectedState, Class<? extends Throwable> expected) throws Exception
- {
- deployBrokenSecondDeployFailure(expectedState, expectedState, brokenExpectedState, expected);
- }
-
- public void deployBrokenSecondDeployFailure(int beforeExpectedState, int afterExpectedState, int brokenExpectedState, Class<? extends Throwable> expected) throws Exception
- {
- boolean error = false;
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceState(NAME_TWO, beforeExpectedState);
- assertRegistered(NAME_TWO);
-
- List<ObjectName> mbeans1 = assertDeployFailure(resourceName1, NAME_ONE, expected);
- try
- {
- assertServiceState(NAME_TWO, afterExpectedState);
- assertRegistered(NAME_TWO);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertServiceState(NAME_TWO, brokenExpectedState);
- assertRegistered(NAME_TWO);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
-
- public void deployBrokenSecondInitialDeployFailure(int expectedState, Class<? extends Throwable> expected) throws Exception
- {
- boolean error = false;
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceState(NAME_TWO, expectedState);
- assertRegistered(NAME_TWO);
-
- assertInitialDeployFailure(resourceName1, NAME_ONE, expected);
- try
- {
- assertServiceState(NAME_TWO, expectedState);
- assertRegistered(NAME_TWO);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- if (error == false)
- {
- assertServiceState(NAME_TWO, expectedState);
- assertRegistered(NAME_TWO);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- }
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/DependsBrokenTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,501 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * NewOnDemandDependencyTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class NewOnDemandDependencyTest extends AbstractControllerTest
-{
- private static ObjectName NAME_ONE = ObjectNameFactory.create("test:name=1");
- private static ObjectName NAME_TWO = ObjectNameFactory.create("test:name=2");
-
- protected String resourceName1;
- protected String resourceName2;
-
- public NewOnDemandDependencyTest(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-
- public void testDeployCorrectOrder() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- assertServiceInstalled(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertNoService(NAME_TWO);
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- test1 = getMBean(Simple.class, NAME_ONE, "Instance");
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = getMBean(Simple.class, NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertServiceRunning(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(6, test2.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(7, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- if (test2 != null)
- {
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(6, test2.destroyOrder);
- }
- }
- }
- }
-
- public void testDeployWrongOrder() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceConfigured(NAME_TWO);
-
- test2 = getMBean(Simple.class, NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(0, test2.createOrder);
- assertEquals(0, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- assertServiceRunning(NAME_TWO);
- assertServiceRunning(NAME_ONE);
-
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- test1 = getMBean(Simple.class, NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertServiceDestroyed(NAME_TWO);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
- assertNotRegistered(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(6, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- if (test1 != null)
- {
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(6, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- }
- }
- }
- }
-
- public void testRedeployOne() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- test1 = getMBean(Simple.class, NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = getMBean(Simple.class, NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- undeploy(mbeans1);
-
- assertNotRegistered(NAME_ONE);
- assertServiceDestroyed(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(6, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
-
- mbeans1 = deploy(resourceName1);
-
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- test1 = getMBean(Simple.class, NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(9, test1.createOrder);
- assertEquals(11, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertEquals(10, test2.createOrder);
- assertEquals(12, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertServiceRunning(NAME_ONE);
- assertEquals(9, test1.createOrder);
- assertEquals(11, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(10, test2.createOrder);
- assertEquals(12, test2.startOrder);
- assertEquals(13, test2.stopOrder);
- assertEquals(14, test2.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(9, test1.createOrder);
- assertEquals(11, test1.startOrder);
- assertEquals(15, test1.stopOrder);
- assertEquals(16, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- if (test2 != null)
- {
- assertEquals(10, test2.createOrder);
- assertEquals(12, test2.startOrder);
- assertEquals(13, test2.stopOrder);
- assertEquals(14, test2.destroyOrder);
- }
- }
- }
- }
-
- public void testRedeployTwo() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- test1 = getMBean(Simple.class, NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = getMBean(Simple.class, NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- undeploy(mbeans2);
-
- assertServiceRunning(NAME_ONE);
- assertNoService(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(6, test2.destroyOrder);
-
- mbeans2 = deploy(resourceName2);
-
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = getMBean(Simple.class, NAME_TWO, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(7, test2.createOrder);
- assertEquals(8, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertServiceRunning(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(7, test2.createOrder);
- assertEquals(8, test2.startOrder);
- assertEquals(9, test2.stopOrder);
- assertEquals(10, test2.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(11, test1.stopOrder);
- assertEquals(12, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- if (test2 != null)
- {
- assertEquals(7, test2.createOrder);
- assertEquals(8, test2.startOrder);
- assertEquals(9, test2.stopOrder);
- assertEquals(10, test2.destroyOrder);
- }
- }
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-/**
- * NewOnDemandDependencyUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class NewOnDemandDependencyUnitTestCase extends NewOnDemandDependencyTest
-{
- public static Test suite()
- {
- return suite(NewOnDemandDependencyUnitTestCase.class);
- }
-
- public NewOnDemandDependencyUnitTestCase(String name)
- {
- super(name);
- resourceName1 = "NewOnDemandDependency_1.xml";
- resourceName2 = "NewOnDemandDependency_2.xml";
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandDependencyUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-/**
- * NewOnDemandServerDependencyUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class NewOnDemandServerDependencyUnitTestCase extends NewOnDemandDependencyTest
-{
- public static Test suite()
- {
- return suite(NewOnDemandServerDependencyUnitTestCase.class);
- }
-
- public NewOnDemandServerDependencyUnitTestCase(String name)
- {
- super(name);
- resourceName1 = "NewOnDemandServerDependency_1.xml";
- resourceName2 = "NewOnDemandServerDependency_2.xml";
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/NewOnDemandServerDependencyUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * SeperatedDependencyDependsNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SeperatedDependencyDependsNewUnitTestCase extends SeperatedDependencyTest
-{
- public static Test suite()
- {
- return suite(SeperatedDependencyDependsNewUnitTestCase.class);
- }
-
- public SeperatedDependencyDependsNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * SeperatedDependencyDependsOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class SeperatedDependencyDependsOldUnitTestCase extends SeperatedDependencyTest
-{
- public static Test suite()
- {
- return suite(SeperatedDependencyDependsOldUnitTestCase.class);
- }
-
- public SeperatedDependencyDependsOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyDependsOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,519 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.seperated.test;
-
-import java.util.List;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.Simple;
-
-/**
- * BasicLifecycleTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class SeperatedDependencyTest extends AbstractControllerTest
-{
- private static ObjectName NAME_ONE = ObjectNameFactory.create("test:name=1");
- private static ObjectName NAME_TWO = ObjectNameFactory.create("test:name=2");
-
- private String resourceName1;
- private String resourceName2;
-
- public SeperatedDependencyTest(String name)
- {
- super(name);
-
- String resourceName = getClass().getName();
- int index= resourceName.lastIndexOf('.');
- if (index != -1)
- resourceName= resourceName.substring(index + 1, resourceName.length());
- index = resourceName.indexOf("NewUnitTestCase");
- if (index != -1)
- resourceName = resourceName.substring(0, index);
- index = resourceName.indexOf("OldUnitTestCase");
- if (index != -1)
- resourceName = resourceName.substring(0, index);
-
- resourceName1 = resourceName + "_1.xml";
- resourceName2 = resourceName + "_2.xml";
- }
-
- public void testDeployCorrectOrder() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertNoService(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertServiceRunning(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(6, test2.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(7, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- if (test2 != null)
- {
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(6, test2.destroyOrder);
- }
- }
- }
- }
-
- public void testDeployWrongOrder() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceConfigured(NAME_TWO);
-
- MBeanServer server = getServer();
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(0, test2.createOrder);
- assertEquals(0, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- assertServiceRunning(NAME_TWO);
- assertServiceRunning(NAME_ONE);
-
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertServiceDestroyed(NAME_TWO);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
- assertNotRegistered(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(6, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(2, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- if (test1 != null)
- {
- assertEquals(1, test1.createOrder);
- assertEquals(3, test1.startOrder);
- assertEquals(6, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- }
- }
- }
- }
-
- public void testRedeployOne() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- undeploy(mbeans1);
-
- assertNotRegistered(NAME_ONE);
- assertServiceDestroyed(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(6, test1.stopOrder);
- assertEquals(8, test1.destroyOrder);
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
-
- mbeans1 = deploy(resourceName1);
-
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(9, test1.createOrder);
- assertEquals(11, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertEquals(10, test2.createOrder);
- assertEquals(12, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(7, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertServiceRunning(NAME_ONE);
- assertEquals(9, test1.createOrder);
- assertEquals(11, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(10, test2.createOrder);
- assertEquals(12, test2.startOrder);
- assertEquals(13, test2.stopOrder);
- assertEquals(14, test2.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(9, test1.createOrder);
- assertEquals(11, test1.startOrder);
- assertEquals(15, test1.stopOrder);
- assertEquals(16, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- if (test2 != null)
- {
- assertEquals(10, test2.createOrder);
- assertEquals(12, test2.startOrder);
- assertEquals(13, test2.stopOrder);
- assertEquals(14, test2.destroyOrder);
- }
- }
- }
- }
-
- public void testRedeployTwo() throws Exception
- {
- Simple test1 = null;
- Simple test2 = null;
-
- boolean error = false;
-
- List<ObjectName> mbeans1 = deploy(resourceName1);
- try
- {
- List<ObjectName> mbeans2 = deploy(resourceName2);
- try
- {
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- MBeanServer server = getServer();
- test1 = (Simple) server.getAttribute(NAME_ONE, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test2.constructorUsed);
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
-
- undeploy(mbeans2);
-
- assertServiceRunning(NAME_ONE);
- assertNoService(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertEquals(3, test2.createOrder);
- assertEquals(4, test2.startOrder);
- assertEquals(5, test2.stopOrder);
- assertEquals(6, test2.destroyOrder);
-
- mbeans2 = deploy(resourceName2);
-
- assertServiceRunning(NAME_ONE);
- assertServiceRunning(NAME_TWO);
-
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- test2 = (Simple) server.getAttribute(NAME_TWO, "Instance");
- assertEquals("()", test1.constructorUsed);
- assertEquals(7, test2.createOrder);
- assertEquals(8, test2.startOrder);
- assertEquals(0, test2.stopOrder);
- assertEquals(0, test2.destroyOrder);
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans2);
-
- if (error == false)
- {
- assertServiceRunning(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(0, test1.stopOrder);
- assertEquals(0, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- assertEquals(7, test2.createOrder);
- assertEquals(8, test2.startOrder);
- assertEquals(9, test2.stopOrder);
- assertEquals(10, test2.destroyOrder);
- }
- }
- }
- catch (Exception e)
- {
- error = true;
- throw e;
- }
- catch (Error e)
- {
- error = true;
- throw e;
- }
- finally
- {
- undeploy(mbeans1);
-
- if (error == false)
- {
- assertNoService(NAME_ONE);
- assertNotRegistered(NAME_ONE);
- assertEquals(1, test1.createOrder);
- assertEquals(2, test1.startOrder);
- assertEquals(11, test1.stopOrder);
- assertEquals(12, test1.destroyOrder);
- assertNoService(NAME_TWO);
- assertNotRegistered(NAME_TWO);
- if (test2 != null)
- {
- assertEquals(7, test2.createOrder);
- assertEquals(8, test2.startOrder);
- assertEquals(9, test2.stopOrder);
- assertEquals(10, test2.destroyOrder);
- }
- }
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/seperated/test/SeperatedDependencyTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,55 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.system.controller.lifecycle.basic.test.ControllerLifecycleBasicTestSuite;
-import org.jboss.test.system.controller.lifecycle.seperated.test.ControllerLifecycleSeperatedTestSuite;
-
-/**
- * Controller Lifecycle Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerLifecycleTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Lifecycle Tests");
-
- suite.addTest(LifecycleRedeployAfterErrorOldUnitTestCase.suite());
- suite.addTest(LifecycleRedeployAfterErrorNewUnitTestCase.suite());
- suite.addTest(ControllerLifecycleBasicTestSuite.suite());
- suite.addTest(ControllerLifecycleSeperatedTestSuite.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/ControllerLifecycleTestSuite.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * LifecycleRedeployAfterErrorNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class LifecycleRedeployAfterErrorNewUnitTestCase extends LifecycleRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(LifecycleRedeployAfterErrorNewUnitTestCase.class);
- }
-
- public LifecycleRedeployAfterErrorNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * LifecycleRedeployAfterErrorOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class LifecycleRedeployAfterErrorOldUnitTestCase extends LifecycleRedeployAfterErrorTest
-{
- public static Test suite()
- {
- return suite(LifecycleRedeployAfterErrorOldUnitTestCase.class);
- }
-
- public LifecycleRedeployAfterErrorOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,65 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.lifecycle.test;
-
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.ContainedMBeanServiceMBean;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * LifecycleRedeployAfterErrorTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class LifecycleRedeployAfterErrorTest extends AbstractControllerTest
-{
- public LifecycleRedeployAfterErrorTest(String name)
- {
- super(name);
- }
-
- public void testErrorInCreateRedeployAfterError() throws Exception
- {
- redeployAfterDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testErrorInStartRedeployAfterError() throws Exception
- {
- redeployAfterDeployFailure(SimpleMBean.OBJECT_NAME, Error.class);
- }
-
- public void testErrorInStopRedeployAfterError() throws Exception
- {
- redeployAfterUndeployFailure(SimpleMBean.OBJECT_NAME);
- }
-
- public void testErrorInDestroyRedeployAfterError() throws Exception
- {
- redeployAfterUndeployFailure(SimpleMBean.OBJECT_NAME);
- }
-
- public void testErrorInContainedStartRedeployAfterError() throws Exception
- {
- redeployAfterDeployFailure(ContainedMBeanServiceMBean.OBJECT_NAME, Error.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/lifecycle/test/LifecycleRedeployAfterErrorTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.parse.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * Controller Parse Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerParseTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Parsing Tests");
-
- suite.addTest(ErrorInParseOldUnitTestCase.suite());
- suite.addTest(ErrorInParseNewUnitTestCase.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ControllerParseTestSuite.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.parse.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ErrorInParseNewUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ErrorInParseNewUnitTestCase extends ErrorInParseTest
-{
- public static Test suite()
- {
- return suite(ErrorInParseNewUnitTestCase.class);
- }
-
- public ErrorInParseNewUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getNewControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseNewUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.parse.test;
-
-import junit.framework.Test;
-
-import org.jboss.test.AbstractTestDelegate;
-
-/**
- * ErrorInParseOldUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ErrorInParseOldUnitTestCase extends ErrorInParseTest
-{
- public static Test suite()
- {
- return suite(ErrorInParseOldUnitTestCase.class);
- }
-
- public ErrorInParseOldUnitTestCase(String name)
- {
- super(name);
- }
-
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- return getOldControllerDelegate(clazz);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseOldUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.parse.test;
-
-import javax.management.MalformedObjectNameException;
-
-import org.jboss.deployment.DeploymentException;
-import org.jboss.test.system.controller.AbstractControllerTest;
-import org.jboss.test.system.controller.support.SimpleMBean;
-
-/**
- * ErrorInParseTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class ErrorInParseTest extends AbstractControllerTest
-{
- public ErrorInParseTest(String name)
- {
- super(name);
- }
-
- protected void errorInParse(Class<? extends Throwable> expected) throws Exception
- {
- String resource = getName();
- resource = resource.substring(4) + ".xml";
- assertInitialDeployFailure(resource, SimpleMBean.OBJECT_NAME, expected);
- }
-
- public void testNameMissing() throws Exception
- {
- errorInParse(DeploymentException.class);
- }
-
- public void testNameEmpty() throws Exception
- {
- errorInParse(DeploymentException.class);
- }
-
- public void testNameInvalid() throws Exception
- {
- errorInParse(MalformedObjectNameException.class);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/parse/test/ErrorInParseTest.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,52 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.MBeanRegistration;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-/**
- * AbstractMBeanRegistration.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class AbstractRegistration implements MBeanRegistration, AbstractRegistrationMBean
-{
- public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
- {
- return name;
- }
-
- public void postRegister(Boolean registrationDone)
- {
- }
-
- public void preDeregister() throws Exception
- {
- }
-
- public void postDeregister()
- {
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistration.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,32 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * AbstractRegistrationMBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface AbstractRegistrationMBean
-{
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractRegistrationMBean.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,32 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * AbstractSimple.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class AbstractSimple extends Simple
-{
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/AbstractSimple.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,76 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.util.NotImplementedException;
-
-/**
- * BrokenDynamicMBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BrokenDynamicMBean implements DynamicMBean
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=BrokenDynamicMBean");
-
- public MBeanInfo getMBeanInfo()
- {
- throw new Error("BROKEN");
- }
-
- public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- throw new org.jboss.util.NotImplementedException("getAttribute");
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- throw new NotImplementedException("getAttributes");
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException
- {
- throw new NotImplementedException("invoke");
- }
-
- public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- throw new NotImplementedException("setAttribute");
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- throw new NotImplementedException("setAttributes");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBean.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,93 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.util.NotImplementedException;
-
-/**
- * BrokenDynamicMBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BrokenDynamicMBeanAttributeInfoTypeNotFound implements DynamicMBean
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=BrokenDynamicMBeanAttributeInfoTypeNotFound");
-
- public MBeanInfo getMBeanInfo()
- {
- return new BrokenMBeanInfoAttributes();
- }
-
- public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- throw new org.jboss.util.NotImplementedException("getAttribute");
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- throw new NotImplementedException("getAttributes");
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException
- {
- throw new NotImplementedException("invoke");
- }
-
- public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- throw new NotImplementedException("setAttribute");
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- throw new NotImplementedException("setAttributes");
- }
-
- private static class BrokenMBeanInfoAttributes extends MBeanInfo
- {
- private static final long serialVersionUID = 1158114004365977632L;
-
- public BrokenMBeanInfoAttributes() throws IllegalArgumentException
- {
- super(BrokenDynamicMBeanAttributeInfoTypeNotFound.class.getName(), "Broken", null, null, null, null);
- }
-
- public MBeanAttributeInfo[] getAttributes()
- {
- MBeanAttributeInfo[] result = { new MBeanAttributeInfo("Name", "TYPEDOESNOTEXIST", "Broken", true, true, false) };
- return result;
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributeInfoTypeNotFound.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,92 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.util.NotImplementedException;
-
-/**
- * BrokenDynamicMBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BrokenDynamicMBeanAttributes implements DynamicMBean
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=BrokenDynamicMBeanAttributes");
-
- public MBeanInfo getMBeanInfo()
- {
- return new BrokenMBeanInfoAttributes();
- }
-
- public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- throw new org.jboss.util.NotImplementedException("getAttribute");
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- throw new NotImplementedException("getAttributes");
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException
- {
- throw new NotImplementedException("invoke");
- }
-
- public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- throw new NotImplementedException("setAttribute");
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- throw new NotImplementedException("setAttributes");
- }
-
- private static class BrokenMBeanInfoAttributes extends MBeanInfo
- {
- private static final long serialVersionUID = 1158114004365977632L;
-
- public BrokenMBeanInfoAttributes() throws IllegalArgumentException
- {
- super(BrokenDynamicMBeanAttributes.class.getName(), "Broken", null, null, null, null);
- }
-
- public MBeanAttributeInfo[] getAttributes()
- {
- throw new Error("BROKEN");
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanAttributes.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,93 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.DynamicMBean;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanAttributeInfo;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.util.NotImplementedException;
-
-/**
- * BrokenDynamicMBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BrokenDynamicMBeanNoAttributeInfoType implements DynamicMBean
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=BrokenDynamicMBeanNoAttributeInfoType");
-
- public MBeanInfo getMBeanInfo()
- {
- return new BrokenMBeanInfoAttributes();
- }
-
- public Object getAttribute(String attribute) throws AttributeNotFoundException, MBeanException, ReflectionException
- {
- throw new org.jboss.util.NotImplementedException("getAttribute");
- }
-
- public AttributeList getAttributes(String[] attributes)
- {
- throw new NotImplementedException("getAttributes");
- }
-
- public Object invoke(String actionName, Object[] params, String[] signature) throws MBeanException, ReflectionException
- {
- throw new NotImplementedException("invoke");
- }
-
- public void setAttribute(Attribute attribute) throws AttributeNotFoundException, InvalidAttributeValueException, MBeanException, ReflectionException
- {
- throw new NotImplementedException("setAttribute");
- }
-
- public AttributeList setAttributes(AttributeList attributes)
- {
- throw new NotImplementedException("setAttributes");
- }
-
- private static class BrokenMBeanInfoAttributes extends MBeanInfo
- {
- private static final long serialVersionUID = 1158114004365977632L;
-
- public BrokenMBeanInfoAttributes() throws IllegalArgumentException
- {
- super(BrokenDynamicMBeanNoAttributeInfoType.class.getName(), "Broken", null, null, null, null);
- }
-
- public MBeanAttributeInfo[] getAttributes()
- {
- MBeanAttributeInfo[] result = { new MBeanAttributeInfo("Name", null, "Broken", true, true, false) };
- return result;
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/BrokenDynamicMBeanNoAttributeInfoType.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,129 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.system.controller.support;
-
-import java.lang.reflect.UndeclaredThrowableException;
-import java.util.Hashtable;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceMBeanSupport;
-
-/**
- * An mbean that creates and starts mbeans outside of the SARDeployer.
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision:$
- */
-public class ContainedMBeanService extends ServiceMBeanSupport
- implements ContainedMBeanServiceMBean
-{
- private String aString;
- private ObjectName simpleName;
- private Simple simpleMBean;
-
- /** Pass through AString for the container SimpleMBean */
- public String getAString()
- {
- return this.aString;
- }
- /** Pass through AString for the container SimpleMBean */
- public void setAString(String string)
- {
- this.aString = string;
- }
-
- /**
- * Create and register the contained SimpleMBean
- */
- @Override
- protected void createService() throws Exception
- {
- simpleMBean = new Simple();
- simpleMBean.setAString(aString);
- Hashtable props = serviceName.getKeyPropertyList();
- props.put("contained", "SimpleMBean");
- simpleName = new ObjectName(serviceName.getDomain(), props);
- server.registerMBean(simpleMBean, simpleName);
- boolean expectError = "ERRORINCREATE".equals(aString);
- // Invoke create on simpleName
- Object[] params = {};
- String[] signature = {};
- server.invoke(simpleName, "create", params, signature);
- if( expectError )
- throw new Error("Did not see expected ERRORINCREATE from: "+simpleName);
- }
-
- @Override
- protected void startService() throws Exception
- {
- if( simpleName != null )
- {
- // Invoke start on simpleName
- boolean expectError = "ERRORINSTART".equals(aString);
- Object[] params = {};
- String[] signature = {};
- server.invoke(simpleName, "start", params, signature);
- if( expectError )
- throw new Error("Did not see expected ERRORINSTART from: "+simpleName);
- }
- }
-
- @Override
- protected void stopService() throws Exception
- {
- if( simpleName != null )
- {
- boolean expectError = "ERRORINSTOP".equals(aString);
- Object[] params = {};
- String[] signature = {};
- server.invoke(simpleName, "stop", params, signature);
- if( expectError )
- throw new Error("Did not see expected ERRORINSTOP from: "+simpleName);
- }
- }
-
- @Override
- protected void destroyService() throws Exception
- {
- if( simpleName != null )
- {
- boolean expectError = "ERRORINDESTROY".equals(aString);
- Object[] params = {};
- String[] signature = {};
- try
- {
- server.invoke(simpleName, "destroy", params, signature);
- if( expectError )
- throw new Error("Did not see expected ERRORINDESTROY from: "+simpleName);
- }
- catch(Throwable e)
- {
- if( expectError == false )
- throw new UndeclaredThrowableException(e);
- }
- server.unregisterMBean(simpleName);
- }
- simpleName = null;
- }
-
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanService.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,43 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.system.controller.support;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceMBean;
-
-/**
- * The mbean interface for ContainedMBeanService
- *
- * @author Scott.Stark at jboss.org
- * @version $Revision:$
- */
-public interface ContainedMBeanServiceMBean extends ServiceMBean
-{
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=test");
-
- /** Pass through AString for the container SimpleMBean */
- String getAString();
- /** Pass through AString for the container SimpleMBean */
- void setAString(String string);
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/ContainedMBeanServiceMBean.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,67 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import java.util.Iterator;
-
-/**
- * JavaBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JavaBean
-{
- private String property1;
- private Integer property2;
- private Iterator property3;
-
- public String getProperty1()
- {
- return property1;
- }
-
- public void setProperty1(String property1)
- {
- this.property1 = property1;
- }
-
- public Integer getProperty2()
- {
- return property2;
- }
-
- public void setProperty2(Integer property2)
- {
- this.property2 = property2;
- }
-
- public Iterator getProperty3()
- {
- return property3;
- }
-
- public void setProperty3(Iterator property3)
- {
- this.property3 = property3;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBean.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,36 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * JavaBeanErrorConstructor.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JavaBeanErrorConstructor extends JavaBean
-{
- public JavaBeanErrorConstructor()
- {
- throw new Error("BROKEN");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorConstructor.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,36 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * JavaBeanErrorProperty.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JavaBeanErrorProperty extends JavaBean
-{
- public void setProperty1(String property1)
- {
- throw new Error("Broken");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/JavaBeanErrorProperty.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,32 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * NotSimpleStandardMBeanInterface.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface NotSimpleStandardMBeanInterface
-{
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/NotSimpleStandardMBeanInterface.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,43 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * Order.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class Order
-{
- private static int order = 0;
-
- public static synchronized int getOrder()
- {
- return ++order;
- }
-
- public static synchronized void reset()
- {
- order = 0;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/Order.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * PostDeregisterError.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PostDeregisterError extends AbstractRegistration
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=PostDeregisterError");
-
- public void postDeregister()
- {
- throw new Error("BROKEN");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PostDeregisterError.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * PostRegisterError.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PostRegisterError extends AbstractRegistration
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=PostRegisterError");
-
- public void postRegister(Boolean registrationDone)
- {
- throw new Error("BROKEN");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PostRegisterError.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * PreDeregisterError.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PreDeregisterError extends AbstractRegistration
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=PreDeregisterError");
-
- public void preDeregister()
- {
- throw new Error("BROKEN");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PreDeregisterError.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,43 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-
-/**
- * PreRegisterError.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class PreRegisterError extends AbstractRegistration
-{
- public static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=PreRegisterError");
-
- public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
- {
- throw new Error("BROKEN");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/PreRegisterError.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,611 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Collection;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.ServiceMBeanSupport;
-import org.jboss.test.system.controller.integration.support.SimpleBean;
-import org.jboss.util.NotImplementedException;
-import org.w3c.dom.Element;
-
-/**
- * Simple.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class Simple extends ServiceMBeanSupport implements SimpleMBean, SimpleStandardMBeanInterface
-{
- public String constructorUsed;
-
- public int createOrder;
- public int startOrder;
- public int stopOrder;
- public int destroyOrder;
-
- boolean touched = false;
-
- /** An object */
- private Object object;
-
- /** A string */
- private String aString;
-
- /** Byte */
- private Byte aByte;
-
- /** Boolean */
- private Boolean aBoolean;
-
- /** Character */
- private Character aCharacter;
-
- /** Short */
- private Short aShort;
-
- /** Int */
- private Integer anInt;
-
- /** Long */
- private Long aLong;
-
- /** Float */
- private Float aFloat;
-
- /** Double */
- private Double aDouble;
-
- /** Date */
- private Date aDate;
-
- /** BigDecimal */
- private BigDecimal aBigDecimal;
-
- /** BigDecimal */
- private BigInteger aBigInteger;
-
- /** byte */
- private byte abyte;
-
- /** boolean */
- private boolean aboolean;
-
- /** char */
- private char achar;
-
- /** short */
- private short ashort;
-
- /** int */
- private int anint;
-
- /** long */
- private long along;
-
- /** float */
- private float afloat;
-
- /** double */
- private double adouble;
-
- /** number */
- private Number aNumber;
-
- /** objectName */
- private ObjectName objectName;
-
- /** objectNames */
- private Collection<ObjectName> objectNames;
-
- /** First attribute */
- private String attribute1;
-
- /** Second attribute */
- private String attribute2;
-
- /** First attribute */
- private ObjectName objectNameAttribute1;
-
- /** Second attribute */
- private ObjectName objectNameAttribute2;
-
- /** First attribute */
- private Collection<ObjectName> objectNamesAttribute1;
-
- /** Second attribute */
- private Collection<ObjectName> objectNamesAttribute2;
-
- private SimpleStandardMBeanInterface proxy;
-
- private Element element;
-
- private JavaBean javaBean;
-
- private Simple simple;
-
- private SimpleBean simpleBean;
-
- public Simple()
- {
- constructorUsed = "()";
- }
-
- public Simple(String string)
- {
- constructorUsed = "(java.lang.String)";
- aString = string;
- if ("error".equals(string))
- throw new Error();
- if ("exception".equals(string))
- throw new RuntimeException();
- }
-
- public Simple(int integer)
- {
- constructorUsed = "(int)";
- anint = integer;
- }
-
- public Simple(int integer, float number)
- {
- constructorUsed = "(int,float)";
- anint = integer;
- afloat = number;
- }
-
- public Simple getInstance()
- {
- return this;
- }
-
- protected void createService()
- {
- createOrder = Order.getOrder();
- if ("ERRORINCREATE".equals(aString))
- throw new Error("BROKEN CREATE");
- }
-
- protected void startService()
- {
- startOrder = Order.getOrder();
- if ("ERRORINSTART".equals(aString))
- throw new Error("BROKEN START");
- }
-
- protected void stopService()
- {
- stopOrder = Order.getOrder();
- if ("ERRORINSTOP".equals(aString))
- throw new Error("BROKEN STOP");
- }
-
- protected void destroyService()
- {
- destroyOrder = Order.getOrder();
- if ("ERRORINDESTROY".equals(aString))
- throw new Error("BROKEN DESTROY");
- }
-
- public Object getObject()
- {
- return object;
- }
-
- public void setObject(Object object)
- {
- this.object = object;
- }
-
- public BigDecimal getABigDecimal()
- {
- return aBigDecimal;
- }
-
- public void setABigDecimal(BigDecimal bigDecimal)
- {
- aBigDecimal = bigDecimal;
- }
-
- public BigInteger getABigInteger()
- {
- return aBigInteger;
- }
-
- public void setABigInteger(BigInteger bigInteger)
- {
- aBigInteger = bigInteger;
- }
-
- public boolean isAboolean()
- {
- return aboolean;
- }
-
- public void setAboolean(boolean aboolean)
- {
- this.aboolean = aboolean;
- }
-
- public Boolean getABoolean()
- {
- return aBoolean;
- }
-
- public void setABoolean(Boolean boolean1)
- {
- aBoolean = boolean1;
- }
-
- public Number getANumber()
- {
- return aNumber;
- }
-
- public void setANumber(Number number)
- {
- aNumber = number;
- }
-
- public byte getAbyte()
- {
- return abyte;
- }
-
- public void setAbyte(byte abyte)
- {
- this.abyte = abyte;
- }
-
- public Byte getAByte()
- {
- return aByte;
- }
-
- public void setAByte(Byte byte1)
- {
- aByte = byte1;
- }
-
- public char getAchar()
- {
- return achar;
- }
-
- public void setAchar(char achar)
- {
- this.achar = achar;
- }
-
- public Character getACharacter()
- {
- return aCharacter;
- }
-
- public void setACharacter(Character character)
- {
- aCharacter = character;
- }
-
- public Date getADate()
- {
- return aDate;
- }
-
- public void setADate(Date date)
- {
- aDate = date;
- }
-
- public double getAdouble()
- {
- return adouble;
- }
-
- public void setAdouble(double adouble)
- {
- this.adouble = adouble;
- }
-
- public Double getADouble()
- {
- return aDouble;
- }
-
- public void setADouble(Double double1)
- {
- aDouble = double1;
- }
-
- public float getAfloat()
- {
- return afloat;
- }
-
- public void setAfloat(float afloat)
- {
- this.afloat = afloat;
- }
-
- public Float getAFloat()
- {
- return aFloat;
- }
-
- public void setAFloat(Float float1)
- {
- aFloat = float1;
- }
-
- public long getAlong()
- {
- return along;
- }
-
- public void setAlong(long along)
- {
- this.along = along;
- }
-
- public Long getALong()
- {
- return aLong;
- }
-
- public void setALong(Long long1)
- {
- aLong = long1;
- }
-
- public int getAnint()
- {
- return anint;
- }
-
- public void setAnint(int anint)
- {
- this.anint = anint;
- }
-
- public Integer getAnInt()
- {
- return anInt;
- }
-
- public void setAnInt(Integer anInt)
- {
- this.anInt = anInt;
- }
-
- public short getAshort()
- {
- return ashort;
- }
-
- public void setAshort(short ashort)
- {
- this.ashort = ashort;
- }
-
- public Short getAShort()
- {
- return aShort;
- }
-
- public void setAShort(Short short1)
- {
- aShort = short1;
- }
-
- public String getAString()
- {
- return aString;
- }
-
- public void setAString(String string)
- {
- aString = string;
- if ("ERRORINPROPERTY".equals(aString))
- throw new Error("BROKEN PROPERTY");
- }
-
- public ObjectName getObjectName()
- {
- return objectName;
- }
-
- public void setObjectName(ObjectName objectName)
- {
- this.objectName = objectName;
- }
-
- public Collection<ObjectName> getObjectNames()
- {
- return objectNames;
- }
-
- public void setObjectNames(Collection<ObjectName> objectNames)
- {
- this.objectNames = objectNames;
- }
-
- public String echoReverse(String test)
- {
- StringBuilder builder = new StringBuilder(test);
- return builder.reverse().toString();
- }
-
- public void touch()
- {
- this.touched = true;
- }
-
- public boolean isTouched()
- {
- return touched;
- }
-
- public void setBrokenAttribute(String broken)
- {
- throw new Error("BROKEN");
- }
-
- public String getAttribute1()
- {
- return attribute1;
- }
-
- public void setAttribute1(String attribute1)
- {
- this.attribute1 = attribute1;
- }
-
- public String getAttribute2()
- {
- return attribute2;
- }
-
- public void setAttribute2(String attribute2)
- {
- this.attribute2 = attribute2;
- }
-
- public void setBrokenObjectNameAttribute(ObjectName broken)
- {
- throw new Error("BROKEN");
- }
-
- public ObjectName getObjectNameAttribute1()
- {
- return objectNameAttribute1;
- }
-
- public void setObjectNameAttribute1(ObjectName objectNameAttribute1)
- {
- this.objectNameAttribute1 = objectNameAttribute1;
- }
-
- public ObjectName getObjectNameAttribute2()
- {
- return objectNameAttribute2;
- }
-
- public void setObjectNameAttribute2(ObjectName objectNameAttribute2)
- {
- this.objectNameAttribute2 = objectNameAttribute2;
- }
-
- public void setBrokenObjectNamesAttribute(Collection<ObjectName> broken)
- {
- throw new Error("BROKEN");
- }
-
- public Collection<ObjectName> getObjectNamesAttribute1()
- {
- return objectNamesAttribute1;
- }
-
- public void setObjectNamesAttribute1(Collection<ObjectName> objectNamesAttribute1)
- {
- this.objectNamesAttribute1 = objectNamesAttribute1;
- }
-
- public Collection<ObjectName> getObjectNamesAttribute2()
- {
- return objectNamesAttribute2;
- }
-
- public void setObjectNamesAttribute2(Collection<ObjectName> objectNamesAttribute2)
- {
- this.objectNamesAttribute2 = objectNamesAttribute2;
- }
-
- public String getReadOnly()
- {
- return "ReadOnly!";
- }
-
- public void setReadOnly(String readOnly)
- {
- throw new NotImplementedException("THIS ATTRIBUTE SHOULD BE READ ONLY!");
- }
-
- public SimpleStandardMBeanInterface getProxy()
- {
- return proxy;
- }
-
- public void setProxy(SimpleStandardMBeanInterface proxy)
- {
- this.proxy = proxy;
- }
-
- public void touchProxy()
- {
- proxy.touch();
- }
-
- public Element getElement()
- {
- return element;
- }
-
- public void setElement(Element element)
- {
- this.element = element;
- }
-
- public JavaBean getJavaBean()
- {
- return javaBean;
- }
-
- public void setJavaBean(JavaBean javaBean)
- {
- this.javaBean = javaBean;
- }
-
- public Simple getSimple()
- {
- return simple;
- }
-
- public void setSimple(Simple simple)
- {
- this.simple = simple;
- }
-
- public SimpleBean getSimpleBean()
- {
- return simpleBean;
- }
-
- public void setSimpleBean(SimpleBean simpleBean)
- {
- this.simpleBean = simpleBean;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/Simple.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,195 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Collection;
-import java.util.Date;
-
-import javax.management.ObjectName;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.ServiceMBean;
-import org.jboss.test.system.controller.integration.support.SimpleBean;
-import org.w3c.dom.Element;
-
-/**
- * SimpleMBean.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface SimpleMBean extends ServiceMBean
-{
- ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss.test:type=test");
-
- Simple getInstance();
-
- Object getObject();
-
- void setObject(Object object);
-
- BigDecimal getABigDecimal();
-
- void setABigDecimal(BigDecimal bigDecimal);
-
- BigInteger getABigInteger();
-
- void setABigInteger(BigInteger bigInteger);
-
- boolean isAboolean();
-
- void setAboolean(boolean aboolean);
-
- Boolean getABoolean();
-
- void setABoolean(Boolean boolean1);
-
- Number getANumber();
-
- void setANumber(Number number);
-
- byte getAbyte();
-
- void setAbyte(byte abyte);
-
- Byte getAByte();
-
- void setAByte(Byte byte1);
-
- char getAchar();
-
- void setAchar(char achar);
-
- Character getACharacter();
-
- void setACharacter(Character character);
-
- Date getADate();
-
- void setADate(Date date);
-
- double getAdouble();
-
- void setAdouble(double adouble);
-
- Double getADouble();
-
- void setADouble(Double double1);
-
- float getAfloat();
-
- void setAfloat(float afloat);
-
- Float getAFloat();
-
- void setAFloat(Float float1);
-
- long getAlong();
-
- void setAlong(long along);
-
- Long getALong();
-
- void setALong(Long long1);
-
- int getAnint();
-
- void setAnint(int anint);
-
- Integer getAnInt();
-
- void setAnInt(Integer anInt);
-
- short getAshort();
-
- void setAshort(short ashort);
-
- Short getAShort();
-
- void setAShort(Short short1);
-
- String getAString();
-
- void setAString(String string);
-
- ObjectName getObjectName();
-
- void setObjectName(ObjectName objectName);
-
- Collection<ObjectName> getObjectNames();
-
- void setObjectNames(Collection<ObjectName> objectNames);
-
- void setBrokenAttribute(String broken);
-
- String getAttribute1();
-
- void setAttribute1(String attribute1);
-
- String getAttribute2();
-
- void setAttribute2(String attribute2);
-
- void setBrokenObjectNameAttribute(ObjectName broken);
-
- ObjectName getObjectNameAttribute1();
-
- void setObjectNameAttribute1(ObjectName objectNameAttribute1);
-
- ObjectName getObjectNameAttribute2();
-
- void setObjectNameAttribute2(ObjectName objectNameAttribute2);
-
- void setBrokenObjectNamesAttribute(Collection<ObjectName> broken);
-
- Collection<ObjectName> getObjectNamesAttribute1();
-
- void setObjectNamesAttribute1(Collection<ObjectName> objectNamesAttribute1);
-
- Collection<ObjectName> getObjectNamesAttribute2();
-
- void setObjectNamesAttribute2(Collection<ObjectName> objectNamesAttribute2);
-
- String getReadOnly();
-
- SimpleStandardMBeanInterface getProxy();
-
- void setProxy(SimpleStandardMBeanInterface proxy);
-
- Element getElement();
-
- void setElement(Element element);
-
- JavaBean getJavaBean();
-
- void setJavaBean(JavaBean javaBean);
-
- Simple getSimple();
-
- void setSimple(Simple simple);
-
- SimpleBean getSimpleBean();
-
- void setSimpleBean(SimpleBean simpleBean);
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleMBean.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,37 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.support;
-
-/**
- * TestStandardMBeanInterface.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public interface SimpleStandardMBeanInterface
-{
- Simple getInstance();
-
- String echoReverse(String test);
-
- void touch();
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/support/SimpleStandardMBeanInterface.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,59 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.controller.test;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.system.controller.basic.test.ControllerBasicTestSuite;
-import org.jboss.test.system.controller.configure.test.ControllerConfigureTestSuite;
-import org.jboss.test.system.controller.instantiate.test.ControllerInstantiateTestSuite;
-import org.jboss.test.system.controller.lifecycle.test.ControllerLifecycleTestSuite;
-import org.jboss.test.system.controller.parse.test.ControllerParseTestSuite;
-
-/**
- * Controller Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class ControllerTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("Controller Tests");
-
- suite.addTest(ControllerBasicTestSuite.suite());
- suite.addTest(ControllerParseTestSuite.suite());
- suite.addTest(ControllerInstantiateTestSuite.suite());
- suite.addTest(ControllerConfigureTestSuite.suite());
- suite.addTest(ControllerLifecycleTestSuite.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/controller/test/ControllerTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,93 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.attributes.test;
-
-import java.util.List;
-
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.test.AbstractMetaDataTest;
-
-/**
- * AbstractAttributeTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class AbstractAttributeTest extends AbstractMetaDataTest
-{
- public AbstractAttributeTest(String name)
- {
- super(name);
- }
-
- protected ServiceAttributeMetaData unmarshallSingleAttribute() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertOthers(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(1, attributes.size());
- return attributes.get(0);
- }
-
- public List<ServiceAttributeMetaData> unmarshallMultipleAttributes(int size) throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertOthers(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(size, attributes.size());
- return attributes;
- }
-
- protected ServiceValueMetaData unmarshallSingleValue() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertOthers(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(1, attributes.size());
- ServiceAttributeMetaData attribute = attributes.get(0);
- assertAttributeName(attribute, "Attribute");
- ServiceValueMetaData result = attribute.getValue();
- assertNotNull(result);
- return result;
- }
-
- public void noAttributes() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertNoAttributes(metaData);
- assertOthers(metaData);
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertNull(metaData.getInterfaceName());
- assertDefaultConstructor(metaData);
- assertNoXMBean(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AbstractAttributeTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,89 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.attributes.test;
-
-import java.util.List;
-
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-
-/**
- * AttributeUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class AttributeUnitTestCase extends AbstractAttributeTest
-{
- public AttributeUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testAttributeNone() throws Exception
- {
- noAttributes();
- }
-
- public void testAttributeOne() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertTextAttribute(attribute);
- }
-
- public void testAttributeTwo() throws Exception
- {
- List<ServiceAttributeMetaData> attributes = unmarshallMultipleAttributes(2);
- ServiceAttributeMetaData test = attributes.get(0);
- assertTextAttribute(test, "Attribute1", "value1");
- test = attributes.get(1);
- assertTextAttribute(test, "Attribute2", "value2");
- }
-
- public void testAttributeNoValue() throws Exception
- {
- noAttributes();
- }
-
- public void testAttributeEmptyValue() throws Exception
- {
- noAttributes();
- }
-
- public void testAttributeNoTrim() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertTextAttribute(attribute, false, true);
- }
-
- public void testAttributeNoReplace() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertTextAttribute(attribute, true, false);
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- super.assertOthers(metaData);
- assertNoDependencies(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,80 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.attributes.test;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-
-/**
- * AttributeValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class AttributeValueUnitTestCase extends AbstractAttributeTest
-{
- public AttributeValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testAttributeValueText() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertTextValue(value, "value");
- }
-
- public void testAttributeValueDepends() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyValue(value, TEST1);
- }
-
- public void testAttributeValueDependsList() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyListValue(value, TEST1);
- }
-
- public void testAttributeValueElement() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertElementValue(value, "dummy");
- }
-
- public void testAttributeValueJavaBean() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertJavaBeanValue(value, "dummy");
- }
-
- public void testAttributeValueJBXB() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertJBXBValue(value, "dummy");
- }
-
- public void testAttributeValueInject() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertInjectValue(value, "bean", "property");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/AttributeValueUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,66 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.attributes.test;
-
-import java.util.List;
-
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-
-/**
- * DependsAttributeUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsAttributeUnitTestCase extends AbstractAttributeTest
-{
- public DependsAttributeUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDependsAttributeNone() throws Exception
- {
- noAttributes();
- }
-
- public void testDependsAttributeOne() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertDependsAttribute(attribute);
- }
-
- public void testDependsAttributeTwo() throws Exception
- {
- List<ServiceAttributeMetaData> attributes = unmarshallMultipleAttributes(2);
- ServiceAttributeMetaData test = attributes.get(0);
- assertDependsAttribute(test, "Attribute1", TEST1);
- test = attributes.get(1);
- assertDependsAttribute(test, "Attribute2", TEST2);
- }
-
- public void testDependsAttributeNoName() throws Exception
- {
- // REVIEW shouldn't this be an error?
- noAttributes();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsAttributeUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,78 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.attributes.test;
-
-import java.util.List;
-
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-
-/**
- * DependsListAttributeUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsListAttributeUnitTestCase extends AbstractAttributeTest
-{
- public DependsListAttributeUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDependsListAttributeNone() throws Exception
- {
- noAttributes();
- }
-
- public void testDependsListAttributeOne() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertDependsListAttribute(attribute);
- }
-
- public void testDependsListAttributeTwo() throws Exception
- {
- List<ServiceAttributeMetaData> attributes = unmarshallMultipleAttributes(2);
- ServiceAttributeMetaData test = attributes.get(0);
- assertDependsListAttribute(test, "Attribute1", TEST1);
- test = attributes.get(1);
- assertDependsListAttribute(test, "Attribute2", TEST2);
- }
-
- public void testDependsListAttributeNoValue() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertDependsListAttributeEmpty(attribute);
- }
-
- public void testDependsListAttributeEmptyValue() throws Exception
- {
- ServiceAttributeMetaData attribute = unmarshallSingleAttribute();
- assertDependsListAttributeEmpty(attribute);
- }
-
- public void testDependsListAttributeNoName() throws Exception
- {
- // REVIEW shouldn't this be an error?
- noAttributes();
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/attributes/test/DependsListAttributeUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/basic)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,95 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.basic.test;
-
-import javax.management.MalformedObjectNameException;
-
-import org.jboss.dependency.spi.ControllerMode;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.test.system.metadata.test.AbstractMetaDataTest;
-
-/**
- * BasicMBeanUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class BasicMBeanUnitTestCase extends AbstractMetaDataTest
-{
- public BasicMBeanUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testBasicMBean() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertNull(metaData.getInterfaceName());
- assertNull(metaData.getMode());
- assertOthers(metaData);
- }
-
- public void testBasicMBeanNoName() throws Exception
- {
- assertFailUnmarshal(DeploymentException.class);
- }
-
- public void testBasicMBeanEmptyName() throws Exception
- {
- assertFailUnmarshal(DeploymentException.class);
- }
-
- public void testBasicMBeanInvalidName() throws Exception
- {
- assertFailUnmarshal(MalformedObjectNameException.class);
- }
-
- public void testBasicMBeanInterface() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertEquals(testBasicMBeanInterface, metaData.getInterfaceName());
- assertNull(metaData.getMode());
- assertOthers(metaData);
- }
-
- public void testBasicMBeanMode() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertEquals(ControllerMode.ON_DEMAND, metaData.getMode());
- assertOthers(metaData);
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- assertDefaultConstructor(metaData);
- assertNoAttributes(metaData);
- assertNoDependencies(metaData);
- assertNoXMBean(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/basic/test/BasicMBeanUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/constructor)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,89 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.constructor.test;
-
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.test.system.metadata.test.AbstractMetaDataTest;
-
-/**
- * ConstructorUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ConstructorUnitTestCase extends AbstractMetaDataTest
-{
- public ConstructorUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testConstructorDefault() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertDefaultConstructor(metaData);
- assertOthers(metaData);
- }
-
- public void testConstructorOneArg() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
-
- String[] expectedSignature = new String[] { "signature1" };
- String[] expectedParams = new String[] { "param1" };
-
- assertConstructor(expectedSignature, expectedParams, metaData);
- assertOthers(metaData);
- }
-
- public void testConstructorTwoArgs() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
-
- String[] expectedSignature = new String[] { "signature1", "signature2" };
- String[] expectedParams = new String[] { "param1", "param2" };
-
- assertConstructor(expectedSignature, expectedParams, metaData);
- assertOthers(metaData);
- }
-
- public void testConstructorEmptyValue() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
-
- String[] expectedSignature = new String[] { "signature1" };
- String[] expectedParams = new String[] { "" };
-
- assertConstructor(expectedSignature, expectedParams, metaData);
- assertOthers(metaData);
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertNull(metaData.getInterfaceName());
- assertNoAttributes(metaData);
- assertNoDependencies(metaData);
- assertNoXMBean(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/constructor/test/ConstructorUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/depends)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,83 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.depends.test;
-
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.test.system.metadata.test.AbstractMetaDataTest;
-
-/**
- * DependsOptionalAttributeUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsOptionalAttributeUnitTestCase extends AbstractMetaDataTest
-{
- public DependsOptionalAttributeUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDependsOptionalAttribute() throws Exception
- {
- dependsOne();
- }
-
- public void testDependsOptionalAttributeNestedMBean() throws Exception
- {
- dependsOne();
- }
-
- public void testDependsListOptionalAttribute() throws Exception
- {
- dependsOne();
- }
-
- public void testDependsListOptionalAttributeNestedMBean() throws Exception
- {
- dependsOne();
- }
-
- protected void dependsOne() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertAttribute(metaData, "AttributeName");
- assertOthers(metaData);
- }
-
- protected void dependsTwo() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertAttributes(metaData, new String[] { "AttributeName1", "AttributeName2" });
- assertOthers(metaData);
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertNull(metaData.getInterfaceName());
- assertDefaultConstructor(metaData);
- assertNoDependencies(metaData);
- assertNoXMBean(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsOptionalAttributeUnitTestCase.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,115 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.depends.test;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.test.system.metadata.test.AbstractMetaDataTest;
-
-/**
- * DependsUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependsUnitTestCase extends AbstractMetaDataTest
-{
- public DependsUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDependsNone() throws Exception
- {
- dependsNone();
- }
-
- public void testDependsOne() throws Exception
- {
- dependsOne();
- }
-
- public void testDependsTwo() throws Exception
- {
- dependsTwo();
- }
-
- public void testDependsNestedMBean() throws Exception
- {
- dependsOne();
- }
-
- // @review shouldn't an empty depends-list be an error?
- public void testDependsListNone() throws Exception
- {
- dependsNone();
- }
-
- public void testDependsListOne() throws Exception
- {
- dependsOne();
- }
-
- public void testDependsListTwo() throws Exception
- {
- dependsTwo();
- }
-
- public void testDependsListNestedMBean() throws Exception
- {
- dependsOne();
- }
-
- protected void dependsNone() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertNoDependencies(metaData);
- assertOthers(metaData);
- }
-
- protected void dependsOne() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- ObjectName[] expected = { TEST1 };
- assertDependencies(metaData, expected);
- assertOthers(metaData);
- }
-
- protected void dependsTwo() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- ObjectName[] expected = { TEST1, TEST2 };
- assertDependencies(metaData, expected);
- assertOthers(metaData);
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertNull(metaData.getInterfaceName());
- assertDefaultConstructor(metaData);
- assertNoAttributes(metaData);
- assertNoXMBean(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/depends/test/DependsUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,468 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.test;
-
-import java.io.IOException;
-import java.net.URL;
-import java.util.Arrays;
-import java.util.HashSet;
-import java.util.List;
-
-import javax.management.ObjectName;
-
-import junit.framework.AssertionFailedError;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceConstructorMetaData;
-import org.jboss.system.metadata.ServiceDependencyListValueMetaData;
-import org.jboss.system.metadata.ServiceDependencyMetaData;
-import org.jboss.system.metadata.ServiceDependencyValueMetaData;
-import org.jboss.system.metadata.ServiceElementValueMetaData;
-import org.jboss.system.metadata.ServiceInjectionValueMetaData;
-import org.jboss.system.metadata.ServiceJBXBValueMetaData;
-import org.jboss.system.metadata.ServiceJavaBeanValueMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceTextValueMetaData;
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.AbstractSystemTest;
-import org.jboss.test.AbstractTestDelegate;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * A MetaDataTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.2 $
- */
-public class AbstractMetaDataTest extends AbstractSystemTest
-{
- protected static ObjectName testBasicMBeanName = ObjectNameFactory.create("jboss.test:type=BasicMBeanName");
- protected static String testBasicMBeanCode = "BasicMBeanCode";
- protected static String testBasicMBeanInterface = "BasicMBeanInterface";
- protected static ObjectName TEST1 = ObjectNameFactory.create("test:test=1");
- protected static ObjectName TEST2 = ObjectNameFactory.create("test:test=2");
- protected static ObjectName[] NO_OBJECT_NAMES = new ObjectName[0];
-
- /**
- * Create a new ContainerTest.
- *
- * @param name the test name
- */
- public AbstractMetaDataTest(String name)
- {
- super(name);
- }
-
- /**
- * Default setup with security manager enabled
- *
- * @param clazz the class
- * @return the delegate
- * @throws Exception for any error
- */
- public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
- {
- MetaDataTestDelegate delegate = new MetaDataTestDelegate(clazz);
- delegate.enableSecurity = true;
- return delegate;
- }
-
- /**
- * Unmarshal some xml
- *
- * @param name the name
- * @return the list of services
- * @throws Exception for any error
- */
- protected List<ServiceMetaData> unmarshal(String name) throws Exception
- {
- URL url = findXML(name);
- return getMetaDataDelegate().unmarshal(url);
- }
-
- /**
- * Unmarshal a single mbean
- *
- * @return the single service
- * @throws Exception for any error
- */
- protected ServiceMetaData unmarshalSingleMBean() throws Exception
- {
- String name = getName();
- name = name.substring(4) + ".xml";
- return unmarshalSingleMBean(name);
- }
-
- /**
- * Unmarshal a single mbean
- *
- * @param name the name
- * @return the single service
- * @throws Exception for any error
- */
- protected ServiceMetaData unmarshalSingleMBean(String name) throws Exception
- {
- URL url = findXML(name);
- List<ServiceMetaData> services = getMetaDataDelegate().unmarshal(url);
- assertFalse(url + " should contain an mbean ", services.isEmpty());
- ServiceMetaData service = services.get(services.size()-1);
- assertNotNull(service);
- return service;
- }
-
- protected void assertFailUnmarshal(Class<? extends Throwable> expected) throws Exception
- {
- String name = getName();
- name = name.substring(4) + ".xml";
- assertFailUnmarshal(name, expected);
- }
-
- protected void assertFailUnmarshal(String name, Class<? extends Throwable> expected) throws Exception
- {
- try
- {
- unmarshal(name);
- fail("Should fail to unmarshal " + name);
- }
- catch (AssertionFailedError e)
- {
- throw e;
- }
- catch (Throwable error)
- {
- AbstractSystemTest.checkThrowableDeep(expected, error);
- }
- }
-
- /**
- * Find the xml
- *
- * @param name the name
- * @return the url of the xml
- */
- protected URL findXML(String name) throws Exception
- {
- URL url = getResource(name);
- if (url == null)
- throw new IOException(name + " not found");
- return url;
- }
-
- protected MetaDataTestDelegate getMetaDataDelegate()
- {
- return (MetaDataTestDelegate) getDelegate();
- }
-
- protected void assertDefaultConstructor(ServiceMetaData metaData) throws Exception
- {
- ServiceConstructorMetaData constructor = metaData.getConstructor();
- assertNotNull(constructor);
- String[] signature = constructor.getSignature();
- assertNotNull(signature);
- assertEquals(0, signature.length);
- String[] params = constructor.getParams();
- assertNotNull(params);
- assertEquals(0, params.length);
- }
-
- protected void assertConstructor(String[] expectedSignature, String[] expectedParams, ServiceMetaData metaData) throws Exception
- {
- ServiceConstructorMetaData constructor = metaData.getConstructor();
- assertNotNull(constructor);
- String[] signature = constructor.getSignature();
- assertNotNull(signature);
- assertEquals(expectedSignature, signature);
- String[] params = constructor.getParams();
- assertNotNull(params);
- assertEquals(expectedParams, params);
- }
-
- protected void assertNoAttributes(ServiceMetaData metaData) throws Exception
- {
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(0, attributes.size());
- }
-
- protected void assertAttributeName(ServiceAttributeMetaData attribute, String name) throws Exception
- {
- assertNotNull(attribute);
- String result = attribute.getName();
- assertNotNull(result);
- assertEquals("Expected attribute with name " + name + " got " + result, name, result);
- }
-
- protected void assertAttribute(ServiceMetaData metaData, String name) throws Exception
- {
- assertNotNull(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(1, attributes.size());
- ServiceAttributeMetaData attribute = attributes.get(0);
- assertAttributeName(attribute, name);
- }
-
- protected void assertAttributes(ServiceMetaData metaData, String[] names) throws Exception
- {
- assertNotNull(names);
- assertNotNull(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(names.length, attributes.size());
- ServiceAttributeMetaData attribute = attributes.get(0);
- for (String name : names)
- assertAttributeName(attribute, name);
- }
-
- protected void assertAttribute(ServiceAttributeMetaData attribute, boolean trim, boolean replace, String name) throws Exception
- {
- assertNotNull(attribute);
- String result = attribute.getName();
- assertNotNull(result);
- assertEquals(name, result);
- assertEquals(trim, attribute.isTrim());
- assertEquals(replace, attribute.isReplace());
- }
-
- protected void assertTextAttribute(ServiceAttributeMetaData attribute) throws Exception
- {
- assertTextAttribute(attribute, true, true, "Attribute", "value");
- }
-
- protected void assertTextAttribute(ServiceAttributeMetaData attribute, String value) throws Exception
- {
- assertTextAttribute(attribute, true, true, "Attribute", value);
- }
-
- protected void assertTextAttribute(ServiceAttributeMetaData attribute, String name, String value) throws Exception
- {
- assertTextAttribute(attribute, true, true, name, value);
- }
-
- protected void assertTextAttribute(ServiceAttributeMetaData attribute, boolean trim, boolean replace) throws Exception
- {
- assertTextAttribute(attribute, trim, replace, "Attribute", "value");
- }
-
- protected void assertTextAttribute(ServiceAttributeMetaData attribute, boolean trim, boolean replace, String name, String value) throws Exception
- {
- assertAttribute(attribute, trim, replace, name);
- ServiceValueMetaData actual = attribute.getValue();
- assertNotNull(actual);
- assertTextValue(actual, value);
- }
-
- protected void assertDependsAttribute(ServiceAttributeMetaData attribute) throws Exception
- {
- assertDependsAttribute(attribute, false, false, "Attribute", TEST1);
- }
-
- protected void assertDependsAttribute(ServiceAttributeMetaData attribute, String name, ObjectName value) throws Exception
- {
- assertDependsAttribute(attribute, false, false, name, value);
- }
-
- protected void assertDependsAttribute(ServiceAttributeMetaData attribute, boolean trim, boolean replace, String name, ObjectName value) throws Exception
- {
- assertAttribute(attribute, trim, replace, name);
- ServiceValueMetaData actual = attribute.getValue();
- assertNotNull(actual);
- assertDependencyValue(actual, value);
- }
-
- protected void assertDependsListAttribute(ServiceAttributeMetaData attribute) throws Exception
- {
- assertDependsListAttribute(attribute, false, false, "Attribute", TEST1);
- }
-
- protected void assertDependsListAttribute(ServiceAttributeMetaData attribute, String name, ObjectName value) throws Exception
- {
- assertDependsListAttribute(attribute, false, false, name, value);
- }
-
- protected void assertDependsListAttribute(ServiceAttributeMetaData attribute, boolean trim, boolean replace, String name, ObjectName value) throws Exception
- {
- assertDependsListAttribute(attribute, trim, replace, name, new ObjectName[] { value });
- }
-
- protected void assertDependsListAttribute(ServiceAttributeMetaData attribute, boolean trim, boolean replace, String name, ObjectName[] value) throws Exception
- {
- assertAttribute(attribute, trim, replace, name);
- ServiceValueMetaData actual = attribute.getValue();
- assertNotNull(actual);
- assertDependencyListValue(actual, value);
- }
-
- protected void assertDependsListAttributeEmpty(ServiceAttributeMetaData attribute) throws Exception
- {
- assertDependsListAttribute(attribute, false, false, "Attribute", NO_OBJECT_NAMES);
- }
-
- protected void assertTextValue(ServiceValueMetaData actual, String expected) throws Exception
- {
- assertNotNull(expected);
- assertNotNull(actual);
-
- ServiceTextValueMetaData value = assertInstanceOf(ServiceTextValueMetaData.class, actual);
-
- assertEquals(expected, value.getText());
- }
-
- protected void assertDependencyValue(ServiceValueMetaData actual, ObjectName expected) throws Exception
- {
- assertDependencyValue(actual, expected, null);
- }
-
- protected void assertDependencyValue(ServiceValueMetaData actual, ObjectName expected, String proxyType) throws Exception
- {
- assertNotNull(expected);
- assertNotNull(actual);
-
- ServiceDependencyValueMetaData value = assertInstanceOf(ServiceDependencyValueMetaData.class, actual);
-
- assertEquals(expected, value.getObjectName());
- assertEquals(proxyType, value.getProxyType());
- }
-
- protected void assertDependencyListValueEmpty(ServiceValueMetaData actual) throws Exception
- {
- assertDependencyListValue(actual, NO_OBJECT_NAMES );
- }
-
- protected void assertDependencyListValue(ServiceValueMetaData actual, ObjectName expected) throws Exception
- {
- assertDependencyListValue(actual, new ObjectName[] { expected } );
- }
-
- protected void assertDependencyListValue(ServiceValueMetaData actual, ObjectName[] expected) throws Exception
- {
- assertNotNull(expected);
- assertNotNull(actual);
-
- ServiceDependencyListValueMetaData value = assertInstanceOf(ServiceDependencyListValueMetaData.class, actual);
-
- List<ObjectName> list = value.getObjectNames();
- assertNotNull(list);
- ObjectName[] test = list.toArray(new ObjectName[list.size()]);
-
- assertTrue("Expected " + Arrays.asList(expected) + " got " + Arrays.asList(test), Arrays.equals(expected, test));
- }
-
- protected void assertElementValue(ServiceValueMetaData actual, String expected) throws Exception
- {
- assertNotNull(expected);
- assertNotNull(actual);
-
- ServiceElementValueMetaData value = assertInstanceOf(ServiceElementValueMetaData.class, actual);
-
- Element element = value.getElement();
- assertNotNull(element);
-
- String name = element.getTagName();
- assertNotNull(name);
-
- assertEquals(expected, name);
- }
-
- protected void assertJavaBeanValue(ServiceValueMetaData actual, String expected) throws Exception
- {
- assertNotNull(actual);
-
- ServiceJavaBeanValueMetaData value = assertInstanceOf(ServiceJavaBeanValueMetaData.class, actual);
-
- Element element = value.getElement();
- assertChildOfAttribute(element, expected);
- }
-
- protected void assertJBXBValue(ServiceValueMetaData actual, String expected) throws Exception
- {
- assertNotNull(actual);
-
- ServiceJBXBValueMetaData value = assertInstanceOf(ServiceJBXBValueMetaData.class, actual);
-
- Element element = value.getElement();
- assertChildOfAttribute(element, expected);
- }
-
- protected void assertInjectValue(ServiceValueMetaData actual, Object dependency, String property) throws Exception
- {
- assertInjectValue(actual, dependency, property, ControllerState.INSTALLED);
- }
-
- protected void assertInjectValue(ServiceValueMetaData actual, Object dependency, String property, ControllerState requiredState) throws Exception
- {
- assertNotNull(actual);
-
- ServiceInjectionValueMetaData value = assertInstanceOf(ServiceInjectionValueMetaData.class, actual);
-
- assertEquals(dependency, value.getDependency());
- assertEquals(property, value.getProperty());
- assertEquals(requiredState, value.getDependentState());
- }
-
- protected void assertChildOfAttribute(Element element, String expected) throws Exception
- {
- assertNotNull(element);
-
- String name = element.getTagName();
- assertEquals("attribute", name);
-
- NodeList children = element.getChildNodes();
- assertEquals(1, children.getLength());
- Node node = children.item(0);
- element = assertInstanceOf(Element.class, node);
- name = element.getTagName();
- assertEquals(expected, name);
- }
-
- protected void assertNoDependencies(ServiceMetaData metaData) throws Exception
- {
- List<ServiceDependencyMetaData> dependencies = metaData.getDependencies();
- assertNotNull(dependencies);
- assertEquals(0, dependencies.size());
- }
-
- protected void assertDependencies(ServiceMetaData metaData, ObjectName[] expected) throws Exception
- {
- List<ServiceDependencyMetaData> dependencies = metaData.getDependencies();
- assertNotNull(dependencies);
- assertEquals(expected.length, dependencies.size());
- HashSet<ObjectName> expectedSet = new HashSet<ObjectName>();
- for (ObjectName expect : expected)
- expectedSet.add(expect);
- HashSet<ObjectName> actual = new HashSet<ObjectName>();
- for (ServiceDependencyMetaData depends : dependencies)
- actual.add(depends.getIDependOnObjectName());
- assertEquals(expectedSet, actual);
- }
-
- protected void assertNoXMBean(ServiceMetaData metaData) throws Exception
- {
- assertNull(metaData.getXMBeanDD());
- assertEquals(ServiceMetaData.XMBEAN_CODE, metaData.getXMBeanCode());
- assertNull(metaData.getXMBeanDescriptor());
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test/AbstractMetaDataTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,104 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.test;
-
-import java.io.InputStream;
-import java.net.URL;
-import java.util.List;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceMetaDataParser;
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.util.xml.JBossEntityResolver;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.xml.sax.InputSource;
-
-/**
- * MetaDataTestDelegate.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class MetaDataTestDelegate extends AbstractTestDelegate
-{
- /** The parser */
- private DocumentBuilder parser;
-
- public MetaDataTestDelegate(Class clazz)
- {
- super(clazz);
- }
-
- public void setUp() throws Exception
- {
- super.setUp();
- DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
- parser = factory.newDocumentBuilder();
- }
-
- /**
- * Unmarshal an object
- *
- * @param url the url
- * @return the list of services
- * @throws Exception for any error
- */
- public List<ServiceMetaData> unmarshal(URL url) throws Exception
- {
- long start = System.currentTimeMillis();
-
- Element element = null;
-
- try
- {
- InputStream stream = url.openStream();
- try
- {
- InputSource is = new InputSource(stream);
- is.setSystemId(url.toString());
- parser.setEntityResolver(new JBossEntityResolver());
- log.debug("Initialized parsing in " + (System.currentTimeMillis() - start) + "ms");
-
- Document document = parser.parse(is);
- element = document.getDocumentElement();
- }
- finally
- {
- stream.close();
- }
-
- ServiceMetaDataParser parser = new ServiceMetaDataParser(element);
- List<ServiceMetaData> result = parser.parse();
- log.debug("Total parse for " + url + " took " + (System.currentTimeMillis() - start) + "ms");
- return result;
- }
- catch (Exception e)
- {
- log.debug("Error during parsing: " + url + ": " + e);
- throw e;
- }
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestDelegate.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,67 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.test;
-
-import org.jboss.test.system.metadata.attributes.test.AttributeUnitTestCase;
-import org.jboss.test.system.metadata.attributes.test.AttributeValueUnitTestCase;
-import org.jboss.test.system.metadata.attributes.test.DependsAttributeUnitTestCase;
-import org.jboss.test.system.metadata.attributes.test.DependsListAttributeUnitTestCase;
-import org.jboss.test.system.metadata.basic.test.BasicMBeanUnitTestCase;
-import org.jboss.test.system.metadata.constructor.test.ConstructorUnitTestCase;
-import org.jboss.test.system.metadata.depends.test.DependsOptionalAttributeUnitTestCase;
-import org.jboss.test.system.metadata.depends.test.DependsUnitTestCase;
-import org.jboss.test.system.metadata.value.MetaDataValueTestSuite;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-/**
- * MetaData Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class MetaDataTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("MetaData Tests");
-
- suite.addTest(new TestSuite(BasicMBeanUnitTestCase.class));
- suite.addTest(new TestSuite(ConstructorUnitTestCase.class));
- suite.addTest(new TestSuite(DependsUnitTestCase.class));
- suite.addTest(new TestSuite(DependsOptionalAttributeUnitTestCase.class));
- suite.addTest(new TestSuite(AttributeUnitTestCase.class));
- suite.addTest(new TestSuite(DependsAttributeUnitTestCase.class));
- suite.addTest(new TestSuite(DependsListAttributeUnitTestCase.class));
- suite.addTest(new TestSuite(AttributeValueUnitTestCase.class));
- suite.addTest(MetaDataValueTestSuite.suite());
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/test/MetaDataTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,76 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value;
-
-import java.util.List;
-
-import org.jboss.system.metadata.ServiceAttributeMetaData;
-import org.jboss.system.metadata.ServiceMetaData;
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.test.AbstractMetaDataTest;
-
-/**
- * AbstractValueTest.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public abstract class AbstractValueTest extends AbstractMetaDataTest
-{
- public AbstractValueTest(String name)
- {
- super(name);
- }
-
- protected ServiceAttributeMetaData unmarshallSingleAttribute() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertOthers(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(1, attributes.size());
- return attributes.get(0);
- }
-
- protected ServiceValueMetaData unmarshallSingleValue() throws Exception
- {
- ServiceMetaData metaData = unmarshalSingleMBean();
- assertOthers(metaData);
- List<ServiceAttributeMetaData> attributes = metaData.getAttributes();
- assertNotNull(attributes);
- assertEquals(1, attributes.size());
- ServiceAttributeMetaData attribute = attributes.get(0);
- assertAttributeName(attribute, "Attribute");
- ServiceValueMetaData result = attribute.getValue();
- assertNotNull(result);
- return result;
- }
-
- protected void assertOthers(ServiceMetaData metaData) throws Exception
- {
- assertEquals(testBasicMBeanName, metaData.getObjectName());
- assertEquals(testBasicMBeanCode, metaData.getCode());
- assertNull(metaData.getInterfaceName());
- assertDefaultConstructor(metaData);
- assertNoXMBean(metaData);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/AbstractValueTest.java)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,63 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.system.metadata.value.depends.test.DependencyValueUnitTestCase;
-import org.jboss.test.system.metadata.value.dependslist.test.DependencyListValueUnitTestCase;
-import org.jboss.test.system.metadata.value.element.test.ElementValueUnitTestCase;
-import org.jboss.test.system.metadata.value.inject.test.InjectionValueUnitTestCase;
-import org.jboss.test.system.metadata.value.javabean.test.JavaBeanValueUnitTestCase;
-import org.jboss.test.system.metadata.value.jbxb.test.JBXBValueUnitTestCase;
-import org.jboss.test.system.metadata.value.text.test.TextValueUnitTestCase;
-
-/**
- * MetaData Value Test Suite.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.8 $
- */
-public class MetaDataValueTestSuite extends TestSuite
-{
- public static void main(String[] args)
- {
- TestRunner.run(suite());
- }
-
- public static Test suite()
- {
- TestSuite suite = new TestSuite("MetaData Value Tests");
-
- suite.addTest(new TestSuite(TextValueUnitTestCase.class));
- suite.addTest(new TestSuite(DependencyValueUnitTestCase.class));
- suite.addTest(new TestSuite(DependencyListValueUnitTestCase.class));
- suite.addTest(new TestSuite(ElementValueUnitTestCase.class));
- suite.addTest(new TestSuite(JavaBeanValueUnitTestCase.class));
- suite.addTest(new TestSuite(JBXBValueUnitTestCase.class));
- suite.addTest(new TestSuite(InjectionValueUnitTestCase.class));
-
- return suite;
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/MetaDataValueTestSuite.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,57 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.depends.test;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * DependencyValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependencyValueUnitTestCase extends AbstractValueTest
-{
- public DependencyValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDependency() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyValue(value, TEST1);
- }
-
- public void testDependencyProxyType() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyValue(value, TEST1, "ProxyType");
- }
-
- public void testDependencyNested() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyValue(value, TEST1);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/depends/test/DependencyValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,65 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.dependslist.test;
-
-import javax.management.ObjectName;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * DependencyListValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class DependencyListValueUnitTestCase extends AbstractValueTest
-{
- public DependencyListValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testDependencyListNone() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyListValueEmpty(value);
- }
-
- public void testDependencyListOne() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyListValue(value, TEST1);
- }
-
- public void testDependencyListTwo() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyListValue(value, new ObjectName[] { TEST1, TEST2 });
- }
-
- public void testDependencyListNested() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertDependencyListValue(value, TEST1);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/dependslist/test/DependencyListValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/element)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.element.test;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * ElementValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class ElementValueUnitTestCase extends AbstractValueTest
-{
- public ElementValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testElement() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertElementValue(value, "dummy");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/element/test/ElementValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.inject.test;
-
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * InjectionValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class InjectionValueUnitTestCase extends AbstractValueTest
-{
- public InjectionValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testInjection() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertInjectValue(value, "bean", null);
- }
-
- public void testInjectionEmpty() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertInjectValue(value, "", null);
- }
-
- public void testInjectionProperty() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertInjectValue(value, "bean", "property");
- }
-
- public void testInjectionState() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertInjectValue(value, "bean", null, ControllerState.INSTANTIATED);
- }
-
- public void testInjectionPropertyState() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertInjectValue(value, "bean", "property", ControllerState.INSTANTIATED);
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/inject/test/InjectionValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.javabean.test;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * JavaBeanValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JavaBeanValueUnitTestCase extends AbstractValueTest
-{
- public JavaBeanValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testJavaBean() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertJavaBeanValue(value, "dummy");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/javabean/test/JavaBeanValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.jbxb.test;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * JBXBValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class JBXBValueUnitTestCase extends AbstractValueTest
-{
- public JBXBValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testJBXB() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertJBXBValue(value, "dummy");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/jbxb/test/JBXBValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/text)
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test)
Deleted: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.system.metadata.value.text.test;
-
-import org.jboss.system.metadata.ServiceValueMetaData;
-import org.jboss.test.system.metadata.value.AbstractValueTest;
-
-/**
- * TextValueUnitTestCase.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
- */
-public class TextValueUnitTestCase extends AbstractValueTest
-{
- public TextValueUnitTestCase(String name)
- {
- super(name);
- }
-
- public void testText() throws Exception
- {
- ServiceValueMetaData value = unmarshallSingleValue();
- assertTextValue(value, "value");
- }
-}
Copied: trunk/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests/org/jboss/test/system/metadata/value/text/test/TextValueUnitTestCase.java)
Copied: trunk/system-jmx/src/tests-support (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support)
Copied: trunk/system-jmx/src/tests-support/org (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org)
Copied: trunk/system-jmx/src/tests-support/org/jboss (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss)
Copied: trunk/system-jmx/src/tests-support/org/jboss/test (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test)
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support)
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1 (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar1)
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1 (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1)
Deleted: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,401 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt in the distribution for a
- * full listing of individual contributors.
- *
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
- * the License, or (at your option) any later version.
- *
- * This software is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
- */
-package org.jboss.test.support.jar1.simple1;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Collection;
-import java.util.Date;
-import java.util.List;
-import java.util.Properties;
-import java.util.Set;
-
-/**
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @author Scott.Stark at jboss.org
- * @version $Revision:$
- */
-public class Bean1 implements ISimpleBean
-{
-
- // Constants -----------------------------------------------------
-
- private static final long serialVersionUID = 1L;
-
- // Attributes ----------------------------------------------------
-
- /** Constructor used */
- private String constructorUsed;
-
- /** A string */
- private String aString;
-
- /** Byte */
- private Byte aByte;
-
- /** Boolean */
- private Boolean aBoolean;
-
- /** Character */
- private Character aCharacter;
-
- /** Short */
- private Short aShort;
-
- /** Int */
- private Integer anInt;
-
- /** Long */
- private Long aLong;
-
- /** Float */
- private Float aFloat;
-
- /** Double */
- private Double aDouble;
-
- /** Date */
- private Date aDate;
-
- /** BigDecimal */
- private BigDecimal aBigDecimal;
-
- /** BigDecimal */
- private BigInteger aBigInteger;
-
- /** byte */
- private byte abyte;
-
- /** boolean */
- private boolean aboolean;
-
- /** char */
- private char achar;
-
- /** short */
- private short ashort;
-
- /** int */
- private int anint;
-
- /** long */
- private long along;
-
- /** float */
- private float afloat;
-
- /** double */
- private double adouble;
-
- /** a simple bean */
- private ISimpleBean other;
-
- /** A collection */
- private Collection collection;
-
- /** A list */
- private List aList;
- /** A set */
- private Set aSet;
- /** A properties */
- private Properties props;
-
- // Static --------------------------------------------------------
-
- // Constructors --------------------------------------------------
-
- public Bean1()
- {
- constructorUsed = "()";
- }
-
- public Bean1(String string)
- {
- constructorUsed = string;
- }
-
- public Bean1(ISimpleBean other)
- {
- constructorUsed = ISimpleBean.class.getName();
- this.other = other;
- }
-
- // Public --------------------------------------------------------
-
- public String getConstructorUsed()
- {
- return constructorUsed;
- }
-
- public BigDecimal getABigDecimal()
- {
- return aBigDecimal;
- }
-
- public void setABigDecimal(BigDecimal bigDecimal)
- {
- aBigDecimal = bigDecimal;
- }
-
- public BigInteger getABigInteger()
- {
- return aBigInteger;
- }
-
- public void setABigInteger(BigInteger bigInteger)
- {
- aBigInteger = bigInteger;
- }
-
- public boolean isAboolean()
- {
- return aboolean;
- }
-
- public void setAboolean(boolean aboolean)
- {
- this.aboolean = aboolean;
- }
-
- public Boolean getABoolean()
- {
- return aBoolean;
- }
-
- public void setABoolean(Boolean boolean1)
- {
- aBoolean = boolean1;
- }
-
- public byte getAbyte()
- {
- return abyte;
- }
-
- public void setAbyte(byte abyte)
- {
- this.abyte = abyte;
- }
-
- public Byte getAByte()
- {
- return aByte;
- }
-
- public void setAByte(Byte byte1)
- {
- aByte = byte1;
- }
-
- public char getAchar()
- {
- return achar;
- }
-
- public void setAchar(char achar)
- {
- this.achar = achar;
- }
-
- public Character getACharacter()
- {
- return aCharacter;
- }
-
- public void setACharacter(Character character)
- {
- aCharacter = character;
- }
-
- public Date getADate()
- {
- return aDate;
- }
-
- public void setADate(Date date)
- {
- aDate = date;
- }
-
- public double getAdouble()
- {
- return adouble;
- }
-
- public void setAdouble(double adouble)
- {
- this.adouble = adouble;
- }
-
- public Double getADouble()
- {
- return aDouble;
- }
-
- public void setADouble(Double double1)
- {
- aDouble = double1;
- }
-
- public float getAfloat()
- {
- return afloat;
- }
-
- public void setAfloat(float afloat)
- {
- this.afloat = afloat;
- }
-
- public Float getAFloat()
- {
- return aFloat;
- }
-
- public void setAFloat(Float float1)
- {
- aFloat = float1;
- }
-
- public long getAlong()
- {
- return along;
- }
-
- public void setAlong(long along)
- {
- this.along = along;
- }
-
- public Long getALong()
- {
- return aLong;
- }
-
- public void setALong(Long long1)
- {
- aLong = long1;
- }
-
- public int getAnint()
- {
- return anint;
- }
-
- public void setAnint(int anint)
- {
- this.anint = anint;
- }
-
- public Integer getAnInt()
- {
- return anInt;
- }
-
- public void setAnInt(Integer anInt)
- {
- this.anInt = anInt;
- }
-
- public short getAshort()
- {
- return ashort;
- }
-
- public void setAshort(short ashort)
- {
- this.ashort = ashort;
- }
-
- public Short getAShort()
- {
- return aShort;
- }
-
- public void setAShort(Short short1)
- {
- aShort = short1;
- }
-
- public String getAString()
- {
- return aString;
- }
-
- public void setAString(String string)
- {
- aString = string;
- }
-
- public ISimpleBean getOther()
- {
- return other;
- }
-
- public void setOther(ISimpleBean other)
- {
- this.other = other;
- }
-
- public Collection getCollection()
- {
- return collection;
- }
-
- public void setCollection(Collection collection)
- {
- this.collection = collection;
- }
-
- public List getAList()
- {
- return aList;
- }
-
- public void setAList(List aList)
- {
- this.aList = aList;
- }
-
- public Set getASet()
- {
- return aSet;
- }
-
- public void setASet(Set aSet)
- {
- this.aSet = aSet;
- }
-
- public Properties getProps()
- {
- return props;
- }
-
- public void setProps(Properties props)
- {
- this.props = props;
- }
-
-}
-
\ No newline at end of file
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/Bean1.java)
Deleted: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,106 +0,0 @@
-
-package org.jboss.test.support.jar1.simple1;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-/**
- *
- * @author Adrian Brock
- * @author Scott.Stark at jboss.org
- * @version $Revision:$
- */
-public interface ISimpleBean
-{
- // Constants -----------------------------------------------------
-
- // Public --------------------------------------------------------
-
- String getConstructorUsed();
-
- BigDecimal getABigDecimal();
-
- void setABigDecimal(BigDecimal bigDecimal);
-
- BigInteger getABigInteger();
-
- void setABigInteger(BigInteger bigInteger);
-
- boolean isAboolean();
-
- void setAboolean(boolean aboolean);
-
- Boolean getABoolean();
-
- void setABoolean(Boolean boolean1);
-
- byte getAbyte();
-
- void setAbyte(byte abyte);
-
- Byte getAByte();
-
- void setAByte(Byte byte1);
-
- char getAchar();
-
- void setAchar(char achar);
-
- Character getACharacter();
-
- void setACharacter(Character character);
-
- Date getADate();
-
- void setADate(Date date);
-
- double getAdouble();
-
- void setAdouble(double adouble);
-
- Double getADouble();
-
- void setADouble(Double double1);
-
- float getAfloat();
-
- void setAfloat(float afloat);
-
- Float getAFloat();
-
- void setAFloat(Float float1);
-
- long getAlong();
-
- void setAlong(long along);
-
- Long getALong();
-
- void setALong(Long long1);
-
- int getAnint();
-
- void setAnint(int anint);
-
- Integer getAnInt();
-
- void setAnInt(Integer anInt);
-
- short getAshort();
-
- void setAshort(short ashort);
-
- Short getAShort();
-
- void setAShort(Short short1);
-
- String getAString();
-
- void setAString(String string);
-
- ISimpleBean getOther();
-
- void setOther(ISimpleBean other);
-
-}
\ No newline at end of file
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar1/simple1/ISimpleBean.java)
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2 (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar2)
Deleted: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java
===================================================================
--- branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,22 +0,0 @@
-package org.jboss.test.support.jar2;
-
-import org.jboss.test.support.jar1.simple1.ISimpleBean;
-
-public class Jar1Consumer
-{
- ISimpleBean bean;
-
- public Jar1Consumer()
- {
-
- }
-
- public ISimpleBean getBean()
- {
- return bean;
- }
- public void setBean(ISimpleBean bean)
- {
- this.bean = bean;
- }
-}
Copied: trunk/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java (from rev 57107, branches/MC_VDF_WORK/system-jmx/src/tests-support/org/jboss/test/support/jar2/Jar1Consumer.java)
Modified: trunk/testsuite/.classpath
===================================================================
--- trunk/testsuite/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/testsuite/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -53,7 +53,9 @@
<classpathentry kind="lib" path="/thirdparty/sun-xacml/lib/sunxacml.jar"/>
<classpathentry kind="lib" path="/thirdparty/sun-xacml/lib/sunxacml-support.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/cache/lib/jboss-cache-jdk50.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
<classpathentry kind="lib" path="/thirdparty/joesnmp/lib/joesnmp.jar"/>
<classpathentry kind="lib" path="/thirdparty/sun-jsf/lib/jsf-api.jar"/>
@@ -70,5 +72,7 @@
<classpathentry kind="lib" path="/thirdparty/jboss/web/lib/jbossweb.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/web/lib/jbossweb-extras.jar"/>
<classpathentry kind="lib" path="/thirdparty/sun-opends/lib/OpenDS.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/testsuite/build.xml
===================================================================
--- trunk/testsuite/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/testsuite/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -152,7 +152,10 @@
<path refid="jboss.aspects.classpath"/>
<path refid="jboss.cache.classpath"/>
<path refid="jboss.cluster.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.deployment.classpath"/>
<path refid="jboss.ejb3x.classpath"/>
<path refid="jboss.hibernate.classpath"/>
@@ -172,6 +175,7 @@
<path refid="jboss.security.spi.classpath"/>
<path refid="jboss.server.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.test.classpath"/>
<path refid="jboss.transaction.classpath"/>
<path refid="jboss.varia.classpath"/>
@@ -2582,7 +2586,10 @@
<path refid="javassist.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
</path>
<aopc compilerclasspathref="aop.task.classpath">
Modified: trunk/testsuite/imports/sections/aop.xml
===================================================================
--- trunk/testsuite/imports/sections/aop.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/testsuite/imports/sections/aop.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -9,7 +9,10 @@
<path refid="qdox.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
</path>
<taskdef name="annotationc" classname="org.jboss.aop.ant.AnnotationC"
classpathref="jboss.aop.classpath"/>
Modified: trunk/testsuite/imports/sections/cache.xml
===================================================================
--- trunk/testsuite/imports/sections/cache.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/testsuite/imports/sections/cache.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -16,7 +16,10 @@
<path refid="javassist.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
</path>
<aopc compilerclasspathref="aop.task.classpath">
Modified: trunk/testsuite/imports/sections/cluster.xml
===================================================================
--- trunk/testsuite/imports/sections/cluster.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/testsuite/imports/sections/cluster.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -168,7 +168,10 @@
<path refid="qdox.classpath"/>
<path refid="trove.classpath"/>
<path refid="jboss.aop.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.cache.classpath"/>
</path>
<taskdef name="annotationc" classname="org.jboss.aop.ant.AnnotationC"
Property changes on: trunk/thirdparty
___________________________________________________________________
Name: svn:ignore
-
antlr
apache-avalon
apache-avalon-logkit
apache-bcel
apache-beanutils
apache-bsf
apache-codec
apache-collections
apache-digester
apache-discovery
apache-fileupload
apache-httpclient
apache-jaxme
apache-lang
apache-log4j
apache-logging
apache-modeler
apache-myfaces
apache-pool
apache-scout
apache-slide
apache-struts
apache-taglibs
apache-tomcat
apache-validator
apache-velocity
apache-vfs
apache-xalan
apache-xerces
apache-xmlsec
asm
beanshell
cglib
codehaus-stax
commons-el
dom4j
easymock
ehcache
gjt-jpl-util
gnu-getopt
hibernate
hibernate-annotations
hibernate-entitymanager
hsqldb
ibm-wsdl4j
jacorb
javassist
jaxen
jboss
jbpm
jbpm-bpel
jfreechart
jgroups
joesnmp
juddi
junit
junitejb
licenses
objectweb-joramtests
odmg
opensaml
oswego-concurrent
qdox
quartz
sleepycat
spring
struts-test-case
sun-jaf
sun-javacc
sun-javamail
sun-jaxb
sun-jaxp
sun-jmf
sun-jmx
sun-jsf
sun-jstl
sun-servlet
sun-xacml
trove
wutka-dtdparser
xdoclet
xmlunit-xmlunit
libraries.ent
testsuite-libraries.ent
sun-opends
+ antlr
apache-avalon
apache-avalon-logkit
apache-bcel
apache-beanutils
apache-bsf
apache-codec
apache-collections
apache-digester
apache-discovery
apache-fileupload
apache-httpclient
apache-jaxme
apache-lang
apache-log4j
apache-logging
apache-modeler
apache-myfaces
apache-pool
apache-scout
apache-slide
apache-struts
apache-taglibs
apache-tomcat
apache-validator
apache-velocity
apache-vfs
apache-xalan
apache-xerces
apache-xmlsec
asm
beanshell
cglib
codehaus-stax
commons-el
dom4j
easymock
ehcache
gjt-jpl-util
gnu-getopt
hibernate
hibernate-annotations
hibernate-entitymanager
hsqldb
ibm-wsdl4j
jacorb
javassist
jaxen
jboss
jbpm
jbpm-bpel
jfreechart
jgroups
joesnmp
juddi
junit
junitejb
licenses
objectweb-joramtests
odmg
opensaml
oswego-concurrent
qdox
quartz
sleepycat
spring
struts-test-case
sun-jaf
sun-javacc
sun-javamail
sun-jaxb
sun-jaxp
sun-jmf
sun-jmx
sun-jsf
sun-jstl
sun-servlet
sun-xacml
trove
wutka-dtdparser
xdoclet
xmlunit-xmlunit
libraries.ent
sun-opends
Modified: trunk/tomcat/.classpath
===================================================================
--- trunk/tomcat/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/tomcat/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -2,7 +2,9 @@
<classpath>
<classpathentry kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/server"/>
<classpathentry kind="src" path="/system"/>
<classpathentry kind="src" path="/cluster"/>
@@ -34,5 +36,7 @@
<classpathentry kind="lib" path="/thirdparty/jboss/web/lib/jbossweb-extras.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/web/lib/jsp-api.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/web/lib/servlet-api.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/tomcat/build.xml
===================================================================
--- trunk/tomcat/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/tomcat/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -58,8 +58,11 @@
<path refid="dom4j.dom4j.classpath"/>
<path refid="oswego.concurrent.classpath"/>
<path refid="jgroups.jgroups.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
<path refid="jboss.jbossxb.classpath"/>
<path refid="jboss.serialization.classpath"/>
+ <path refid="jboss.microcontainer.classpath"/>
</path>
<!-- ======= -->
@@ -71,10 +74,10 @@
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.security.spi.classpath"/>
<path refid="jboss.security.classpath"/>
<path refid="jboss.server.classpath"/>
- <path refid="jboss.common.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.cluster.classpath"/>
<path refid="jboss.cache.classpath"/>
Modified: trunk/tools/etc/buildmagic/modules.ent
===================================================================
--- trunk/tools/etc/buildmagic/modules.ent 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/tools/etc/buildmagic/modules.ent 2006-09-23 20:55:54 UTC (rev 57108)
@@ -195,6 +195,7 @@
<path id="jboss.system.classpath">
<pathelement path="${jboss.system.lib}/jboss-system.jar"/>
</path>
+
<!-- System JMX -->
<property name="jboss.systemjmx.root" value="${project.root}/system-jmx/output"/>
<property name="jboss.systemjmx.lib" value="${jboss.systemjmx.root}/lib"/>
@@ -229,86 +230,3 @@
<path id="jboss.hibernate.classpath">
<pathelement path="${jboss.hibernate.lib}/jboss-hibernate.jar"/>
</path>
-
-
-<!-- below this line starts the kingdom of nukes ***************************************************************** -->
-
-<!-- Nukes on JBoss -->
-<property name="jboss.nukes.root" value="${project.root}/nukes/output"/>
-<property name="jboss.nukes.lib" value="${jboss.nukes.root}/lib"/>
-<path id="jboss.nukes.classpath">
- <pathelement path="${jboss.nukes.lib}/nukes-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss adminmessages -->
-<property name="jboss.nukes-adminmessages.root" value="${project.root}/adminmessages/output"/>
-<property name="jboss.nukes-adminmessages.lib" value="${jboss.nukes-adminmessages.root}/lib"/>
-<path id="jboss.nukes-adminmessages.classpath">
- <pathelement path="${jboss.nukes-adminmessages.lib}/nukes-adminmessages-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss faq -->
-<property name="jboss.nukes-faq.root" value="${project.root}/faq/output"/>
-<property name="jboss.nukes-faq.lib" value="${jboss.nukes-faq.root}/lib"/>
-<path id="jboss.nukes-faq.classpath">
- <pathelement path="${jboss.nukes-faq.lib}/nukes-faq-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss jmx -->
-<property name="jboss.nukes-jmx.root" value="${project.root}/jmx/output"/>
-<property name="jboss.nukes-jmx.lib" value="${jboss.nukes-jmx.root}/lib"/>
-<path id="jboss.nukes-jmx.classpath">
- <pathelement path="${jboss.nukes-jmx.lib}/nukes-jmx-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss journal -->
-<property name="jboss.nukes-journal.root" value="${project.root}/journal/output"/>
-<property name="jboss.nukes-journal.lib" value="${jboss.nukes-journal.root}/lib"/>
-<path id="jboss.nukes-journal.classpath">
- <pathelement path="${jboss.nukes-journal.lib}/nukes-journal-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss mp3player -->
-<property name="jboss.nukes-mp3player.root" value="${project.root}/mp3player/output"/>
-<property name="jboss.nukes-mp3player.lib" value="${jboss.nukes-mp3player.root}/lib"/>
-<path id="jboss.nukes-mp3player.classpath">
- <pathelement path="${jboss.nukes-mp3player.lib}/nukes-mp3player-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss news -->
-<property name="jboss.nukes-news.root" value="${project.root}/news/output"/>
-<property name="jboss.nukes-news.lib" value="${jboss.nukes-news.root}/lib"/>
-<path id="jboss.nukes-news.classpath">
- <pathelement path="${jboss.nukes-news.lib}/nukes-news-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss quotes -->
-<property name="jboss.nukes-quotes.root" value="${project.root}/quotes/output"/>
-<property name="jboss.nukes-quotes.lib" value="${jboss.nukes-quotes.root}/lib"/>
-<path id="jboss.nukes-quotes.classpath">
- <pathelement path="${jboss.nukes-quotes.lib}/nukes-quotes-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss list -->
-<property name="jboss.nukes-list.root" value="${project.root}/list/output"/>
-<property name="jboss.nukes-list.lib" value="${jboss.nukes-list.root}/lib"/>
-<path id="jboss.nukes-list.classpath">
- <pathelement path="${jboss.nukes-list.lib}/nukes-list-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss script -->
-<property name="jboss.nukes-script.root" value="${project.root}/script/output"/>
-<property name="jboss.nukes-script.lib" value="${jboss.nukes-script.root}/lib"/>
-<path id="jboss.nukes-script.classpath">
- <pathelement path="${jboss.nukes-script.lib}/nukes-script-lib.jar"/>
-</path>
-
-<!-- Nukes on JBoss sections -->
-<property name="jboss.nukes-sections.root" value="${project.root}/sections/output"/>
-<property name="jboss.nukes-sections.lib" value="${jboss.nukes-sections.root}/lib"/>
-<path id="jboss.nukes-sections.classpath">
- <pathelement path="${jboss.nukes-sections.lib}/nukes-sections-lib.jar"/>
-</path>
-
-
-
Modified: trunk/transaction/.classpath
===================================================================
--- trunk/transaction/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/transaction/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -1,12 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry excluding="org/jboss/tm/recovery/test/**" kind="src" path="src/main"/>
+ <classpathentry kind="src" path="/j2se"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/j2ee"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
- <classpathentry kind="src" path="/j2ee"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system"/>
<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
- <classpathentry kind="src" path="/j2se"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/transaction/build.xml
===================================================================
--- trunk/transaction/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/transaction/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -89,7 +89,11 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.system.classpath"/>
<path refid="jboss.j2se.classpath"/>
</path>
Modified: trunk/varia/.classpath
===================================================================
--- trunk/varia/.classpath 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/varia/.classpath 2006-09-23 20:55:54 UTC (rev 57108)
@@ -3,7 +3,9 @@
<classpathentry excluding="org/jboss/jaxr/|org/jboss/jdo/castor/|org/jboss/tm/plugins/tyrex/" kind="src" path="src/main"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="src" path="/system"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common/lib/jboss-common.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-2.0.0.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-2.0.0.jar"/>
<classpathentry kind="src" path="/cluster"/>
<classpathentry kind="src" path="/j2ee"/>
<classpathentry kind="src" path="/server"/>
@@ -35,5 +37,7 @@
<classpathentry kind="lib" path="/thirdparty/juddi/lib/juddi.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
+ <classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Modified: trunk/varia/build.xml
===================================================================
--- trunk/varia/build.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/varia/build.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -103,10 +103,14 @@
<!-- The combined dependent module classpath -->
<path id="dependentmodule.classpath">
<path refid="jboss.j2ee.classpath"/>
- <path refid="jboss.common.classpath"/>
+ <path refid="jboss.common.core.classpath"/>
+ <path refid="jboss.common.logging.spi.classpath"/>
+ <path refid="jboss.common.logging.log4j.classpath"/>
+ <path refid="jboss.common.logging.jdk.classpath"/>
<path refid="jboss.jmx.classpath"/>
<path refid="jboss.cluster.classpath"/>
<path refid="jboss.system.classpath"/>
+ <path refid="jboss.systemjmx.classpath"/>
<path refid="jboss.j2se.classpath"/>
<path refid="jboss.naming.classpath"/>
<path refid="jboss.server.classpath"/>
Modified: trunk/varia/src/main/org/jboss/jmx/adaptor/snmp/system/MIB2SystemGroupService.java
===================================================================
--- trunk/varia/src/main/org/jboss/jmx/adaptor/snmp/system/MIB2SystemGroupService.java 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/varia/src/main/org/jboss/jmx/adaptor/snmp/system/MIB2SystemGroupService.java 2006-09-23 20:55:54 UTC (rev 57108)
@@ -202,7 +202,8 @@
if (this.sysName == null)
{
String serverConfig = ServerConfigLocator.locate().getServerName();
- String hostAddress = (String)server.getAttribute(ServerInfoMBean.OBJECT_NAME, "HostAddress");
+ ObjectName name = new ObjectName(ServerInfoMBean.OBJECT_NAME_STR);
+ String hostAddress = (String)server.getAttribute(name, "HostAddress");
this.sysName = serverConfig + "@" + hostAddress;
log.debug("Setting sysName name to " + sysName);
Modified: trunk/varia/src/resources/kernel/META-INF/jboss-service.xml
===================================================================
--- trunk/varia/src/resources/kernel/META-INF/jboss-service.xml 2006-09-23 14:37:48 UTC (rev 57107)
+++ trunk/varia/src/resources/kernel/META-INF/jboss-service.xml 2006-09-23 20:55:54 UTC (rev 57108)
@@ -10,6 +10,7 @@
<attribute name="Extension">.beans</attribute>
<attribute name="MetaDataURL">META-INF/jboss-beans.xml</attribute>
+ <depends>jboss.system:service=MainDeployer</depends>
</mbean>
</server>
More information about the jboss-cvs-commits
mailing list