Package org.wso2.carbon.governance.api.services

Examples of org.wso2.carbon.governance.api.services.ServiceManager.updateService()


        Service newService = serviceManager.getService(serviceId);

        assertEquals(newService.getAttribute("testAttribute"), "somevalue");

        service.addAttribute("testAttribute", "somevalue2");
        serviceManager.updateService(service);

        newService = serviceManager.getService(serviceId);

        String[] values = newService.getAttributes("testAttribute");
View Full Code Here


        assertTrue(services[1].getQName().equals(service.getQName()) ||
                services[1].getQName().equals(service2.getQName()));

        // update the service2
        service2.setQName(new QName("http://bom.bom.com/baaaang", "bingo"));
        serviceManager.updateService(service2);

        newService = serviceManager.getService(service2.getId());
        assertEquals(service2.getAttribute("custom-attribute"), "custom-value2");

View Full Code Here

        Service service = serviceManager.newService(new QName("http://banga.queek.queek/blaa", "sfosf"));
        serviceManager.addService(service);

        service.setQName(new QName("http://doc.x.ge/yong", "almdo"));
        serviceManager.updateService(service);

        Service exactServiceCopy = serviceManager.getService(service.getId());
        QName qname = exactServiceCopy.getQName();

        assertEquals(new QName("http://doc.x.ge/yong", "almdo"), qname);
View Full Code Here

        service = serviceManager.newService(contentElement);
        serviceManager.addService(service);

        service.setQName(new QName("http://doc.x.ge/yong", "almdo"));
        serviceManager.updateService(service);

        exactServiceCopy = serviceManager.getService(service.getId());
        qname = exactServiceCopy.getQName();

        assertEquals(new QName("http://doc.x.ge/yong", "almdo"), qname);
View Full Code Here

                        throw new Exception(msg);
                    }
                    // id is used to differentiate the service
                    String id = oldArtifact.getId();
                    service.setId(id);
                    serviceManager.updateService(service);
                    Resource serviceResource = registry.get(service.getPath());
                    String oldLifeCycleName = serviceResource.getProperty("registry.LC.name");
                    if (lifeCycleName == null) {
                        removeAspect(registry, service.getPath(), oldLifeCycleName);
                    }
View Full Code Here

        service.setAttributes("endpoints_entry", new String[] {
                "Dev:http://endpoint3",
                "Production:http://endpoint4",
                "QA:http://endpoint2",
        });
        serviceManager.updateService(service);

        endpoints = service.getAttachedEndpoints();
        assertEquals(3, endpoints.length);

View Full Code Here

        service.setAttributes("endpoints_entry", new String[] {
                "Dev:http://endpoint3",
                "Production:http://endpoint4",
                "QA:http://endpoint2xx",
        });
        serviceManager.updateService(service);

        endpoints = service.getAttachedEndpoints();
        assertEquals(3, endpoints.length);

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.