• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Flex with Struts; Is it good?

 
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I read in some tutorials on the web that implementing Flex on Struts is not good design pattern !!!.

Because I don't know Flex (try to learn) so unable to understand why.

Q. 1> Why is it not good design ?
Q. 2> How to implement best way Flex RIA with Struts if require?


thanks
regards.
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Who says it's not good?

It might not be the way *I'd* do a Flex project, but Struts serves up data suitable for a Flex front end just as well as anything else. (Well, Struts 2 does--you don't mention which version of Struts you're using. I wouldn't recommend Struts 1.)
 
Ranveer K Kumar
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

David Newton wrote:Who says it's not good?

It might not be the way *I'd* do a Flex project, but Struts serves up data suitable for a Flex front end just as well as anything else. (Well, Struts 2 does--you don't mention which version of Struts you're using. I wouldn't recommend Struts 1.)



I am using Struts 1.2 (or 1.3). I am very NEW to Flex so wondering about the front end.
As flex getting data as XML (other format too but for now) and struts forwarding to response(jsp) so my Q is how to forward to Flex?
As I understand (on basis of some tutorials, may be I wrong) flex getting data with struts as follows:

Action (forward)> JSP > Flex

Here JSP converting data (here as XML) for Flex. Now I want to know is it possible to not use JSP and direct send from Struts Action to Flex, if possible then is it the good way...
please suggest...

thanks
regards
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There are any number of ways to create XML.

If you're not doing anything *but* Flex, however, there are easier ways, and there are *certainly* better ways than Struts 1.
 
Ranch Hand
Posts: 263
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Flex with Struts is a pretty good design.

I have converted a Struts based Web (html front-end) application to one with a Flex front-end.
We simply wrote new set of JSP pages which started returning XML instead of HTML, and in struts config file we forwarded to these pages. So, the server side we had a good solution whereby we could return HTML or XML!

Other good things:
1. Flex has a Flex IDE (now called Flash IDE), which is created out of Eclipse IDE.
2. Flex uses ActionScript as programming language; which is very similar to Java.

So, for Java Programmers, Flex and Struts are a very good combination.
 
reply
    Bookmark Topic Watch Topic
  • New Topic