当前位置: 首页>>代码示例>>Java>>正文


Java RpcProgram类代码示例

本文整理汇总了Java中org.apache.hadoop.oncrpc.RpcProgram的典型用法代码示例。如果您正苦于以下问题:Java RpcProgram类的具体用法?Java RpcProgram怎么用?Java RpcProgram使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


RpcProgram类属于org.apache.hadoop.oncrpc包,在下文中一共展示了RpcProgram类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: main

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
public static void main(String[] args) {
  StringUtils.startupShutdownMessage(Portmap.class, args, LOG);

  final int port = RpcProgram.RPCB_PORT;
  Portmap pm = new Portmap();
  try {
    pm.start(DEFAULT_IDLE_TIME_MILLISECONDS,
        new InetSocketAddress(port), new InetSocketAddress(port));
  } catch (Throwable e) {
    LOG.fatal("Failed to start the server. Cause:", e);
    pm.shutdown();
    System.exit(-1);
  }
}
 
开发者ID:naver,项目名称:hadoop,代码行数:15,代码来源:Portmap.java

示例2: RpcProgramPortmap

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
RpcProgramPortmap(ChannelGroup allChannels) {
  this.allChannels = allChannels;
  PortmapMapping m = new PortmapMapping(PROGRAM, VERSION,
      PortmapMapping.TRANSPORT_TCP, RpcProgram.RPCB_PORT);
  PortmapMapping m1 = new PortmapMapping(PROGRAM, VERSION,
      PortmapMapping.TRANSPORT_UDP, RpcProgram.RPCB_PORT);
  map.put(PortmapMapping.key(m), m);
  map.put(PortmapMapping.key(m1), m1);
}
 
开发者ID:naver,项目名称:hadoop,代码行数:10,代码来源:RpcProgramPortmap.java

示例3: getRpcProgram

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
public RpcProgram getRpcProgram() {
  return rpcProgram;
}
 
开发者ID:naver,项目名称:hadoop,代码行数:4,代码来源:MountdBase.java

示例4: Nfs3Base

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
protected Nfs3Base(RpcProgram rpcProgram, Configuration conf) {
  this.rpcProgram = rpcProgram;
  LOG.info("NFS server port set to: " + rpcProgram.getPort());
}
 
开发者ID:naver,项目名称:hadoop,代码行数:5,代码来源:Nfs3Base.java

示例5: Nfs3Base

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
protected Nfs3Base(MountdBase mountd, RpcProgram program) {
  this.mountd = mountd;
  this.rpcProgram = program;
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:5,代码来源:Nfs3Base.java

示例6: startUDPServer

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
private static void startUDPServer(RpcProgramPortmap rpcProgram) {
  rpcProgram.register(PortmapMapping.TRANSPORT_UDP);
  SimpleUdpServer udpServer = new SimpleUdpServer(RpcProgram.RPCB_PORT,
      rpcProgram, 1);
  udpServer.run();
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:7,代码来源:Portmap.java

示例7: startTCPServer

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的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

示例8: Nfs3Base

import org.apache.hadoop.oncrpc.RpcProgram; //导入依赖的package包/类
protected Nfs3Base(MountdBase mountd, RpcProgram program, Configuration conf) {
  this.mountd = mountd;
  this.rpcProgram = program;
  this.nfsPort = conf.getInt("nfs3.server.port", Nfs3Constant.PORT);
  LOG.info("NFS server port set to: "+nfsPort);
}
 
开发者ID:chendave,项目名称:hadoop-TCP,代码行数:7,代码来源:Nfs3Base.java


注:本文中的org.apache.hadoop.oncrpc.RpcProgram类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。