Package org.wso2.carbon.registry.core

Examples of org.wso2.carbon.registry.core.CollectionImpl.discard()


                rr.setProperty("p1", "vvv1");
                //long startUpdate = System.nanoTime();
                registry.put(rPath, rr);
                //long endUpdate = System.nanoTime();
                //System.out.println("CSV,"+threadName+",update,"+(endUpdate-startUpdate));
                rr.discard();
                Thread.yield();

                // copy the resource
                String pathToCopy = basePath + "/copy/r" + i;
                registry.copy(rPath, pathToCopy);
View Full Code Here


                System.out.println(rPath);
                registry.createVersion(rPath);
                String[] versions = registry.getVersions(rPath);
                if (versions.length > 0) {
                    Resource rVersion = registry.get(versions[0]);
                    rVersion.discard();
                    registry.restoreVersion(versions[0]);
                }


View Full Code Here

            if (registry.resourceExists(resourcePath)) {
               
                Resource resource = registry.get(resourcePath);
                if (resource != null) {
                    String value = resource.getProperty(key);
                    resource.discard();
                    return value;
                }
            }
           
        } catch (RegistryException e) {
View Full Code Here

                //*****************************//
                long putEnd = System.nanoTime();
                long putTime = putEnd - putStart;
                System.out.println("CSV," + threadName + "," + "put," + putTime / 1000000);
                //System.out.println("~~~~~end put~~~~~");
                r1.discard();

                long getStart = System.nanoTime();
                //*****************************//
                Resource r2 = registry.get(basePath + i);
                //*****************************//
 
View Full Code Here

                //*****************************//
                long getEnd = System.nanoTime();
                long getTime = getEnd - getStart;
                System.out.println("CSV," + threadName + "," + "get," + getTime / 1000000);

                r2.discard();

                //System.out.println("~~~~~begin delete~~~~~");
                long deleteStart = System.nanoTime();
                //*****************************//
                registry.delete(basePath + i);
View Full Code Here

        keyInfoResource.setContent(PKCertificate.getEncoded());
        keyInfoResource.addProperty(IdentityRegistryResources.PROP_SAML_SSO_PUB_KEY_FILE_PATH, filePath);
        keyInfoResource.addProperty(IdentityRegistryResources.PROP_SAML_SSO_GEN_KEY_PASS, password);
        registry.put(IdentityRegistryResources.SAML_SSO_GEN_KEY, keyInfoResource);

        keyInfoResource.discard();
        //return the location of the pub. key
        return filePath;
    }

    /**
 
View Full Code Here

                //*****************************//
                long putEnd = System.nanoTime();
                long putTime = putEnd - putStart;
                System.out.println("CSV," + threadName + "," + "put," + putTime / 1000000);
                //System.out.println("~~~~~end put~~~~~");
                r1.discard();

                long queryStart = System.nanoTime();
                //*****************************//
                Map params = new HashMap();
                params.put("1", "%production%");
View Full Code Here

                r.setProperty("p2", "v2");
                //long startPut = System.nanoTime();
                registry.put(rPath, r);
                //long endPut = System.nanoTime();
                //System.out.println("CSV,"+threadName+",put,"+(endPut-startPut));
                r.discard();
                Thread.yield();

                // read and update the resource

                registry.resourceExists(rPath);
View Full Code Here

                rr.setProperty("p1", "vvv1");
                //long startUpdate = System.nanoTime();
                registry.put(rPath, rr);
                //long endUpdate = System.nanoTime();
                //System.out.println("CSV,"+threadName+",update,"+(endUpdate-startUpdate));
                rr.discard();
                Thread.yield();

                // copy the resource
                String pathToCopy = basePath + "/copy/r" + i;
                registry.copy(rPath, pathToCopy);
View Full Code Here

                System.out.println(rPath);
                registry.createVersion(rPath);
                String[] versions = registry.getVersions(rPath);
                if (versions.length > 0) {
                    Resource rVersion = registry.get(versions[0]);
                    rVersion.discard();
                    registry.restoreVersion(versions[0]);
                }


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.