Package org.rhq.core.domain.configuration

Examples of org.rhq.core.domain.configuration.Configuration.deepCopy()


   * @see ConfigurationFacet#updateResourceConfiguration(ConfigurationUpdateReport)
   */
  public void updateResourceConfiguration(ConfigurationUpdateReport report) {

    Configuration resourceConfig = report.getConfiguration();
    resourceConfiguration = resourceConfig.deepCopy();

    // First update simple properties
    super.updateResourceConfiguration(report);

    // Then update models
View Full Code Here


   * @see ConfigurationFacet#updateResourceConfiguration(ConfigurationUpdateReport)
   */
  public void updateResourceConfiguration(ConfigurationUpdateReport report) {

    Configuration resourceConfig = report.getConfiguration();
    resourceConfiguration = resourceConfig.deepCopy();

    // Get the vdb and update date role anyAuthenticated and MappedRoleNames
    ManagementView managementView = null;
    ComponentType componentType = new ComponentType(
        PluginConstants.ComponentType.VDB.TYPE,
View Full Code Here

        pojoResource.setResourceType(resource.getResourceType());
        pojoResource.setMtime(resource.getMtime());
        pojoResource.setInventoryStatus(resource.getInventoryStatus());
        Configuration pcCopy = resource.getPluginConfiguration();
        if (pcCopy != null) {
            pcCopy = pcCopy.deepCopy();
        }
        pojoResource.setPluginConfiguration(pcCopy);
        pojoResource.setName(resource.getName());
        pojoResource.setDescription(resource.getDescription());
        pojoResource.setLocation(resource.getLocation());
View Full Code Here

    @Override
    @TransactionAttribute(TransactionAttributeType.REQUIRES_NEW)
    public ConfigurationUpdateResponse executePluginConfigurationUpdate(PluginConfigurationUpdate update) {
        Resource resource = update.getResource();
        Configuration configuration = update.getConfiguration();
        configuration = configuration.deepCopy(false);

        ConfigurationUpdateResponse response = null;

        try {
            // now let's tell the agent to actually update the resource component's plugin configuration
View Full Code Here

    @Override
    public void executeResourceConfigurationUpdate(int updateId) {
        ResourceConfigurationUpdate update = getResourceConfigurationUpdate(subjectManager.getOverlord(), updateId);
        Configuration originalConfig = update.getConfiguration();
        update.setConfiguration(originalConfig.deepCopy(false));
        executeResourceConfigurationUpdate(update);
    }

    /**
     * Tells the Agent to asynchronously update a managed resource's configuration as per the specified
View Full Code Here

            // Note: we explicitly do not call configurationManager.updatePluginConfiguration() because the
            // agent is already updated to the new configuration. Instead we call the dedicated local method
            // supporting this use case.
            Configuration pluginConfig = upgradeRequest.getNewPluginConfiguration();
            if (null != pluginConfig) {
                pluginConfig = pluginConfig.deepCopy(false);
                PluginConfigurationUpdate update = configurationManager.upgradePluginConfiguration(
                    subjectManager.getOverlord(), resource.getId(), pluginConfig);
                ret.setUpgradedResourcePluginConfiguration(update.getResource().getPluginConfiguration());
            }
View Full Code Here

            op = operationManager.getSupportedGroupOperation(user, group.getId(), schedule.getOperationName(), false);

            // first we need to create an INPROGRESS *group* history item
            Configuration parameters = schedule.getParameters();
            if (parameters != null) {
                parameters = parameters.deepCopy(false); // we need a copy to avoid constraint violations upon delete
            }

            groupHistory = new GroupOperationHistory(jobDetail.getName(), jobDetail.getGroup(), user.getName(), op,
                parameters, group);

View Full Code Here

        plugin = (ServerPlugin) query.getSingleResult();

        Configuration config = plugin.getPluginConfiguration();
        if (config != null) {
            config = entityManager.find(Configuration.class, config.getId());
            plugin.setPluginConfiguration(config.deepCopy());
        }

        config = plugin.getScheduledJobsConfiguration();
        if (config != null) {
            config = entityManager.find(Configuration.class, config.getId());
View Full Code Here

        }

        config = plugin.getScheduledJobsConfiguration();
        if (config != null) {
            config = entityManager.find(Configuration.class, config.getId());
            plugin.setScheduledJobsConfiguration(config.deepCopy());
        }

        return plugin;
    }
View Full Code Here

            Configuration deploymentConfiguration = null;
            List deploymentConfigurationResults = deploymentConfigurationQuery.getResultList();
            if (deploymentConfigurationResults.size() > 0) {
                deploymentConfiguration = (Configuration) deploymentConfigurationResults.get(0);
                deploymentConfiguration = deploymentConfiguration.deepCopy(false);
            }

            history.setDeploymentConfigurationValues(deploymentConfiguration);

            // If the package indicated installation steps, link them to the resulting history entry
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.