Hi all,

Section 1.4.1 of the SCA Java Common Annotations and APIs specification states 
the following:

"Using reference injection is the recommended way to access a service, since it 
results in code with minimal use of middleware APIs. The ComponentContext API 
should be used in cases where reference injection is not possible."

Injection is not appropriate where a client component does not know how many 
service components its will need to create until runtime. Conferencing is a 
good example of this, how many participant instances should be created?

In order to dynamically create the objects we need, we have devised the 
following pattern:

   * The factory will be stateless.
   * The factory will be injected into the client component.
   * The factory will create a specific type of component.
   * The factory will use the ComponentContext to create the required component.
   * The created component must obey the specified implementation scope, 
stateless or conversational.
   * The factory will use the RequestContext to connect up any callbacks 
between the component and the client.
   * The connected callback must also obey the specified implementation scope, 
stateless or conversational. 

Does anyone have any thoughts as to whether this:

   * Is perhaps trying to bring an OO style of programming to what is really a 
SOA environment?
   * Whether the callback aspect is realistic?
   * In short, is this a good pattern or an anti-pattern?

Any thoughts would be much appreciated

Thank you




Information contained in this e-mail and any attachments are intended for the 
use of the addressee only, and may contain confidential information of Ubiquity 
Software Corporation. All unauthorized use, disclosure or distribution is 
strictly prohibited.  If you are not the addressee, please notify the sender 
immediately and destroy all copies of this email. Ubiquity Software Corporation 
plc, a company registered under the laws of England and Wales, Registration 
2719723, registered offices at Eastern Business Park, Building 3, Wern Fawr 
Lane, St. Mellons, Cardiff CF3 5EA, Wales, United Kingdom.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to