Sencha

JSON, JSR-303, Spring MVC and Ext.js

So I thought I’d post this in case others hit it. If you want to Spring MVC and POST JSON from an Ext JsonWriter to the server and have it populate your bean model and also get validated by JSR-303 validator then you’ll need to do a little work because it doesn’t work out of the box.

In the end I had to do some ugly classpath overriding to get it to work in the way I expected by writing my own modified version of Spring’s HandlerMethodInvoker. If you hit similar issues I suggest following this JIRA: http://jira.springframework.org/browse/SPR-7114 and feel free to use the attached code on the JIRA. It’s been working great for me now.

Author: Matt Goldspink

I'm a web developer based in the UK. I'm currently UI Architect at Vlocity, Inc, developing UI's on the Salesforce platform using a mix of Web Components, Angular.js and Lightning.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.