greenwich commented on code in PR #9807: URL: https://github.com/apache/ozone/pull/9807#discussion_r2843300849
########## hadoop-ozone/common/src/main/java/org/apache/hadoop/hdds/protocol/OzoneStoragePolicy.java: ########## @@ -0,0 +1,111 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.hadoop.hdds.protocol; + +import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.StoragePolicyProto; + +/** + * Enum representing named storage policies that map semantic intent + * (HOT, WARM, COLD) to physical {@link StorageType} values. + * + * <ul> + * <li><b>HOT</b> – primary SSD, fallback DISK</li> + * <li><b>WARM</b> – primary DISK, no fallback</li> + * <li><b>COLD</b> – primary ARCHIVE, no fallback</li> + * </ul> + */ +public enum OzoneStoragePolicy { + + HOT(StorageType.SSD, StorageType.DISK), + WARM(StorageType.DISK, null), + COLD(StorageType.ARCHIVE, null); Review Comment: Yeah, good that you pointed it out; it's probably a misconfiguration here. As in our team, we use the following storage types: DISK, SSD, NVME. From my perspective, it should be: - HOT -> NVME - WARM -> SSD - COLD -> DISK Technically, NVMe is an SSD, but they are much faster, with different throughput and performance profiles, and we want separate layers for each. So in our team, we have to define distinct storage for them. -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
