incubator-ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From swa...@apache.org
Subject svn commit: r1459982 - in /incubator/ambari/trunk: CHANGES.txt ambari-server/src/main/java/org/apache/ambari/server/api/handlers/QueryCreateHandler.java
Date Fri, 22 Mar 2013 20:53:26 GMT
Author: swagle
Date: Fri Mar 22 20:53:26 2013
New Revision: 1459982

URL: http://svn.apache.org/r1459982
Log:
AMBARI-1689. 500 Exception creating service component during install. (Sumit Mohanty via swagle)

Modified:
    incubator/ambari/trunk/CHANGES.txt
    incubator/ambari/trunk/ambari-server/src/main/java/org/apache/ambari/server/api/handlers/QueryCreateHandler.java

Modified: incubator/ambari/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/CHANGES.txt?rev=1459982&r1=1459981&r2=1459982&view=diff
==============================================================================
--- incubator/ambari/trunk/CHANGES.txt (original)
+++ incubator/ambari/trunk/CHANGES.txt Fri Mar 22 20:53:26 2013
@@ -509,6 +509,9 @@ Trunk (unreleased changes):
 
  BUG FIXES
 
+ AMBARI-1689. 500 Exception creating service component during install. (Sumit 
+ Mohanty via swagle)
+
  AMBARI-1504. Hosts show physical CPUs, instead of cores. (Sumit Mohanty 
  via swagle)
 

Modified: incubator/ambari/trunk/ambari-server/src/main/java/org/apache/ambari/server/api/handlers/QueryCreateHandler.java
URL: http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-server/src/main/java/org/apache/ambari/server/api/handlers/QueryCreateHandler.java?rev=1459982&r1=1459981&r2=1459982&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-server/src/main/java/org/apache/ambari/server/api/handlers/QueryCreateHandler.java
(original)
+++ incubator/ambari/trunk/ambari-server/src/main/java/org/apache/ambari/server/api/handlers/QueryCreateHandler.java
Fri Mar 22 20:53:26 2013
@@ -65,13 +65,14 @@ public class QueryCreateHandler extends 
     ResourceInstance createResource = getResourceFactory().createResource(
         entry.getKey(), request.getResource().getIds());
 
+    RequestBody requestBody = new RequestBody();
+    requestBody.setBody(request.getBody().getBody());
+    for (Map<String, Object> map : entry.getValue()) {
+      requestBody.addPropertySet(new NamedPropertySet("", map));
+    }
+
     return persist(createResource,
-        new RequestBody() {
-          @Override
-          public Set<Map<String, Object>> getPropertySets() {
-            return entry.getValue();
-          }
-        }
+        requestBody
       );
   }
 



Mime
View raw message