ayushtkn commented on a change in pull request #2377:
URL: https://github.com/apache/hadoop/pull/2377#discussion_r514032406
##########
File path:
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSNamesystem.java
##########
@@ -3569,6 +3569,9 @@ void setQuota(String src, long nsQuota, long ssQuota,
StorageType type)
if (type != null) {
requireEffectiveLayoutVersionForFeature(Feature.QUOTA_BY_STORAGE_TYPE);
}
+ if (type == StorageType.NVDIMM) {
+ requireEffectiveLayoutVersionForFeature(Feature.NVDIMM_SUPPORT);
Review comment:
This check should be done in case of setStoragePolicy also, if the
storage policy is `ALLNVDIMM`
##########
File path:
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/StorageType.java
##########
@@ -33,13 +33,12 @@
@InterfaceAudience.Public
@InterfaceStability.Unstable
public enum StorageType {
- // sorted by the speed of the storage types, from fast to slow
RAM_DISK(true, true),
- NVDIMM(false, true),
SSD(false, false),
DISK(false, false),
ARCHIVE(false, false),
- PROVIDED(false, false);
+ PROVIDED(false, false),
+ NVDIMM(false, true);
Review comment:
I am not sure but will getStoragePolicies also land up in something
similar issue? Due to unavailability of storage type? The quota stuff shall be
there for PROVIDED also but in case this backward incompatibility is there with
Storage Policy too, Then we need to find out some way.
@vinayakumarb do you have pointers or suggestions on this, how to tackle
this?
##########
File path:
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/NameNodeLayoutVersion.java
##########
@@ -89,7 +89,8 @@ public static boolean supports(final LayoutFeature f, final
int lv) {
APPEND_NEW_BLOCK(-62, -61, "Support appending to new block"),
QUOTA_BY_STORAGE_TYPE(-63, -61, "Support quota for specific storage
types"),
ERASURE_CODING(-64, -61, "Support erasure coding"),
- EXPANDED_STRING_TABLE(-65, -61, "Support expanded string table in
fsimage");
+ EXPANDED_STRING_TABLE(-65, -61, "Support expanded string table in
fsimage"),
+ NVDIMM_SUPPORT(-66, -66, "Support NVDIMM storage type");
Review comment:
Not very aware, but yes, if I am decoding the comment correct, This
should be 66 both.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]