org.apache.hadoop.mapreduce.v2.jobhistory
Class FileNameIndexUtils

java.lang.Object
  extended by org.apache.hadoop.mapreduce.v2.jobhistory.FileNameIndexUtils

public class FileNameIndexUtils
extends Object


Constructor Summary
FileNameIndexUtils()
           
 
Method Summary
static String decodeJobHistoryFileName(String logFileName)
          Helper function to decode the URL of the filename of the job-history log file.
static String encodeJobHistoryFileName(String logFileName)
          Helper function to encode the URL of the filename of the job-history log file.
static String getDoneFileName(JobIndexInfo indexInfo)
          Constructs the job history file name from the JobIndexInfo.
static JobIndexInfo getIndexInfo(String jhFileName)
          Parses the provided job history file name to construct a JobIndexInfo object which is returned.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileNameIndexUtils

public FileNameIndexUtils()
Method Detail

getDoneFileName

public static String getDoneFileName(JobIndexInfo indexInfo)
                              throws IOException
Constructs the job history file name from the JobIndexInfo.

Parameters:
indexInfo - the index info.
Returns:
the done job history filename.
Throws:
IOException

getIndexInfo

public static JobIndexInfo getIndexInfo(String jhFileName)
                                 throws IOException
Parses the provided job history file name to construct a JobIndexInfo object which is returned.

Parameters:
jhFileName - the job history filename.
Returns:
a JobIndexInfo object built from the filename.
Throws:
IOException

encodeJobHistoryFileName

public static String encodeJobHistoryFileName(String logFileName)
                                       throws IOException
Helper function to encode the URL of the filename of the job-history log file.

Parameters:
logFileName - file name of the job-history file
Returns:
URL encoded filename
Throws:
IOException

decodeJobHistoryFileName

public static String decodeJobHistoryFileName(String logFileName)
                                       throws IOException
Helper function to decode the URL of the filename of the job-history log file.

Parameters:
logFileName - file name of the job-history file
Returns:
URL decoded filename
Throws:
IOException


Copyright © 2014 Apache Software Foundation. All Rights Reserved.