spring-guides / gs-crud-with-vaadin

Creating CRUD UI with Vaadin :: Use Vaadin and Spring Data JPA to build a dynamic UI
https://spring.io/guides/gs/crud-with-vaadin
Apache License 2.0
108 stars 141 forks source link

How to handle repository events? #1

Closed rknabe closed 6 years ago

rknabe commented 8 years ago

I have a project using Spring Data JPA and would like to do something similar to what gs-crud-with-vaadin is doing by using the Repository as a data source for vaadin. However, i have business logic in RepositoryEventListeners (AbstractRepositoryEventListener<> instances), eg, onBeforeSave.

The events in Spring data jpa are fired higher up at the web mvc controller level, so using the repository in vaadin like this example would not cause the events to fire.

Any suggestions on how to deal with this?

snicoll commented 6 years ago

Thanks for getting in touch, but it feels like this is a question that would be better suited to Stack Overflow. Feel free to update this issue with a link to the re-posted question (so that other people can find it).