Anyone using laszlo and spring mind sharing some of their architecture ideas or experiences?
Anyone using laszlo and spring mind sharing some of their architecture ideas or experiences?
I've been using Spring and Laszlo, but I'm not sure if my approach is the best use of the combined technologies. Specifically, I am looking at the laszlo data binding and rpc methods of interacting with the backend, and wondering if conventional Spring usage fits the bill.
Essentially, I am using the same stack as the Spring samples: Dao->Domain->Controller->Model+View. I've found an AbstractXmlView, and I'm using that to feed laszlo XML 'views'.
I think that the architecture coincides with this article:
http://osteele.com/archives/2003/08/rethinking-mvc
If you are using an RIA with client side logic, and have the ability to talk to the server with soap, xml-rpc, java-rpc or http, is there a better alternative than serving up XmlViews? (by the way, it appears that laszlo uses httpclient to talk to the web server).
Thanks.
I guess that you are referring to "AbstractXsltView", as I could not find a "AbstractXmlView" in the Spring distribution 1.1.2. Is that so? Also, can you please describe briefly how you use it?
What I am planning to do with my current knowledge is:
This way I can return the XML to Laszlo (or whatever else), andCode:public class LaszloController extends org.springframework.web.servlet.mvc.Controller { public ModelAndView handleRequest(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException{ <prepare the XML (I am using JDOM>, doc = my XML document (JDOM Document object) new XMLOutputter().output(doc,response.getOutputStream()); response.getOutputStream().close(); return null; } }
consume in a Laszlo dataset. I guess there must be a better way though,
because the Controller above is primarily intended to be used in a
HTTP browser(expecting HTML) I guess.
Also, some questions:
- How to handle large datasets? I mean, if there are 5,000 employees
of XML produced, how to handle this in Laszlo (andSpring)?
- Can Hessian, Burlap, or HttpInvoker be used for this purpose?
Thanks,
Turgay Zengin
I found an AbstractXmlView at:
http://www.sateh.com/index.php?node=5
This sounds like the way your are going, which works fine. It is particularly nice if you are using other view technologies, like jstl. With regard to large DataSets and the like, the trade-off is more client resources and longer load time for faster and more responsive app with less round trips. It depends on your users and how they need to work.
I haven't tried hessian or burlap, so I would be curious to hear about your experiences.
using AbstractXsltView without actually setting an xslt will just output the XML.
Cool - thanks for the tip.Originally Posted by stueccles