spring-projects/spring-framework — pull request #493 by royclarkson (2014-03-21 20:05:30+00:00)
Title: SPR-9488 Add GsonHttpMessageConverter

This commit adds support to read and write JSON using using Gson. The
GsonHttpMessageConverter includes several convenience properties for
configuring the internal GsonBuilder. Some of these properties default
to settings that make Gson behave more consistently with Jackson.

By default Gson converts byte arrays to JSON arrays instead of a Base64
encoded string. GsonHttpMessageConverter includes a type adapter to
read and write Base64 encoded byte arrays, which is enabled by
default.

RestTemplate will enable GsonHttpMessageConverter, only if Jackson 1
and 2 are not found on the class path, because by default
GsonHttpMessageConverter supports the same media types as Jackson.

Issue: SPR-9488