Skip to content

Commit

Permalink
IGNITE-15404 Rework disctributed configuration flow. (#330)
Browse files Browse the repository at this point in the history
  • Loading branch information
sanpwc authored Sep 17, 2021
1 parent 1f1ca6c commit 403085d
Show file tree
Hide file tree
Showing 68 changed files with 1,164 additions and 1,983 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
/*
* 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.ignite.internal.affinity;

import java.util.Collection;
import java.util.List;
import org.apache.ignite.network.ClusterNode;
import org.jetbrains.annotations.NotNull;

/**
* Stateless affinity utils that produces helper methods for an affinity assignments calculation.
*/
public class AffinityUtils {
/**
* Calculates affinity assignments.
*
* @param partitions Partitions count.
* @param replicas Replicas count.
* @return List nodes by partition.
*/
public static List<List<ClusterNode>> calculateAssignments(
@NotNull Collection<ClusterNode> baselineNodes,
int partitions,
int replicas
) {
return RendezvousAffinityFunction.assignPartitions(
baselineNodes,
partitions,
replicas,
false,
null
);
}
}

This file was deleted.

Loading

0 comments on commit 403085d

Please sign in to comment.