本文整理汇总了Java中org.apache.hadoop.oncrpc.SimpleTcpServer类的典型用法代码示例。如果您正苦于以下问题:Java SimpleTcpServer类的具体用法?Java SimpleTcpServer怎么用?Java SimpleTcpServer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SimpleTcpServer类属于org.apache.hadoop.oncrpc包,在下文中一共展示了SimpleTcpServer类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(rpcProgram.getPort(),
rpcProgram, 1);
rpcProgram.startDaemons();
try {
tcpServer.run();
} catch (Throwable e) {
LOG.fatal("Failed to start the TCP server.", e);
if (tcpServer.getBoundPort() > 0) {
rpcProgram.unregister(PortmapMapping.TRANSPORT_TCP,
tcpServer.getBoundPort());
}
tcpServer.shutdown();
terminate(1, e);
}
tcpBoundPort = tcpServer.getBoundPort();
}
开发者ID:naver,项目名称:hadoop,代码行数:18,代码来源:MountdBase.java
示例2: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(rpcProgram.getPort(),
rpcProgram, 0);
rpcProgram.startDaemons();
try {
tcpServer.run();
} catch (Throwable e) {
LOG.fatal("Failed to start the TCP server.", e);
if (tcpServer.getBoundPort() > 0) {
rpcProgram.unregister(PortmapMapping.TRANSPORT_TCP,
tcpServer.getBoundPort());
}
tcpServer.shutdown();
terminate(1, e);
}
nfsBoundPort = tcpServer.getBoundPort();
}
开发者ID:naver,项目名称:hadoop,代码行数:18,代码来源:Nfs3Base.java
示例3: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(Nfs3Constant.PORT,
rpcProgram, 0) {
@Override
public ChannelPipelineFactory getPipelineFactory() {
return new ChannelPipelineFactory() {
@Override
public ChannelPipeline getPipeline() {
return Channels.pipeline(new RpcFrameDecoder(),
new SimpleTcpServerHandler(rpcProgram));
}
};
}
};
tcpServer.run();
}
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:17,代码来源:Nfs3Base.java
示例4: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(rpcProgram.getPort(),
rpcProgram, 1);
rpcProgram.startDaemons();
tcpServer.run();
tcpBoundPort = tcpServer.getBoundPort();
}
开发者ID:Nextzero,项目名称:hadoop-2.6.0-cdh5.4.3,代码行数:8,代码来源:MountdBase.java
示例5: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(rpcProgram.getPort(),
rpcProgram, 0);
rpcProgram.startDaemons();
tcpServer.run();
nfsBoundPort = tcpServer.getBoundPort();
}
开发者ID:Nextzero,项目名称:hadoop-2.6.0-cdh5.4.3,代码行数:8,代码来源:Nfs3Base.java
示例6: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(nfsPort,
rpcProgram, 0);
rpcProgram.startDaemons();
tcpServer.run();
nfsBoundPort = tcpServer.getBoundPort();
}
开发者ID:Seagate,项目名称:hadoop-on-lustre2,代码行数:8,代码来源:Nfs3Base.java
示例7: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(rpcProgram.getPort(),
rpcProgram, 1);
tcpServer.run();
}
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:6,代码来源:MountdBase.java
示例8: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private static void startTCPServer(final RpcProgramPortmap rpcProgram) {
rpcProgram.register(PortmapMapping.TRANSPORT_TCP);
SimpleTcpServer tcpServer = new SimpleTcpServer(RpcProgram.RPCB_PORT,
rpcProgram, 1);
tcpServer.run();
}
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:7,代码来源:Portmap.java
示例9: startTCPServer
import org.apache.hadoop.oncrpc.SimpleTcpServer; //导入依赖的package包/类
private void startTCPServer() {
SimpleTcpServer tcpServer = new SimpleTcpServer(nfsPort,
rpcProgram, 0);
tcpServer.run();
}
开发者ID:chendave,项目名称:hadoop-TCP,代码行数:6,代码来源:Nfs3Base.java
注:本文中的org.apache.hadoop.oncrpc.SimpleTcpServer类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论