Package org.drools.grid.service.directory.impl

Examples of org.drools.grid.service.directory.impl.GridServiceDescriptionImpl


{
    public static void main( String[] args )
    {
        //ClassPathXmlApplicationContext springContext = new ClassPathXmlApplicationContext( "classpath:beans-test-grid.xml" );
        Map<String, GridServiceDescription> coreServicesMap = new HashMap<String, GridServiceDescription>();
        GridServiceDescriptionImpl gsd = new GridServiceDescriptionImpl(WhitePages.class.getName());
        Address addr = gsd.addAddress("socket");
        addr.setObject(new InetSocketAddress[]{new InetSocketAddress("localhost", 8000)});
        coreServicesMap.put(WhitePages.class.getCanonicalName(), gsd);   
       
        GridImpl grid2 = new GridImpl(new ConcurrentHashMap<String, Object>());
       
View Full Code Here


        CoreServicesLookup wp = grid.get( CoreServicesLookup.class );

        ((GridImpl) grid).addService( CoreServicesScheduler.class,
                                      new CoreServicesSchedulerImpl( new SchedulerImpl( "scheduler:core" ) ) );
        wp.getServices().put( CoreServicesScheduler.class.getName(),
                              new GridServiceDescriptionImpl( CoreServicesScheduler.class, grid.getId() ) );
    }
View Full Code Here

                                      String id,
                                      String ip,
                                      int port) {
        CoreServicesLookupImpl coreServicesWP = (CoreServicesLookupImpl) grid.get( CoreServicesLookup.class );

        GridServiceDescriptionImpl gsd = (GridServiceDescriptionImpl) coreServicesWP.lookup( SchedulerService.class );
        if ( gsd == null ) {
            gsd = new GridServiceDescriptionImpl( WhitePages.class, grid.getId() );
        }

        GridServiceDescription<WhitePages> service = coreServicesWP.getServices().get( SchedulerService.class.getName() );
        if ( service == null ) {
            coreServicesWP.getServices().put( SchedulerService.class.getName(),
View Full Code Here

TOP

Related Classes of org.drools.grid.service.directory.impl.GridServiceDescriptionImpl

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.