You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Giacomo Pati <gi...@apache.org> on 2007/09/17 13:41:36 UTC
Re: Springifying CForms: How to solve LifecycleHelper stuff
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Giacomo Pati wrote:
> Hi all
>
> If there is nobody working on the subject I'll spend a few hours on doing that.
>
> My general tactic would be to first rewrite the xconf/rules into a spring config so that adding new
> Widgets/Converters/Datatypes will than be easily manageable (using bean-maps) and than see how the
> classes have to be rewritten to follow that.
>
> Any better ideas?
Now that I'm trying to do it I have some qustions about how we can manage LifecycleHelper stuff in
a Spring context.
In CForm definition files there are constructs that accepted a class attribute to denote a Java
class being instantiated and managed as it where a Avalon Component (Validators, SelectionLists,
and more). Whats the oppinion of other on this subject.
I'd like to get rid of LifecycleHelpre at all (it is already deprecated) but this will probably
lead to incompatabilities with the old CForm.
WDOT?
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.6 (GNU/Linux)
iD8DBQFG7mfvLNdJvZjjVZARAtXmAKDXjXllUV6QzNYUtpn1a+UQWk6TnwCcCtLu
uAzfDYdggRUkYsH3fPKV8sw=
=8Y/u
-----END PGP SIGNATURE-----
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Grzegorz Kossakowski <gk...@apache.org>.
Daniel Fagerstrom pisze:
> Giacomo Pati skrev:
>> Daniel Fagerstrom wrote:
>>
>>
>> I think we should vote on this, shouldn't we?
> Probably. I think we should start to use lazy votes for this kind of
> stuff. While we are Springifying and refactoring Cocoon there will
> probably continue to be lots of stuff that we should vote about. But
> ordinary votes are IMO to much administration for things that might be
> of minor interest for most people anyway.
+1
--
Grzegorz Kossakowski
Committer and PMC Member of Apache Cocoon
http://reflectingonthevicissitudes.wordpress.com/
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Giacomo Pati skrev:
> Daniel Fagerstrom wrote:
>
>> Giacomo Pati skrev:
>>
>>> Daniel Fagerstrom wrote:
>>>
>>>
>>>> Giacomo Pati skrev:
>>>>
>>> Again, how should deprecation be implemented:
>>>
>>> a) use deprecation logger but keep current implementation
>>> b) throw an exception and remove current implementation
>>>
>>>
>> a) is probably the correct solution, but at least I would prefer b). To
>> me, the class attribute in forms for creating components seem like some
>> hack or workaround that hopefully very few depends on.
>>
>
> I think we should vote on this, shouldn't we?
Probably. I think we should start to use lazy votes for this kind of
stuff. While we are Springifying and refactoring Cocoon there will
probably continue to be lots of stuff that we should vote about. But
ordinary votes are IMO to much administration for things that might be
of minor interest for most people anyway.
> I absolutely dislike having the LifecycleHelper (and
> thus Avalon classes) staying in the CForms code.
>
> What do otehrs think about it?
>
+1, remove it.
/Daniel
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Grzegorz Kossakowski <gk...@apache.org>.
Giacomo Pati pisze:
>
> I think we should vote on this, shouldn't we? I absolutely dislike having the LifecycleHelper (and
> thus Avalon classes) staying in the CForms code.
>
> What do otehrs think about it?
+1 for removing this stuff as long as it's released as 1.1.0 AND migration documentation is
provided. I'm very strong on both points here.
--
Grzegorz Kossakowski
Committer and PMC Member of Apache Cocoon
http://reflectingonthevicissitudes.wordpress.com/
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Reinhard Poetz <re...@apache.org>.
Giacomo Pati wrote:
> Daniel Fagerstrom wrote:
>> Giacomo Pati skrev:
>>> Daniel Fagerstrom wrote:
>>>
>>>> Giacomo Pati skrev:
>>> Again, how should deprecation be implemented:
>>>
>>> a) use deprecation logger but keep current implementation
>>> b) throw an exception and remove current implementation
>>>
>> a) is probably the correct solution, but at least I would prefer b). To
>> me, the class attribute in forms for creating components seem like some
>> hack or workaround that hopefully very few depends on.
>
> I think we should vote on this, shouldn't we? I absolutely dislike having the LifecycleHelper (and
> thus Avalon classes) staying in the CForms code.
>
> What do otehrs think about it?
I don't like them either. I would vote +1.
--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}
web(log): http://www.poetz.cc
--------------------------------------------------------------------
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Daniel Fagerstrom wrote:
> Giacomo Pati skrev:
>> Daniel Fagerstrom wrote:
>>
>>> Giacomo Pati skrev:
>> Again, how should deprecation be implemented:
>>
>> a) use deprecation logger but keep current implementation
>> b) throw an exception and remove current implementation
>>
> a) is probably the correct solution, but at least I would prefer b). To
> me, the class attribute in forms for creating components seem like some
> hack or workaround that hopefully very few depends on.
I think we should vote on this, shouldn't we? I absolutely dislike having the LifecycleHelper (and
thus Avalon classes) staying in the CForms code.
What do otehrs think about it?
>
>>> What I also would like to see, but it might be outside you current
>>> scope, is to get rid of the selectors. I would prefer a solution where
>>> maps with widgets, data types and so on are created with the bean-map
>>> and these maps are injected into the form manager.
>>>
>>
>> This is absolutely in my scope. I don't want to see those Avalon
>> ServiceSelector again ;-)
>>
> Great!
>
> /Daniel
>
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.6 (GNU/Linux)
iD8DBQFG7o/mLNdJvZjjVZARAgxwAJ47WQP+2xYv3zgyjQIXhLnB76a+MwCfag8w
G87uWKj8/klmCw9UdOymVq8=
=Domv
-----END PGP SIGNATURE-----
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Giacomo Pati skrev:
> Daniel Fagerstrom wrote:
>
>> Giacomo Pati skrev:
>>
>>> Giacomo Pati wrote:
>>>
>>>
>>>> Hi all
>>>>
>>>> If there is nobody working on the subject I'll spend a few hours on
>>>> doing that.
>>>>
>>>> My general tactic would be to first rewrite the xconf/rules into a
>>>> spring config so that adding new
>>>> Widgets/Converters/Datatypes will than be easily manageable (using
>>>> bean-maps) and than see how the
>>>> classes have to be rewritten to follow that.
>>>>
>>>> Any better ideas?
>>>>
>>>>
>>> Now that I'm trying to do it I have some qustions about how we can
>>> manage LifecycleHelper stuff in
>>> a Spring context.
>>>
>>> In CForm definition files there are constructs that accepted a class
>>> attribute to denote a Java
>>> class being instantiated and managed as it where a Avalon Component
>>> (Validators, SelectionLists,
>>> and more). Whats the oppinion of other on this subject.
>>>
>>>
>> Deprecate it. It should be enough to define beans in the Spring
>> container and refer to them in the form definition.
>>
>
> Again, how should deprecation be implemented:
>
> a) use deprecation logger but keep current implementation
> b) throw an exception and remove current implementation
>
a) is probably the correct solution, but at least I would prefer b). To
me, the class attribute in forms for creating components seem like some
hack or workaround that hopefully very few depends on.
>> What I also would like to see, but it might be outside you current
>> scope, is to get rid of the selectors. I would prefer a solution where
>> maps with widgets, data types and so on are created with the bean-map
>> and these maps are injected into the form manager.
>>
>
> This is absolutely in my scope. I don't want to see those Avalon ServiceSelector again ;-)
>
Great!
/Daniel
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Daniel Fagerstrom wrote:
> Giacomo Pati skrev:
>> Giacomo Pati wrote:
>>
>>> Hi all
>>>
>>> If there is nobody working on the subject I'll spend a few hours on
>>> doing that.
>>>
>>> My general tactic would be to first rewrite the xconf/rules into a
>>> spring config so that adding new
>>> Widgets/Converters/Datatypes will than be easily manageable (using
>>> bean-maps) and than see how the
>>> classes have to be rewritten to follow that.
>>>
>>> Any better ideas?
>>>
>>
>> Now that I'm trying to do it I have some qustions about how we can
>> manage LifecycleHelper stuff in
>> a Spring context.
>>
>> In CForm definition files there are constructs that accepted a class
>> attribute to denote a Java
>> class being instantiated and managed as it where a Avalon Component
>> (Validators, SelectionLists,
>> and more). Whats the oppinion of other on this subject.
>>
> Deprecate it. It should be enough to define beans in the Spring
> container and refer to them in the form definition.
Again, how should deprecation be implemented:
a) use deprecation logger but keep current implementation
b) throw an exception and remove current implementation
> What I also would like to see, but it might be outside you current
> scope, is to get rid of the selectors. I would prefer a solution where
> maps with widgets, data types and so on are created with the bean-map
> and these maps are injected into the form manager.
This is absolutely in my scope. I don't want to see those Avalon ServiceSelector again ;-)
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.6 (GNU/Linux)
iD8DBQFG7otRLNdJvZjjVZARAilDAJ9tKF49BH+Q8AXrOpy7d1U09ZguPwCgtRYQ
cM974YYtkLL2vbMna0j7g80=
=3/SP
-----END PGP SIGNATURE-----
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Giacomo Pati skrev:
> Giacomo Pati wrote:
>
>> Hi all
>>
>> If there is nobody working on the subject I'll spend a few hours on doing that.
>>
>> My general tactic would be to first rewrite the xconf/rules into a spring config so that adding new
>> Widgets/Converters/Datatypes will than be easily manageable (using bean-maps) and than see how the
>> classes have to be rewritten to follow that.
>>
>> Any better ideas?
>>
>
> Now that I'm trying to do it I have some qustions about how we can manage LifecycleHelper stuff in
> a Spring context.
>
> In CForm definition files there are constructs that accepted a class attribute to denote a Java
> class being instantiated and managed as it where a Avalon Component (Validators, SelectionLists,
> and more). Whats the oppinion of other on this subject.
>
Deprecate it. It should be enough to define beans in the Spring
container and refer to them in the form definition.
What I also would like to see, but it might be outside you current
scope, is to get rid of the selectors. I would prefer a solution where
maps with widgets, data types and so on are created with the bean-map
and these maps are injected into the form manager.
/Daniel
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Carsten Ziegeler <cz...@apache.org>.
Giacomo Pati wrote:
>
>
> Vadim Gritsenko wrote:
>> Giacomo Pati wrote:
>>> Now that I'm trying to do it I have some qustions about how we can
>>> manage LifecycleHelper stuff in
>>> a Spring context.
>>>
>>> In CForm definition files there are constructs that accepted a class
>>> attribute to denote a Java
>>> class being instantiated and managed as it where a Avalon Component
>>> (Validators, SelectionLists,
>>> and more). Whats the oppinion of other on this subject.
>> 1. Implement @role attribute (aka bean reference)
>
> shouldn't it be @ref?
>
>> 2. Deprecate @class attribute
>
> How to deprecate? Leaving LifecycleHelper in the code or throwing exception because we remove that
> handling?
>
I think we should just remove this stuff and provide the above mentioned
@ref configuration.
Carsten
--
Carsten Ziegeler
cziegeler@apache.org
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Vadim Gritsenko wrote:
> Giacomo Pati wrote:
>> Now that I'm trying to do it I have some qustions about how we can
>> manage LifecycleHelper stuff in
>> a Spring context.
>>
>> In CForm definition files there are constructs that accepted a class
>> attribute to denote a Java
>> class being instantiated and managed as it where a Avalon Component
>> (Validators, SelectionLists,
>> and more). Whats the oppinion of other on this subject.
>
> 1. Implement @role attribute (aka bean reference)
shouldn't it be @ref?
> 2. Deprecate @class attribute
How to deprecate? Leaving LifecycleHelper in the code or throwing exception because we remove that
handling?
- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.6 (GNU/Linux)
iD8DBQFG7nrWLNdJvZjjVZARAg7qAJ9nKEM2UkmSz46LQTolSnLrY9sOBgCfQx1z
HmZzSFR4Fc+buq2fG14AIeI=
=/JZq
-----END PGP SIGNATURE-----
Re: Springifying CForms: How to solve LifecycleHelper stuff
Posted by Vadim Gritsenko <va...@reverycodes.com>.
Giacomo Pati wrote:
> Now that I'm trying to do it I have some qustions about how we can manage LifecycleHelper stuff in
> a Spring context.
>
> In CForm definition files there are constructs that accepted a class attribute to denote a Java
> class being instantiated and managed as it where a Avalon Component (Validators, SelectionLists,
> and more). Whats the oppinion of other on this subject.
1. Implement @role attribute (aka bean reference)
2. Deprecate @class attribute
I don't think there is a better way to handle this...
Vadim