@Override public KerberosInfo getKerberosInfo(Class<?> protocol, Configuration conf) { if (!protocol .equals(HSClientProtocolPB.class)) { return null; } return new KerberosInfo() { @Override public Class<? extends Annotation> annotationType() { return null; } @Override public String serverPrincipal() { return JHAdminConfig.MR_HISTORY_PRINCIPAL; } @Override public String clientPrincipal() { return null; } }; }
@Override public TokenInfo getTokenInfo(Class<?> protocol, Configuration conf) { if (!protocol .equals(HSClientProtocolPB.class)) { return null; } return new TokenInfo() { @Override public Class<? extends Annotation> annotationType() { return null; } @Override public Class<? extends TokenSelector<? extends TokenIdentifier>> value() { return ClientHSTokenSelector.class; } }; }
public HSClientProtocolPBClientImpl(long clientVersion, InetSocketAddress addr, Configuration conf) throws IOException { super(); RPC.setProtocolEngine(conf, HSClientProtocolPB.class, ProtobufRpcEngine.class); proxy = (HSClientProtocolPB)RPC.getProxy( HSClientProtocolPB.class, clientVersion, addr, conf); }