This is an automated email from the ASF dual-hosted git repository. rzo1 pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/storm.git
commit fc7bd5f68e38a4ce88955f1db82fc173f6e5bcb6 Author: Richard Zowalla <[email protected]> AuthorDate: Fri Aug 25 09:50:25 2023 +0200 STORM-3933 - Fix errors/warnings found while generating javadoc in storm-server --- .../org/apache/storm/metric/timed/TimerDecorated.java | 2 +- .../storm/nimbus/AssignmentDistributionService.java | 1 - .../apache/storm/nimbus/LeaderListenerCallback.java | 1 - .../scheduling/BaseResourceAwareStrategy.java | 2 +- .../strategies/scheduling/ObjectResourcesItem.java | 7 +++---- .../strategies/scheduling/sorter/NodeSorter.java | 15 +++------------ .../scheduling/sorter/NodeSorterHostProximity.java | 18 ++++-------------- .../src/main/java/org/apache/storm/utils/EnumUtil.java | 2 -- 8 files changed, 12 insertions(+), 36 deletions(-) diff --git a/storm-server/src/main/java/org/apache/storm/metric/timed/TimerDecorated.java b/storm-server/src/main/java/org/apache/storm/metric/timed/TimerDecorated.java index 309519cce..abac63633 100644 --- a/storm-server/src/main/java/org/apache/storm/metric/timed/TimerDecorated.java +++ b/storm-server/src/main/java/org/apache/storm/metric/timed/TimerDecorated.java @@ -21,7 +21,7 @@ public interface TimerDecorated extends AutoCloseable { long stopTiming(); /** - * Stop the timer for measured object. (Copied from {@link Timer.Context#stop()}) + * Stop the timer for measured object. * Call to this method will not reset the start time. * Multiple calls result in multiple updates. * diff --git a/storm-server/src/main/java/org/apache/storm/nimbus/AssignmentDistributionService.java b/storm-server/src/main/java/org/apache/storm/nimbus/AssignmentDistributionService.java index ee9f1361c..e0645e5f8 100644 --- a/storm-server/src/main/java/org/apache/storm/nimbus/AssignmentDistributionService.java +++ b/storm-server/src/main/java/org/apache/storm/nimbus/AssignmentDistributionService.java @@ -107,7 +107,6 @@ public class AssignmentDistributionService implements Closeable { * Function for initialization. * * @param conf config - * @param callback callback for sendAssignment results */ public void prepare(Map conf, INodeAssignmentSentCallBack callBack) { this.conf = conf; diff --git a/storm-server/src/main/java/org/apache/storm/nimbus/LeaderListenerCallback.java b/storm-server/src/main/java/org/apache/storm/nimbus/LeaderListenerCallback.java index 08c7e9905..e9286c57b 100644 --- a/storm-server/src/main/java/org/apache/storm/nimbus/LeaderListenerCallback.java +++ b/storm-server/src/main/java/org/apache/storm/nimbus/LeaderListenerCallback.java @@ -69,7 +69,6 @@ public class LeaderListenerCallback { private final int requeueDelayMs; /** - * Constructor for {@LeaderListenerCallback}. * @param conf config * @param zk zookeeper CuratorFramework client * @param blobStore BlobStore diff --git a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/BaseResourceAwareStrategy.java b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/BaseResourceAwareStrategy.java index 94550a1fe..5f12557fe 100644 --- a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/BaseResourceAwareStrategy.java +++ b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/BaseResourceAwareStrategy.java @@ -75,7 +75,7 @@ public abstract class BaseResourceAwareStrategy implements IStrategy { /** * New and only node sorting type going forward. - * {@link NodeSorterHostProximity#NodeSorterHostProximity(Cluster, TopologyDetails)} for more details + * See {@link NodeSorterHostProximity} for more details. */ COMMON, } diff --git a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/ObjectResourcesItem.java b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/ObjectResourcesItem.java index 7b4f7d291..6b87dbdb2 100644 --- a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/ObjectResourcesItem.java +++ b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/ObjectResourcesItem.java @@ -19,6 +19,7 @@ package org.apache.storm.scheduler.resource.strategies.scheduling; import org.apache.storm.scheduler.resource.normalization.NormalizedResourceOffer; +import org.apache.storm.scheduler.resource.strategies.scheduling.sorter.NodeSorter; /** * class to keep track of resources on a rack or node. @@ -33,8 +34,7 @@ public class ObjectResourcesItem { * Note that nodes are grouped into hosts. Hosts into racks. And racks are grouped under the cluster. * * <p> - * An example of this calculation is in - * {@link NodeSorter#sortObjectResourcesCommon(ObjectResourcesSummary, ExecutorDetails, NodeSorter.ExistingScheduleFunc)} + * An example of this calculation is in {@link NodeSorter} * where value is calculated by {@link ObjectResourcesSummary#getAvailableResourcesOverall()} * using {@link NormalizedResourceOffer#calculateMinPercentageUsedBy(NormalizedResourceOffer)}. * </p> @@ -46,8 +46,7 @@ public class ObjectResourcesItem { * Note that nodes are grouped into hosts, hosts into racks, and racks are grouped under the cluster. * * <p> - * An example of this calculation is in - * {@link NodeSorter#sortObjectResourcesCommon(ObjectResourcesSummary, ExecutorDetails, NodeSorter.ExistingScheduleFunc)} + * An example of this calculation is in {@link NodeSorter} * where value is calculated by {@link ObjectResourcesSummary#getAvailableResourcesOverall()} * using {@link NormalizedResourceOffer#calculateAveragePercentageUsedBy(NormalizedResourceOffer)}. * </p> diff --git a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorter.java b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorter.java index 7f892dd70..affd8e004 100644 --- a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorter.java +++ b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorter.java @@ -76,15 +76,6 @@ public class NodeSorter implements INodeSorter { /** * Initialize for the default implementation node sorting. * - * <p> - * <li>{@link BaseResourceAwareStrategy.NodeSortType#GENERIC_RAS} sorting implemented in - * {@link #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, NodeSorter.ExistingScheduleFunc)}</li> - * <li>{@link BaseResourceAwareStrategy.NodeSortType#DEFAULT_RAS} sorting implemented in - * {@link #sortObjectResourcesDefault(ObjectResourcesSummary, NodeSorter.ExistingScheduleFunc)}</li> - * <li>{@link BaseResourceAwareStrategy.NodeSortType#COMMON} sorting implemented in - * {@link #sortObjectResourcesCommon(ObjectResourcesSummary, ExecutorDetails, NodeSorter.ExistingScheduleFunc)}</li> - * </p> - * * @param cluster for which nodes will be sorted. * @param topologyDetails the topology to sort for. * @param nodeSortType type of sorting to be applied to object resource collection {@link BaseResourceAwareStrategy.NodeSortType}. @@ -169,14 +160,14 @@ public class NodeSorter implements INodeSorter { * above will be ranked after racks that have more balanced resource availability and nodes or racks that have * resources that are not requested will be ranked below . So we will be less likely to pick a rack that * have a lot of one resource but a low amount of another and have a lot of resources that are not requested by the executor. - * This is similar to logic used {@link #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. + * This is similar to logic used in {@code #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. * </li> * * <li> * The tie between two nodes with same resource availability is broken by using the node with lower minimum * percentage used. This comparison was used in {@link #sortObjectResourcesDefault(ObjectResourcesSummary, ExistingScheduleFunc)} * but here it is made subservient to modified resource availbility used in - * {@link #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. + * {@code #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. * * </li> * @@ -365,7 +356,7 @@ public class NodeSorter implements INodeSorter { * <p>2) the subordinate/subservient resource availability percentage of a node in descending * order We calculate the resource availability percentage by dividing the resource availability that have exhausted or little of one of * the resources mentioned above will be ranked after on the node by the resource availability of the entire rack By doing this - * calculation, nodes nodes that have more balanced resource availability. So we will be less likely to pick a node that have a lot of + * calculation, nodes that have more balanced resource availability. So we will be less likely to pick a node that have a lot of * one resource but a low amount of another. * * @param availRasNodes a list of all the nodes we want to sort diff --git a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorterHostProximity.java b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorterHostProximity.java index a58c24d07..07a167223 100644 --- a/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorterHostProximity.java +++ b/storm-server/src/main/java/org/apache/storm/scheduler/resource/strategies/scheduling/sorter/NodeSorterHostProximity.java @@ -80,16 +80,6 @@ public class NodeSorterHostProximity implements INodeSorter { /** * Initialize for the default implementation node sorting. - * - * <p> - * <li>{@link BaseResourceAwareStrategy.NodeSortType#GENERIC_RAS} sorting implemented in - * {@link #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, NodeSorterHostProximity.ExistingScheduleFunc)}</li> - * <li>{@link BaseResourceAwareStrategy.NodeSortType#DEFAULT_RAS} sorting implemented in - * {@link #sortObjectResourcesDefault(ObjectResourcesSummary, NodeSorterHostProximity.ExistingScheduleFunc)}</li> - * <li>{@link BaseResourceAwareStrategy.NodeSortType#COMMON} sorting implemented in - * {@link #sortObjectResourcesCommon(ObjectResourcesSummary, ExecutorDetails, NodeSorterHostProximity.ExistingScheduleFunc)}</li> - * </p> - * * @param cluster for which nodes will be sorted. * @param topologyDetails the topology to sort for. * @param nodeSortType type of sorting to be applied to object resource collection {@link BaseResourceAwareStrategy.NodeSortType}. @@ -179,14 +169,14 @@ public class NodeSorterHostProximity implements INodeSorter { * above will be ranked after racks that have more balanced resource availability and nodes or racks that have * resources that are not requested will be ranked below . So we will be less likely to pick a rack that * have a lot of one resource but a low amount of another and have a lot of resources that are not requested by the executor. - * This is similar to logic used {@link #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. + * This is similar to logic used in {@code #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. * </li> * * <li> * The tie between two nodes with same resource availability is broken by using the node with lower minimum * percentage used. This comparison was used in {@link #sortObjectResourcesDefault(ObjectResourcesSummary, ExistingScheduleFunc)} * but here it is made subservient to modified resource availbility used in - * {@link #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. + * {@code #sortObjectResourcesGeneric(ObjectResourcesSummary, ExecutorDetails, ExistingScheduleFunc)}. * * </li> * @@ -384,7 +374,7 @@ public class NodeSorterHostProximity implements INodeSorter { * <p>2) the subordinate/subservient resource availability percentage of a node in descending * order We calculate the resource availability percentage by dividing the resource availability that have exhausted or little of one of * the resources mentioned above will be ranked after on the node by the resource availability of the entire rack By doing this - * calculation, nodes nodes that have more balanced resource availability. So we will be less likely to pick a node that have a lot of + * calculation, nodes that have more balanced resource availability. So we will be less likely to pick a node that have a lot of * one resource but a low amount of another. * * @param availHosts a collection of all the hosts we want to sort @@ -431,7 +421,7 @@ public class NodeSorterHostProximity implements INodeSorter { * <p>2) the subordinate/subservient resource availability percentage of a node in descending * order We calculate the resource availability percentage by dividing the resource availability that have exhausted or little of one of * the resources mentioned above will be ranked after on the node by the resource availability of the entire rack By doing this - * calculation, nodes nodes that have more balanced resource availability. So we will be less likely to pick a node that have a lot of + * calculation, nodes that have more balanced resource availability. So we will be less likely to pick a node that have a lot of * one resource but a low amount of another. * * @param availRasNodes a list of all the nodes we want to sort diff --git a/storm-server/src/main/java/org/apache/storm/utils/EnumUtil.java b/storm-server/src/main/java/org/apache/storm/utils/EnumUtil.java index 0b1d723ab..33ff14983 100644 --- a/storm-server/src/main/java/org/apache/storm/utils/EnumUtil.java +++ b/storm-server/src/main/java/org/apache/storm/utils/EnumUtil.java @@ -26,8 +26,6 @@ public class EnumUtil { * Create an Enum map with given lambda mapper. * @param klass the Enum class * @param mapper The mapper producing value with key (enum constant) - * @param <T> An Enum class - * @param <U> Mapped class * @return An Enum map */ public static <T extends Enum<T>, U> EnumMap<T, U> toEnumMap(Class<T> klass, Function<? super T, ? extends U> mapper) {
