-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/22262/
-----------------------------------------------------------

Review request for Ambari, John Speidel and Nate Cole.


Bugs: AMBARI-6028
    https://issues.apache.org/jira/browse/AMBARI-6028


Repository: ambari


Description
-------

For managed resource GET calls I wanted JSON response. 
{code}
{
 "a": "b"
}
{code}

Keeping {code}@Produces({"application/json"}){code}  on the @GET method gives a 
string-serialized output of the JSON
{code}
"{\"a\":\"b\"}"
{code}

However when I keep {code}@Produces({"text/plain", "application/json"}){code} 
correctly produces JSON.


Diffs
-----

  
ambari-server/src/main/java/org/apache/ambari/server/api/services/BaseService.java
 8953796 
  
ambari-server/src/main/java/org/apache/ambari/server/api/services/ViewSubResourceService.java
 135cd78 
  
ambari-server/src/test/java/org/apache/ambari/server/api/services/ViewSubResourceServiceTest.java
 2b2c269 
  
ambari-views/examples/weather-view/src/main/java/org/apache/ambari/view/weather/CityService.java
 0c7f0c5 
  ambari-views/src/main/java/org/apache/ambari/view/ViewResourceHandler.java 
2d42454 

Diff: https://reviews.apache.org/r/22262/diff/


Testing
-------

Manual test with ambari-views/examples.  Added new unit tests.  All existing 
tests pass ...

Results :

Tests run: 1654, Failures: 0, Errors: 0, Skipped: 13
…


[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 22:37.650s
[INFO] Finished at: Thu Jun 05 09:33:20 EDT 2014
[INFO] Final Memory: 37M/123M
[INFO] ------------------------------------------------------------------------


Thanks,

Tom Beerbower

Reply via email to