Tuesday Jan 27, 2015
Monday Jan 26, 2015
By reza_rahman on Jan 26, 2015
My former colleague at Oracle and fellow Java EE advocate Arun Gupta has been up to something pretty cool - what he calls "Java EE Hanginars". The idea is essentially to have a series of webinars on various Java EE topics using Google Hangout. The format is also a bit different - the idea is to be more code and Q & A centric rather than lecture centric. He gathers a set of questions from the community on the topic before the webinar for live discussion. Thus far he has had good success covering a number of topics including Hibernate OGM, OSGi, jOOQ and CI/CD using Java EE. You can find all of the webinars thus far here. For the fifth webinar in the series, it's now my turn :-).
I'll be talking about a topic that's been near and dear to me as a former Java EE architect/consultant for a while - Java EE and DDD (Domain-Driven Design). The Java EE part is probably obvious to most of you, but the DDD part may or may not be. DDD is an architectural style that strongly emphasizes reflecting the business domain in software development. Though there are some superficial similarities with the classical J2EE design patterns, in my view DDD is a cleaner, more modern and more OO centric design paradigm. Interestingly DDD concepts like the bounded context are becoming increasing important in determining sensible application partitioning amongst the microservices hype of the day. I think Java EE is actually an excellent fit for DDD (and vice versa). To demonstrate how marrying Java EE and DDD is done, I started a small side project a few years ago at Oracle named Cargo Tracker. As a nice (somewhat intended) side-effect the project is actually a good non-trivial example of a working Java EE (7) application. Do feel free to check out the linked site if this intrigues you.
During the webinar, I hope to go over a little bit of the very basics of DDD, demo cargo tracker, show some key code and answer questions. If so inclined, you could add your own questions here. The webinar will start a few minutes before 10 AM Pacific Time (PT) on Thursday January 29th. You should join live here. Hope to see you there?
Please note that any views expressed here are my own only and certainly does not reflect the position of Oracle as a company.
Friday Jan 23, 2015
By reza_rahman on Jan 23, 2015
While some people miss this point, one of the key goals of introducing CDI into Java EE was to easily enable integrating solutions outside the standard into the platform. I was recently reminded of this myself when I saw the announcement that Vaadin now officially supports CDI and Java EE.
Another great GWT based Java web framework worth checking out that works with CDI and Java EE is Errai.
Friday Dec 12, 2014
By reza_rahman on Dec 12, 2014
On behalf of the GlassFish and Java EE team at Oracle I wish you and your family Season's Greetings and a very Happy New Year!
I am very happy to say this has been yet another busy and eventful year for us. We finished the community survey effort to help drive the agenda for Java EE 8 and GlassFish 5; we released GlassFish 4.1 with support for Java EE 7, CDI 1.2, WebSocket 1.1 and Java SE 8; we released WebLogic 12.1.3 with support for WebSocket, JSON-P, JAX-RS 2, JPA 2.1 and Java SE 8; we officially launched the Java EE 8 JSRs; we are now in the process of spinning up Adopt-a-JSR for Java EE 8. We are ever thankful for your support and we hope to continue to try our best to serve your interests, perhaps against what many would consider pretty tall odds.
As you know, I and my colleague David Delabassee are the primary maintainers of this blog with some occasional help from folks like Bruno Borges and John Clingan. Both David and I will be enjoying some well-earned time-off with our families the next few weeks. As a result the guns will be mostly quiet at this particular Java bulwark to return recharged and full force in the new year. Others on our team will continue to work hard behind the scenes towards the goals stated.
Until then, thanks and best wishes once again. We hope to see you next year!
Tuesday Dec 09, 2014
By reza_rahman on Dec 09, 2014
JavaOne 2014 San Francisco was held September 28 – October 2. I think this was a particularly good year for JavaOne in many ways and it's certainly been a privilege to try to do justice to the crucial role of Java EE track lead (a role I took on for the first time this year). I'd like to share my thoughts, observations and experiences at JavaOne 2014 from that perspective. We did a few things differently this year that seemed to have paid off fairly well.
Besides helping organize the conference, I pitched in the keynote demo, scouted as many Java EE sessions as I could in my track and led a few sessions. More details on all of this, including thoughts, analysis, slide decks and code, is posted on my personal blog.
Tuesday Nov 04, 2014
By David Delabassee-Oracle on Nov 04, 2014
Next week (Nov. 10-14), 3.500 Devoxxians from 40 different countries will come to
sunny Antwerp to attend the 13th edition of Devoxx (Belgium). Devoxx covers a broad range of topics ranging from Java SE, Mobile and Web Development, Embedded... to Java on the Server. This year Server-side Java track has very good contents including a good Java EE 8 coverage. Also, this year, you have the possibility to ask, in advance, questions to any of the speaker. For that, just check a session page and click on 'Send a question to the speaker'.
You can check the full Devoxx agenda here but here are the sessions that will discuss Java EE 8.
Java EE 8: let's get concrete by Johan Vos and various Java EE Specification Leads.
Tuesday 09:30 - 12:30 (Room 8)
This University session is fully devoted to Java EE 8. During 3h, various specifications lead will outline, in some details, their plans for Java EE 8. If you are new to Java EE 8, this should be a good introduction!
The Future of MVC in JAX-RS (BoF) with Michal Gajdos
Tuesday at 19:00 - 20:00 (BoF 2)
JCP, Adopt-a-JSR, and You (BoF) with Heather VanCura
Tuesday at 21:00 - 22:00 (BoF 2)
This is not a pure Java EE 8 session per say but some of the discussed points (e.g. Adopt-A-JSR) will be important for Java EE 8.
HTTP 2.0 comes to Java. What Servlet 4.0 means to you by Ed Burns
Wednesday at 14:00 - 15:00 (Room 8)
Java EE Game Changers by David Blevins
Wednesday at 15:10 - 16:10 (Room 8)
The Future of Java in the Enterprise (Bof) with Anatole Tresch et al.
Wednesday at 20:00 - 21:00 (BoF1)
A first look at JSON-B and JSON-P 1.1 by Martin Grebac and David Delabassee
Thursday at 17:50 - 18:50 (Room 4)
The path to CDI 2.0 by Antoine Sabot-Durand
Friday at 09:30 - 10:30 (Room 5)
MVC 1.0 (JSR 371) by Manfred Riem
Friday at 10:45 - 11:45 (Room 4)
And this is just for Java EE 8! Here are some other Java EE related sessions that are worth to mentions too.
Three hours to build a Java EE application (Hands-on Lab) by Antonio Goncalves et al.
Tuesday at 09:30 - 12:30
Going farther with CDI 1.2 by Antoine Sabot-Durand
Tuesday at 13:30 - 16:30 (Room 5)
Concurrency in Enterprise Java by Alexander Heusingfeld
Wednesday at 16:40 - 17:40 (Room 7)
Pico Services with Java EE 7 on Java 8 and Docker by Adam Bien
Wednesday at 12:00 - 13:00 (Room 8)
Pushing Java EE outside the Enterprise Space: Home Automation by David Delabassee
Thursday at 14:00 - 15:00 (Room 7)
50 JMS 2.0 Best Practices in 50 Minutes by Nigel Deakin
Thursday at 16:40 - 17:40 (Room 4)
Again, this is just an overview, make sure to check full agenda here.
Also, we are still working on the details but do expect some Java EE 8 coverage during the Devoxx Hackergarten.Will I see you next week at Devoxx?
Monday Oct 27, 2014
By reza_rahman on Oct 27, 2014
ORM is a by and large proven technique that has been around for a long time now (believe it or not TopLink was created in the early nineties for Smalltalk and then ported to Java). It maximizes code flexibility and database independence while minimizing boilerplate code and allowing the construction of rich domain models. Even for relatively complex domain models and queries, ORM engines tend to generate better quality SQL optimized to the underlying database than the average Java developer would with considerable time and effort. This is precisely why JPA is the persistence standard for Java EE and why a majority of modern server-side applications use ORM (indeed almost every other major development platform including .NET and Ruby on Rails positions ORM as it's default persistence solution).
That being said, there can certainly be cases where using hand-written native SQL is necessary or desirable. Most people don't seem to realize it, but JPA has always included very good support for native queries to meet these use cases (JPA 2.1 now even includes formal support for stored procedures - the ultimate form of database bound query execution). If you weren't aware of this, you should definitely read Taudo Wenzel's excellent write-up on using JPA native queries to generate reports (a common use case for native queries).
In fact you have other options for native SQL centric persistence in Java EE applications. One of the nicest ones is MyBatis-CDI. It provides a very nice CDI based abstraction for MyBatis, making it extremely easy to use in Java EE applications (in case you are wondering MyBatis is the successor to the old iBatis project). Here is how simple MyBatis CDI code can look like:
In addition to JTA transactions, MyBatis-CDI also supports local transactions. I've personally also successfully used Apache Commons DbUtils with CDI to quickly port over a legacy application with tons of hand-written SQL to Java EE/GlassFish.
Thursday Oct 16, 2014
By David Delabassee-Oracle on Oct 16, 2014
- VTS America : November 18th, 2014 – 9am to 12:30pm PST
- VTA Asia : November 19th, 2014 – 10:00am to 1:30pm IST
- VTS Europe : November 26th, 2014 – 9am to 12:30pm GMT
Friday Oct 10, 2014
By BrunoBorges-Oracle on Oct 10, 2014
At JavaOne 2014, there were several sessions covering Java EE topics. One of the most expected features in Java EE 8 is the JSON Binding API. Martin Grebac from the Expert Group shared his slides with the proposals (yes, lots of code already!) for this API and also details how you can participate and be involved in the development and specification process for JSR 367 - JSON-B.
Get the slides now from JavaOne 2014 (PDF) and follow these links below to participate:
Wednesday Oct 08, 2014
By David Delabassee-Oracle on Oct 08, 2014
"The only thing that interferes with my learning is my education." (Albert Einstein)
The Java EE 7 Tutorial is one of the lesser-known gem. It is an extensive tutorial that covers the Java EE platform and its different APIs. The nearly 1.000 pages of the Tutorial might looks a bit daunting for newcomers. But let's be clear, one doesn't have to go through the complete tutorial! The tutorial has been structured in a way to make it easy to learn specific aspects of the platform. And last but not least, the Tutorial also covers more advanced parts of the platform such as JCA for example. In short, the Java EE Tutorial is a great ressource to learn the Java EE platform at large but also learn more specific aspects of Java EE. The tutorial comes in 3 flavours, a free online version and free PDF version but also a 2 tomes based books edition (paper & Kindle version).
The Tutorial also bundles many samples that demonstrate specific API but also a few sample applications that shows how to use and combine the different API's to build a complete application. The samples can be download from the SVN repository but also using the GlassFish update center. The following short screencast shows how to install the samples in NetBeans using the GF update center. It's easy, the samples are just a few clicks away!
It should be mentioned that that the Tutorial and its samples have been recently updated for the release of GlassFish 4.1 (see here for more details).
And if you find any issue on the Tutorial or on one if its samples, please make sure to fill a Jira ticket. That input is valuable to continue to maintain and improve the Java EE Tutorial!
Tuesday Sep 09, 2014
By John Clingan-Oracle on Sep 09, 2014
GlassFish Server 4.1 Open Source Edition is available for download! This release of the world's first Java EE 7 application server includes multiple new and valuable features and updates. Here is a quick look at what's new:
- Updated Platform Support. This release adds support for Java 8, CDI 1.2, and WebSocket 1.1. GlassFish, the world's first Java EE 7 application server, maintains leading compatibility with the latest Java EE specifications.
- Improved Developer Experience.While GlassFish 4.1 remains an open-source
only release, quality and a productive developer experience remain a key focus. GlassFish Server is made up of over 20 sub-projects (like Tyrus, Jersey, Weld, EclipseLink, and more). Each of these projects adds features and bug fixes, over 1,000 in all! Thanks to those developers who
participated in the GlassFish 4.1 FishCAT program to make GlassFish even better! A special shout out to Joonas Lehtinen, who found a bug that caused GlassFish to fail to boot on Mac OS X 10.10 (Yosemite)!
- New Features. Here's a list of some of the most important updates in this release.
- Tyrus (WebSocket 1.1 RI). Now supports the
WebSocket 1.1 specification, which adds a couple of APIs for improved
support for Lambda expressions. Tyrus adds some features above and
beyond the specification, like throttling the number of open sessions, metrics
exposed through JMX, client reconnect, proxy support, optimized
broadcasting of a message to all open sockets, and more.
- Jersey (JAX-RS 2.0 RI). Updated with some impressive new features. Jersey brings the OAuth support originally available in Jersey 1.1, and adds a new client-side API for OAuth 1 and 2 support. Jersey has also improved diagnostics with better error reporting, exposes Jersey metrics over JMS, and per-request tracing to a log file or to the HTTP reponse header. Jersey also adds client-side server-sent event reconnect support.
- OpenMQ (JMS 2.0 RI). Open MQ adds support for
communicating over WebSocket. There are two types of WebSocket clients
that are supported. First, mqstomp, which adds support for any WebSocket
client that supports the STOMP 1.2 protocol. Second, mqjsonstomp, which
enables a (WebSocket) client to send JSON formatted messages using the
STOMP 1.2 protocol.
- Java EE 7 SDK. The Java EE 7 SDK has been updated to make it more approachable
overall. First, it is shipped as a zip bundle, offering a very simple installation
process. The SDK also bundles GlassFish 4.1 and now supports Java 8. Last, the Java
EE 7 SDK bundle includes updates to both the Java EE 7 Tutorial and Java EE 7 First
- [Update] Netbeans 8.0.1 available for download; bundles GlassFish 4.0.1.
Wednesday Aug 13, 2014
By reza_rahman on Aug 13, 2014
It is disappointing to come across the occasional mindset that Java EE somehow limits you to using only what is in the standard and nothing more. This is really not the case now and never was. Java EE is intended to provide a stable, open, compatible and reliable core that the ecosystem can build upon without the risks of vendor lock-in or monopolies. The idea is to provide a seamless platform that just works for the vast majority of cases. The ecosystem on the other hand is free to innovate and extend much farther beyond the standard core, ideally to cover every reasonably conceivable use case. The standard can then draw from well understood, successful use cases and bring those back into the core. To this end, almost every Java EE API today is designed with extensibility in mind. In fact, extensibility through CDI and CDI portable extensions in particular was a core goal for Java EE 6.
DeltaSpike is one of the projects that demonstrates these principles in action. For those unaware, it is a consolidation of Seam 3, Apache CODI and a few smaller projects. It is a set of portable CDI extensions that provide useful features for Java EE applications. In fact, the DeltaSpike team has already been instrumental in standardizing some of the innovative changes in Java EE 7. The project just released version 1.0 and it is a great time to check it out if you haven't done so already. Veteran Java EE advocate Arun Gupta has an excellent write-up on DeltaSpike 1.0.
Here are just some of the things that are in DeltaSpike 1.0 right now:
- Many Java EE 7 features that you can use in Java EE 6 such as @Transactional, @TransactionScoped, CDI support in bean validation/JSF converters, @ViewScoped in CDI and so on.
- An excellent higher level abstraction for reducing boilerplate in JPA based repositories.
- A simplified, pluggable security framework for Java EE.
- Simple integration with Quartz 2.
- Injecting common Servlet objects.
- Many, many more...
A great place to start is actually the excellent DeltaSpike site. The project is almost entirely community driven, completely vendor-neutral and very friendly to contributors. DeltaSpike was nominated for the Duke's Choice Awards this year - they certainly deserve to win.
Thursday Aug 07, 2014
By reza_rahman on Aug 07, 2014
While a lot of folks (our team included) spend most of their efforts spreading the good word on Java EE 7 and now increasingly Java EE 8, sometimes it helps to get back to the basics. This is especially true for beginners to Java EE and GlassFish. This point is fortunately not lost on Andrew Pielage of C2B2 consulting (the good folks that run the London GlassFish user group). In this extremely well written blog post Andrew explains step-by-step how to write, deploy and run a very simple web application using GlassFish 4 and NetBeans. He uses Windows in his instructions and I know that will actually be helpful to many of you since most corporate desktop environments still standardize on Windows.
If you know someone who could benefit from the nicely done entry, do make sure to share it. As such, there's few write-ups out there that are so basic and yet so incredibly helpful to the right person.
Tuesday Aug 05, 2014
By David Delabassee-Oracle on Aug 05, 2014
Welcome to the second installment of the JCP news focused on the server side. And despite the summertime, July has been a busy month!
We now have the first Java EE 8 component JSR: JSR 365 (Contexts and Dependency Injection for Java 2.0). The CDI 2.0 JSR has passed the review ballot so the EG can now be formed and start the technical work. Check here to see what the CDI 2.0 plans are.
Those 5 JSRs (CDI 2.0, JMS 2.1, Servlet 4.0, JSF 2.3 and JSONB) are targeted for inclusion in Java EE 8. We are still in the early days but we can now start to see a path towards Java EE 8!
On the Java EE 7 front, JSR 356 has recently passed the maintenance release ballot : Java API for WebSocket 1.1. The upcoming GlassFish 4.1 (Java EE 7 Reference Implementation) should include a Tyrus release (JSR 356 RI) that supports WebSocket 1.1.
In July, ZEEF has joined the JCP as a Corporate Member, Zeef will be represented by Arjan Tijms who is well known in the Java EE community. I am sure Arjan's knowledge on security, JSF and Java EE in general will be extremly valuable!
Monday Jul 28, 2014
By reza_rahman on Jul 28, 2014
For the Java EE track at JavaOne 2014 we are highlighting some key sessions and speakers to better inform you of what you can expect, right up until the start of the conference.
To this end we recently interviewed David Blevins. Although not as well known as some of the other folks in the Java EE community, David has been instrumental in the ecosystem for a very long time. He has been the powerhouse developer behind the innovative OpenEJB project and a key committer on many other Java EE related Apache projects including OpenWebBeans. Over the years he has ardently advocated for Java EE and directly contributed to many Java EE expert groups including EJB 3.1, EJB 3.2, Java EE 6 and Java EE 7. More recently he launched Apache TomEE - a project that turns the Tomcat vs Java EE debate on it's head by creating a Java EE certified application server squarely focused on Tomcat users. David is also a JavaOne Rock Star. We are very honored to have David speak at JavaOne and interview him on his sessions this year:
David has several key sessions on the track:
- Java EE Game Changers: It never fails to surprise me how many pretty intelligent folks still associate Java EE with J2EE (a technology now more a decade in the past). Many of these folks don't realize just how much has changes especially since Java EE 6 and certainly as of Java EE 7 and beyond. This session is primary geared towards these folks and outlines why Java EE and the JCP today is a fundamental game changer. You probably should attend even if you are already a Java EE fan - besides covering key evolutions David will also cover forward looking ideas that are on his keen radar to keep moving the platform forward.
- Apache TomEE, Java EE Web Profile, and More on Tomcat: If you are a current Tomcat user curious about Java EE, this is a session you shouldn't miss. Using live coding, David will show exactly how the real world Java EE development experience using TomEE looks like. He will also explain the fundamental value proposition of Java EE/TomEE and explain some of the technical details of how TomEE is made possible.
- Java EE 8 Community Update and Panel: This panel is intended to be an open forum for discussing Java EE 8. The panel consists of both some implementors like David/TomEE and some key independent folks in the community. The panel will be moderated by my colleague Bruno Borges. The idea is to encourage panelists to interact with each other and the audience - so bring your questions, comments and ideas!
Besides David's sessions, we have a very strong program for the Java EE track and JavaOne overall - just explore the content catalog. If you can't make it, you can be assured that we will make key content available after the conference just as we have always done.
The early bird offer for JavaOne expires August 1st so if you plan to come to JavaOne it would be wise to register early now and save some money for yourself or your organization. I certainly hope to see you there.
Podcasts & Videos
- JSON-P 1.1/Java EE 8 Webinar at Istanbul JUG
- Asynchronous Support in JAX-RS 2/Java EE 7
- Java API for JSON Binding (JSON-B) 1.0 Early Draft Now Available!
- Java EE @ Chicago Coder Conference 2015
- A new CDI scope in Java EE 8 ?
- A Journey from Tapestry to JSF 2.2 and JavaEE 7
- Submit Now to Win a Duke's Choice Award!
- Adopt-a-JSR/Java EE 8 at Istanbul JUG
- Maven, Java EE and ... NetBeans
- Help Recognize Java Community Process (JCP) Heroes!