Make compilation pass.

Note: tests are still failing.

Original commit: elastic/x-pack-elasticsearch@827d129876
This commit is contained in:
Adrien Grand 2016-05-06 09:05:45 +02:00
parent bd04cc9d1f
commit 22c4fb9a32
4 changed files with 12 additions and 7 deletions

View File

@ -105,7 +105,7 @@ public class TransportMonitoringBulkActionTests extends ESTestCase {
clusterService.setClusterStatePublisher((event, ackListener) -> {});
clusterService.start();
transportService = new TransportService(transport, threadPool);
transportService = new TransportService(Settings.EMPTY, transport, threadPool, clusterService.state().getClusterName());
transportService.start();
transportService.acceptIncomingRequests();
exportService = new CapturingExporters();

View File

@ -5,6 +5,7 @@
*/
package org.elasticsearch.shield.transport;
import org.elasticsearch.cluster.ClusterName;
import org.elasticsearch.cluster.node.DiscoveryNode;
import org.elasticsearch.common.inject.Inject;
import org.elasticsearch.common.settings.Settings;
@ -22,8 +23,9 @@ public class ShieldClientTransportService extends TransportService {
private final ClientTransportFilter clientFilter;
@Inject
public ShieldClientTransportService(Settings settings, Transport transport, ThreadPool threadPool, ClientTransportFilter clientFilter) {
super(settings, transport, threadPool);
public ShieldClientTransportService(Settings settings, Transport transport, ThreadPool threadPool,
ClusterName clusterName, ClientTransportFilter clientFilter) {
super(settings, transport, threadPool, clusterName);
this.clientFilter = clientFilter;
}

View File

@ -5,6 +5,7 @@
*/
package org.elasticsearch.shield.transport;
import org.elasticsearch.cluster.ClusterName;
import org.elasticsearch.cluster.node.DiscoveryNode;
import org.elasticsearch.common.inject.Inject;
import org.elasticsearch.common.settings.Settings;
@ -55,12 +56,13 @@ public class ShieldServerTransportService extends TransportService {
@Inject
public ShieldServerTransportService(Settings settings, Transport transport, ThreadPool threadPool,
ClusterName clusterName,
AuthenticationService authcService,
AuthorizationService authzService,
ShieldActionMapper actionMapper,
ClientTransportFilter clientTransportFilter,
SecurityLicenseState licenseState) {
super(settings, transport, threadPool);
super(settings, transport, threadPool, clusterName);
this.authcService = authcService;
this.authzService = authzService;
this.actionMapper = actionMapper;

View File

@ -6,6 +6,7 @@
package org.elasticsearch.shield.transport;
import org.elasticsearch.cluster.service.ClusterService;
import org.elasticsearch.cluster.ClusterName;
import org.elasticsearch.cluster.node.DiscoveryNode;
import org.elasticsearch.common.inject.AbstractModule;
import org.elasticsearch.common.inject.Inject;
@ -307,9 +308,9 @@ public class TransportFilterTests extends ESIntegTestCase {
@Inject
public InternalPluginServerTransportService(Settings settings, Transport transport, ThreadPool threadPool,
AuthenticationService authcService, AuthorizationService authzService, ShieldActionMapper actionMapper,
ClientTransportFilter clientTransportFilter) {
super(settings, transport, threadPool, authcService, authzService, actionMapper, clientTransportFilter,
ClusterName clusterName, AuthenticationService authcService, AuthorizationService authzService,
ShieldActionMapper actionMapper, ClientTransportFilter clientTransportFilter) {
super(settings, transport, threadPool, clusterName, authcService, authzService, actionMapper, clientTransportFilter,
mock(SecurityLicenseState.class));
when(licenseState.authenticationAndAuthorizationEnabled()).thenReturn(true);
}