[
https://issues.apache.org/jira/browse/AMBARI-11566?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14566628#comment-14566628
]
Jonathan Hurley commented on AMBARI-11566:
------------------------------------------
Tests pass for me:
Tests run: 3022, Failures: 0, Errors: 0, Skipped: 21
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 23:17 min
[INFO] Finished at: 2015-05-31T13:56:21-04:00
[INFO] Final Memory: 46M/1319M
[INFO] ------------------------------------------------------------------------
> Alert Definition Source Field Has Numerical Values Converted To Strings On
> Creation Or Update
> ---------------------------------------------------------------------------------------------
>
> Key: AMBARI-11566
> URL: https://issues.apache.org/jira/browse/AMBARI-11566
> Project: Ambari
> Issue Type: Bug
> Components: ambari-server
> Affects Versions: 2.0.0
> Reporter: Jonathan Hurley
> Assignee: Jonathan Hurley
> Fix For: 2.1.0
>
> Attachments: AMBARI-11566.patch
>
>
> When creating or updating an alert definition from the API, any numerical
> values in the {{source}} element are converted into {{String}} and stored in
> the database as such. This causes de-serialization problems for definitions
> on Ambari Server restart.
> The problem stems from how Ambari converts the JSON body to a Map inside of
> {{JsonRequestBodyParser}}. This uses a {{Map<String,String>}} instead of a
> {{Map<String,Object>}}. As a result, the {{JsonObject}} has it's {{asText()}}
> method used to retrieve the value.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)