DeltaSpike is now providing a Data module allowing to use interface or abstract classes as repositories for JPA (a bit like spring-data). It got recently a new feature aiming to support DTOs pattern.
I’ll just show how to use it on a simple “User” entity in this post.
Working on cassandra store for Apache Sirona (I’ll speak surely of it in another post) I used cassandra-cli to check my persisted data and browse my Cassandra keyspace easily.
However doing a simple ‘list’ (select *) the result looked like the expected one but was not that readable. Even if test data values were not that important the row keys were something crucial in my modelling and tests so I needed to read it (even if my unit tests were green it is always better to validate it twice ;).
Few days ago a user went on #deltaspike IRC channel (on freenode) and asked if there was a replacement for seam rest. There is no one ATM (a bit too early) but this post will show you how simple it is to build a MVC framework based on any template engine you want (velocity for me) and JAXRS.
Resources are something basic in JavaEE but in TomEE and OpenEJB it is quite more powerful than it looks like.