[ZEPPELIN-1354] [WIP] Inject Services#1361
Closed
echarles wants to merge 35 commits intoapache:masterfrom
Closed
Conversation
Conflicts: pom.xml zeppelin-server/src/main/java/org/apache/zeppelin/server/ZeppelinServer.java zeppelin-zengine/src/main/java/org/apache/zeppelin/conf/ZeppelinConfiguration.java
zeppelin-web/pom.xml
Outdated
| </goals> | ||
| <configuration> | ||
| <arguments>build</arguments> | ||
| <arguments>build --force</arguments> |
Member
Author
There was a problem hiding this comment.
nope, bad commit, I will remove this at next push.
Conflicts: zeppelin-zengine/src/main/java/org/apache/zeppelin/conf/ZeppelinConfiguration.java
Contributor
anthonycorbacho
left a comment
There was a problem hiding this comment.
Thank you for bringing the DI foundation to Zeppelin, this is awesome, i left some comment, please check and let me know what you think.
| <slf4j.version>1.7.10</slf4j.version> | ||
| <log4j.version>1.2.17</log4j.version> | ||
| <libthrift.version>0.9.2</libthrift.version> | ||
| <governator.version>1.14.2</governator.version> |
Contributor
There was a problem hiding this comment.
Seems like governator is not used (all import are commented), I think it better to remove it instead of having bunch of commented code.
| public void configure(Binder binder) { | ||
|
|
||
| binder.bind(WebSecurity.class) | ||
| .to((Class<WebSecurity>) conf.getZeppelinWebSecurityClassname()); |
Contributor
There was a problem hiding this comment.
Shall we add Singleton scope here? what do you think?
| webApp.addFilter(org.apache.shiro.web.servlet.ShiroFilter.class, "/api/*", | ||
| EnumSet.allOf(DispatcherType.class)); | ||
|
|
||
| webApp.addEventListener(new org.apache.shiro.web.env.EnvironmentLoaderListener()); |
Contributor
There was a problem hiding this comment.
Wouldnt be cleaner to import org.apache.shiro.web.env and change this line with
webApp.addEventListener(new EnvironmentLoaderListener()); ?
…issues with upcoming jersey2
asfgit
pushed a commit
that referenced
this pull request
May 9, 2018
close #83 close #86 close #125 close #133 close #139 close #146 close #193 close #203 close #246 close #262 close #264 close #273 close #291 close #299 close #320 close #347 close #389 close #413 close #423 close #543 close #560 close #658 close #670 close #728 close #765 close #777 close #782 close #783 close #812 close #822 close #841 close #843 close #878 close #884 close #918 close #989 close #1076 close #1135 close #1187 close #1231 close #1304 close #1316 close #1361 close #1385 close #1390 close #1414 close #1422 close #1425 close #1447 close #1458 close #1466 close #1485 close #1492 close #1495 close #1497 close #1536 close #1545 close #1561 close #1577 close #1600 close #1603 close #1678 close #1695 close #1739 close #1748 close #1765 close #1767 close #1776 close #1783 close #1799
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What is this PR for?
Services like authentication, authorization, security filters... should be injected rather than manually instanciated.
This will allow to give central + finer control and abstracting the functionaly in interface and allow third parties to implement their own functions in with configurable injection points.
For this, I propose to use Guice as injection framework.
What type of PR is it?
Improvement
Todos
What is the Jira issue?
How should this be tested?
Just compile and run
Screenshots (if appropriate)
NA
Questions: