Class CredentialShell

All Implemented Interfaces:
Configurable, Tool

public class CredentialShell extends CommandShell
This program is the CLI utility for the CredentialProvider facilities in Hadoop.
  • Field Details

  • Constructor Details

    • CredentialShell

      public CredentialShell()
  • Method Details

    • init

      protected int init(String[] args) throws IOException
      Parse the command line arguments and initialize the data.
       % hadoop credential create alias [-provider providerPath]
       % hadoop credential list [-provider providerPath]
       % hadoop credential check alias [-provider providerPath]
       % hadoop credential delete alias [-provider providerPath] [-f]
       
      Specified by:
      init in class CommandShell
      Parameters:
      args - args.
      Returns:
      0 if the argument(s) were recognized, 1 otherwise
      Throws:
      IOException - raised on errors performing I/O.
    • getCommandUsage

      public String getCommandUsage()
      Description copied from class: CommandShell
      Return usage string for the command including any summary of subcommands.
      Specified by:
      getCommandUsage in class CommandShell
      Returns:
      command usage.
    • promptForCredential

      protected char[] promptForCredential() throws IOException
      Throws:
      IOException
    • getPasswordReader

      public CredentialShell.PasswordReader getPasswordReader()
    • setPasswordReader

      public void setPasswordReader(CredentialShell.PasswordReader reader)
    • main

      public static void main(String[] args) throws Exception
      Main program.
      Parameters:
      args - Command line arguments
      Throws:
      Exception - exception.