Package org.rhq.core.util.updater

Examples of org.rhq.core.util.updater.FileHashcodeMap


            "should not have exploded this");
        assertFalse(new File(DEPLOY_DIR, "archived-subdir").isDirectory(), "should not still have the exploded dir");

        DeploymentsMetadata dm = new DeploymentsMetadata(DEPLOY_DIR);
        if (!dryRun) {
            FileHashcodeMap fhm = dm.getCurrentDeploymentFileHashcodes();
            assertFalse(fhm.containsKey("archived-bundle-file.txt"),
                "should not have metadata - this is inside the compressed zip");
            assertFalse(fhm.containsKey("archived-subdir/archived-file-in-subdir.properties"),
                "should not have metadata - this is inside the compressed zip");
            assertTrue(fhm.containsKey("file.zip"),
                String
                    .valueOf("should have metadata for this - we didn't explode it, we just have this compressed file"));

            // test that we created the zip OK. Note that our test did not do any file replacing/realization of templates
            final String[] templateVarValue = new String[1];
View Full Code Here


            "should not have exploded this");
        assertFalse(new File(DEPLOY_DIR, "archived-subdir").isDirectory(), "should not still have the exploded dir");

        DeploymentsMetadata dm = new DeploymentsMetadata(DEPLOY_DIR);
        if (!dryRun) {
            FileHashcodeMap fhm = dm.getCurrentDeploymentFileHashcodes();
            assertFalse(fhm.containsKey("archived-bundle-file.txt"),
                "should not have metadata - this is inside the compressed zip");
            assertFalse(fhm.containsKey("archived-subdir/archived-file-in-subdir.properties"),
                "should not have metadata - this is inside the compressed zip");
            assertTrue(fhm.containsKey("file.zip"),
                String
                    .valueOf("should have metadata for this - we didn't explode it, we just have this compressed file"));

            // test that the file in the zip is realized
            final String[] templateVarValue = new String[1];
View Full Code Here

                manageAllDeployDir = metadata.getCurrentDeploymentProperties().getDestinationCompliance() == DestinationComplianceMode.full;

                int totalExternalFiles = 0;
                ArrayList<String> externalDeleteSuccesses = new ArrayList<String>(0);
                ArrayList<String> externalDeleteFailures = new ArrayList<String>(0);
                FileHashcodeMap deployDirFileHashcodes = metadata.getCurrentDeploymentFileHashcodes();
                for (String filePath : deployDirFileHashcodes.keySet()) {
                    File file = new File(filePath);
                    if (file.isAbsolute()) {
                        totalExternalFiles++;
                        if (file.exists()) {
                            if (file.delete()) {
View Full Code Here

TOP

Related Classes of org.rhq.core.util.updater.FileHashcodeMap

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.