You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cloudstack.apache.org by "Sanjay Tripathi (JIRA)" <ji...@apache.org> on 2013/04/24 14:33:16 UTC

[jira] [Comment Edited] (CLOUDSTACK-1903) API:MS: deleteAlerts API responds with error even though required parameters are specified

    [ https://issues.apache.org/jira/browse/CLOUDSTACK-1903?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13640370#comment-13640370 ] 

Sanjay Tripathi edited comment on CLOUDSTACK-1903 at 4/24/13 12:32 PM:
-----------------------------------------------------------------------

Parth,

In the deleteAlert API call, the parameter you are passing is "date", you have to pass one of the three mentioned parameter i.e. ids, type or olderthan and the parameter you passed is not one of them.
And in the error message it is clearly saying that "either ids, type or olderthan must be specified ", if you want error message to be more clear, i'll work on it or you can suggest one.

Can you please confirm this?
                
      was (Author: sanjay.tripathi):
    Parth,

In the deleteAlert API call, the parameter you are passing is "data", you have to pass one of the three mentioned parameter i.e. ids, type or olderthan and the parameter you passed is not one of them.

Can you please confirm this?

                  
> API:MS: deleteAlerts API responds with error even though required parameters are specified
> ------------------------------------------------------------------------------------------
>
>                 Key: CLOUDSTACK-1903
>                 URL: https://issues.apache.org/jira/browse/CLOUDSTACK-1903
>             Project: CloudStack
>          Issue Type: Bug
>      Security Level: Public(Anyone can view this level - this is the default.) 
>          Components: API, Management Server
>    Affects Versions: 4.2.0
>         Environment: Master # 171
>            Reporter: Parth Jagirdar
>            Assignee: Sanjay Tripathi
>         Attachments: Screen Shot 2013-04-02 at 9.37.44 PM.png
>
>
> Error 431 is retuned by deleteEvents even though required parameters (Atleast one) ID or Category Or Older than date.
> Refer to FS for more details.
> https://cwiki.apache.org/CLOUDSTACK/ability-to-delete-or-archive-events-and-alerts.html#AbilitytodeleteorarchiveEventsandAlerts-%257B%257DDeleteorArchiveAlerts%257B%257D
> From FS:
> In the above mentioned APIs, id, type and olderthan are optional parameters but while calling the APIs atleast one of them is required.
> Refer to screen attached.
> Following is apilog.log::
> 2013-04-02 21:36:46,291 INFO  [cloud.api.ApiServer] (catalina-exec-5:null) (userId=2 accountId=2 sessionId=0C73E2C61CD035A6DE0166028B4197EC) 10.216.51.174 -- GET command=listAlerts&response=json&sessionkey=EAGzdD1SnlPsoDLFQ9p8sN8Mk3U%3D&listAll=true&page=1&pagesize=20&_=1364963809516 200 { "listalertsresponse" : { "count":1 ,"alert" : [  {"id":"71fbf30d-74c0-4047-a22e-4049025f4012","type":13,"description":"No usage server process running","sent":"2013-04-02T21:31:51-0700"} ] } }
> 2013-04-02 21:37:00,674 INFO  [cloud.api.ApiServer] (catalina-exec-17:null) (userId=2 accountId=2 sessionId=0C73E2C61CD035A6DE0166028B4197EC) 10.216.51.174 -- GET command=deleteAlerts&response=json&sessionkey=EAGzdD1SnlPsoDLFQ9p8sN8Mk3U%3D&date=2013-04-10&_=1364963823793 431 either ids, type or olderthan must be specified
> 2013-04-02 21:37:00,909 INFO  [cloud.api.ApiServer] (catalina-exec-1:null) (userId=2 accountId=2 sessionId=0C73E2C61CD035A6DE0166028B4197EC) 10.216.51.174 -- GET command=listAlerts&response=json&sessionkey=EAGzdD1SnlPsoDLFQ9p8sN8Mk3U%3D&listAll=true&page=1&pagesize=20&_=1364963824042 200 { "listalertsresponse" : { "count":1 ,"alert" : [  {"id":"71fbf30d-74c0-4047-a22e-4049025f4012","type":13,"description":"No usage server process running","sent":"2013-04-02T21:31:51-0700"} ] } }

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira