Mercurial > hg > Database > Christie
diff src/main/java/christie/remoteTextEditor/StartRemotingTextEditor.java @ 239:8a7a2b8d0f07
add renew
author | ichikitakahiro <e165713@ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 21 Jan 2020 21:14:04 +0900 |
parents | src/main/java/christie/remoteTextEditor2/StartRemotingTextEditor.java@90d463bfe734 |
children | faff3236236d |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/src/main/java/christie/remoteTextEditor/StartRemotingTextEditor.java Tue Jan 21 21:14:04 2020 +0900 @@ -0,0 +1,33 @@ +package christie.remoteTextEditor; + +import christie.codegear.CodeGearManager; +import christie.codegear.StartCodeGear; +import christie.topology.manager.StartTopologyManager; +import christie.topology.manager.TopologyManagerConfig; + +public class StartRemotingTextEditor extends StartCodeGear { + + public StartRemotingTextEditor(CodeGearManager cgm) { + super(cgm); + } + + public static void main(String[] args){ + int TopologyManagerPort = 10000; + int TopologyNodePort = 10001; + + String[] managerArg = {"--localPort", String.valueOf(TopologyManagerPort), "--confFile", "scripts/Log/star.dot"}; + + TopologyManagerConfig topologyManagerConfig = new TopologyManagerConfig(managerArg); + new StartTopologyManager(topologyManagerConfig); + + + for (int i = 0; i <= 1; i++){ + String[] nodeArg = {"--managerPort", String.valueOf(TopologyManagerPort), + "--managerHost", "localhost", + "--localPort", String.valueOf(TopologyNodePort + i), + }; + + RemoteNodeStart.main(nodeArg); + } + } +}