In September, we saw the release of MicroProfile 1.0. It is a exploration looking at a vendor-neutral, lightweight baseline set of technologies to offer Java EE for a microservices architecture. On 25th February, author of three books on JavaEE Antonio Goncalves will be speaking at Voxxed Days CERN. He will demonstrate how MicroProfile fits in a microservice architecture with an Angular front-end. We interviewed Antonio to find out what we can expect from his talk, and what he would like to see next with MicroProfile.
What can attendees expect to learn from your session?
They will learn what happens when you have several microservices written in Java (Wildfly Swarm) on the back-end, with a single Angular front-end. For example, which APIs format to expose, how to document them and how to use Hateoas to simplify the life of the front-end or CORS to make it work. Of course, when you deal with a complex distributed architecture, there comes the time when you need to log on and be authenticated. So I’ll show how to use JSON Web Token. Plus bits and pieces such as optimizing calls with Cache Control or ETags. All that with a bit of Docker, Traefik and Consul.
What would you like to see happen with the MicroProfile initiative?
The MicroProfile is doing great as it is focusing on the 1.1 release. It will add configuration and health-check functionality. Quickly it will solve other concerns such as circuit-breaker, service discovery or JWT and OAuth support. Personally I would like to see CDI (Context & Dependency Injection) as the programming model for the MicroProfile, and also a TCK (Technology Compatibility Kit) so we are sure that all implementations will be compatible.
Why do you think Angular is a good fit for MicroProfile applications?
What kind of projects will benefit the most from using a MicroProfile application?
It’s actually perfect for Java EE monolith applications you are trying to split apart. When you have developed with Java EE for years, you don’t want to lose this experience by jumping into a new language, a new platform, and forget about your expertise. With MicroProfile you can leave what you don’t need (eg. EJBs, IIOP), focus on what you know (JAX-RS, JSON-P, CDI) and learn what you need: microservice architectures embrace new patterns and some are quite challenging. And if you are a Java EE expert, you already know about distribution (the genesis of EJB), you already know about clustering (stateless vs stateful), load balancing or failover, you already know about discovery (JNDI), you already know most of these architectural patterns that are so fashionable today. So MicroProfile is perfect for you to both be trendy, and use your expertise.