Package org.codehaus.wadi.servicespace

Examples of org.codehaus.wadi.servicespace.ServiceRegistry


        ServiceName serviceName = new ServiceName("name");
        modify().returnValue(serviceName);

        beginSection(s.ordered("Register service then start"));

        ServiceRegistry serviceRegistry = serviceSpace.getServiceRegistry();
        serviceRegistry.register(serviceName, service);
       
        serviceSpace.start();
        endSection();
       
        startVerification();
View Full Code Here


            configInfo.getSweepInterval(),
            backingStrategyFactory);
    }
   
    protected void registerClusteredServices() throws ServiceAlreadyRegisteredException {
        ServiceRegistry serviceRegistry = serviceSpace.getServiceRegistry();
        for (ClusteredServiceHolder serviceHolder : serviceHolders) {
            serviceRegistry.register(serviceHolder.getServiceName(), serviceHolder.getService());
        }
    }
View Full Code Here

            public ServletContext getServletContext() {
                return null;
            }
        });

        ServiceRegistry serviceRegistry = serviceSpace.getServiceRegistry();
        serviceRegistry.register(ReplicaStorage.NAME, repStorageFactory.factory(serviceSpace));
        serviceRegistry.register(ReplicationManager.NAME, replicationManager);
        serviceRegistry.register(ClusteredManager.NAME, manager);

        serviceSpace.start();
    }
View Full Code Here

        }
        this.serviceSpace = serviceSpace;
    }

    public void registerNodeService(NodeService nodeService) {
        ServiceRegistry serviceRegistry = serviceSpace.getServiceRegistry();
        try {
            serviceRegistry.register(NodeService.SERVICE_NAME, nodeService);
        } catch (ServiceAlreadyRegisteredException e) {
            throw new IllegalStateException("NodeService already registered.", e);
        }
    }
View Full Code Here

        serviceSpace = (ServiceSpace) mock(ServiceSpace.class);
        serviceHelper = new NodeServiceHelper(serviceSpace);
    }
   
    public void testNodeServiceRegistration() throws Exception {
        ServiceRegistry serviceRegistry = serviceSpace.getServiceRegistry();
        serviceRegistry.register(NodeService.SERVICE_NAME, nodeService);
       
        startVerification();
       
        serviceHelper.registerNodeService(nodeService);
    }
View Full Code Here

TOP

Related Classes of org.codehaus.wadi.servicespace.ServiceRegistry

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.