Skip to content

Commit

Permalink
remove constructor indirection as its not required anymore after the …
Browse files Browse the repository at this point in the history
…removal

of the old endpoints
  • Loading branch information
Hendrik Muhs committed Oct 28, 2021
1 parent f4eaad2 commit 32934f0
Show file tree
Hide file tree
Showing 9 changed files with 28 additions and 192 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,31 +52,9 @@ public TransportDeleteTransformAction(
IndexNameExpressionResolver indexNameExpressionResolver,
TransformServices transformServices,
Client client
) {
this(
DeleteTransformAction.NAME,
transportService,
actionFilters,
threadPool,
clusterService,
indexNameExpressionResolver,
transformServices,
client
);
}

protected TransportDeleteTransformAction(
String name,
TransportService transportService,
ActionFilters actionFilters,
ThreadPool threadPool,
ClusterService clusterService,
IndexNameExpressionResolver indexNameExpressionResolver,
TransformServices transformServices,
Client client
) {
super(
name,
DeleteTransformAction.NAME,
transportService,
clusterService,
threadPool,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,18 +48,7 @@ public TransportGetTransformAction(
Client client,
NamedXContentRegistry xContentRegistry
) {
this(GetTransformAction.NAME, transportService, actionFilters, clusterService, client, xContentRegistry);
}

protected TransportGetTransformAction(
String name,
TransportService transportService,
ActionFilters actionFilters,
ClusterService clusterService,
Client client,
NamedXContentRegistry xContentRegistry
) {
super(name, transportService, actionFilters, Request::new, client, xContentRegistry);
super(GetTransformAction.NAME, transportService, actionFilters, Request::new, client, xContentRegistry);
this.clusterService = clusterService;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,19 +72,16 @@ public TransportGetTransformStatsAction(
Client client,
Settings settings
) {
this(GetTransformStatsAction.NAME, transportService, actionFilters, clusterService, transformServices, client, settings);
}

protected TransportGetTransformStatsAction(
String name,
TransportService transportService,
ActionFilters actionFilters,
ClusterService clusterService,
TransformServices transformServices,
Client client,
Settings settings
) {
super(name, clusterService, transportService, actionFilters, Request::new, Response::new, Response::new, ThreadPool.Names.SAME);
super(
GetTransformStatsAction.NAME,
clusterService,
transportService,
actionFilters,
Request::new,
Response::new,
Response::new,
ThreadPool.Names.SAME
);
this.transformConfigManager = transformServices.getConfigManager();
this.transformCheckpointService = transformServices.getCheckpointService();
this.client = client;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,33 +91,7 @@ public TransportPreviewTransformAction(
Settings settings,
IngestService ingestService
) {
this(
PreviewTransformAction.NAME,
licenseState,
transportService,
actionFilters,
client,
threadPool,
indexNameExpressionResolver,
clusterService,
settings,
ingestService
);
}

protected TransportPreviewTransformAction(
String name,
XPackLicenseState licenseState,
TransportService transportService,
ActionFilters actionFilters,
Client client,
ThreadPool threadPool,
IndexNameExpressionResolver indexNameExpressionResolver,
ClusterService clusterService,
Settings settings,
IngestService ingestService
) {
super(name, transportService, actionFilters, Request::new);
super(PreviewTransformAction.NAME, transportService, actionFilters, Request::new);
this.licenseState = licenseState;
this.securityContext = XPackSettings.SECURITY_ENABLED.get(settings)
? new SecurityContext(settings, threadPool.getThreadContext())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,35 +69,9 @@ public TransportPutTransformAction(
TransformServices transformServices,
Client client,
IngestService ingestService
) {
this(
PutTransformAction.NAME,
settings,
transportService,
threadPool,
actionFilters,
indexNameExpressionResolver,
clusterService,
transformServices,
client,
ingestService
);
}

protected TransportPutTransformAction(
String name,
Settings settings,
TransportService transportService,
ThreadPool threadPool,
ActionFilters actionFilters,
IndexNameExpressionResolver indexNameExpressionResolver,
ClusterService clusterService,
TransformServices transformServices,
Client client,
IngestService ingestService
) {
super(
name,
PutTransformAction.NAME,
transportService,
clusterService,
threadPool,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,29 +78,16 @@ public TransportStopTransformAction(
TransformServices transformServices,
Client client
) {
this(
super(
StopTransformAction.NAME,
clusterService,
transportService,
actionFilters,
clusterService,
threadPool,
persistentTasksService,
transformServices,
client
Request::new,
Response::new,
Response::new,
ThreadPool.Names.SAME
);
}

protected TransportStopTransformAction(
String name,
TransportService transportService,
ActionFilters actionFilters,
ClusterService clusterService,
ThreadPool threadPool,
PersistentTasksService persistentTasksService,
TransformServices transformServices,
Client client
) {
super(name, clusterService, transportService, actionFilters, Request::new, Response::new, Response::new, ThreadPool.Names.SAME);
this.threadPool = threadPool;
this.transformConfigManager = transformServices.getConfigManager();
this.persistentTasksService = persistentTasksService;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,33 +74,16 @@ public TransportUpdateTransformAction(
Client client,
IngestService ingestService
) {
this(
super(
UpdateTransformAction.NAME,
settings,
clusterService,
transportService,
threadPool,
actionFilters,
indexNameExpressionResolver,
clusterService,
transformServices,
client,
ingestService
Request::new,
Response::new,
Response::new,
ThreadPool.Names.SAME
);
}

protected TransportUpdateTransformAction(
String name,
Settings settings,
TransportService transportService,
ThreadPool threadPool,
ActionFilters actionFilters,
IndexNameExpressionResolver indexNameExpressionResolver,
ClusterService clusterService,
TransformServices transformServices,
Client client,
IngestService ingestService
) {
super(name, clusterService, transportService, actionFilters, Request::new, Response::new, Response::new, ThreadPool.Names.SAME);

this.settings = settings;
this.client = client;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,33 +65,9 @@ public TransportUpgradeTransformsAction(
TransformServices transformServices,
Client client,
Settings settings
) {
this(
UpgradeTransformsAction.NAME,
transportService,
actionFilters,
clusterService,
threadPool,
indexNameExpressionResolver,
transformServices,
client,
settings
);
}

protected TransportUpgradeTransformsAction(
String name,
TransportService transportService,
ActionFilters actionFilters,
ClusterService clusterService,
ThreadPool threadPool,
IndexNameExpressionResolver indexNameExpressionResolver,
TransformServices transformServices,
Client client,
Settings settings
) {
super(
name,
UpgradeTransformsAction.NAME,
transportService,
clusterService,
threadPool,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,29 +56,7 @@ public TransportValidateTransformAction(
Settings settings,
IngestService ingestService
) {
this(
ValidateTransformAction.NAME,
transportService,
actionFilters,
client,
indexNameExpressionResolver,
clusterService,
settings,
ingestService
);
}

protected TransportValidateTransformAction(
String name,
TransportService transportService,
ActionFilters actionFilters,
Client client,
IndexNameExpressionResolver indexNameExpressionResolver,
ClusterService clusterService,
Settings settings,
IngestService ingestService
) {
super(name, transportService, actionFilters, Request::new);
super(ValidateTransformAction.NAME, transportService, actionFilters, Request::new);
this.client = client;
this.clusterService = clusterService;
this.transportService = transportService;
Expand Down

0 comments on commit 32934f0

Please sign in to comment.