Skip to content

Commit

Permalink
HornetQJMSClient.createConnectionFactoryWithoutHA(JMSFactoryType....
Browse files Browse the repository at this point in the history
  • Loading branch information
harp077 committed Nov 23, 2021
1 parent 22cde47 commit 17d00a2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Binary file added hornetq/HornetQ_Spring-master.zip
Binary file not shown.
4 changes: 3 additions & 1 deletion src/main/java/jennom/hot/AppContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import javax.jms.Topic;
import jennom.jms.JmsExceptionListener;
import org.hornetq.api.jms.HornetQJMSClient;
import org.hornetq.api.jms.JMSFactoryType;
import org.hornetq.jms.client.HornetQTopic;
import org.springframework.core.task.SimpleAsyncTaskExecutor;
import org.springframework.core.task.TaskExecutor;
Expand Down Expand Up @@ -66,7 +67,8 @@ private ConnectionFactory createJmsConnectionFactory(JmsExceptionListener jmsExc
TransportConfiguration transportConfiguration =
new TransportConfiguration(NettyConnectorFactory.class.getName(), connDetails);
// HornetQJMSConnectionFactory(boolean ha, TransportConfiguration[] initialConnectors)
ConnectionFactory hornetCF = new HornetQJMSConnectionFactory(false, transportConfiguration);
//ConnectionFactory hornetCF = new HornetQJMSConnectionFactory(false, transportConfiguration);
ConnectionFactory hornetCF = HornetQJMSClient.createConnectionFactoryWithoutHA(JMSFactoryType.QUEUE_CF, transportConfiguration);
UserCredentialsConnectionFactoryAdapter userCF = new UserCredentialsConnectionFactoryAdapter();
userCF.setTargetConnectionFactory(hornetCF);
userCF.setUsername("romka");
Expand Down

0 comments on commit 17d00a2

Please sign in to comment.