JavaPins - Stories tagged with JPA
1
Pins

Hibernate and JPA guidelines [part 1] « Java Team at Kentor

published 508 days, 5 hours, 38 minutes ago posted by anujaanuja 539 days, 12 hours, 21 minutes ago
Tuesday, November 27, 2012 2:24:55 PM GMT Saturday, October 27, 2012 7:41:49 AM GMT
I recently had a cooperation with some colleagues from the Oracle team, putting together a document with some guidelines and tips for working with Hibernate/JPA and Oracle from a performance point of view. I decided to take some of these general guidelines and tips for Hibernate/JPA to do a three part serie with blogposts here on our blog. Each topic is divided into three parts; problem, suggestion and value. Each topic evolves from a identified problem and then makes a suggestion for dealing with the pr... (more)
category: ORM | clicked: 19 | comment | | source: kentorjava.com
tags: guidelines, Hibernate, Java, JPA, Performance
1
Pins

Hibernate and JPA guidelines [part 3] « Java Team at Kentor

published 508 days, 5 hours, 38 minutes ago posted by anujaanuja 539 days, 12 hours, 22 minutes ago
Tuesday, November 27, 2012 2:24:55 PM GMT Saturday, October 27, 2012 7:40:43 AM GMT
This is the last post of three with Hibernate/JPA guidelines. This post consists more of some tips and trix rather then general guidelines. As I wrote in previous posts each topic is divided into three parts; problem, suggestion and value. All topics evolves from a identified problem and then makes a suggestion for dealing with the problem and a value for what benefits you get from using the suggestion. Solving LAZY FetchType for OneToOne relations (more)
category: ORM | clicked: 3 | comment | | source: kentorjava.com
tags: guidelines, Hibernate, Java, JPA, Performance
1
Pins

Improve your life Through Science and Art: JEE6: JSF + JPA - EJB = More Code

published 585 days, 8 hours, 1 minute ago posted by anishaanisha 586 days, 1 hour, 29 minutes ago
Tuesday, September 11, 2012 12:01:13 PM GMT Monday, September 10, 2012 6:33:38 PM GMT
Without an EJB you will need for every EntityManager interaction at least 4 lines of code: 1.trx.begin 2.EntityManager interaction 3.trx.commit 4.consistent error handling + trx.rollback (more)
category: Java EE | clicked: 5 | comment | | source: tamanmohamed.blogspot.in
tags: EJB, JEE6, JPA, JSF
1
Pins

Improve your life Through Science and Art: JPA: Locking mechanisms in JPA 2

posted by anishaanisha 586 days, 23 hours, 33 minutes ago
Sunday, September 09, 2012 8:29:13 PM GMT
JPA 2 supports both optimistic locking and pessimistic locking. Locking is essential to avoid update collisions resulting from simultaneous updates to the same data by two concurrent users.Optimistic locking is applied on transaction commit. Any database object that has to be updated or deleted is checked. (more)
category: Java EE | clicked: 1 | comment | | source: tamanmohamed.blogspot.in
tags: JPA, locking mechanism
1
Pins

Improve your life Through Science and Art: JPA: Injection level-types in JavaEE5+

posted by anishaanisha 586 days, 23 hours, 49 minutes ago
Sunday, September 09, 2012 8:13:33 PM GMT
There are 3 types of resource injections in JavaEE in the order of usage frequency: Field injection.Setter injection.Type-level injection.  Unlike field and setter injections, type-level injections are not really injection. It does not inject anything into anywhere; it just declares a resource reference in a descriptor-free manner. (more)
category: Java EE | clicked: 0 | comment | | source: tamanmohamed.blogspot.in
tags: java EE5, JPA, type level injection
1
Pins

Improve your life Through Science and Art: JPA: Why we need to specifies the type-level injections in JavaEE?

posted by anishaanisha 586 days, 23 hours, 50 minutes ago
Sunday, September 09, 2012 8:12:32 PM GMT
As I wrote in the Injection level-types in JavaEE5+, JavaEE type-level injection is more verbose than field and setter injections. So why don't we just all use the simple field or setter injections? Well, there are sometimes a type-level injection is more appropriate (more)
category: Java EE | clicked: 1 | comment | | source: tamanmohamed.blogspot.in
tags: JavaEE, JPA, type level injection
1
Pins

Improve your life Through Science and Art: JPA: Thread-safety when injecting EntityManager

posted by anishaanisha 586 days, 23 hours, 51 minutes ago
Sunday, September 09, 2012 8:11:30 PM GMT
As I wrote in post Why we need type-level injections in JavaEE, injecting EJB 3 stateful beans into servlet instance fields is not thread-safe. Along the same line, injecting EntityManager with @PersistenceContext into servlet instance variables is not thread-safe, either. EntityManager is just not designed to be thread-safe. (more)
category: Java EE | clicked: 0 | comment | | source: tamanmohamed.blogspot.in
tags: entity manager, JPA, thread safety
1
Pins

Improve your life Through Science and Art: JPA: 2 ways to get container-managed EntityManager in servlet

posted by anishaanisha 586 days, 23 hours, 52 minutes ago
Sunday, September 09, 2012 8:10:38 PM GMT
In Thread-safety when injecting EntityManager post, I wrote about the danger of using field/setter injection to get EntityManager in servlets and compares container-managed EntityManager vs application-managed EntityManager. What if I need a container-managed EntityManager in my servlet class? (more)
category: Java EE | clicked: 0 | comment | | source: tamanmohamed.blogspot.in
tags: JPA, Servelet
1
Pins

Improve your life Through Science and Art: JPA: Query, incompatible types compilation error

posted by anishaanisha 587 days, 1 minute ago
Sunday, September 09, 2012 8:01:47 PM GMT
I have faced a problem while I am writing a generic JPA query like the following: Compile it and you will get the following error in Jdeveloper 11.1.2.1.0 • Error(200,37): incompatible types. (more)
category: Java EE | clicked: 0 | comment | | source: tamanmohamed.blogspot.in
tags: compilation error, JPA, Query
1
Pins

Improve your life Through Science and Art: JPA: Dynamic search builder, the power of annotation, reflection and generics.

posted by anishaanisha 587 days, 6 minutes ago
Sunday, September 09, 2012 7:56:16 PM GMT
JPA (Java persistence API) is a powerful tool for domain objects mapping, and object oriented view perspective of database. Always I used to use JPA in my projects, but JPA2 introduces extra feature that facilitate the generic way of persisting, merging, deleting and searching. (more)
category: Java EE | clicked: 0 | comment | | source: tamanmohamed.blogspot.in
tags: JPA
1
Pins

Welcome to semika's blog: How to delete child elements in Parent/Child relationship - JPA

posted by anishaanisha 592 days, 1 hour, 17 minutes ago
Tuesday, September 04, 2012 6:45:53 PM GMT
Orphans are the elements removed from a child collection in a parent/child relation ship. If You expect the deletions of child records from the database with by removing child elements from the child collection or with the deletion of parent record in a parent/child relationship with javax.persistence.CascadeType.All , it will not delete the child records from the database. (more)
category: Java EE | clicked: 1 | comment | | source: semikas.blogspot.in
tags: JPA, parent child relation
1
Pins

Chandana Napagoda - Java, Eclipse,Maven and Other Programming Tips: Google Cloud SQL, Hibernate JPA Support

posted by anishaanisha 594 days, 1 hour, 4 minutes ago
Sunday, September 02, 2012 6:58:04 PM GMT
With my last post about Google Cloud SQL(Google App Engine) with Spring Hibernate, many people had encountered the same issue about HIbenrate JPA. If you are developing Hibernate JPA based applications,there is some issues with Hibernate JPA support which you need to be awared. (more)
category: Java EE | clicked: 0 | comment | | source: cnapagoda.blogspot.in
tags: google cloud sql, Hibernate, JPA
1
Pins

Warlock's Thoughts: JPA - Lazy Loading and View rendering

posted by anishaanisha 594 days, 1 hour, 27 minutes ago
Sunday, September 02, 2012 6:35:31 PM GMT
JPA would be unusable without Lazy Loading, which is a feature allowing fetching of correlated entities from the database when they are referenced for the first time, rather than immediately when you perform the database query. Imagine that you cannot use Lazy Loading ... One query for the single result can return the whole database in this case, if you are lucky enough ;) (more)
category: Java EE | clicked: 1 | comment | | source: vard-lokkur.blogspot.in
tags: JPA, Lazy Loading, view rendering
1
Pins

Warlock's Thoughts: JPA and unmodifiable collections

posted by anishaanisha 594 days, 1 hour, 33 minutes ago
Sunday, September 02, 2012 6:29:28 PM GMT
Patrycja Węgrzynowicz (see Yon Labs / Yon Consulting) had very interesting talk on 33rd Degree Conference this year called "Patterns and Anti-Patterns in Hibernate". Inspired by this talk, I decided to verify JPA providers behavior regarding unmodifiable Collections. (more)
category: Java EE | clicked: 0 | comment | | source: vard-lokkur.blogspot.in
tags: Collection, JPA
1
Pins

Oracle JDeveloper 11g – First Hand on EJB/JPA Development | Alvin "Jay" Reyes Blog

posted by anishaanisha 594 days, 2 hours, 3 minutes ago
Sunday, September 02, 2012 5:59:33 PM GMT
I find EJB/JPA Development in Oracle JDeveloper too good to be true! Seriously. I tried developing a new Java EE Application using JDeveloper: The wizard created 2 components in the project. A ViewController package and a Model Package. ViewController Package – Is where all JSF/JSP and Servlets go, basically the view and controller sources. (more)
category: Java EE | clicked: 2 | comment | | source: alvinjayreyes.com
tags: Development, EJB, JPA, oracle
1
Pins

Fundamentals – ICEFaces with JPA | Alvin "Jay" Reyes Blog

posted by anishaanisha 594 days, 2 hours, 15 minutes ago
Sunday, September 02, 2012 5:47:12 PM GMT
Its been a while since I put up some stuffs in here, yet not to fear since I’ve just been drafting my writings. For this post, I’ll be going through my first hands- on experience in using ICEFaces Web Framework. You can view ICEFaces very details description here: Click Me. For my hands-on experience, I tried putting up a simple Inventory Input Form like this: (more)
category: Java EE | clicked: 0 | comment | | source: alvinjayreyes.com
tags: ICEFaces, JPA
1
Pins

J2EE JDBC based authentication with JPA Entities in Glassfish « Development world stories

posted by anishaanisha 595 days, 46 minutes ago
Saturday, September 01, 2012 7:16:56 PM GMT
One of the authentication options you get in Glassfish is to store your users/roles just in database tables. This way you can implement your custom UIs and logic for managing users. Usual solution you’ll find over the web for that is to create them by hand with SQL and fill using JDBC. What I needed was to get some entities for the users so I just could start my app and everything is created by JPA. (more)
category: Java EE | clicked: 0 | comment | | source: jdevel.wordpress.com
tags: Authentication, Glassfish, J2ee, JDBC, JPA
1
Pins

Bozho's tech blog » Abstracting the DAO Layer with Hibernate/JPA

posted by anishaanisha 596 days, 23 hours, 55 minutes ago
Thursday, August 30, 2012 8:07:36 PM GMT
A well-abstracted DAO layer means that the service layer doesn’t know anything of the persistence mechanism. This is generally desirable – you can later switch to a different storage – NoSQL, XML, etc. by only implementing a new DAO layer, and not touching anything else in the application. (more)
category: Java EE | clicked: 0 | comment | | source: techblog.bozho.net
tags: abstraction, DAO layer, JPA
1
Pins

Bozho's tech blog » How Does Merge Work in JPA (and Hibernate)

posted by anishaanisha 596 days, 23 hours, 56 minutes ago
Thursday, August 30, 2012 8:06:10 PM GMT
The JPA EntityManager there are the merge() and persist() methods. In hibernate there’s more – save, persist, saveOrUpdate, update, merge. I’m always using merge() for the sake of simplicity, but one must be aware what is the exact behaviour of this method. (more)
category: Java EE | clicked: 0 | comment | | source: techblog.bozho.net
tags: JPA, merge
1
Pins

Bozho's tech blog » An Idea for JPA Regarding Domain-Driven Design

posted by anishaanisha 597 days, 1 minute ago
Thursday, August 30, 2012 8:01:06 PM GMT
JPA and domain-driven design don’t mix well. In fact, JPA “entities” are representatives of the anemic data model that Fowler warns against. I have already discussed DDD in the light of JPA and dependency injection, so I won’t go into much details here whether anemic data model is bad or not (for the record: I don’t think it’s bad). (more)
category: Java EE | clicked: 2 | comment | | source: techblog.bozho.net
tags: domain driven design, JPA
Previous 1 2 3 4 Next