Examples of INodeConfig


Examples of mephi.cybernetics.dhcn.nodes.config.INodeConfig

//                        {
//                            config = new NodeConfigSocket(info.getIp(), info.getPort(), this.counterNodeId, info.getType(), info.getTaskTypes());
//                            NodeInfoSocket dispatcherInfo = new NodeInfoSocket(this.ip, this.port, this.counterNodeId, null, this.id);
//                            this.manager.writeData(dispatcherInfo, config);
//                        }
                        INodeConfig config = new NodeConfigSocket(info.getIp(), info.getPort(), this.counterNodeId, info.getType(), info.getTaskTypes());
                        this.nodes.add(config);
                        counterNodeId++;
                    }
                    continue;
                }
               
                if ( NewPoolResultConfig.class.isAssignableFrom(message.getClass()))
                {
                   
                    NewPoolResultConfig config = (NewPoolResultConfig)message;
                    System.out.println("Pool new Size: "  + config.getSizePool() + "TaskId: " + config.getTaskId());
                    this.pools.add(new ResultPool(config.getSizePool(), config.getTaskId(), this.counterPoolId, config.getTargetId(), false, config.getNumOfMessage()));
                    for (int i = 0; i < config.getSizePool(); i++)
                    {
                        DataTask task = config.getTask(i);
                        task.setTargetId(this.counterPoolId);
                        this.messages.add(task);
                    }
              
                    //this.writeMessage(new MNewPoolCreated(this.counterPoolId), config.getNodeId());
                    this.nodeFree(config.getNodeId());
                    this.counterPoolId++;
                    print("Pool create");
                    continue;
                }
               
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.