HADOOP-11607. Reduce log spew in S3AFileSystem. (Lei (Eddy) Xu via stevel)

This commit is contained in:
Steve Loughran 2015-02-20 20:45:05 +00:00
parent 02e7dec79d
commit aa1c437b6a
2 changed files with 9 additions and 3 deletions

View File

@ -626,6 +626,8 @@ Release 2.7.0 - UNRELEASED
HADOOP-11440. Use "test.build.data" instead of "build.test.dir" for testing
in ClientBaseWithFixes. (Kengo Seki via aajisaka)
HADOOP-11607. Reduce log spew in S3AFileSystem. (Lei (Eddy) Xu via stevel)
OPTIMIZATIONS
HADOOP-11323. WritableComparator#compare keeps reference to byte array.

View File

@ -354,7 +354,9 @@ public class S3AFileSystem extends FileSystem {
public FSDataInputStream open(Path f, int bufferSize)
throws IOException {
LOG.info("Opening '" + f + "' for reading");
if (LOG.isDebugEnabled()) {
LOG.debug("Opening '{}' for reading.", f);
}
final FileStatus fileStatus = getFileStatus(f);
if (fileStatus.isDirectory()) {
throw new FileNotFoundException("Can't open " + f + " because it is a directory");
@ -425,7 +427,9 @@ public class S3AFileSystem extends FileSystem {
* @return true if rename is successful
*/
public boolean rename(Path src, Path dst) throws IOException {
LOG.info("Rename path " + src + " to " + dst);
if (LOG.isDebugEnabled()) {
LOG.debug("Rename path {} to {}", src, dst);
}
String srcKey = pathToKey(src);
String dstKey = pathToKey(dst);
@ -441,7 +445,7 @@ public class S3AFileSystem extends FileSystem {
try {
srcStatus = getFileStatus(src);
} catch (FileNotFoundException e) {
LOG.info("rename: src not found " + src);
LOG.error("rename: src not found {}", src);
return false;
}