Return-Path: Delivered-To: apmail-jakarta-hivemind-cvs-archive@www.apache.org Received: (qmail 91623 invoked from network); 21 Jun 2004 14:55:09 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 21 Jun 2004 14:55:09 -0000 Received: (qmail 21585 invoked by uid 500); 21 Jun 2004 14:55:18 -0000 Delivered-To: apmail-jakarta-hivemind-cvs-archive@jakarta.apache.org Received: (qmail 21499 invoked by uid 500); 21 Jun 2004 14:55:17 -0000 Mailing-List: contact hivemind-cvs-help@jakarta.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: Reply-To: hivemind-dev@jakarta.apache.org Delivered-To: mailing list hivemind-cvs@jakarta.apache.org Received: (qmail 21445 invoked by uid 99); 21 Jun 2004 14:55:14 -0000 Received: from [209.237.227.194] (HELO minotaur.apache.org) (209.237.227.194) by apache.org (qpsmtpd/0.27.1) with SMTP; Mon, 21 Jun 2004 07:55:14 -0700 Received: (qmail 91567 invoked from network); 21 Jun 2004 14:55:03 -0000 Received: from localhost.hyperreal.org (HELO minotaur.apache.org) (127.0.0.1) by localhost.hyperreal.org with SMTP; 21 Jun 2004 14:55:03 -0000 Content-Type: text/plain; charset="iso-8859-1" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: hivemind-cvs@jakarta.apache.org To: hivemind-cvs@jakarta.apache.org Subject: =?iso-8859-1?q?=5BJakarta_HiveMind_Wiki=5D_New=3A__FrequentlyAskedQuestio?= =?iso-8859-1?q?ns?= Date: Mon, 21 Jun 2004 14:55:03 -0000 Message-ID: <20040621145503.91553.51197@minotaur.apache.org> X-Spam-Rating: localhost.hyperreal.org 1.6.2 0/1000/N X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N Date: 2004-06-21T07:55:02 Editor: 200.63.136.102 <> Wiki: Jakarta HiveMind Wiki Page: FrequentlyAskedQuestions URL: http://wiki.apache.org/jakarta-hivemind/FrequentlyAskedQuestions no comment New Page: =3D Frequently Asked Questions =3D This page will eventually become the !HiveMind FAQ. The idea is that peopl= e ask questions and that other !HiveMind users and developers respond and c= omment until a "accepted solution" is reached. Eventually we will be able = to compile a list of questions and accepted solutions into a more official = FAQ for the !HiveMind website. Q. (DanielFeist 21/06/2004) = ''(Maybe this is a ChangeProposal rather than a question. That depends on = the answer ... lets wait and see and possibly move it is it doesn't belon= g here)'' Is there anyway to inject a service, using the BuilderFactory, with an obje= ct obtained by invoking a method of another service. I can think of many c= ases were this would be very useful but it doesn't seem to be possible. Co= ncrete examples are as follows: 'Example 1': I have a Mailer service which depends on, and uses, a datasou= rce to obtain email address. This datasource is to be obtained via JNDI so= i decide to use the NameLookup service to obtain the datasource. As the d= atasource is not a service but rather the result from executing a lookup me= thod of a service it seems i am limited from injecting it into my Mailer se= rvice through declarative configuration in the hivemodule.sdl. 'Example 2': I have a Mailer service which uses a Properties to obtain ema= il address. The backing store of the properties has to be flexible and con= figurable so i decide to create a !PropertyFactory service that returns a P= roperties object for a given locator and whose backing store is defined and= configured through a configuration point. This is a good solution to my p= roblem but as in example 1 I cannot inject this properties into my Mailer S= ervice. On a side note: If this type of injection is possible then a clean solution= to my change proposal ModuleResourcesProposal is very simple. Resources = would be created using a factory specifically designed to do this (much lik= e the BeanFactory) which would also manage backing-store type and synchroni= zation issues. These resources could then be injected into services by usi= ng ResourceFactory's get method to obtain the resource. --------------------------------------------------------------------- To unsubscribe, e-mail: hivemind-cvs-unsubscribe@jakarta.apache.org For additional commands, e-mail: hivemind-cvs-help@jakarta.apache.org