spring-projects / spring-data-rest

Simplifies building hypermedia-driven REST web services on top of Spring Data repositories
https://spring.io/projects/spring-data-rest
Apache License 2.0
916 stars 563 forks source link

JSONP support removed? #97

Open ArloL opened 11 years ago

ArloL commented 11 years ago

Currently the wiki states that JSONP is supported.

But I cant get it working. Also commit 8fcf568 removed the customization parameter.

What is the status on JSONP?

jbrisbin commented 11 years ago

After some discussion we decided that the logical place for the JSONP support was in an external post-processor or filter rather than directly in the Spring Data REST code itself. Rossen (Spring MVC author) thought it would be a good idea to develop a general-purpose JSONP component that could be used for any Spring MVC application. So that's the direction we decided to go. I'm hopeful that such a filter would be included as part of Spring MVC itself. I don't have any solid information on what version that would appear in, though.

For the interim, a simple content-negotiating servlet Filter should do the trick.

ptahchiev commented 11 years ago

Hi I'm also interested in the JSONP filter. Any updates on when it is expected? And wouldn't it be better to leave the existing implementation in Spring Data REST until the filter is ready? Also I don't understand how to implement the "simple content-negotiating servlet Filter" - if you couldn't point me to a test-case or some example I would be really grateful. Thank you :)