Package org.rhq.plugins.jbossas5.util

Examples of org.rhq.plugins.jbossas5.util.ProfileServiceTestUtil


            propertyAdapter = new PropertyMapToGenericValueAdapter();
        }
        else if (metaType.isComposite())
        {
            if (metaType instanceof MapCompositeMetaType)
                propertyAdapter = new PropertyMapToMapCompositeValueSupportAdapter();
            else
                propertyAdapter = new PropertyMapToCompositeValueSupportAdapter();
        }
        else if (metaType.isTable())
        {
View Full Code Here


        {
            propertyAdapter = new PropertySimpleToEnumValueAdapter();
        }
        else if (metaType instanceof PropertiesMetaType)
        {
            propertyAdapter = new PropertyMapToPropertiesValueAdapter();
        }
        else
        {
            LOG.warn("Unsupported MetaType: " + metaType);
        }
View Full Code Here

            else
                propertyAdapter = new PropertyMapToCompositeValueSupportAdapter();
        }
        else if (metaType.isTable())
        {
            propertyAdapter = new PropertyMapToTableValueAdapter();
        }
        else if (metaType.isCollection())
        {
            propertyAdapter = new PropertyListToCollectionValueAdapter();
        }
View Full Code Here

        {
            propertyAdapter = new PropertyListToArrayValueAdapter();
        }
        else if (metaType.isEnum())
        {
            propertyAdapter = new PropertySimpleToEnumValueAdapter();
        }
        else if (metaType instanceof PropertiesMetaType)
        {
            propertyAdapter = new PropertyMapToPropertiesValueAdapter();
        }
View Full Code Here

    public static PropertyAdapter getPropertyAdapter(MetaType metaType)
    {
        PropertyAdapter propertyAdapter = null;
        if (metaType.isSimple())
        {
            propertyAdapter = new PropertySimpleToSimpleValueAdapter();
        }
        else if (metaType.isGeneric())
        {
            propertyAdapter = new PropertyMapToGenericValueAdapter();
        }
View Full Code Here

                    if (value != null) {
                        MeasurementDefinition measurementDefinition = ResourceTypeUtils.getMeasurementDefinition(
                            context.getResourceType(), metricName);

                        if (type.isSimple()) {
                            MeasurementAdapter measurementAdapter = new SimpleMetaValueMeasurementAdapter();
                            if (measurementDefinition != null & measurementAdapter != null)
                                measurementAdapter.setMeasurementData(report, value, request, measurementDefinition);
                        }
                        if (type.isComposite()) {

                            ManagedObject obj = prop.getManagedObject();
                            Object attachment = obj.getAttachment();
View Full Code Here

    public static MeasurementAdapter getMeasurementPropertyAdapter(MetaType metaType)
    {
        MeasurementAdapter measurementAdapter = null;
        if (metaType.isSimple())
        {
            measurementAdapter = new SimpleMetaValueMeasurementAdapter();
        }
        else if (metaType.isGeneric())
        {
            measurementAdapter = null;
        }
View Full Code Here

     *
     * @return if successful, the Resource details, otherwise, null
     */
    @Nullable
    public DiscoveredResourceDetails discoverInProcessJBossAS(ResourceDiscoveryContext discoveryContext) {
        ProfileServiceConnectionProvider connectionProvider = new LocalProfileServiceConnectionProvider();
        ProfileServiceConnection connection;
        try {
            connection = connectionProvider.connect();
        } catch (Exception e) {
            // This most likely just means we're not embedded inside a JBoss 5.x or 6.x app server instance.
            log.debug("Unable to connect to in-process ProfileService.", e);
            return null;
        }
View Full Code Here

            return;
        }
        // TODO: Check for a defunct connection and if found try to reconnect?
        ProfileServiceConnectionProvider connectionProvider;
        if (runningEmbedded()) {
            connectionProvider = new LocalProfileServiceConnectionProvider();
        } else {
            Configuration pluginConfig = this.resourceContext.getPluginConfiguration();
            String namingURL = pluginConfig.getSimpleValue(ApplicationServerPluginConfigurationProperties.NAMING_URL,
                null);
            validateNamingURL(namingURL);
View Full Code Here

  public Set<DiscoveredResourceDetails> discoverResources(
      ResourceDiscoveryContext discoveryContext)
      throws InvalidPluginConfigurationException, Exception {
    Set<DiscoveredResourceDetails> discoveredResources = new HashSet<DiscoveredResourceDetails>();
    ProfileServiceConnection connection = ((PlatformComponent) discoveryContext
        .getParentResourceComponent()).getConnection();
 
    Set<ManagedComponent> translators = ProfileServiceUtil
        .getManagedComponents(connection, new ComponentType(
            PluginConstants.ComponentType.Translator.TYPE,
View Full Code Here

TOP

Related Classes of org.rhq.plugins.jbossas5.util.ProfileServiceTestUtil

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.