use of org.apache.druid.server.security.AllowAllAuthorizer in project druid by druid-io.
the class AsyncQueryForwardingServletTest method setupInjector.
@Override
protected Injector setupInjector() {
return Initialization.makeInjectorWithModules(GuiceInjectors.makeStartupInjector(), ImmutableList.<Module>of(new Module() {
@Override
public void configure(Binder binder) {
JsonConfigProvider.bindInstance(binder, Key.get(DruidNode.class, Self.class), new DruidNode("test", "localhost", false, null, null, true, false));
binder.bind(JettyServerInitializer.class).to(ProxyJettyServerInit.class).in(LazySingleton.class);
binder.bind(AuthorizerMapper.class).toInstance(new AuthorizerMapper(null) {
@Override
public Authorizer getAuthorizer(String name) {
return new AllowAllAuthorizer();
}
});
Jerseys.addResource(binder, SlowResource.class);
Jerseys.addResource(binder, ExceptionResource.class);
Jerseys.addResource(binder, DefaultResource.class);
LifecycleModule.register(binder, Server.class);
}
}));
}
Aggregations