Search in sources :

Example 1 with QueueListingDetails

use of com.microsoft.azure.storage.queue.QueueListingDetails in project camel by apache.

the class QueueServiceProducer method listQueues.

private void listQueues(Exchange exchange) throws Exception {
    CloudQueue client = QueueServiceUtil.createQueueClient(getConfiguration());
    QueueServiceRequestOptions opts = QueueServiceUtil.getRequestOptions(exchange);
    QueueListingDetails details = (QueueListingDetails) exchange.getIn().getHeader(QueueServiceConstants.QUEUE_LISTING_DETAILS);
    if (details == null) {
        details = QueueListingDetails.ALL;
    }
    Iterable<CloudQueue> list = client.getServiceClient().listQueues(getConfiguration().getQueuePrefix(), details, opts.getRequestOpts(), opts.getOpContext());
    ExchangeUtil.getMessageForResponse(exchange).setBody(list);
}
Also used : QueueListingDetails(com.microsoft.azure.storage.queue.QueueListingDetails) CloudQueue(com.microsoft.azure.storage.queue.CloudQueue)

Aggregations

CloudQueue (com.microsoft.azure.storage.queue.CloudQueue)1 QueueListingDetails (com.microsoft.azure.storage.queue.QueueListingDetails)1