Thanks for the great post, just what I was looking for.
One question related to the way to handle CRUD operations in these types of integrated applications..
We have the main application integrating bounded tasksflows from more than one shared application. the shared application themselves have the entity objects/view objects shared from one common application that owns all the entities used in the project.
We are trying to determine the best means of handling the CRUD operations on the tables and the forms.
- When the user hits the save button, a common method in the backing bean would be called.
- This common method would identify all the sub-applications (shared ones) and the view objects within the shared ones that are changed, identify the type of change and then apply the change to the model layer.
We are able to get the applications and the view objects with their current values. We are not able to identify the "changed action" - whether insert or update. Also, in case of deleted rows, wonder how we can identify the deleted ones.
I reviewed the CRUD examples you have posted and these handle one object at a time.
Thanks for your suggestion. We have been able to resolve most of the issues highlighted here.
Please ignore my earlier comment - it got submitted before I could complete it. Sorry about that.
There is one open issue in our development. From the View layer, we are able to identify the objects changed and also the type of change done.
Currently, we are required to define a SQL type object for each table and use java methods to build an array based on each SQL object and call a PLSQL routine to handle the changes. Wondering if this can be done using PLSQL tables or PLSQL records etc., so that the need to define SQL objects for 50+ tables need not be done.
Also, is there any other alternate way of passing collection of records from the view layer to the back end, other than arrays based on SQL objects? If so, please let us know. Appreciate all your help.