cancel
Showing results for 
Search instead for 
Did you mean: 

JPA and CAF BO - are there any editors of the JPA data (like CAF)?

Former Member
0 Kudos

Hello!

As you know SAP invented some layer above JPA and called it CAF. There is a very convenient way to edit data in CAF.

But now I have to create a complex database scheme, also with CAF doesn't allow us to work with objects. So we can't use someObject.getChildren().

So my question is are there any editors of the JPA data (like it is done in CAF)?

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Kirill, create JAX-WS web service with CRUD operations on JPA objects with some simple methods like persist, merge etc. and use it in WSNavigator or other ws client tool to operate data. I did so

rolf_paulsen
Active Participant
0 Kudos

Hi Kirill,

at the beginning of our project at the end of 2009, we did a deep analysis of CAF since our architect vehemently suggested to use this framework.

First about the history and purpose of CAF: Initially, CAF was never meant to be a layer above CAF since CAF was invented in the time before EJB 3.0 and JPA standard where writing persistence with EJB 2.x CMP forced the developer to write pages of boiler plate code. This background was approved by SAP.

With upcoming of JPA, CAF ist mostly useless (except for very simply structured data) and prevents you from writing good software.

It is easy just to write @Entity, @Id and @OneToMany (for complex database schemes) and CAF forces you to use an ugly, imperformant database scheme (e.g. CAF uses mapping tables even for 1:n relationships, a clear antipattern!)

The CRUD-services generated with CAF are a pain, too. Usage of pessimistic locking is not up to date for web applications.

With your complex database schemes, you exceed the limit of CAF.

(We decided not to use CAF and did never regret this.)

Concerning your question: There is an "JPA Details" view in NWDS that might help you. It needs JPA Persistence facet on your project to work. Developed by SAP. For JPA beginners, it is a good cheat sheet for JPA annotations and their attributes.

You do not need more since a JPA POJO is easy to code.

Regards,

Rolf

Former Member
0 Kudos

Hi Rolf!

Thank you for your answer. So you mean that if the scheme is a bit complex it's better to use JPA?

And when I asked about the editor, I meant not the NWDS editor, but something like SE11 or http://host:port/caf for editing the tables' data. Or we should generate custom application to edit raw data?

ps We don't want to user Oracle editors:).