Skip to content

Commit

Permalink
Merge pull request #7 from protegeproject/remove-channel-transacted
Browse files Browse the repository at this point in the history
Remove channel transacted
  • Loading branch information
alexsilaghi authored Nov 14, 2024
2 parents 4b03061 + 0a1743a commit 4868a0c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
</parent>
<groupId>edu.stanford.protege</groupId>
<artifactId>webprotege-ipc</artifactId>
<version>1.0.5</version>
<version>1.0.6</version>
<name>webprotege-ipc</name>
<description>Inter Process Communication framework</description>
<properties>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ public SimpleMessageListenerContainer replyListenerContainer(ConnectionFactory c
SimpleMessageListenerContainer container = new SimpleMessageListenerContainer();
container.setConnectionFactory(connectionFactory);
container.setQueues(replyQueue);
container.setChannelTransacted(false);
container.setConcurrency("15-20");
return container;
}
Expand All @@ -125,6 +126,7 @@ public SimpleMessageListenerContainer messageListenerContainers() {
SimpleMessageListenerContainer container = new SimpleMessageListenerContainer();
container.setQueueNames(getCommandQueue());
container.setConnectionFactory(connectionFactory);
container.setChannelTransacted(false);
container.setMessageListener(rabbitMqCommandHandlerWrapper());
container.setConcurrency("15-20");
return container;
Expand All @@ -134,7 +136,7 @@ public SimpleMessageListenerContainer messageListenerContainers() {
@ConditionalOnProperty(prefix = "webprotege.rabbitmq", name = "commands-subscribe", havingValue = "true", matchIfMissing = true)
public void createBindings() {
try (Connection connection = connectionFactory.createConnection();
Channel channel = connection.createChannel(true)) {
Channel channel = connection.createChannel(false)) {
channel.exchangeDeclare(COMMANDS_EXCHANGE, "direct", true);
channel.queueDeclare(getCommandQueue(), true, false, false, null);
channel.queueDeclare(getCommandResponseQueue(), true, false, false, null);
Expand Down

0 comments on commit 4868a0c

Please sign in to comment.