Skip to content

Commit

Permalink
Support different types of MiddleManagers by Autoscaler apache#8695
Browse files Browse the repository at this point in the history
 - Added Javadocs to the created classes
  • Loading branch information
Vladimir Iordanov committed Feb 13, 2020
1 parent e16e40b commit 045e598
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,10 @@
import java.util.concurrent.ScheduledExecutorService;
import java.util.stream.Collectors;

/**
* Autoscaler provisioning strategy based on {@link AutoScaler#getCategory()} field. It selects autoscaler according
* to category of a submitted Task.
*/
@JsonTypeName("categoriedTaskBased")
public class CategoriedProvisioningStrategy extends AbstractWorkerProvisioningStrategy
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
import java.util.List;
import java.util.Objects;

/**
* This implementation is suitable for categoried provisioning strategies
*/
public class CategoriedWorkerBehaviorConfig implements WorkerBehaviorConfig
{
// Use the same category constant as for worker category to match default workers and autoscalers
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@

package org.apache.druid.indexing.overlord.setup;

/**
* Extended version of WorkerSelectStrategy which is suitable for categoried strategies
*/
public interface CategoriedWorkerSelectStrategy extends WorkerSelectStrategy
{
WorkerCategorySpec getWorkerCategorySpec();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.atomic.AtomicReference;


/**
* More test cases for PendingTaskBasedProvisioningStrategy
*/
public class PendingTaskBasedProvisioningStrategyTestExtended
{
private static final String DEFAULT_CATEGORY_1 = "default_category1";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
import java.util.concurrent.atomic.AtomicReference;

/**
*
* More test cases for SimpleProvisioningStrategy
*/
public class SimpleProvisioningStrategyTestExtended
{
Expand Down

0 comments on commit 045e598

Please sign in to comment.