-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Druid authentication/authorization on router's side #73
base: 0.12.1-mmx
Are you sure you want to change the base?
Changes from 1 commit
0af5d8c
d4237cf
517b714
2ad064e
945d752
d047b2c
5619b2f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -219,7 +219,7 @@ public List<? extends Module> getJacksonModules() | |
public static <T> T getInstance( | ||
Injector injector, | ||
String configClassName, | ||
Class<? extends T> isCoordClass, | ||
Class<? extends T> classRunByCoordinator, | ||
Class<? extends T> defaultClass | ||
) throws ClassNotFoundException | ||
{ | ||
|
@@ -229,8 +229,8 @@ public static <T> T getInstance( | |
final T instance = (T) injector.getInstance(Class.forName(configClassName)); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think we exposing too much internals in configs propagating the class names for each sub-component. In fact, we would like a switch like There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This will require refactoring current DI of the module There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. That works for testing, but it's awkward for production. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Agree, this might be improved There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Let's add it to the issue we create for #73 (comment) |
||
return instance; | ||
} | ||
if (isCoordClass != null && isCoordinator(injector)) { | ||
return injector.getInstance(isCoordClass); | ||
if (classRunByCoordinator != null && isCoordinator(injector)) { | ||
return injector.getInstance(classRunByCoordinator); | ||
} | ||
if (defaultClass != null) { | ||
return injector.getInstance(defaultClass); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,6 +21,7 @@ | |
|
||
/** | ||
* Noop basic authenticator cache notifier. | ||
* No notification is sent on user udpate. | ||
* Might be used as a config option to override default authenticator cache notifier. | ||
*/ | ||
public class NoopBasicAuthenticatorCacheNotifier implements BasicAuthenticatorCacheNotifier | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why this class is needed? It's not used in this PR. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It is needed on a config level There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Would be nice to specify whether "noop" means "no auth" or "always rejecting auth". |
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,6 +21,7 @@ | |
|
||
/** | ||
* Noop basic authorizer cache notifier. | ||
* No notification is sent on user/role udpate. | ||
* Might be used as a config option to override default authorizer cache notifier. | ||
*/ | ||
public class NoopBasicAuthorizerCacheNotifier implements BasicAuthorizerCacheNotifier | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I also removed the same classes from test scope so this class is used in tests now There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same |
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I intended that "of user/role managers, caches and notifiers" is retained - please fix the upstream PR.