Search in sources :

Example 11 with TopicExchange

use of org.springframework.amqp.core.TopicExchange in project microservices by pwillhan.

the class RabbitAdminExample method main.

public static void main(String[] args) {
    CachingConnectionFactory factory = new CachingConnectionFactory("localhost");
    RabbitAdmin admin = new RabbitAdmin(factory);
    Queue queue = new Queue("test-queue");
    admin.declareQueue(queue);
    TopicExchange exchange = new TopicExchange("sample-topic-exchange");
    admin.declareExchange(exchange);
    admin.declareBinding(BindingBuilder.bind(queue).to(exchange).with("sample-key"));
    factory.destroy();
}
Also used : CachingConnectionFactory(org.springframework.amqp.rabbit.connection.CachingConnectionFactory) RabbitAdmin(org.springframework.amqp.rabbit.core.RabbitAdmin) Queue(org.springframework.amqp.core.Queue) TopicExchange(org.springframework.amqp.core.TopicExchange)

Aggregations

TopicExchange (org.springframework.amqp.core.TopicExchange)11 Capability (com.dell.cpsd.hdp.capability.registry.api.Capability)9 CapabilityProvider (com.dell.cpsd.hdp.capability.registry.api.CapabilityProvider)9 EndpointProperty (com.dell.cpsd.hdp.capability.registry.api.EndpointProperty)9 CapabilityRegistryException (com.dell.cpsd.hdp.capability.registry.client.CapabilityRegistryException)9 ListCapabilityProvidersResponse (com.dell.cpsd.hdp.capability.registry.client.callback.ListCapabilityProvidersResponse)9 ServiceTimeoutException (com.dell.cpsd.service.common.client.exception.ServiceTimeoutException)9 CompletableFuture (java.util.concurrent.CompletableFuture)9 MalformedURLException (java.net.MalformedURLException)8 URL (java.net.URL)8 UUID (java.util.UUID)8 EndpointCredentials (com.dell.cpsd.paqx.fru.rest.dto.EndpointCredentials)6 Credentials (com.dell.cpsd.virtualization.capabilities.api.Credentials)6 Date (java.util.Date)6 MessageProperties (com.dell.cpsd.virtualization.capabilities.api.MessageProperties)5 ClusterOperationResponse (com.dell.cpsd.paqx.fru.rest.dto.vcenter.ClusterOperationResponse)2 ClusterOperationRequest (com.dell.cpsd.virtualization.capabilities.api.ClusterOperationRequest)2 ClusterOperationRequestMessage (com.dell.cpsd.virtualization.capabilities.api.ClusterOperationRequestMessage)2 Queue (org.springframework.amqp.core.Queue)2 ListNodesRequest (com.dell.cpsd.paqx.fru.amqp.model.ListNodesRequest)1