William has posted 6 posts at DZone. View Full User Profile

Enterprise RIA with Spring 3, Flex 4 and GraniteDS

01.25.2011
| 47868 views |
  • submit to reddit

Conclusion

That was a long article, but at least I hope it gave you a good idea about the client+server RIA platform concept of GraniteDS. Applications can be written faster with a lot less code, and still have a clean architecture with clearly separated layers.

Published at DZone with permission of its author, William Draï.

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)

Comments

Nuttapong Maneenate replied on Sat, 2011/02/12 - 9:59am

Why step mvn install it error ? [ERROR] Failed to execute goal org.sonatype.flexmojos:flexmojos-maven-plugin:3.8 :compile-swf (default-compile-swf) on project gdsspringflex-flex: Error compilin g! -> [Help 1]

Lucas Marino replied on Tue, 2011/02/22 - 11:05pm

Thank you for your work is excellent. I am interested in your articles and I would ask permission to translate into Spanish and post mentioning the source of course. If you agree email me. My email is marinoluck@gmail.com or answer me in this article. Thank you very much. Lucas Marino

Arthur Vernon replied on Wed, 2011/02/23 - 5:22pm

With the Data Push part of the tutorial, what facilities exist within the framework to identify the source of an update to avoid adding a new author twice to the list? As it currently stands, when I take this code "as is" and add a new author, the code 1. Adds the author to the authors list at creation time. 2. Adds it a second time as a result of the observer. I suppose the trusting solution is to maintain the list only via the observer.

William Draï replied on Thu, 2011/02/24 - 3:55pm in response to: Nuttapong Maneenate

@Nuttapong : Not sure what happens here, maybe try to reset you maven repo.

@Arthur : Right, the recommended solution is to keep only the observer. Unfortunately there is currently no way of knowing where the update comes from (local, remoting or push).

Chris Jansen replied on Fri, 2011/02/25 - 11:24am

I had to specify a version for maven-jetty-plugin to get it to run inside of Spring STS IDE.  Great tutorial too - thank for writing it up!

Richard Van Der Laan replied on Tue, 2011/03/08 - 6:09am

Hi there,

I am unable to extract the extended data from the validation exception, as described in the example:

function(event:TideFaultEvent):void {

    if (event.fault.faultCode == 'Validation.Failed') {        // Do something interesting, for example show the first error message-->        Alert.show(event.fault.extendedData.invalidValues[0].message);    }}
 The problem is that fault (type mx.rpc.Fault) has no extendedData property and the property cannot dynamically be accessed. Is this due to an API change? Or am I doing something wrong?

Deepak Srivastav replied on Fri, 2011/03/11 - 8:01am

my entity attached with a form is not updated in the database ie the effect of updating entity in flex side does not update the entity the method of service is called each time but the entity remained same .I will greatly appreciate any kind of help

iain starks replied on Fri, 2011/04/01 - 5:43am

I failed to do jetty:run-war after creating the archetype, getting a java.lang.NoSuchMethodError: javax.persistence.spi.PersistenceUnitInfo.getValidationMode()Ljavax/persistence/ValidationMode; The version ins persistence-api 1.0 doesn't have this method, but it was being pulled in as well from the hibernate-jpa-2.0-api-1.0.0.Final.jar So I removed the dependency: javax.persistence persistence-api 1.0 From the java pom and re-build and that seemed to get me going.

Eric Be replied on Mon, 2011/05/02 - 11:12pm

Hi, Great article! I was wondering if there was a way to access your completed exmaple/application to see the entire sources of everything. I can't find a d/l link anywhere in the tutorial and the archetype project doesn't include any of your more detailed classes/interfaces/etc. Thanks! Eric

Lou Leal replied on Mon, 2011/07/18 - 3:18pm in response to: Richard Van Der Laan

According to this http://www.graniteds.org/jira/browse/GDS-846 this error was fixed in 2.2.-_SP2 but I updated my pom to this version of granite and the same error occurs. I guess it didn't get fixed...

Dmitry Kv replied on Tue, 2011/08/09 - 11:03am in response to: Lou Leal

should be
(event.extendedData.invalidValues[0].message);

Khent Johnson replied on Fri, 2011/09/02 - 2:41pm

Hello! Just got in here. I used the most recent release of GraniteDS and same with Eric I'd like to access your complete example and if possible could anyone share the links of guide related to the topic. I'll be glad and thankful to any response. Cheers! GAR Labs

Sanjay Patel replied on Wed, 2012/08/29 - 7:53am

Thanks. This is very nice article to get started. 

Can you please add or guide how to get flexmojos wrapper goal working? 

Gary Huitson replied on Wed, 2012/09/12 - 10:03am in response to: Richard Van Der Laan

I think theres a mistake in the example code

The line should read...

Alert.show(event.extendedData.invalidValues[0].message);  

The extendedData is a property of event not event.fault 

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.