JavaOne 2010 : Java EE 6 Panel “What do we do now?” notes
September 27, 2010 § 1 Comment
I was privileged to be moderating this year’s Java EE panel at JavaOne (session 313278). We had a great list of panelists and a lively discussion. Here are my notes:
Panelists (from left to right)
• Adam Bien (individual)
• Jim Knutson (IBM)
• Emmanuel Bernard (JBoss, Red Hat)
• Reza Rahman (individual, Caucho)
• Krasimir Semerdzhiev (SAP)
• Roberto Chinnici (Oracle, spec lead)
• David Blevins (OpenEJB, Apache Geronimo)
• Alexis MP (Oracle, moderator)
Platform and API Adoption
JBoss is feature-complete (RC1) for the Web Profile, probably final in the Fall. Two more months before Caucho Resin is final. WebSphere is in Beta and WebLogic is working on it (GlassFish of course, has had a full implementation since the spec was released in December 2009).
Jim (IBM): adoption for JSF 2.0 (performance), servlet 3.0 and JPA 2.0 (mappings) seem to be very strong. Also JAX-RS (which unfortunately is not in the web profile and as such not part of the upcoming Resin 4 release). Krasimir (SAP) mentions EJB 3.x. Reza says people are very satisfied after studying Java EE 6. In some cases Java EE is back in people’s radar. Emmanuel (JBoss): people like the consistency and tight integration of the platform. David (OpenEJB) : achievements with EJB’s in WARs, singletons, asynch may replace JMS. Roberto (Oracle) on JAX-RS having helped REST become a mainstream technology for Java developers. Adam: migrated all his EAR’s to WAR’s, removed Quartz and replaced it with EJB Timer, removed a bunch of interfaces. RESTful resources as EJB removes layers, this is good. Event model in CDI is maybe one of the best features. Some of Adam’s customers use EJB’s and CDI without knowing that it’s JavaEE which is the best possible sign that they’re focusing on business logic.
CDI is a bit of a special case. Some think that it’s powerful but that this power comes with complexity attached. Adam disagrees in terms of complexity of code (@Inject is really all you need to get started). JBoss/Emmanuel says that people are excited by CDI but portable extensions still not known by most. Jim: not that much demand for the time being, complexity might be causing some people to shy away from it but there is a lot of power there and adoption will come no doubt about it. Reza: the fact that it’s part of the web profile is the reason they’re certifying, also all Resin early adopters are coming for its CDI implementation. Need to re-align more of the platform in Java EE 7. Adam: CDI is like insurance, if there’s a need for integrating additional frameworks, anything’s possible with portable extensions, yet 90% of the projects don’t need it. SAP: CDI is great but some people still haven’t gotten their heads around Java EE 5 yet.
Java EE vs. Spring
Adam: I would never put Spring and Java EE together because there’s too much overlap. Also from a business point of view, you’d need support from two companies (Spring and AS vendor) which typically don’t like each other, so that’s a big risk. Reza: there are a several reasons to integrate both: gradual migration, leveraging Spring’s work (integration APIs). Adam replies that for new applications, there really should only be one as the injection styles overlap too much. IBM says it’s hard to align technologies like Spring with the specification planing requirements, in particular JSR 330 does not quite allow for the integration of Spring, using a CDI-style of injection will offer greater fidelity. EE needs more work there. David Blevins says they’re looking at a Guice implementation of CDI. Krasimir agrees that many projects do start from scratch so Java EE is the right choice.
Impact on tooling and testing
Krasimir: EJBContainer is a huge step forward. Emmanuel: tooling should help the developer and not be a requirement. For testing, JBoss has the Arquillian project (sort of next-generation Cargo), also works with GlassFish. David: would be neat to be able to inject resources in test code (OpenEJB working on that). Reza says trend in JavaEE is towards annotation and being more Java-centric (type-safe). Resin has no tooling plans but will integrate with Arquillian and is also developing and end-to-end testing solution. Adam: just use APIs, wizards are always suspicious and prevent people from using different tools (often the case in projects). Still looking for good unit tests (currently using junit 4, jmock, mockito). OpenEJB and GlassFish embedded help too. Roberto says that tools are also there to help people learn (NetBeans has a lot in store for that). Wizards also now produce clean annotation-based code if you decide to use them. Krasimir: tools are key because this is how most people experience and use the platform so they need to improve on a regular basis. Calling people to contribute to Eclipse. IBM: tooling evolved mainly in EE 5. Now more coverage with EE 6.
Questions from the audience
• CDI vs. JSF annotations (@ManagedBeans for instance) ? => Need to streamline some of this in future releases. CDI beans build on top of JSR 250 ManagedBeans. Need more of that throughout the platform.
• SpringMVC and CDI? => Technically possible: use CDI beans as controllers (but Reza says they’re not seeing enough demand for SpringMVC to do the work).
• Java EE vs. Spring? => Reza: different approaches, make your own decision. Jim: don’t reap out what works well. David: chose the platform you believe in and that will listen to you in the long run.
Roberto (see also his technical keynote for details): Cloud as a focus, modularity as enabler (built on top of what JDK will offer). Also need to track emerging technologies (WebSockets, HTML 5). Need to evolve the specification and not let it up to vendors to implement. Jim: JavaEE can mostly run in the cloud today, bigger problem is dealing with putting large app together: need a modules system. Krasimir: really wanted modules to be there in EE 6 so couldn’t agree more. David: more generalization of the various annotations across the platform. Reza: modularity can’t be the only value-proposition of EE.next, also need realignment of underlying technologies.
Java EE 6 is here today, go ahead and try it out!