deleteMessage()


从Queue中删除已被成功处理的message
接收到的message被成功处理后,应及时从Queue中删除

方法参数DeleteMessageRequest

queueName : String : required
receiptHandle : String : required

需要删除的message的receiptHandle

方法返回void

deleteMessageBatch()


从Queue中批量删除已被成功处理的message
此操作不具有原子性,可能部分message成功删除,部分失败

方法参数DeleteMessageBatchRequest

queueName : String : required
deleteMessageBatchRequestEntryList : List< DeleteMessageBatchRequestEntry > : required

需要删除的message列表
DeleteMessageBatchRequestEntry字段包括

  1. receiptHandle : String : required

方法返回DeleteMessageBatchResponse

successful : List< String >

成功的message的receiptHandle列表

failed : List< MessageBatchErrorEntry >

失败的message的receiptHandle列表及对应异常
MessageBatchErrorEntry类型的具体内容可参见sendMessageBatch()

results matching ""

    No results matching ""