This forum is now a read-only archive. All commenting, posting, registration services have been turned off. Those needing community support and/or wanting to ask questions should refer to the Tag/Forum map, and to http://spring.io/questions for a curated list of stackoverflow tags that Pivotal engineers, and the community, monitor.
I have recently started working with flex and the spring integration was the first question that came to my mind. What I plan on doing is integrating my flex apps with spring via web services.
I just finished a POC tonight, exposing my Spring middle tier via Xfire webservices in my web tier, secured with acegi. Now that the webservices are properly secured, it should be pretty straight-forward to hook up the flex client.
The only gotcha I ran into with the webservices was not being able to advise my web service implementation class with JSR-181 annotations or the http invoker proxy that it uses to make rpcs to the middle tier. HttpInvokerProxyFactoryBean is a final class, so it can't be advised and Xfire will pick up the annotations from the proxy and try to map it to the url a second time which causes an exception. Consequently, I had to create another class that I could advise for security purposes that I otherwise would not need.
Last edited by the_fryar; Apr 28th, 2007, 10:23 PM.
Hi, the webservices one alternative, but when you have a site that make several queries to the database, this alternative is too expensive. My question is żexist other alternative to access to the business tier with remote object? or other capabilitie of flex.
I have been actively working on a project that exposes Web Services that are consumed by Flex. Most of my work is in the MT side with very little on the Flex side of the house. But the Flex guys are a bean bag toss away.
If you are going to build a closed system, then go with BlazeDS and remoting. You'll get good performance and good support.
We want an open system where our Flex interface is just one of any possible points of consumption.
There really isn't much in the way of integrating Flex and Spring-WS if your app is just consuming the web services.
However, Flex has a number of short comings around it's support for SOAP. Here is a brief list of the comments:
1) BAD: Flex doesn't support a number of SOAP related features that you might like (like WS-Security)
2) GOOD: Flex has a nice tool to code gen classes to enable typesafe management of requests and responses.
3) BAD: The code gen tool doesn't like the IMPORT wsdl tag. If, like us, you create one or more common XSD that are leveraged by multiple Services, the Code gen tool will recreate the common objects for each of the different services.
4) BAD: Most of the flex demos have you creating a web service object, load the wsdl, then execute the operation. If you follow this pattern, EVERY SINGLE WS CALL IS TWO CALLS.
5) GOOD: It is very easy to call simple web services by simply created a webservice object, pointing to the WSDL, getting the operation, passing in the parameters, and fire away.
6) BAD: The generated flex code doesn't support a lot of the XSD types (for example, enums)
We started with a real joke of Flex developer that established a horrible architecture that was unmanagable that included modifying the autogenerated code because "most of it isn't necessary"!!!
Today, we have three strong technical people that are taking on Flex and beating it.