|
From: =?iso-8859-1?Q?<jp....@ti...> - 2003-07-18 15:47:53
|
+1=0D=0A=0D=0AJust to see how handle the Exceptions. No Spring specific E= xception has to be waited for. The called method can have or not a throws= statement and it can always throw a RuntimeException. The factory will h= ave to catch any Exception and throwing itself a ServletException? If an = initialization method throws any kind of Exception, it's allways fatal.=0D= =0A=0D=0ASo we can gain a new design step.=0D=0A=0D=0AJean-Pierre=0D=0A--= -------- Initial Header -----------=0D=0A=0D=0AFrom : springframewor= k-d...@li...=0D=0ATo : "j=C3=BCrgen h= =C3=B6ller [werk3AT]" <jue...@we...>=0D=0ACc : sp= rin...@li...=0D=0ADate : Fri, 18 Ju= l 2003 09:55:43 -0400=0D=0ASubject : Re: [Springframework-developer] Fw: = [springframework - Open Discussion] RE: BeanFactory=3D>Generic Container=0D= =0A=0D=0AJuergen,=0D=0A=0D=0A> I consider that an interesting idea: As an= alternative to InitializingBean,=0D=0A> we could indeed add such an "ini= tializing_method" attribute, specifying a=0D=0A> no-arg init method on th= e object. That would allow for initialization that=0D=0A> depends on mult= iple properties without implementing any Spring-specific=0D=0A> interface= . What you think about this?=0D=0A=0D=0A+1=0D=0A=0D=0AI see no disadvanta= ges, and it would be nice to not having to depend on any=0D=0ASpring inte= rfaces at all.=0D=0A=0D=0AThomas=0D=0A=0D=0A=0D=0A-----------------------= --------------------------------=0D=0AThis SF.net email is sponsored by: = VM Ware=0D=0AWith VMware you can run multiple operating systems on a sing= le machine.=0D=0AWITHOUT REBOOTING! Mix Linux / Windows / Novell virtual = machines at the=0D=0Asame time. Free trial click here: http://www.vmware.= com/wl/offer/345/0=0D=0A_______________________________________________=0D= =0ASpringframework-developer mailing list=0D=0ASpringframework-developer@= lists.sourceforge.net=0D=0Ahttps://lists.sourceforge.net/lists/listinfo/s= pringframework-developer=0D=0A=0A=0A********** L'ADSL A 20 EUR/MOIS******= ****=0ATiscali propose l'ADSL le moins cher du march=E9 : 20 EUR/mois et = le modem ADSL offert ! =0APour profiter de cette offre exceptionnelle, cl= iquez ici : http://register.tiscali.fr/adsl/=0AOffre soumise =E0 conditio= ns.=0A |
|
From: Rod J. <rod...@in...> - 2003-07-18 17:49:41
|
OK, I can implement this. I think we must keep InitializingBean however. Many framework classes depend on it and we should not force users to know the relevant init method that they may not care about, and we must not force users to remember to set the magic initialization attribute to get the AOP framework etc to work. So I propose: - Keep InitializingBean - Add a new "init-method" attribute for arbitrary methods. If a class implements both IB and has an initializer, the IB method will be called first. If the user specifies an init-method att and there's no such method that's treated as a fatal exception. Regards, Rod ----- Original Message ----- From: <jp....@ti...> To: "trisberg" <tri...@tr...> Cc: "juergen.hoeller" <jue...@we...>; "springframework-developer" <spr...@li...> Sent: Friday, July 18, 2003 4:47 PM Subject: [Springframework-developer] Re: [Springframework-developer] Fw: [springframework - Open Discussion] RE: BeanFactory=>Generic Container +1 Just to see how handle the Exceptions. No Spring specific Exception has to be waited for. The called method can have or not a throws statement and it can always throw a RuntimeException. The factory will have to catch any Exception and throwing itself a ServletException? If an initialization method throws any kind of Exception, it's allways fatal. So we can gain a new design step. Jean-Pierre ---------- Initial Header ----------- From : spr...@li... To : "jürgen höller [werk3AT]" <jue...@we...> Cc : spr...@li... Date : Fri, 18 Jul 2003 09:55:43 -0400 Subject : Re: [Springframework-developer] Fw: [springframework - Open Discussion] RE: BeanFactory=>Generic Container Juergen, > I consider that an interesting idea: As an alternative to InitializingBean, > we could indeed add such an "initializing_method" attribute, specifying a > no-arg init method on the object. That would allow for initialization that > depends on multiple properties without implementing any Spring-specific > interface. What you think about this? +1 I see no disadvantages, and it would be nice to not having to depend on any Spring interfaces at all. Thomas ------------------------------------------------------- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here: http://www.vmware.com/wl/offer/345/0 _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer ********** L'ADSL A 20 EUR/MOIS********** Tiscali propose l'ADSL le moins cher du marché : 20 EUR/mois et le modem ADSL offert ! Pour profiter de cette offre exceptionnelle, cliquez ici : http://register.tiscali.fr/adsl/ Offre soumise à conditions. ------------------------------------------------------- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here: http://www.vmware.com/wl/offer/345/0 _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |
|
From: Ken K. <kk...@kk...> - 2003-07-18 22:42:42
|
+1 Sounds right to me. Rod Johnson wrote: >OK, I can implement this. > >I think we must keep InitializingBean however. Many framework classes depend >on it and we should not force users to know the relevant init method that >they may not care about, and we must not force users to remember to set the >magic initialization attribute to get the AOP framework etc to work. > >So I propose: >- Keep InitializingBean >- Add a new "init-method" attribute for arbitrary methods. If a class >implements both IB and has an initializer, the IB method will be called >first. If the user specifies an init-method att and there's no such method >that's treated as a fatal exception. > >Regards, >Rod > >----- Original Message ----- >From: <jp....@ti...> >To: "trisberg" <tri...@tr...> >Cc: "juergen.hoeller" <jue...@we...>; >"springframework-developer" ><spr...@li...> >Sent: Friday, July 18, 2003 4:47 PM >Subject: [Springframework-developer] Re: [Springframework-developer] Fw: >[springframework - Open Discussion] RE: BeanFactory=>Generic Container > > >+1 > >Just to see how handle the Exceptions. No Spring specific Exception has to >be waited for. The called method can have or not a throws statement and it >can always throw a RuntimeException. The factory will have to catch any >Exception and throwing itself a ServletException? If an initialization >method throws any kind of Exception, it's allways fatal. > >So we can gain a new design step. > >Jean-Pierre >---------- Initial Header ----------- > >>From : spr...@li... >To : "jürgen höller [werk3AT]" <jue...@we...> >Cc : spr...@li... >Date : Fri, 18 Jul 2003 09:55:43 -0400 >Subject : Re: [Springframework-developer] Fw: [springframework - Open >Discussion] RE: BeanFactory=>Generic Container > >Juergen, > > > >>I consider that an interesting idea: As an alternative to >> >> >InitializingBean, > > >>we could indeed add such an "initializing_method" attribute, specifying a >>no-arg init method on the object. That would allow for initialization that >>depends on multiple properties without implementing any Spring-specific >>interface. What you think about this? >> >> > >+1 > >I see no disadvantages, and it would be nice to not having to depend on any >Spring interfaces at all. > >Thomas > > >------------------------------------------------------- >This SF.net email is sponsored by: VM Ware >With VMware you can run multiple operating systems on a single machine. >WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the >same time. Free trial click here: http://www.vmware.com/wl/offer/345/0 >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > >********** L'ADSL A 20 EUR/MOIS********** >Tiscali propose l'ADSL le moins cher du marché : 20 EUR/mois et le modem >ADSL offert ! >Pour profiter de cette offre exceptionnelle, cliquez ici : >http://register.tiscali.fr/adsl/ >Offre soumise à conditions. > > > > >------------------------------------------------------- >This SF.net email is sponsored by: VM Ware >With VMware you can run multiple operating systems on a single machine. >WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the >same time. Free trial click here: http://www.vmware.com/wl/offer/345/0 >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > > > >------------------------------------------------------- >This SF.net email is sponsored by: VM Ware >With VMware you can run multiple operating systems on a single machine. >WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the >same time. Free trial click here: http://www.vmware.com/wl/offer/345/0 >_______________________________________________ >Springframework-developer mailing list >Spr...@li... >https://lists.sourceforge.net/lists/listinfo/springframework-developer > > > > |