HDFS-13357. Improve AclException message "Invalid ACL: only directories may have a default ACL.". Contributed by Gabor Bota.

This commit is contained in:
Wei-Chiu Chuang 2018-03-29 07:08:22 -07:00
parent 431076f637
commit ad10cbd91b

View File

@ -281,7 +281,8 @@ public static void updateINodeAcl(INode inode, List<AclEntry> newAcl,
// Only directories may have a default ACL.
if (!defaultEntries.isEmpty() && !inode.isDirectory()) {
throw new AclException(
"Invalid ACL: only directories may have a default ACL.");
"Invalid ACL: only directories may have a default ACL. "
+ "Path: " + inode.getFullPathName());
}
// Attach entries to the feature.