ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Levas" <rle...@hortonworks.com>
Subject Re: Review Request 30120: Add getUpdateDirectives to org.apache.ambari.server.api.resources.ResourceDefinition and use when handling PUT requests
Date Tue, 27 Jan 2015 18:52:07 GMT

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

(Updated Jan. 27, 2015, 1:52 p.m.)


Review request for Ambari, John Speidel, Robert Nettleton, and Tom Beerbower.


Changes
-------

Fixed commed as suggested.


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


Repository: ambari


Description
-------

Add `getUpdateDirectives` method to `org.apache.ambari.server.api.resources.ResourceDefinition`:

```
  public Collection<String> getUpdateDirectives();
```

Add default implementation to `org.apache.ambari.server.api.resources.BaseResourceDefinition`
to return an empty Set

Update `org.apache.ambari.server.api.services.RequestFactory` to process _update directives_
like it processes _create directives_ - see `org.apache.ambari.server.api.services.RequestFactory#createPostRequest`


Diffs (updated)
-----

  ambari-server/src/main/java/org/apache/ambari/server/api/predicate/PredicateCompiler.java
7deabb2 
  ambari-server/src/main/java/org/apache/ambari/server/api/predicate/QueryLexer.java e7051a1

  ambari-server/src/main/java/org/apache/ambari/server/api/resources/BaseResourceDefinition.java
f98779c 
  ambari-server/src/main/java/org/apache/ambari/server/api/resources/ResourceDefinition.java
7632e64 
  ambari-server/src/main/java/org/apache/ambari/server/api/services/BaseRequest.java 7494491

  ambari-server/src/main/java/org/apache/ambari/server/api/services/RequestFactory.java 649e210

  ambari-server/src/test/java/org/apache/ambari/server/api/services/BaseRequestTest.java 27fc077

  ambari-server/src/test/java/org/apache/ambari/server/api/services/RequestFactoryTest.java
5c56670 

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


Testing
-------

#Jenkins test results:

Running org.apache.ambari.server.api.services.RequestFactoryTest
Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.351 sec

Running org.apache.ambari.server.api.services.GetRequestTest
Tests run: 16, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.959 sec

Running org.apache.ambari.server.api.services.PostRequestTest
Tests run: 16, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.911 sec

Running org.apache.ambari.server.api.services.PutRequestTest
Tests run: 16, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.902 sec

Running org.apache.ambari.server.api.services.DeleteRequestTest
Tests run: 16, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.902 sec

Complete ambari-server tests
Tests run: 2576, Failures: 0, Errors: 0, Skipped: 15


[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:11 h
[INFO] Finished at: 2015-01-21T13:43:07+00:00
[INFO] Final Memory: 43M/514M
[INFO] ------------------------------------------------------------------------


Thanks,

Robert Levas


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message