ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dmytro Sen" <d...@hortonworks.com>
Subject Review Request 28395: Refactor version comparisons to use function
Date Mon, 24 Nov 2014 17:44:53 GMT

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

Review request for Ambari, Alejandro Fernandez and Dmitro Lisnichenko.


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


Repository: ambari


Description
-------

In Ambari 1.7.0, we started introducing checks for the HDP version like
stack_is_hdp22_or_further = not (stack_version.startswith('2.0') or stack_version.startswith('2.1'))
This may lead to problems in future HDP versions.
Instead, we should create a function/class for doing version comparisons.
ambari-server.py already has a method called compare_versions() that compares the each segment
of a version (separated by dots).


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/controller/ControllerModule.java a02f49d

  ambari-server/src/test/java/org/apache/ambari/server/orm/InMemoryDefaultTestModule.java
1484698 

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


Testing
-------

[INFO] Ambari Main ....................................... SUCCESS [4.979s]
[INFO] Apache Ambari Project POM ......................... SUCCESS [0.327s]
[INFO] Ambari Web ........................................ SUCCESS [49.858s]
[INFO] Ambari Views ...................................... SUCCESS [2.629s]
[INFO] Ambari Admin View ................................. SUCCESS [10.618s]
[INFO] Ambari Server ..................................... SUCCESS [31:41.344s]
[INFO] Ambari Agent ...................................... SUCCESS [14.152s]
[INFO] Ambari Client ..................................... SUCCESS [0.097s]
[INFO] Ambari Python Client .............................. SUCCESS [0.372s]
[INFO] Ambari Groovy Client .............................. SUCCESS [11.151s]
[INFO] Ambari Shell ...................................... SUCCESS [0.038s]
[INFO] Ambari Python Shell ............................... SUCCESS [0.056s]
[INFO] Ambari Groovy Shell ............................... SUCCESS [7.568s]


Thanks,

Dmytro Sen


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