How to CRUD with JPA if not Jpacontainer

I have a Vaadin7 application in a Wildfly 10, MySQL 5.7.16, Eclipselink JPA 2.6.2 environment, where jpacontainer is heavily used for accessing and modifying a database with many tables and relations.

Using jpacontainer seemed wise at the time mainly due;

  1. there were many examples,
  2. it seemed rather simpler than to understand the other methods, especially CDI or pure JPA,

…until I noticed the
Deprecated!
remark at the
add-on home page
and
Don’t Use (JPA) Container
article.

Added that the container approach is dropped in Vaadin 8, I would like to ask for opinions and help to put me in the right direction about how to implement CRUD properly this time with Vaadin 8 and Wildfly, Eclipselink, MySqL.

Hi,

For Vaadin 7 my reference apps where:

https://github.com/mstahv/spring-data-vaadin-crud
https://github.com/mstahv/jpa-invoicer

I still haven’t found time to upgrade those for Vaadin 8, but the principles are the same.

You also had a questin about “nested properties”. With V7 Viritin you could practically use any kind of nested properties with property names. With Vaadin 8, you can do the same programmatically at lease addColumn(ValueProvider), but I don’t remember right away if you can use nested properties if you declare the columns with property names.

cheers,
matti

Vaadin 8 version of these examples using the Grid rather than the Vritin table would be very helpful, thank you.

Agreed, I’ll try to squeeze time for those upgrades soon.

Any updates on the reference app with Vaadin 8

The invoicer example still isn’t upgraded, but a simpler addressbook example is upgraded to V8:


https://github.com/mstahv/jpa-addressbook