JPA2 & Vaadin -> Examples?

Hi All

First: Grats for the great work! We are just one step away from choosing Vaadin for a new project. Still, we have some questions:

  1. Does Vaadin work with JPA2 e.g. EclipseLink? Any examples/tutorials?

  2. If yes: Does asynchronous data binding work fine with e.g. EclipseLink?

Thanks & regs

ST

Hi Sascha,

Vaadin does not tie you itself to any particular persistence framework, su you’re feel free to use any one. You only might have to implement Vaadin’s container interfaces to nicely bind data to UI components (however you can just use generic continaers such as BeanItemContainer).

As for JPA - please take a look at
JPA Container add-on
- it just binds JPA data to Vaadin UI components - so it both is a fully functional addon and also can be used as example (see sources)

Oops, just made a post and then noticed that you are intersted in v 2.0 of JPA API… sorry, did not notice it earlier. Maybe JPA Container is in progress for 2.0 support, I think Vaadin folks will say better on the status.

Dmitri

Take a look at the
AppFoundation
and its
persistence module
which uses EclipseLink.

Hi Kim,

Thanks for the great work with appfoundation. I am completely new to vaadin, but with some experience with JPA.

How do I get to use the appfoundation, i mean;

  1. How do I create my entity containers, examples will be great.
  2. How do I set my tables to use JPA as datasource
  3. How do I tie my forms to the JPA datasource.

The example from you repo didnt particularly help me, are there any others?

Thanks
Michael

JPA Criteria Lazy Container works with JPA 2.0; it uses the criteria mode for building queries, however (as opposed to textual JPQL queries).


This blog post
shows how to integrate AppFoundation with LazyQueryContainer. I’ve been cooking up a blog post on how to use the container in an example application, but I’ve yet to finish and release to post.