Back in June, I was in San Francisco at RedHatâ€™s DevNation 2016 to launch MicroProfile. Since then, I’ve been talking about MicroProfile at JavaOne 2016 and, soon, also at Devoxx Belgium 2016 but it’s been a while since I wrote about it here.
— Edson Yanaga (@yanaga) June 27, 2016
What is MicroProfile?
The MicroProfile is an initiative that is supported by many people from the Java EE community, as well as key Enterprise Java vendors IBM, RedHat, Tomitribe, and Payara.
— Martijn Verburg (@karianna) September 19, 2016
The first release of MicroProfile was announced at JavaOne and simply brought together a foundation consisting of CDI, JAX-RS, and JSON-P. Since then, multiple threads of discussion have been going on, such as:
- Moving MicroProfile to the Eclipse Software Foundation to enable a neutral third-party to steward the on-going effort
- Discussing new APIs for the MicroProfile, including:
- Security and identity
We’re also creating a sample application and architecture consisting of a set of microservices that run on each of the four vendors’ application servers and collaborate to provide a conference session management application.
MicroProfile and Liberty
Of course, because of how MicroProfile 1.0 has been defined, any Java EE 7-compliant application server is, by definition, MicroProfile-certified. Given the modular architecture of Liberty (enabled by OSGi), we decided we could do better. So, in September this year, we added a
microProfile-1.0 feature to Liberty and a MicroProfile download ZIP package so that you can easily download and enable just what you need to write a MicroProfile-based application.
The MicroProfile is currently defined to be a very small, but powerful, subset of the Java EE 7 specifications. Iâ€™ve been involved in Java EE for a long time, so my goto technologies from Java EE are historically JSP, Servlet, EJB, and JPA. I decided to rewrite one of my existing demo applications to make use of MicroProfile. That application served as the basis of a presentation I did at JavaOne (PDF) with Kevin Sutter about MicroProfile.
I’ll be the first to admit that there are gaps in MicroProfile. Those gaps are things that the MicroProfile initiative hopes to address quickly by doing lots of small iterations.
The sample application solves a real problem that the Liberty development team had. The Liberty development team has a lot of online meetings using IBM Connections Cloud Meetings (and yes IBM really does like long names). IBM Connections Cloud provides meeting rooms to individuals, which is a problem for team meetings if the person who initially set up the meeting room canâ€™t make it (e.g. they were called into another meeting, are on vacation, or sick). So we wrote a simple application that provides a single URL for a meeting, which can then be â€˜startedâ€™ by one person and everyone else gets redirected.
The original version of the application used JAX-RS, EJB, JPA, Concurrency Utilities for Java EE, and WebSockets. In writing this update I also learned that POJO -> REST binding isnâ€™t part of the JAX-RS specification, and I was apparently relying on Jackson (without realising it). So I switched to using JSON-P instead.
In coming weeks, I’ll be writing a series of articles in which I will go through the sample, step by step, developing its capabilities by adding just the technologies needed to make it work well.