You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Joe Germuska <Jo...@Germuska.com> on 2005/02/14 23:43:56 UTC

Recalibrate Roadmap (Re: Action threadsafe)

Frank Z wrote:
>>>This point made me think of something... What about the idea of adding the
>>>concept of an <action-bean> in struts-config?

At 12:11 PM -0800 2/14/05, Don Brown wrote:
>The question is whether there will be a one-to-one mapping between 
>action-beans and action-mappings.  If 90%+ of the time there will 
>be, this will needlessly complicate the config.  I suppose, however, 
>if action mappings used wildcards heavily, this could come in handy, 
>course then I'd argue for wildcards in the action-beans to help 
>group them. :)

I guess I figured on<action-bean> being an alternative to <action> in 
that it would have a "path" property.  Maybe that's a bad idea, but 
it would be easy enough to throw another chain command in there which 
looked up the path against another store of expertise.

Then again, it would presumably mean adding yet another property to 
ActionContext (getActionBean()?)  That might be a bad path to head 
down.

OK, Frank, sorry; you're not on to anything.  ;^)  Just kidding -- 
good to think outside the box in all events.

My inclination at this point is to treat the most complicated 
questions we're bumping up against as fertile ground for subprojects 
and contrib-type code until we really see what people want and what 
works.  I don't think it is necessary to wrestle them all to the 
ground at once.  Reviewing the latest roadmap, even some of the 
things I've already done or am planning on doing are a rew minor revs 
out.  It's probably time to recalibrate the roadmap to our current 
interests and ideas.

I've copied some of
http://struts.apache.org/roadmap.html below; I left out the parts on 
which I didn't have direct comments.

>Experimental Members
>
>ActionCommand - A Chain Command-like interface with one method...
>ActionContext - A Chain Context that implements the logical Action class API.
>ViewContext - A Chain Context that implements the logical "Velocity 
>Tools" API.

At this time, I am convinced that explicitly passing ActionContext 
through Struts' chain is sufficiently better than having all the 
commands have to share info about where to find key context 
attributes and having them frequently cast to WebContext or 
ServletWebContext that I would take this out of "experimental" state.

I also don't see how ViewContext would be terribly experimental, 
unless we immediately rewrote the taglib classes to use it.  Even so, 
I'm not sure I believe it requires a long incubation period.

After reading the section on ActionCommand, I could be persuaded to 
abandon my suggestion about changing Action in favor of presenting 
the ActionCommand interface, and "overloading" the <action> type 
attribute so that it might specify either an Action or an 
ActionCommand, or possibly adding a new attribute.   Ted wrote it so 
that this level of "smarts" would be deferred until "Struts 1.5"

>The Commons Chain WebContext we now pass around Struts Chain could 
>be called the "StrutsContext" to differentiate it from the 
>ActionContext and ViewContext.

I'm not sure this is an issue any more.  After trying to mix and 
match commands, I think it's worth stipulating that the 
ComposableRequestProcessor will always start the chain with an 
ActionContext.

>1.4 considerations
>
>Consider adding catalog element. Depending on how the work goes with 
>the experimental ActionCommand interface, we might identifiy a need 
>to add a catalog element to the Struts configuration, to support 
>using a Chain of ActionCommands.

This has already been done or doesn't matter, depending on how you 
look at it.  There's direct support for looking up any command using 
the command/catalog attributes; on the other hand, if you want to 
specify an ActionCommand as the "type" for an ActionConfig, it seems 
like there's no clean way to support a catalog or any kind of lookup, 
nor a need, since the former solution exists.

>1.5 considerations
>
>Based on our own work with the "experimental" members inroduced in 
>1.3.x, we might consider some other changes.
>
>Consider a "smart" action type. The idea is that a command in Struts 
>chain could look at the type indicated by the ActionMapping so both 
>Action classes and ActionCommand implementations are supported. 
>People could then mix-and-match Actions with ActionCommands (or even 
>chains of ActionCommands). We might even support placing an 
>ActionCommand interface on ActionForm, so people could skip having a 
>sepate Action or ActionCommand class. The ActionForm could do it all.

As noted above, this seems like a necessity before 1.5 if you're 
going to actually use ActionCommand; I'm not quite sure how one would 
effectively designate ActionForm as a command; if one wants to have 
something "do it all," I don't think that thing should be called 
"ActionForm."

Of course, this document has always just been a scratchpad of sorts, 
but perhaps now that a few of us are back to actively thinking about 
implementing future changes, we should revisit it and come up with 
one which reflects our intentions?

Joe

-- 
Joe Germuska            
Joe@Germuska.com  
http://blog.germuska.com    
"Narrow minds are weapons made for mass destruction"  -The Ex

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Ted Husted <hu...@apache.org>.
On Mon, 14 Feb 2005 17:45:01 -0600, Hubert Rabago wrote:
>�On Mon, 14 Feb 2005 17:39:34 -0600, Joe Germuska <Jo...@germuska.com>
>�wrote: <snip/>
>
>>
>>�One thing which has been talked about in a few places, and which
>>�would be valuable, but which no one has done any work on is
>>�implementing "extends" in as many places in struts-config.xml as
>>�it would be useful, to eliminate repeated chunks of XML. �For
>>�Validation, this would really be an enhancement to commons-
>>�validator, but perhaps the same general strategy could be
>>�applied. �I haven't even looked at what would be involved in
>>�trying to implement it.

I would suggest that  implementing extends might have a higher priority than some of the other things that we've been discussing. 

If the issue is locking the DTD until extends is implemented, then so be it. 

Extends would solve *so* many problems, and eliminate *so* many "forest from the trees" bugs. 

For example, with extends, we don't really need action-beans. People can define a base mapping with whatever settings they need, and just extend it elsewhere.

And don't get me started on what this could mean for DynaActionForms :) 

-Ted.



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Hubert Rabago <hr...@gmail.com>.
On Mon, 14 Feb 2005 17:39:34 -0600, Joe Germuska <Jo...@germuska.com> wrote:
<snip/> 
> 
> One thing which has been talked about in a few places, and which
> would be valuable, but which no one has done any work on is
> implementing "extends" in as many places in struts-config.xml as it
> would be useful, to eliminate repeated chunks of XML.  For
> Validation, this would really be an enhancement to commons-validator,
> but perhaps the same general strategy could be applied.  I haven't
> even looked at what would be involved in trying to implement it.

I was actually thinking of taking on this one, but it looked to me
that with the current state of things, now isn't the best time to
include a patch for this.  If I'm mistaken, let me know and I'll work
on an implementation.  I haven't looked at what's involved for this
specifically, but with my work on FormDef I got familiar with how
Struts gets configured and have some ideas how this could be
implemented.

<snip/> 
> 
> And, of course, many users have filed enhancement requests throughout
> Bugzilla, although working on those may or may not be close enough to
> the current discussions which have generated so much discussion.
> 

I actually have a patch for the most voted enhancement request, that
you and Don have thought of committing at one time or another.  :)

> Joe
> 
> --
> Joe Germuska
> Joe@Germuska.com
> http://blog.germuska.com
> "Narrow minds are weapons made for mass destruction"  -The Ex
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Joe Germuska <Jo...@Germuska.com>.
At 5:23 PM -0600 2/14/05, Hubert Rabago wrote:
>Would this mean if I had an idea I'd like to offer up, I'd implement
>it, create the sample app, then present everything to the dev list?
>What about those looking to contribute to the path the committers have chosen?

I don't think that the only way to contribute is a full-blown sample 
app; I think Don was speaking about a specific type of contribution.

I just sent an email with a few of the things I'm thinking about 
doing; otherwise, I'm not sure what to "break off" and delegate.  Do 
you see anything I didn't mention?  What is the part that interests 
you?

One thing which has been talked about in a few places, and which 
would be valuable, but which no one has done any work on is 
implementing "extends" in as many places in struts-config.xml as it 
would be useful, to eliminate repeated chunks of XML.  For 
Validation, this would really be an enhancement to commons-validator, 
but perhaps the same general strategy could be applied.  I haven't 
even looked at what would be involved in trying to implement it.

I also like the idea of auto-discovery of struts-config.xml and the 
other config files; we've taken to making many of them for our apps, 
and it's boring to have to add them all.

And, of course, many users have filed enhancement requests throughout 
Bugzilla, although working on those may or may not be close enough to 
the current discussions which have generated so much discussion.

Joe

-- 
Joe Germuska            
Joe@Germuska.com  
http://blog.germuska.com    
"Narrow minds are weapons made for mass destruction"  -The Ex

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Don Brown <mr...@twdata.org>.
FormDef has just been brought to my attention and I plan to look into it 
further.  This is a good example of setting something up and inviting 
folks to take a look.  Several of the features, combining forms defs and 
validations in the same DTD for example, are things we've been talking 
about but haven't done.  From my cursory glance of the home page, 
formdef is a great fit for Struts.

Don

Hubert Rabago wrote:
> What about an idea that's not part of the current discussion, like
> FormDef?  I would love for Struts to have something like what FormDef
> offers.  I wouldn't mind working on something that incorporates
> FormDef's features to the Struts core, or even just contribute FormDef
> to Struts directly.
> 
> On Mon, 14 Feb 2005 15:38:07 -0800, Don Brown <mr...@twdata.org> wrote:
> 
>>I think so.  An idea with a working, and ideally deployed,
>>implementation is much more interesting than some guy/gal's opinion.
>>Apache works on the principle of a meritocracy where those that do the
>>most work get the most privilege.  "Patches speak louder than words" :)
>>
>>If you want to tackle one of the major bullets on the roadmap, I'd
>>suggest you write up a short proposal of your idea and what it will
>>entail.  If you get a favorable response, code it up and stick it on a
>>server somewhere with a nice demo and explanation.  It takes more time
>>to publish the code properly by writing up a small website with an
>>explanation and hopefully demo, but it makes it much more likely folks
>>will bother to give it a look.  Throwing code over the wall is not
>>attractive as most committers and developers in general don't have that
>>kind of free time.
>>
>>Bottom line: get involved.  Check out the code, fix minor bugs, write a
>>small extension, improve on someone else's idea, but just get involved.
>>
>>Don
>>
>>
>>Hubert Rabago wrote:
>>
>>>Would this mean if I had an idea I'd like to offer up, I'd implement
>>>it, create the sample app, then present everything to the dev list?
>>>What about those looking to contribute to the path the committers have chosen?
>>>
>>>
>>>On Mon, 14 Feb 2005 15:18:10 -0800, Don Brown <mr...@twdata.org> wrote:
>>>
>>>
>>>>Of course, you and anyone else, are welcome to attack bugs in bugzilla
>>>>to speed us along to another release.  What I personally would be
>>>>interested in is for you to explore your "vision" of how action
>>>>invocation should work, then rewrite a small app like the mail reader to
>>>>use it.  I don't believe commons-chain belongs in the action tier so I'd
>>>>be interested in being proven wrong. :)
>>>>
>>>>Don
>>>>
>>>>Frank W. Zammetti wrote:
>>>>
>>>>
>>>>>Since I've been involved in these discussions today, I wanted to "put my
>>>>>money where my (rather substantially large) mouth is" and offer up
>>>>>myself to do some actual work.
>>>>>
>>>>>If there's anything you guys can pawn off on me, I wouldn't mind being
>>>>>involved in some small way.  I don't think I could sign up for any major
>>>>>pieces at the moment, but if you have some things you might be able to
>>>>>offload to me, you'll have my best effort :)
>>>>>
>>>>
>>>>---------------------------------------------------------------------
>>>>To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
>>>>For additional commands, e-mail: dev-help@struts.apache.org
>>>>
>>>>
>>>
>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
>>>For additional commands, e-mail: dev-help@struts.apache.org
>>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
>>For additional commands, e-mail: dev-help@struts.apache.org
>>
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Hubert Rabago <hr...@gmail.com>.
What about an idea that's not part of the current discussion, like
FormDef?  I would love for Struts to have something like what FormDef
offers.  I wouldn't mind working on something that incorporates
FormDef's features to the Struts core, or even just contribute FormDef
to Struts directly.

On Mon, 14 Feb 2005 15:38:07 -0800, Don Brown <mr...@twdata.org> wrote:
> I think so.  An idea with a working, and ideally deployed,
> implementation is much more interesting than some guy/gal's opinion.
> Apache works on the principle of a meritocracy where those that do the
> most work get the most privilege.  "Patches speak louder than words" :)
> 
> If you want to tackle one of the major bullets on the roadmap, I'd
> suggest you write up a short proposal of your idea and what it will
> entail.  If you get a favorable response, code it up and stick it on a
> server somewhere with a nice demo and explanation.  It takes more time
> to publish the code properly by writing up a small website with an
> explanation and hopefully demo, but it makes it much more likely folks
> will bother to give it a look.  Throwing code over the wall is not
> attractive as most committers and developers in general don't have that
> kind of free time.
> 
> Bottom line: get involved.  Check out the code, fix minor bugs, write a
> small extension, improve on someone else's idea, but just get involved.
> 
> Don
> 
> 
> Hubert Rabago wrote:
> > Would this mean if I had an idea I'd like to offer up, I'd implement
> > it, create the sample app, then present everything to the dev list?
> > What about those looking to contribute to the path the committers have chosen?
> >
> >
> > On Mon, 14 Feb 2005 15:18:10 -0800, Don Brown <mr...@twdata.org> wrote:
> >
> >>Of course, you and anyone else, are welcome to attack bugs in bugzilla
> >>to speed us along to another release.  What I personally would be
> >>interested in is for you to explore your "vision" of how action
> >>invocation should work, then rewrite a small app like the mail reader to
> >>use it.  I don't believe commons-chain belongs in the action tier so I'd
> >>be interested in being proven wrong. :)
> >>
> >>Don
> >>
> >>Frank W. Zammetti wrote:
> >>
> >>>Since I've been involved in these discussions today, I wanted to "put my
> >>>money where my (rather substantially large) mouth is" and offer up
> >>>myself to do some actual work.
> >>>
> >>>If there's anything you guys can pawn off on me, I wouldn't mind being
> >>>involved in some small way.  I don't think I could sign up for any major
> >>>pieces at the moment, but if you have some things you might be able to
> >>>offload to me, you'll have my best effort :)
> >>>
> >>
> >>---------------------------------------------------------------------
> >>To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> >>For additional commands, e-mail: dev-help@struts.apache.org
> >>
> >>
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> > For additional commands, e-mail: dev-help@struts.apache.org
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Don Brown <mr...@twdata.org>.
I think so.  An idea with a working, and ideally deployed, 
implementation is much more interesting than some guy/gal's opinion. 
Apache works on the principle of a meritocracy where those that do the 
most work get the most privilege.  "Patches speak louder than words" :)

If you want to tackle one of the major bullets on the roadmap, I'd 
suggest you write up a short proposal of your idea and what it will 
entail.  If you get a favorable response, code it up and stick it on a 
server somewhere with a nice demo and explanation.  It takes more time 
to publish the code properly by writing up a small website with an 
explanation and hopefully demo, but it makes it much more likely folks 
will bother to give it a look.  Throwing code over the wall is not 
attractive as most committers and developers in general don't have that 
kind of free time.

Bottom line: get involved.  Check out the code, fix minor bugs, write a 
small extension, improve on someone else's idea, but just get involved.

Don


Hubert Rabago wrote:
> Would this mean if I had an idea I'd like to offer up, I'd implement
> it, create the sample app, then present everything to the dev list?
> What about those looking to contribute to the path the committers have chosen?
> 
> 
> On Mon, 14 Feb 2005 15:18:10 -0800, Don Brown <mr...@twdata.org> wrote:
> 
>>Of course, you and anyone else, are welcome to attack bugs in bugzilla
>>to speed us along to another release.  What I personally would be
>>interested in is for you to explore your "vision" of how action
>>invocation should work, then rewrite a small app like the mail reader to
>>use it.  I don't believe commons-chain belongs in the action tier so I'd
>>be interested in being proven wrong. :)
>>
>>Don
>>
>>Frank W. Zammetti wrote:
>>
>>>Since I've been involved in these discussions today, I wanted to "put my
>>>money where my (rather substantially large) mouth is" and offer up
>>>myself to do some actual work.
>>>
>>>If there's anything you guys can pawn off on me, I wouldn't mind being
>>>involved in some small way.  I don't think I could sign up for any major
>>>pieces at the moment, but if you have some things you might be able to
>>>offload to me, you'll have my best effort :)
>>>
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
>>For additional commands, e-mail: dev-help@struts.apache.org
>>
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Hubert Rabago <hr...@gmail.com>.
Would this mean if I had an idea I'd like to offer up, I'd implement
it, create the sample app, then present everything to the dev list?
What about those looking to contribute to the path the committers have chosen?


On Mon, 14 Feb 2005 15:18:10 -0800, Don Brown <mr...@twdata.org> wrote:
> Of course, you and anyone else, are welcome to attack bugs in bugzilla
> to speed us along to another release.  What I personally would be
> interested in is for you to explore your "vision" of how action
> invocation should work, then rewrite a small app like the mail reader to
> use it.  I don't believe commons-chain belongs in the action tier so I'd
> be interested in being proven wrong. :)
> 
> Don
> 
> Frank W. Zammetti wrote:
> > Since I've been involved in these discussions today, I wanted to "put my
> > money where my (rather substantially large) mouth is" and offer up
> > myself to do some actual work.
> >
> > If there's anything you guys can pawn off on me, I wouldn't mind being
> > involved in some small way.  I don't think I could sign up for any major
> > pieces at the moment, but if you have some things you might be able to
> > offload to me, you'll have my best effort :)
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Struts-EL missing from nightlies (was Re: Recalibrate Roadmap)

Posted by Joe Germuska <Jo...@Germuska.com>.
At 10:07 AM -0800 2/15/05, Craig McClanahan wrote:
>On Tue, 15 Feb 2005 10:12:24 -0700, Wendy Smoak <ja...@wendysmoak.com> wrote:
>>  From: "Joe Germuska" <Jo...@Germuska.com>
>>
>>  > The simplest thing that *anyone* can do would be to start trying to
>>  > plug the nightly build into applications
>>
>>  I tried out the 20050215 nightly build, but the Struts-EL .jar files aren't
>>  there.  Can they be included?
>>
>
>Joe et. al.,
>
>The nightly build script for Struts is totally customized (unlike the
>ones for commons packages), so let me know what target(s) to run in
>what directories, and what files to upload.  If we're moving towards
>separately releaseable artifacts, we should probably mirror that
>structure in the nightly builds.

I haven't been very involved in the reorganizations, except as a 
user, so I would want to get some other voices in here.

I've been using Maven to get JARs to use for my testing.  I hadn't 
yet tried to build el, so I just now added the maven.xml file which 
causes Maven to get the TLD files in the JAR.

It appears that the "maven dist:deploy-snapshot" goal works more or 
less as expected to both create and deploy binary and source tarballs 
and ZIP files to 
http://www.apache.org/dist/java-repository/struts/distributions (I 
deleted the ones my test produced)

If no one prefers ANT builds, I could spend a bit more time looking 
at that process and specifying how to configure an environment so 
that the script would be something like this:

cd core/trunk
maven jar:deploy-snapshot
maven dist:deploy-snapshot
cd ../../taglib/trunk
maven jar:deploy-snapshot
maven dist:deploy-snapshot
cd ../../el/trunk
maven jar:deploy-snapshot
maven dist:deploy-snapshot
cd ../../tiles/trunk
maven jar:deploy-snapshot
maven dist:deploy-snapshot

If we did that, we'd want to have the nightly build process override 
the version dependency to "SNAPSHOT" (which I prefer leaving out of 
the normal project.xml to avoid the check-for-newer-every-time hit), 
and we'd need to change the directory to which we link for 
downloading nightlies; but otherwise, it seems very straightforward.

If anyone else wants to work on this more, I'm not flush with spare 
time for it this week, but if no one else can, I can pursue.  I'd 
rather not get into figuring out nightlies with ANT, but don't object 
if someone else wants to do that before we get it working with Maven.

Joe

-- 
Joe Germuska            
Joe@Germuska.com  
http://blog.germuska.com    
"Narrow minds are weapons made for mass destruction"  -The Ex

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Struts-EL missing from nightlies (was Re: Recalibrate Roadmap)

Posted by Craig McClanahan <cr...@gmail.com>.
On Tue, 15 Feb 2005 10:12:24 -0700, Wendy Smoak <ja...@wendysmoak.com> wrote:
> From: "Joe Germuska" <Jo...@Germuska.com>
> 
> > The simplest thing that *anyone* can do would be to start trying to
> > plug the nightly build into applications
> 
> I tried out the 20050215 nightly build, but the Struts-EL .jar files aren't
> there.  Can they be included?
> 

Joe et. al.,

The nightly build script for Struts is totally customized (unlike the
ones for commons packages), so let me know what target(s) to run in
what directories, and what files to upload.  If we're moving towards
separately releaseable artifacts, we should probably mirror that
structure in the nightly builds.

Craig

> --
> Wendy Smoak
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Struts-EL missing from nightlies (was Re: Recalibrate Roadmap)

Posted by Wendy Smoak <ja...@wendysmoak.com>.
From: "Joe Germuska" <Jo...@Germuska.com>

> The simplest thing that *anyone* can do would be to start trying to
> plug the nightly build into applications

I tried out the 20050215 nightly build, but the Struts-EL .jar files aren't
there.  Can they be included?

-- 
Wendy Smoak






---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Joe Germuska <Jo...@Germuska.com>.
At 6:13 PM -0500 2/14/05, Frank W. Zammetti wrote:
>Since I've been involved in these discussions today, I wanted to 
>"put my money where my (rather substantially large) mouth is" and 
>offer up myself to do some actual work.
>
>If there's anything you guys can pawn off on me, I wouldn't mind 
>being involved in some small way.  I don't think I could sign up for 
>any major pieces at the moment, but if you have some things you 
>might be able to offload to me, you'll have my best effort :)

Here's a pretty self-contained chunk that I haven't gotten to: see if 
you can make the mailreader app work with the nightly builds.  I 
started on that last night, and at least got the "examples" working 
with "maven dist".

Note that that section of the repository is still not necessarily 
perfect, so you may be flushing out more things we need to do to 
"finish" the reorg in that area.

If we take changes to Action and ActionForm off the table until 1.4, 
then we might be nearing a good point for a candidate beta release. 
No action has happened on switching out the message resources front, 
but that's not something I care enough about to want to delay things. 
I agree that ViewContext should get in.  I'd even consider laying off 
of "ActionCommand" as a possible 1.3 extension but not critical to 
starting candidate releases flowing.

I have a few other small things I'd like to do:
* write a simple command which terminates process-action when the 
form is invalid but which is independent of other commands, and 
updating the commands which fall after to no longer worry about the 
state of the forms validity (or maybe not so simple and use JEXL to 
evaluate an arbitrary expression against the Context to abort, which 
I think has good potential for general usefulness.)
* consider the best way to package a tiles-chain-config.xml in some 
JAR so that users don't have to handle the XML in order to use Tiles; 
the only real issue is how annoying it might be to have a near-copy 
of the chain-config.xml in the tiles repository, but anything much 
else is getting more complicated than its worth.  Maybe for now, we 
just accept that and move on.
* revise whatever parts of the user guide need revising to help 
people understand the changes
* spend at least a little time considering extensions to 
ForwardConfig to better support form prepopulation and "PagePrep", 
rather than re-rolling a homegrown variant for Struts 1.3  (See 
archived discussions on "ViewController" and "PagePrep", etc)

So, Frank, if you or anyone else finds any of those intriguing, 
there's another chance for doing some actual work.

The simplest thing that *anyone* can do would be to start trying to 
plug the nightly build into applications and (a) help identify any 
challenges which should be documented and (b) flush out bugs.  The 
intention is that Struts 1.3 will be drop-in compatible with any 
existing Struts 1.2 app which uses the default request processor, and 
will require only minimal changes to drop it in to a Struts 1.2 app 
which uses the TilesRequestProcessor.  Verifying/testing that 
intention will require real-world field-testing.

Joe

-- 
Joe Germuska            
Joe@Germuska.com  
http://blog.germuska.com    
"Narrow minds are weapons made for mass destruction"  -The Ex

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Don Brown <mr...@twdata.org>.
Of course, you and anyone else, are welcome to attack bugs in bugzilla 
to speed us along to another release.  What I personally would be 
interested in is for you to explore your "vision" of how action 
invocation should work, then rewrite a small app like the mail reader to 
use it.  I don't believe commons-chain belongs in the action tier so I'd 
be interested in being proven wrong. :)

Don

Frank W. Zammetti wrote:
> Since I've been involved in these discussions today, I wanted to "put my 
> money where my (rather substantially large) mouth is" and offer up 
> myself to do some actual work.
> 
> If there's anything you guys can pawn off on me, I wouldn't mind being 
> involved in some small way.  I don't think I could sign up for any major 
> pieces at the moment, but if you have some things you might be able to 
> offload to me, you'll have my best effort :)
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by "Frank W. Zammetti" <fz...@omnytex.com>.
Since I've been involved in these discussions today, I wanted to "put my 
money where my (rather substantially large) mouth is" and offer up 
myself to do some actual work.

If there's anything you guys can pawn off on me, I wouldn't mind being 
involved in some small way.  I don't think I could sign up for any major 
pieces at the moment, but if you have some things you might be able to 
offload to me, you'll have my best effort :)

-- 
Frank W. Zammetti
Founder and Chief Software Architect
Omnytex Technologies
http://www.omnytex.com

Don Brown wrote:
> Joe Germuska wrote:
> 
>> My inclination at this point is to treat the most complicated 
>> questions we're bumping up against as fertile ground for subprojects 
>> and contrib-type code until we really see what people want and what 
>> works.  I don't think it is necessary to wrestle them all to the 
>> ground at once.  Reviewing the latest roadmap, even some of the things 
>> I've already done or am planning on doing are a rew minor revs out.  
>> It's probably time to recalibrate the roadmap to our current interests 
>> and ideas.
> 
> 
> Agreed.  With chain in place, it is shockingly easy to develop a new 
> action framework, and I'd rather wait and put in a successful, tested 
> extension than put experimental code.  Lets go with ActionContext and 
> hopefully ViewContext, and call it 1.3.
> 
> In the meantime, I'll revive the Struts Action Invocation Framework 
> (SAIF - http://struts.sf.net/saif) to test out my POJO action idea.
> 
> Lets bump up 1.5 features to 1.4 and plan for 1.4 as the release that 
> includes the new action/form framework.  I'd also like to target 1.4 as 
> the release that doesn't depend on the Servlet API at all.  I'm getting 
> involved in portlet applications at work and am interested in using 
> Struts without cumbersome servlet wrapping hacks.
> 
> Don
> 
>>
>> I've copied some of
>> http://struts.apache.org/roadmap.html below; I left out the parts on 
>> which I didn't have direct comments.
>>
>>> Experimental Members
>>>
>>> ActionCommand - A Chain Command-like interface with one method...
>>> ActionContext - A Chain Context that implements the logical Action 
>>> class API.
>>> ViewContext - A Chain Context that implements the logical "Velocity 
>>> Tools" API.
>>
>>
>>
>> At this time, I am convinced that explicitly passing ActionContext 
>> through Struts' chain is sufficiently better than having all the 
>> commands have to share info about where to find key context attributes 
>> and having them frequently cast to WebContext or ServletWebContext 
>> that I would take this out of "experimental" state.
>>
>> I also don't see how ViewContext would be terribly experimental, 
>> unless we immediately rewrote the taglib classes to use it.  Even so, 
>> I'm not sure I believe it requires a long incubation period.
>>
>> After reading the section on ActionCommand, I could be persuaded to 
>> abandon my suggestion about changing Action in favor of presenting the 
>> ActionCommand interface, and "overloading" the <action> type attribute 
>> so that it might specify either an Action or an ActionCommand, or 
>> possibly adding a new attribute.   Ted wrote it so that this level of 
>> "smarts" would be deferred until "Struts 1.5"
>>
>>> The Commons Chain WebContext we now pass around Struts Chain could be 
>>> called the "StrutsContext" to differentiate it from the ActionContext 
>>> and ViewContext.
>>
>>
>>
>> I'm not sure this is an issue any more.  After trying to mix and match 
>> commands, I think it's worth stipulating that the 
>> ComposableRequestProcessor will always start the chain with an 
>> ActionContext.
>>
>>> 1.4 considerations
>>>
>>> Consider adding catalog element. Depending on how the work goes with 
>>> the experimental ActionCommand interface, we might identifiy a need 
>>> to add a catalog element to the Struts configuration, to support 
>>> using a Chain of ActionCommands.
>>
>>
>>
>> This has already been done or doesn't matter, depending on how you 
>> look at it.  There's direct support for looking up any command using 
>> the command/catalog attributes; on the other hand, if you want to 
>> specify an ActionCommand as the "type" for an ActionConfig, it seems 
>> like there's no clean way to support a catalog or any kind of lookup, 
>> nor a need, since the former solution exists.
>>
>>> 1.5 considerations
>>>
>>> Based on our own work with the "experimental" members inroduced in 
>>> 1.3.x, we might consider some other changes.
>>>
>>> Consider a "smart" action type. The idea is that a command in Struts 
>>> chain could look at the type indicated by the ActionMapping so both 
>>> Action classes and ActionCommand implementations are supported. 
>>> People could then mix-and-match Actions with ActionCommands (or even 
>>> chains of ActionCommands). We might even support placing an 
>>> ActionCommand interface on ActionForm, so people could skip having a 
>>> sepate Action or ActionCommand class. The ActionForm could do it all.
>>
>>
>>
>> As noted above, this seems like a necessity before 1.5 if you're going 
>> to actually use ActionCommand; I'm not quite sure how one would 
>> effectively designate ActionForm as a command; if one wants to have 
>> something "do it all," I don't think that thing should be called 
>> "ActionForm."
>>
>> Of course, this document has always just been a scratchpad of sorts, 
>> but perhaps now that a few of us are back to actively thinking about 
>> implementing future changes, we should revisit it and come up with one 
>> which reflects our intentions?
>>
>> Joe
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
> 
> 
> 
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by Don Brown <mr...@twdata.org>.
Joe Germuska wrote:
> My inclination at this point is to treat the most complicated questions 
> we're bumping up against as fertile ground for subprojects and 
> contrib-type code until we really see what people want and what works.  
> I don't think it is necessary to wrestle them all to the ground at 
> once.  Reviewing the latest roadmap, even some of the things I've 
> already done or am planning on doing are a rew minor revs out.  It's 
> probably time to recalibrate the roadmap to our current interests and 
> ideas.

Agreed.  With chain in place, it is shockingly easy to develop a new 
action framework, and I'd rather wait and put in a successful, tested 
extension than put experimental code.  Lets go with ActionContext and 
hopefully ViewContext, and call it 1.3.

In the meantime, I'll revive the Struts Action Invocation Framework 
(SAIF - http://struts.sf.net/saif) to test out my POJO action idea.

Lets bump up 1.5 features to 1.4 and plan for 1.4 as the release that 
includes the new action/form framework.  I'd also like to target 1.4 as 
the release that doesn't depend on the Servlet API at all.  I'm getting 
involved in portlet applications at work and am interested in using 
Struts without cumbersome servlet wrapping hacks.

Don

> 
> I've copied some of
> http://struts.apache.org/roadmap.html below; I left out the parts on 
> which I didn't have direct comments.
> 
>> Experimental Members
>>
>> ActionCommand - A Chain Command-like interface with one method...
>> ActionContext - A Chain Context that implements the logical Action 
>> class API.
>> ViewContext - A Chain Context that implements the logical "Velocity 
>> Tools" API.
> 
> 
> At this time, I am convinced that explicitly passing ActionContext 
> through Struts' chain is sufficiently better than having all the 
> commands have to share info about where to find key context attributes 
> and having them frequently cast to WebContext or ServletWebContext that 
> I would take this out of "experimental" state.
> 
> I also don't see how ViewContext would be terribly experimental, unless 
> we immediately rewrote the taglib classes to use it.  Even so, I'm not 
> sure I believe it requires a long incubation period.
> 
> After reading the section on ActionCommand, I could be persuaded to 
> abandon my suggestion about changing Action in favor of presenting the 
> ActionCommand interface, and "overloading" the <action> type attribute 
> so that it might specify either an Action or an ActionCommand, or 
> possibly adding a new attribute.   Ted wrote it so that this level of 
> "smarts" would be deferred until "Struts 1.5"
> 
>> The Commons Chain WebContext we now pass around Struts Chain could be 
>> called the "StrutsContext" to differentiate it from the ActionContext 
>> and ViewContext.
> 
> 
> I'm not sure this is an issue any more.  After trying to mix and match 
> commands, I think it's worth stipulating that the 
> ComposableRequestProcessor will always start the chain with an 
> ActionContext.
> 
>> 1.4 considerations
>>
>> Consider adding catalog element. Depending on how the work goes with 
>> the experimental ActionCommand interface, we might identifiy a need to 
>> add a catalog element to the Struts configuration, to support using a 
>> Chain of ActionCommands.
> 
> 
> This has already been done or doesn't matter, depending on how you look 
> at it.  There's direct support for looking up any command using the 
> command/catalog attributes; on the other hand, if you want to specify an 
> ActionCommand as the "type" for an ActionConfig, it seems like there's 
> no clean way to support a catalog or any kind of lookup, nor a need, 
> since the former solution exists.
> 
>> 1.5 considerations
>>
>> Based on our own work with the "experimental" members inroduced in 
>> 1.3.x, we might consider some other changes.
>>
>> Consider a "smart" action type. The idea is that a command in Struts 
>> chain could look at the type indicated by the ActionMapping so both 
>> Action classes and ActionCommand implementations are supported. People 
>> could then mix-and-match Actions with ActionCommands (or even chains 
>> of ActionCommands). We might even support placing an ActionCommand 
>> interface on ActionForm, so people could skip having a sepate Action 
>> or ActionCommand class. The ActionForm could do it all.
> 
> 
> As noted above, this seems like a necessity before 1.5 if you're going 
> to actually use ActionCommand; I'm not quite sure how one would 
> effectively designate ActionForm as a command; if one wants to have 
> something "do it all," I don't think that thing should be called 
> "ActionForm."
> 
> Of course, this document has always just been a scratchpad of sorts, but 
> perhaps now that a few of us are back to actively thinking about 
> implementing future changes, we should revisit it and come up with one 
> which reflects our intentions?
> 
> Joe
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by "Peter A. Pilgrim" <pe...@xenonique.co.uk>.
David Bowers wrote:
> Comment regarding the <action-bean> idea, though it looks like an
> enhancement like this might be put off until a later version.
> 
> I currently use Spring extensively to configure my Action objects
> using the Spring DelegatingActionProxy.  This works well on some
> fronts, but configuration is a little painful to have to define all my
> actions mappings in the struts-config.xml, and then define the actual
> bean with its dependencies in action-servlet.xml.  Since better
> Spring/IoC container support is already on the Struts roadmap, it's
> worth mentioning that the action-bean concept starts us down that
> road.
> 
> In the near term, I think a concept like this would make it easier for
> someone to build a better Spring add-on, where mappings and actions
> *with their dependencies* could be defined in the same file.  And I
> think it goes without saying, that more complex dependencies such as
> Chains could also be defined by the IoC container.  Adding an
> action-bean concept would allow the same actions class to have
> different functionality not only by the ActionMapping passed in as an
> argument, but also by having different dependencies injected.
> 
> This might not ever be part of struts - core, but it would be nice if
> it could at least be supported with an add-on using XSL transforms:
> 

Here is an example where XML namespace awareness would be
paramount useful.

> <action path="/somePath" bean="myBean"
>        validate="false" name="myForm" >
>     <forward name="success" path=".theTile"/>
> </action>
> 
> <action-bean id="myBean" class="com.xyz.actions.SomeAction">
>      <property name="businessDelegate"><ref bean="businessDelegate"/></property>
> </action-bean>
> 

<struts-config xmlns="http://struts.apache.org/struts-config" >
    <action-bean id="myBean" class="com.xyz.actions.SomeAction" >
       <spring:property name="businessDelegate"><ref bean="businessDelegate"/></property>
    </action-bean>
</struts-config>

> --or--
> 
> <action-bean id="myBean2" class="org.apache.commons.chain.impl.ChainBase">
>     <constructor-arg><list>
>         <ref bean="specialValidationCommand"/>
>         <bean class="org.xyz.actions.commands.SaveCommand">
>              <property name="businessDelegate"><ref
> bean="businessDelegate"/></property>
>         </bean>
>     </list></constructor-arg>
> </action-bean>
> 
> /David Bowers

<struts-config xmlns="http://struts.apache.org/struts-config" >
  <action-bean id="myBean2" class="org.apache.commons.chain.impl.ChainBase">
      <spring:constructor-arg><list>
          <spring:ref bean="specialValidationCommand"/>
          <spring:bean class="org.xyz.actions.commands.SaveCommand">
               <spring:property name="businessDelegate"><spring:ref
  		bean="businessDelegate"/></spring:property>
          </spring:bean>
      </spring:list></spring:constructor-arg>
  </action-bean>
</struts-config>

Obviously presupposes Digester rules for Spring that will be
registered during the parsing. It would also allow other IoC containers
to be plugged in natively to the Struts Config.

With regard to the Action Bean XML. Am I right in assuming that
the "execute()" method is assumed, if the bean is a type of chain
`Command' or `ActionCommand' or even an `Action'? You can override
the name of the execution method with a XML attribute e.g.

	<struts:action-bean id="myPayrollBackingBean"
		type="org.apache.foo.bar.OpenSourcePayroll"
     		method="specialMethod" />


> 
> On Mon, 14 Feb 2005 16:43:56 -0600, Joe Germuska <Jo...@germuska.com> wrote:
> 
>>Frank Z wrote:
>>
>>>>>This point made me think of something... What about the idea of adding the
>>>>>concept of an <action-bean> in struts-config?
>>
>>At 12:11 PM -0800 2/14/05, Don Brown wrote:
>>
>>>The question is whether there will be a one-to-one mapping between
>>>action-beans and action-mappings.  If 90%+ of the time there will
>>>be, this will needlessly complicate the config.  I suppose, however,
>>>if action mappings used wildcards heavily, this could come in handy,
>>>course then I'd argue for wildcards in the action-beans to help
>>>group them. :)
>>
>>I guess I figured on<action-bean> being an alternative to <action> in
>>that it would have a "path" property.  Maybe that's a bad idea, but
>>it would be easy enough to throw another chain command in there which
>>looked up the path against another store of expertise.
>>
>>Then again, it would presumably mean adding yet another property to
>>ActionContext (getActionBean()?)  That might be a bad path to head
>>down.
>>
>>OK, Frank, sorry; you're not on to anything.  ;^)  Just kidding --
>>good to think outside the box in all events.
>>
>>My inclination at this point is to treat the most complicated
>>questions we're bumping up against as fertile ground for subprojects
>>and contrib-type code until we really see what people want and what
>>works.  I don't think it is necessary to wrestle them all to the
>>ground at once.  Reviewing the latest roadmap, even some of the
>>things I've already done or am planning on doing are a rew minor revs
>>out.  It's probably time to recalibrate the roadmap to our current
>>interests and ideas.
>>
>>I've copied some of
>>http://struts.apache.org/roadmap.html below; I left out the parts on
>>which I didn't have direct comments.
>>
>>
>>>Experimental Members
>>>
>>>ActionCommand - A Chain Command-like interface with one method...
>>>ActionContext - A Chain Context that implements the logical Action class API.
>>>ViewContext - A Chain Context that implements the logical "Velocity
>>>Tools" API.
>>
>>At this time, I am convinced that explicitly passing ActionContext
>>through Struts' chain is sufficiently better than having all the
>>commands have to share info about where to find key context
>>attributes and having them frequently cast to WebContext or
>>ServletWebContext that I would take this out of "experimental" state.
>>
>>I also don't see how ViewContext would be terribly experimental,
>>unless we immediately rewrote the taglib classes to use it.  Even so,
>>I'm not sure I believe it requires a long incubation period.
>>
>>After reading the section on ActionCommand, I could be persuaded to
>>abandon my suggestion about changing Action in favor of presenting
>>the ActionCommand interface, and "overloading" the <action> type
>>attribute so that it might specify either an Action or an
>>ActionCommand, or possibly adding a new attribute.   Ted wrote it so
>>that this level of "smarts" would be deferred until "Struts 1.5"
>>
>>
>>>The Commons Chain WebContext we now pass around Struts Chain could
>>>be called the "StrutsContext" to differentiate it from the
>>>ActionContext and ViewContext.
>>
>>I'm not sure this is an issue any more.  After trying to mix and
>>match commands, I think it's worth stipulating that the
>>ComposableRequestProcessor will always start the chain with an
>>ActionContext.
>>
>>
>>>1.4 considerations
>>>
>>>Consider adding catalog element. Depending on how the work goes with
>>>the experimental ActionCommand interface, we might identifiy a need
>>>to add a catalog element to the Struts configuration, to support
>>>using a Chain of ActionCommands.
>>
>>This has already been done or doesn't matter, depending on how you
>>look at it.  There's direct support for looking up any command using
>>the command/catalog attributes; on the other hand, if you want to
>>specify an ActionCommand as the "type" for an ActionConfig, it seems
>>like there's no clean way to support a catalog or any kind of lookup,
>>nor a need, since the former solution exists.
>>
>>
>>>1.5 considerations
>>>
>>>Based on our own work with the "experimental" members inroduced in
>>>1.3.x, we might consider some other changes.
>>>
>>>Consider a "smart" action type. The idea is that a command in Struts
>>>chain could look at the type indicated by the ActionMapping so both
>>>Action classes and ActionCommand implementations are supported.
>>>People could then mix-and-match Actions with ActionCommands (or even
>>>chains of ActionCommands). We might even support placing an
>>>ActionCommand interface on ActionForm, so people could skip having a
>>>sepate Action or ActionCommand class. The ActionForm could do it all.
>>
>>As noted above, this seems like a necessity before 1.5 if you're
>>going to actually use ActionCommand; I'm not quite sure how one would
>>effectively designate ActionForm as a command; if one wants to have
>>something "do it all," I don't think that thing should be called
>>"ActionForm."
>>
>>Of course, this document has always just been a scratchpad of sorts,
>>but perhaps now that a few of us are back to actively thinking about
>>implementing future changes, we should revisit it and come up with
>>one which reflects our intentions?
>>
>>Joe
>>
>>--
>>Joe Germuska
>>Joe@Germuska.com
>>http://blog.germuska.com
>>"Narrow minds are weapons made for mass destruction"  -The Ex
>>
>>---------------------------------------------------------------------
>>To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
>>For additional commands, e-mail: dev-help@struts.apache.org
>>
>>
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
> 


-- 
Peter Pilgrim
            __ _____ _____ _____
           / //__  // ___// ___/   +  Serverside Java
          / /___/ // /__ / /__     +  Struts
         / // ___// ___// ___/     +  Expresso Committer
      __/ // /__ / /__ / /__       +  Independent Contractor
     /___//____//____//____/       +  Intrinsic Motivation
On Line Resume
    ||
    \\===>  `` http://www.xenonsoft.demon.co.uk/no-it-striker.html ''

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Re: Recalibrate Roadmap (Re: Action threadsafe)

Posted by David Bowers <vi...@gmail.com>.
Comment regarding the <action-bean> idea, though it looks like an
enhancement like this might be put off until a later version.

I currently use Spring extensively to configure my Action objects
using the Spring DelegatingActionProxy.  This works well on some
fronts, but configuration is a little painful to have to define all my
actions mappings in the struts-config.xml, and then define the actual
bean with its dependencies in action-servlet.xml.  Since better
Spring/IoC container support is already on the Struts roadmap, it's
worth mentioning that the action-bean concept starts us down that
road.

In the near term, I think a concept like this would make it easier for
someone to build a better Spring add-on, where mappings and actions
*with their dependencies* could be defined in the same file.  And I
think it goes without saying, that more complex dependencies such as
Chains could also be defined by the IoC container.  Adding an
action-bean concept would allow the same actions class to have
different functionality not only by the ActionMapping passed in as an
argument, but also by having different dependencies injected.

This might not ever be part of struts - core, but it would be nice if
it could at least be supported with an add-on using XSL transforms:

<action path="/somePath" bean="myBean"
       validate="false" name="myForm" >
    <forward name="success" path=".theTile"/>
</action>

<action-bean id="myBean" class="com.xyz.actions.SomeAction">
     <property name="businessDelegate"><ref bean="businessDelegate"/></property>
</action-bean>

--or--

<action-bean id="myBean2" class="org.apache.commons.chain.impl.ChainBase">
    <constructor-arg><list>
        <ref bean="specialValidationCommand"/>
        <bean class="org.xyz.actions.commands.SaveCommand">
             <property name="businessDelegate"><ref
bean="businessDelegate"/></property>
        </bean>
    </list></constructor-arg>
</action-bean>

/David Bowers

On Mon, 14 Feb 2005 16:43:56 -0600, Joe Germuska <Jo...@germuska.com> wrote:
> Frank Z wrote:
> >>>This point made me think of something... What about the idea of adding the
> >>>concept of an <action-bean> in struts-config?
> 
> At 12:11 PM -0800 2/14/05, Don Brown wrote:
> >The question is whether there will be a one-to-one mapping between
> >action-beans and action-mappings.  If 90%+ of the time there will
> >be, this will needlessly complicate the config.  I suppose, however,
> >if action mappings used wildcards heavily, this could come in handy,
> >course then I'd argue for wildcards in the action-beans to help
> >group them. :)
> 
> I guess I figured on<action-bean> being an alternative to <action> in
> that it would have a "path" property.  Maybe that's a bad idea, but
> it would be easy enough to throw another chain command in there which
> looked up the path against another store of expertise.
> 
> Then again, it would presumably mean adding yet another property to
> ActionContext (getActionBean()?)  That might be a bad path to head
> down.
> 
> OK, Frank, sorry; you're not on to anything.  ;^)  Just kidding --
> good to think outside the box in all events.
> 
> My inclination at this point is to treat the most complicated
> questions we're bumping up against as fertile ground for subprojects
> and contrib-type code until we really see what people want and what
> works.  I don't think it is necessary to wrestle them all to the
> ground at once.  Reviewing the latest roadmap, even some of the
> things I've already done or am planning on doing are a rew minor revs
> out.  It's probably time to recalibrate the roadmap to our current
> interests and ideas.
> 
> I've copied some of
> http://struts.apache.org/roadmap.html below; I left out the parts on
> which I didn't have direct comments.
> 
> >Experimental Members
> >
> >ActionCommand - A Chain Command-like interface with one method...
> >ActionContext - A Chain Context that implements the logical Action class API.
> >ViewContext - A Chain Context that implements the logical "Velocity
> >Tools" API.
> 
> At this time, I am convinced that explicitly passing ActionContext
> through Struts' chain is sufficiently better than having all the
> commands have to share info about where to find key context
> attributes and having them frequently cast to WebContext or
> ServletWebContext that I would take this out of "experimental" state.
> 
> I also don't see how ViewContext would be terribly experimental,
> unless we immediately rewrote the taglib classes to use it.  Even so,
> I'm not sure I believe it requires a long incubation period.
> 
> After reading the section on ActionCommand, I could be persuaded to
> abandon my suggestion about changing Action in favor of presenting
> the ActionCommand interface, and "overloading" the <action> type
> attribute so that it might specify either an Action or an
> ActionCommand, or possibly adding a new attribute.   Ted wrote it so
> that this level of "smarts" would be deferred until "Struts 1.5"
> 
> >The Commons Chain WebContext we now pass around Struts Chain could
> >be called the "StrutsContext" to differentiate it from the
> >ActionContext and ViewContext.
> 
> I'm not sure this is an issue any more.  After trying to mix and
> match commands, I think it's worth stipulating that the
> ComposableRequestProcessor will always start the chain with an
> ActionContext.
> 
> >1.4 considerations
> >
> >Consider adding catalog element. Depending on how the work goes with
> >the experimental ActionCommand interface, we might identifiy a need
> >to add a catalog element to the Struts configuration, to support
> >using a Chain of ActionCommands.
> 
> This has already been done or doesn't matter, depending on how you
> look at it.  There's direct support for looking up any command using
> the command/catalog attributes; on the other hand, if you want to
> specify an ActionCommand as the "type" for an ActionConfig, it seems
> like there's no clean way to support a catalog or any kind of lookup,
> nor a need, since the former solution exists.
> 
> >1.5 considerations
> >
> >Based on our own work with the "experimental" members inroduced in
> >1.3.x, we might consider some other changes.
> >
> >Consider a "smart" action type. The idea is that a command in Struts
> >chain could look at the type indicated by the ActionMapping so both
> >Action classes and ActionCommand implementations are supported.
> >People could then mix-and-match Actions with ActionCommands (or even
> >chains of ActionCommands). We might even support placing an
> >ActionCommand interface on ActionForm, so people could skip having a
> >sepate Action or ActionCommand class. The ActionForm could do it all.
> 
> As noted above, this seems like a necessity before 1.5 if you're
> going to actually use ActionCommand; I'm not quite sure how one would
> effectively designate ActionForm as a command; if one wants to have
> something "do it all," I don't think that thing should be called
> "ActionForm."
> 
> Of course, this document has always just been a scratchpad of sorts,
> but perhaps now that a few of us are back to actively thinking about
> implementing future changes, we should revisit it and come up with
> one which reflects our intentions?
> 
> Joe
> 
> --
> Joe Germuska
> Joe@Germuska.com
> http://blog.germuska.com
> "Narrow minds are weapons made for mass destruction"  -The Ex
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org