Uh oh!
There was an error while loading. Please reload this page.
[ZEPPELIN-1354] [WIP] Inject Services - #1361
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
| </goals> | ||
| <configuration> | ||
| <arguments>build</arguments> | ||
| <arguments>build --force</arguments> |
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
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> |
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()); |
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()); |
There was a problem hiding this comment.
Wouldnt be cleaner to import org.apache.shiro.web.env and change this line withwebApp.addEventListener(new EnvironmentLoaderListener()); ?
…issues with upcoming jersey2
close#83close#86close#125close#133close#139close#146close#193close#203close#246close#262close#264close#273close#291close#299close#320close#347close#389close#413close#423close#543close#560close#658close#670close#728close#765close#777close#782close#783close#812close#822close#841close#843close#878close#884close#918close#989close#1076close#1135close#1187close#1231close#1304close#1316close#1361close#1385close#1390close#1414close#1422close#1425close#1447close#1458close#1466close#1485close#1492close#1495close#1497close#1536close#1545close#1561close#1577close#1600close#1603close#1678close#1695close#1739close#1748close#1765close#1767close#1776close#1783close#1799
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: