struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dave Newton <>
Subject Re: Where to put non action associated data
Date Mon, 01 Aug 2011 11:34:27 GMT
Meh, while I think turning this into something event-based is way overkill,
I wouldn't turn to chaining, either. I'd probably just use an interceptor,
AOP, or any other "around"-type solution.

I view actions as something a user can hit (insert mom-joke here), not as a
chunk of general-purpose functionality, even though in the end it'd act the
same--it's more of a semantic/cognitive difference.


 On Jul 31, 2011 2:27 PM, "Chris Pratt" <> wrote:
> This sounds like one of the very few legitimate uses of the chain result
> type. Check out
> (*Chris*)
> On Jul 31, 2011 9:50 AM, "Marcus Bond" <> wrote:
>> Hi,
>> Say I have a form where user can carry out a product search which hits an
>> action and returns a list of results - easy.. however in response to the
>> user changing their search criteria I want to also generate some search
>> terms which would be passed through to Ebay, google ads etc.. but not
> within
>> my action which is designed with one purpose in mind - to search my db
> (the
>> action doesn't know about google ads, ebay, AWS or any other thing that
>> comes along). Gut reaction here is to fire an event (say product changed)
>> and have some listeners do the work of generating the relevant google /
> ebay
>> stuff and storing this in the users session.
>> Firstly, is this how most of you would go about it?
>> Secondly in terms of the view side of things, whilst normally my action
>> would simply return 'success' I may want to tweak the view depending upon
>> which external source returned the best results (currently I use tiles
> I
>> don't think I can or should dynamically switch the result after my action
>> has processed).. How would you tackle this? By adding logic to the tile /
>> template jsp or some other means?
>> Can any of you share experiences of using Struts in apps like this and
>> you tackled similar scenarios or if maybe another framework is more
> suited?
>> You'll have to bear with me here since all my work thus far has had no
> need
>> to collaborate data from multiple sources in one page.
>> Regards and thanks in advance,
>> Marcus

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message