Close

Getting started with Java EE and Spring

One of the most interesting findings in the latest Vaadin Community Survey was that Java EE is used slightly more than Spring Framework among developers. Although the difference between the Java EE and Spring Framework shares is small, if we combine both, we get that 73% of the developers using Vaadin also use either Java EE or Spring Framework:

95cc7858-c061-4e75-9ca6-80b6c0b57b80

The good news for developers is that Vaadin officially supports both Java EE and Spring Framework. Vaadin’s Matti Tahvonen and Petter Holmström recently explained the Dependency Injection alternatives in a webinar and I recently published two videos showing how simple it is to set up a Vaadin project with Java EE and Spring back-ends. Of course, these videos aren’t the only resources available. I’ll talk about some resources for learning Spring and Java EE with Vaadin below.

Java EE + Vaadin

To see Java EE and Vaadin in action, watch this 5 minute video:

Java EE is supported through the Vaadin CDI add-on. You can find the must-read documentation at the docs site. As Java EE includes several APIs specifications, you can use a Compatibility Matrix to check the compatibility of Vaadin with several of these APIs. One way to master CDI is by reading the specification and then putting the concepts into practice. There’s also a Vaadin Framework & Java EE training that focuses on the basics of Java EE and how to use it in Vaadin applications.

Spring + Vaadin

To see how to mix these two frameworks in less than 5 minutes, watch this video:

 

https://vaadin.com/spring is a good starting point if you want to learn about the Vaadin + Spring combination. In short, Spring Framework is supported through the Vaadin Spring (a new release is coming this month) and Vaadin Spring Boot add-ons. The best place to start learning about these add-ons is the docs site. If you like learning by watching videos, you should watch Marcus Hellberg’s video where a full-stack “to do” application is developed from scratch, and this webinar with Stéphane Nicoll and Matti Tahvonen. Alternatively, you can read the guide at spring.io.

Subscribe to the Vaadin YouTube Channel

State of Web Components in real life app development

The collaborative Vaadin, Polymer, and Skate web platform study is almost over and we have some great initial results! After opening one month ago we’ve received over 700 responses from every kind of developer. Architects, managers, hobbyists, students, all answered our fifteen minute survey about Web Components and Progressive Web Apps.

We’re going to run the survey for one more week from the release of this blog post, so fill out the survey and share the link: https://bit.ly/web-survey-2016 .

Interesting Findings

We are planning on doing a more in depth analysis of the data, but here are three big takeaways from our survey.

Lots of people already build with Web Components

74% of respondents have used web components and at least 46% have launched a production app with web components. It’s remarkable that so many people are already building with web components. Developers cite ease of use, quicker development, and less code complexity as why they chose to build with web components.

When answering why they haven’t decided to build with web components, respondents expressed hesitation with immature standards and implementation, and many were concerned with lack of browser support. Many respondents were unhappy with web component polyfills and are waiting for better performance.

But there’s light on the horizon! All major browsers are planned to support most features of web components as early as next year.

Tables of Web Component support from caniuse.com

Progressive Web Apps are coming

33% of respondents have built a Progressive Web App and a full 55% are planning on building their next mobile app as a PWA. It seems that developers are committed to creating high quality web apps that work as well on mobile as they do on desktop.

On the flip side, when asked why they might build a native mobile app instead of a PWA, respondents were most concerned with performance and access to hardware such as bluetooth and accelerometer.

We believe, however, that the web platform will grow to encompass advanced use cases that currently can only be done with a native app.

Bring on the web components!

We asked respondents who use web components which element collections they use. Polymer Elements was used by 85% of respondents and our own Vaadin Elements were used by 23%.

However, 53% of respondents used in-house developed element collections, meaning that they couldn’t find the elements they needed in public collections. Now that web component specifications and libraries have matured, it’s up to developers and companies to create powerful collections of web components.

We’re excited to display all the results of this collaborative survey, so we’re going to run the survey for one more week. Keep following this blog to see our full results soon.

Click here to fill out the survey.

Vaadin Spring 1.1 is out

I’m pleased to announce that a new version of Vaadin Spring is released! The version 1.1 brings a major enhancement for Navigator and View handling, which shaves away a lot of boilerplate code from non-trivial applications that have multiple views.

Spring powered Navigator

The big new feature in Vaadin Spring 1.1 relates to using Navigator and Views in non-trivial Vaadin applications. The new version contains a SpringNavigator class that greatly simplifies the configuration of views.

There is also a new @SpringViewDisplay annotation that can be used to mark the target Vaadin component, where your views should actually be displayed. Together these two new features make it easier to create top level navigation (main layout, navigation and menu) to your non-trivial Vaadin applications.

See this example change set for how much the new API can actually simplify your Vaadin Spring code. Our Vaadin Spring documentation and Spring tutorial are also updated to showcase the new features.

A set of bugs squashed

We have also made a number of important bugfixes, prioritised by our Support customers.

One of the most relevant fixes is related to serialization of http sessions using Vaadin Spring. These fixes, which actually already landed in the 1.0.3 release, now allow using Vaadin Spring in applications which require a HA setup for hosting.

Too see the full set of changes, refer to the release notes and issues closed for milestone 1.1  in the github project.

Fully backwards compatible, upgrade now!

The new release is practically 100% backwards compatible with previous stable releases, so go ahead and upgrade your Vaadin Spring versions to 1.1.0. If you haven’t started your Spring + Vaadin project yet, see the recent Spring Boot webinar and head to start.spring.io, which already use the latest version!

Watch the latest Spring Boot webinar to get started