## org.apache.hadoop.mapred
Class TaskLogsTruncater

    java.lang.Object
      org.apache.hadoop.mapred.TaskLogsTruncater

    public class TaskLogsTruncater

extends Object

The class for truncating the user logs. Should be used only by `UserLogManager`.

Constructor Summary
`TaskLogsTruncater(Configuration conf)`

Method Summary
`static void` `main(String[] args)`
`boolean` `shouldTruncateLogs(JVMInfo lInfo)` Check the log file sizes generated by the attempts that ran in a particular JVM
`void` `truncateLogs(JVMInfo lInfo)` Process the removed task's logs.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### TaskLogsTruncater

    public TaskLogsTruncater(Configuration conf)

Method Detail

### shouldTruncateLogs

    public boolean shouldTruncateLogs(JVMInfo lInfo)
                               throws IOException

  Check the log file sizes generated by the attempts that ran in a particular JVM

  Parameters:
    `lInfo` -
  Returns:
    is truncation required?
  Throws:
    `IOException`

### truncateLogs

    public void truncateLogs(JVMInfo lInfo)

  Process the removed task's logs. This involves truncating them to retainSize.

### main

    public static void main(String[] args)
                     throws IOException

  Throws:
    `IOException`

Copyright © 2009 The Apache Software Foundation