30 |
import org.nongnu.storm.impl.*; |
import org.nongnu.storm.impl.*; |
31 |
import org.nongnu.storm.impl.p2p.*; |
import org.nongnu.storm.impl.p2p.*; |
32 |
import org.nongnu.storm.util.HTTPProxy; |
import org.nongnu.storm.util.HTTPProxy; |
33 |
|
import org.nongnu.storm.util.HtmlLinkIndex; |
34 |
|
|
35 |
import java.io.*; |
import java.io.*; |
36 |
import java.util.*; |
import java.util.*; |
53 |
IndexedPool publishedPool = null; |
IndexedPool publishedPool = null; |
54 |
int gisp_port = GispP2PMap.PORT; |
int gisp_port = GispP2PMap.PORT; |
55 |
int gateway_port = -1; |
int gateway_port = -1; |
56 |
|
Set indexTypes = Collections.singleton(HtmlLinkIndex.type); |
57 |
|
|
58 |
int i=0; |
int i=0; |
59 |
while(i<argv.length) { |
while(i<argv.length) { |
61 |
i++; |
i++; |
62 |
p("Publish pool: "+argv[i]); |
p("Publish pool: "+argv[i]); |
63 |
publishedPool = new DirPool(new File(argv[i]), |
publishedPool = new DirPool(new File(argv[i]), |
64 |
Collections.EMPTY_SET); |
indexTypes); |
65 |
} else if(argv[i].equals("-gw")) { |
} else if(argv[i].equals("-gw")) { |
66 |
i++; |
i++; |
67 |
gateway_port = Integer.parseInt(argv[i]); |
gateway_port = Integer.parseInt(argv[i]); |
82 |
System.arraycopy(argv, i, seeds, 0, seeds.length); |
System.arraycopy(argv, i, seeds, 0, seeds.length); |
83 |
|
|
84 |
GispPeer peer = new GispPeer(publishedPool, |
GispPeer peer = new GispPeer(publishedPool, |
85 |
new TransientPool(Collections.EMPTY_SET), |
new TransientPool(indexTypes), |
86 |
gisp_port, seeds); |
gisp_port, seeds); |
87 |
if(gisp_port == GispP2PMap.PORT) |
if(gisp_port == GispP2PMap.PORT) |
88 |
p("GISP UDP port: default of "+gisp_port); |
p("GISP UDP port: default of "+gisp_port); |