siena

Multiple relationship on play with siena

£可爱£侵袭症+ 提交于 2019-12-25 04:45:25
问题 I'm creating a an entity with 2 one-to-many relationships. An Event has a User field and a Place field. I'm trying to use the automatic-query, but this code always returns an empty list. User user = new User("mauriziopz@gmail.com","Maurizio Pozzobon","01","hash","facebook"); user.insert(); Place place = new Place("posto","bel posto",null,null); place.insert(); Event e =new Event(user,place, "Festa","Questa è una gran bella festa",null,new Date(),(long) 10,false,null); e.insert(); List<Event>

How can I do paging with @OneToMany collections

淺唱寂寞╮ 提交于 2019-12-21 07:04:40
问题 Suppose I have a Post entity and a Comment entity and a one to many relationship: @Entity class Post { ... @OneToMany List<Comment> comments; ... } How can I achieve paging like this: Post post = //Find the post. return post.getComments().fetch(100, 10); // Find the 11th page (page size 10); Is it possible to emulate dynamic paging with @OneToMany collections on top of JPA, or do we have to rewrite the association mechanism of JPA totally ? (e.g. create a PersistentList collection type that

How mature is Ebean or Siena? [closed]

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-09 08:06:54
问题 Closed . This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing this post. Closed 6 years ago . In the last time I heard a lot of complaining about hibernate. And indeed I have some painful experiences with hibernate too. So I read about Ebean and Siena. Both have interesting approaches. Unfortunately, database access layers are very easy to write, but if your project

How can I do paging with @OneToMany collections

白昼怎懂夜的黑 提交于 2019-12-03 23:04:19
Suppose I have a Post entity and a Comment entity and a one to many relationship: @Entity class Post { ... @OneToMany List<Comment> comments; ... } How can I achieve paging like this: Post post = //Find the post. return post.getComments().fetch(100, 10); // Find the 11th page (page size 10); Is it possible to emulate dynamic paging with @OneToMany collections on top of JPA, or do we have to rewrite the association mechanism of JPA totally ? (e.g. create a PersistentList collection type that could manage the paging, sorting and searching). P.S.: I recently found the Play! framework uses a very

How mature is Ebean or Siena? [closed]

谁说我不能喝 提交于 2019-12-03 09:33:06
Closed . This question is opinion-based. It is not currently accepting answers. Learn more . Want to improve this question? Update the question so it can be answered with facts and citations by editing this post . In the last time I heard a lot of complaining about hibernate. And indeed I have some painful experiences with hibernate too. So I read about Ebean and Siena . Both have interesting approaches. Unfortunately, database access layers are very easy to write, but if your project grows and you have to handle great database-tables, you know if they are good or not. So it's really difficult

How to reduce the memory usage of Appstats on Google App Engine Java

拟墨画扇 提交于 2019-11-30 09:08:37
问题 This is related to question Java Appengine APPSTATS causing java out of memory error. Appstats seems to cause a java.lang.OutOfMemoryError on 128MB instances and I wonder whether there are ways to reduce the amount of logging. Is there a way to filter some package names from the stack trace? GAE API: @14ms memcache.Get real=7ms api=0ms Stack: com.google.appengine.tools.appstats.Recorder:290 makeAsyncCall() com.google.apphosting.api.ApiProxy:184 makeAsyncCall() com.google.apphosting.api

How to reduce the memory usage of Appstats on Google App Engine Java

余生颓废 提交于 2019-11-29 12:56:33
This is related to question Java Appengine APPSTATS causing java out of memory error . Appstats seems to cause a java.lang.OutOfMemoryError on 128MB instances and I wonder whether there are ways to reduce the amount of logging. Is there a way to filter some package names from the stack trace? GAE API: @14ms memcache.Get real=7ms api=0ms Stack: com.google.appengine.tools.appstats.Recorder:290 makeAsyncCall() com.google.apphosting.api.ApiProxy:184 makeAsyncCall() com.google.apphosting.api.ApiProxy:123 makeAsyncCall() com.google.appengine.api.memcache.MemcacheServiceApiHelper:104 makeAsyncCall()