Skip to content
Ralph Schaer edited this page Dec 7, 2013 · 4 revisions

1.1.3 - July 1, 2012

  • Revert the 1.1.2 change that automatically wraps responses of TREE_LOAD methods. This does not work if the result contains the root node in this case the method has to return only one object.

1.1.2 - June 30, 2012

  • Fix for writing output in the classes ExtDirectResponseBuilder and ApiController. The library used getBytes() but that does not work if the application is running on a platform where the default character set is not UTF-8. Now both classes use getBytes("UTF-8").

  • Fix for Issue 33. Added method setSuccess(boolean flag) to the class ExtDirectResponseBuilder.

  • Added code that wraps the result of a TREE_LOAD method in a collection if it's not already a collection or an array.

1.1.1 - June 13, 2012

  • Added the method ExtDirectResponseBuilder.setException(Exception exception). This method creates an exception response. Primarly used for implementations of HandlerExceptionResolver. Needed for exception handling of FORM_POST methods. This is possible with 1.0.x but was forgotten to implement in 1.1.0

  • Fix for Issue 32. Bug introduced with version 1.1.0 and it looks like it only appears with JDK-based proxies. The afterPropertiesSet (InitializingBean) method of RouterController was reading all the beans of the application context and got the normal bean instead of the JDK-based proxies. Looks like the afterPropertiesSet is running before the proxy bean post processor. Now the registration of the methods happens in the bean ch.ralscha.extdirectspring.controller.MethodRegistrar after receiving the ContextRefreshedEvent. At this point everything in the application context is proxied.

1.1.0 - May 29, 2012

  • Spring 3.0.7 is now the minimum requirement. Apart from that the library should still work with Java 1.5 and Servlet 2.4.

  • Removed deprecated code:

    • ExtDirectMethodType.TREE_LOADER. Replace it with ExtDirectMethodType.TREE_LOAD
    • Removed autowiring of Map extDirectSpringExceptionToMessage. Replace it with a extDirectSpringConfiguration bean. Configuration
  • The library writes JSON into the response with the help of the JsonHandler bean. It no longer uses the MappingJacksonHttpMessageConverter from Spring. There is a new config parameter streamResponse that specifies if the Jackson ObjectMapper should write the response directly into the response without setting the http header Content-Length (true) or first write the response into an internal buffer, set the Content-Length header and write the JSON into the Servlet response (false, default).

  • @ExtDirectMethod annotation scanning now happens at the application startup and logs errors and warning if there are configuration errors. Version 1.0.x is scanning for annotated methods at the first request to api.js.

  • Added support for @RequestHeader annotation.

  • FORM_POST handling changed. These methods now must have a return type of void and no longer need the @ResponseBody annotation. With the help of ExtDirectResponseBuilder the result has to be created and written into the http response. There is no longer a difference between methods with file upload and without file upload.

      ExtDirectResponseBuilder.create(servletRequest, servletResponse)
           .addResultProperty("key", value)
           .addErrors(...)
           .buildAndWrite(); 
    

    OR

      ExtDirectResponseBuilder builder = new ExtDirectResponseBuilder(servletRequest, servletResponse);
      builder.addResultProperty("key", value);
      builder.addErrors(...);
      builder.buildAndWrite(); 
    

Changelog for older version 1.0.x

Clone this wiki locally