You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by Nate Cole <nc...@hortonworks.com> on 2016/02/01 23:24:16 UTC

Review Request 43068: Allow post of Version Definition file directly

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

Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley.


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


Repository: ambari


Description
-------

Add an endpoint to allow posting of the Version Definition file directly.  The API doesn't like XML in json, so the body is base64'ed and added to a json object that is then passed to the framework.


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java 43eb424 
  ambari-server/src/main/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProvider.java 3533293 
  ambari-server/src/test/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProviderTest.java dbac1b4 

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


Testing
-------

Manual.  Automated Pending.


Thanks,

Nate Cole


Re: Review Request 43068: Allow post of Version Definition file directly

Posted by Nate Cole <nc...@hortonworks.com>.

> On Feb. 1, 2016, 6:07 p.m., Jonathan Hurley wrote:
> > ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java, lines 82-88
> > <https://reviews.apache.org/r/43068/diff/1/?file=1228823#file1228823line82>
> >
> >     I take it this is because we can't add non-JSON to the request handler, otherwise it'll complain about some parse error? 
> >     
> >     Neat idea to make it base64'd and pass that value in a small JSON wrapper. Let's hope we don't run out of heap :)

Correct.  The amount this would get called (rare) and size of the XML (sub-128k for sure), we better not run out.  We pull more data in metrics and host requests then we would this (rare) call.


- Nate


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


On Feb. 1, 2016, 6:09 p.m., Nate Cole wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43068/
> -----------------------------------------------------------
> 
> (Updated Feb. 1, 2016, 6:09 p.m.)
> 
> 
> Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley.
> 
> 
> Bugs: AMBARI-14870
>     https://issues.apache.org/jira/browse/AMBARI-14870
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Add an endpoint to allow posting of the Version Definition file directly.  The API doesn't like XML in json, so the body is base64'ed and added to a json object that is then passed to the framework.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java 43eb424 
>   ambari-server/src/main/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProvider.java 3533293 
>   ambari-server/src/test/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProviderTest.java dbac1b4 
> 
> Diff: https://reviews.apache.org/r/43068/diff/
> 
> 
> Testing
> -------
> 
> Manual.  Automated:
> 
> Tests run: 3794, Failures: 0, Errors: 0, Skipped: 31
> 
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 30:58.048s
> [INFO] Finished at: Mon Feb 01 17:52:28 EST 2016
> [INFO] Final Memory: 47M/725M
> [INFO] ------------------------------------------------------------------------
> 
> 
> Thanks,
> 
> Nate Cole
> 
>


Re: Review Request 43068: Allow post of Version Definition file directly

Posted by Jonathan Hurley <jh...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43068/#review117300
-----------------------------------------------------------


Ship it!





ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java (lines 82 - 88)
<https://reviews.apache.org/r/43068/#comment178460>

    I take it this is because we can't add non-JSON to the request handler, otherwise it'll complain about some parse error? 
    
    Neat idea to make it base64'd and pass that value in a small JSON wrapper. Let's hope we don't run out of heap :)


- Jonathan Hurley


On Feb. 1, 2016, 5:24 p.m., Nate Cole wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43068/
> -----------------------------------------------------------
> 
> (Updated Feb. 1, 2016, 5:24 p.m.)
> 
> 
> Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley.
> 
> 
> Bugs: AMBARI-14870
>     https://issues.apache.org/jira/browse/AMBARI-14870
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Add an endpoint to allow posting of the Version Definition file directly.  The API doesn't like XML in json, so the body is base64'ed and added to a json object that is then passed to the framework.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java 43eb424 
>   ambari-server/src/main/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProvider.java 3533293 
>   ambari-server/src/test/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProviderTest.java dbac1b4 
> 
> Diff: https://reviews.apache.org/r/43068/diff/
> 
> 
> Testing
> -------
> 
> Manual.  Automated Pending.
> 
> 
> Thanks,
> 
> Nate Cole
> 
>


Re: Review Request 43068: Allow post of Version Definition file directly

Posted by Alejandro Fernandez <af...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43068/#review117305
-----------------------------------------------------------


Ship it!




Ship It!

- Alejandro Fernandez


On Feb. 1, 2016, 11:09 p.m., Nate Cole wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43068/
> -----------------------------------------------------------
> 
> (Updated Feb. 1, 2016, 11:09 p.m.)
> 
> 
> Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley.
> 
> 
> Bugs: AMBARI-14870
>     https://issues.apache.org/jira/browse/AMBARI-14870
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Add an endpoint to allow posting of the Version Definition file directly.  The API doesn't like XML in json, so the body is base64'ed and added to a json object that is then passed to the framework.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java 43eb424 
>   ambari-server/src/main/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProvider.java 3533293 
>   ambari-server/src/test/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProviderTest.java dbac1b4 
> 
> Diff: https://reviews.apache.org/r/43068/diff/
> 
> 
> Testing
> -------
> 
> Manual.  Automated:
> 
> Tests run: 3794, Failures: 0, Errors: 0, Skipped: 31
> 
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 30:58.048s
> [INFO] Finished at: Mon Feb 01 17:52:28 EST 2016
> [INFO] Final Memory: 47M/725M
> [INFO] ------------------------------------------------------------------------
> 
> 
> Thanks,
> 
> Nate Cole
> 
>


Re: Review Request 43068: Allow post of Version Definition file directly

Posted by Dmitro Lisnichenko <dl...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43068/#review117389
-----------------------------------------------------------


Ship it!




Ship It!

- Dmitro Lisnichenko


On Feb. 2, 2016, 1:09 a.m., Nate Cole wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43068/
> -----------------------------------------------------------
> 
> (Updated Feb. 2, 2016, 1:09 a.m.)
> 
> 
> Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley.
> 
> 
> Bugs: AMBARI-14870
>     https://issues.apache.org/jira/browse/AMBARI-14870
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> Add an endpoint to allow posting of the Version Definition file directly.  The API doesn't like XML in json, so the body is base64'ed and added to a json object that is then passed to the framework.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java 43eb424 
>   ambari-server/src/main/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProvider.java 3533293 
>   ambari-server/src/test/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProviderTest.java dbac1b4 
> 
> Diff: https://reviews.apache.org/r/43068/diff/
> 
> 
> Testing
> -------
> 
> Manual.  Automated:
> 
> Tests run: 3794, Failures: 0, Errors: 0, Skipped: 31
> 
> [INFO] ------------------------------------------------------------------------
> [INFO] BUILD SUCCESS
> [INFO] ------------------------------------------------------------------------
> [INFO] Total time: 30:58.048s
> [INFO] Finished at: Mon Feb 01 17:52:28 EST 2016
> [INFO] Final Memory: 47M/725M
> [INFO] ------------------------------------------------------------------------
> 
> 
> Thanks,
> 
> Nate Cole
> 
>


Re: Review Request 43068: Allow post of Version Definition file directly

Posted by Nate Cole <nc...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43068/
-----------------------------------------------------------

(Updated Feb. 1, 2016, 6:09 p.m.)


Review request for Ambari, Dmitro Lisnichenko and Jonathan Hurley.


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


Repository: ambari


Description
-------

Add an endpoint to allow posting of the Version Definition file directly.  The API doesn't like XML in json, so the body is base64'ed and added to a json object that is then passed to the framework.


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/api/services/VersionDefinitionService.java 43eb424 
  ambari-server/src/main/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProvider.java 3533293 
  ambari-server/src/test/java/org/apache/ambari/server/controller/internal/VersionDefinitionResourceProviderTest.java dbac1b4 

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


Testing (updated)
-------

Manual.  Automated:

Tests run: 3794, Failures: 0, Errors: 0, Skipped: 31

[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 30:58.048s
[INFO] Finished at: Mon Feb 01 17:52:28 EST 2016
[INFO] Final Memory: 47M/725M
[INFO] ------------------------------------------------------------------------


Thanks,

Nate Cole