Package com.mapr.fs

Class Rpc


public class Rpc extends RpcNative
Class to export RPC layer functionality to Java Layers.
  • Field Details

    • MAX_RPC_THREADS_PER_INSTANCE

      public static int MAX_RPC_THREADS_PER_INSTANCE
  • Constructor Details

    • Rpc

      public Rpc()
  • Method Details

    • initialize

      public static int initialize(int port, int numThreads, String clusterName) throws Exception
      Throws:
      Exception
    • initialize

      public static int initialize(int listenPort, int numThreads, String clusterName, RpcExport[] rpcPrograms, ThreadPoolFinder poolFinder) throws Exception
      Spawns and starts the RPC Listener Thread.
      Throws:
      Exception
    • initializeRpcServer

      public static int initializeRpcServer(String processName, int listenPort, int numThreads, String clusterName, RpcExport[] rpcPrograms, ThreadPoolFinder poolFinder, int serverIdx, long ipStatsAddr, int ipStatsMemSize) throws Exception
      Spawns and starts the RPC Listener Thread.
      Throws:
      Exception
    • sendRequest

      public static byte[] sendRequest(long binding, int programId, int procedureId, com.google.protobuf.MessageLite request) throws Exception
      Throws:
      Exception
    • exportProgram

      public static void exportProgram(int programId, RpcProgram program) throws Exception
      Throws:
      Exception
    • exportProgram

      public static void exportProgram(int programId, RpcProgram program, int serverIdx) throws Exception
      Throws:
      Exception
    • sendReply

      public static void sendReply(RpcCallContext c, com.google.protobuf.MessageLite reply) throws Exception
      Throws:
      Exception
    • sendReplyAsync

      public static void sendReplyAsync(RpcCallContext c, com.google.protobuf.MessageLite reply) throws Exception
      Throws:
      Exception
    • sendReplyAsync

      public static void sendReplyAsync(RpcCallContext c, com.google.protobuf.MessageLite reply, boolean replyWithEBusy) throws Exception
      Throws:
      Exception
    • rejectCall

      public static void rejectCall(RpcCallContext c) throws Exception
      Throws:
      Exception
    • closeBinding

      public static void closeBinding(RpcCallContext c) throws Exception
      Throws:
      Exception
    • getAuthenticatedTicket

      public static com.mapr.fs.proto.Security.Ticket getAuthenticatedTicket(RpcCallContext c)
    • initializeGuts

      public static int initializeGuts(long shmAddr)