As I understand you have two services, one with users and another with products, and of course you do not want to connect those services.
As I understand you have two services, one with users and another with products, and of course you do not want to connect those services. I think you should orchestrate over those two services with another service and, in that orchestration service, collect the products from the product service and after call the user services for user names. If it destroys your performance you could "denormalize" your services adding the name to the product entity or caching or whatever.
But I would avoid that as possible.
The products are in an application among other entities that need to reference the users in a service. The users used to be in the database with a foreign key relationship but I'm taking it out in order to distribute the membership service to other applications. I could call the product table and then for each row call pass the userid to the service and retrieve the user, i'm just thinking this would terrible performance wise.
– Eitan Jun 8 '10 at 9:31.
I would take a completely different approach. You often find that when programmers write inline dynamic sql it is to get a readonly view of the data. Therefore why do you want to populate heavy entity beans which could bring back n rows when you only need readonly access?
This is especially true if you are dealing with web services. Instead I take the approach of having a CRUD data service that returns single and a collection of entity beans say product and for the readonly queries I need I have a lookup service. Which takes in a lookup name say 'LookupAllProductsUploadedToday' and maps it to a db stored proc (eliminating the need for horrible dynamic sql!) the returned dataset is then turned into a lookup bean which is basically a collection of key/value pairs and sent out of the service to the application.
I heavily favour stored procs over inline sql for security reasons as you can then only give read and execute rights to stored procs and deny access to executing dynamic sql statements. I developed various SOA applications and have not needed to write any inline sql taking this approach.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.