Skip to content

Commit

Permalink
CAMEL-20300: camel-jms - Add resolver for creating custom temporary q… (
Browse files Browse the repository at this point in the history
#13433)

CAMEL-20300: camel-jms - Add resolver for creating custom temporary queues that IBM brokers and others would need for custom need when clients create queues. Also make Camel delete the temporary queue when stopping.
  • Loading branch information
davsclaus committed Mar 10, 2024
1 parent 7765249 commit e962337
Show file tree
Hide file tree
Showing 27 changed files with 872 additions and 204 deletions.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class ActiveMQEndpointUriFactory extends org.apache.camel.support.compone
private static final Set<String> SECRET_PROPERTY_NAMES;
private static final Set<String> MULTI_VALUE_PREFIXES;
static {
Set<String> props = new HashSet<>(99);
Set<String> props = new HashSet<>(100);
props.add("acceptMessagesWhileStopping");
props.add("acknowledgementModeName");
props.add("allowAdditionalHeaders");
Expand Down Expand Up @@ -108,6 +108,7 @@ public class ActiveMQEndpointUriFactory extends org.apache.camel.support.compone
props.add("subscriptionShared");
props.add("synchronous");
props.add("taskExecutor");
props.add("temporaryQueueResolver");
props.add("testConnectionOnStartup");
props.add("timeToLive");
props.add("transacted");
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class AMQPEndpointUriFactory extends org.apache.camel.support.component.E
private static final Set<String> SECRET_PROPERTY_NAMES;
private static final Set<String> MULTI_VALUE_PREFIXES;
static {
Set<String> props = new HashSet<>(98);
Set<String> props = new HashSet<>(99);
props.add("acceptMessagesWhileStopping");
props.add("acknowledgementModeName");
props.add("allowAdditionalHeaders");
Expand Down Expand Up @@ -107,6 +107,7 @@ public class AMQPEndpointUriFactory extends org.apache.camel.support.component.E
props.add("subscriptionShared");
props.add("synchronous");
props.add("taskExecutor");
props.add("temporaryQueueResolver");
props.add("testConnectionOnStartup");
props.add("timeToLive");
props.add("transacted");
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,8 @@ public boolean configure(CamelContext camelContext, Object obj, String name, Obj
case "synchronous": getOrCreateConfiguration(target).setSynchronous(property(camelContext, boolean.class, value)); return true;
case "taskexecutor":
case "taskExecutor": getOrCreateConfiguration(target).setTaskExecutor(property(camelContext, org.springframework.core.task.TaskExecutor.class, value)); return true;
case "temporaryqueueresolver":
case "temporaryQueueResolver": getOrCreateConfiguration(target).setTemporaryQueueResolver(property(camelContext, org.apache.camel.component.jms.TemporaryQueueResolver.class, value)); return true;
case "testconnectiononstartup":
case "testConnectionOnStartup": getOrCreateConfiguration(target).setTestConnectionOnStartup(property(camelContext, boolean.class, value)); return true;
case "timetolive":
Expand Down Expand Up @@ -397,6 +399,8 @@ public Class<?> getOptionType(String name, boolean ignoreCase) {
case "synchronous": return boolean.class;
case "taskexecutor":
case "taskExecutor": return org.springframework.core.task.TaskExecutor.class;
case "temporaryqueueresolver":
case "temporaryQueueResolver": return org.apache.camel.component.jms.TemporaryQueueResolver.class;
case "testconnectiononstartup":
case "testConnectionOnStartup": return boolean.class;
case "timetolive":
Expand Down Expand Up @@ -598,6 +602,8 @@ public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
case "synchronous": return getOrCreateConfiguration(target).isSynchronous();
case "taskexecutor":
case "taskExecutor": return getOrCreateConfiguration(target).getTaskExecutor();
case "temporaryqueueresolver":
case "temporaryQueueResolver": return getOrCreateConfiguration(target).getTemporaryQueueResolver();
case "testconnectiononstartup":
case "testConnectionOnStartup": return getOrCreateConfiguration(target).isTestConnectionOnStartup();
case "timetolive":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,8 @@ public boolean configure(CamelContext camelContext, Object obj, String name, Obj
case "synchronous": target.getConfiguration().setSynchronous(property(camelContext, boolean.class, value)); return true;
case "taskexecutor":
case "taskExecutor": target.getConfiguration().setTaskExecutor(property(camelContext, org.springframework.core.task.TaskExecutor.class, value)); return true;
case "temporaryqueueresolver":
case "temporaryQueueResolver": target.getConfiguration().setTemporaryQueueResolver(property(camelContext, org.apache.camel.component.jms.TemporaryQueueResolver.class, value)); return true;
case "testconnectiononstartup":
case "testConnectionOnStartup": target.getConfiguration().setTestConnectionOnStartup(property(camelContext, boolean.class, value)); return true;
case "timetolive":
Expand Down Expand Up @@ -376,6 +378,8 @@ public Class<?> getOptionType(String name, boolean ignoreCase) {
case "synchronous": return boolean.class;
case "taskexecutor":
case "taskExecutor": return org.springframework.core.task.TaskExecutor.class;
case "temporaryqueueresolver":
case "temporaryQueueResolver": return org.apache.camel.component.jms.TemporaryQueueResolver.class;
case "testconnectiononstartup":
case "testConnectionOnStartup": return boolean.class;
case "timetolive":
Expand Down Expand Up @@ -570,6 +574,8 @@ public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
case "synchronous": return target.getConfiguration().isSynchronous();
case "taskexecutor":
case "taskExecutor": return target.getConfiguration().getTaskExecutor();
case "temporaryqueueresolver":
case "temporaryQueueResolver": return target.getConfiguration().getTemporaryQueueResolver();
case "testconnectiononstartup":
case "testConnectionOnStartup": return target.getConfiguration().isTestConnectionOnStartup();
case "timetolive":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class JmsEndpointUriFactory extends org.apache.camel.support.component.En
private static final Set<String> SECRET_PROPERTY_NAMES;
private static final Set<String> MULTI_VALUE_PREFIXES;
static {
Set<String> props = new HashSet<>(98);
Set<String> props = new HashSet<>(99);
props.add("acceptMessagesWhileStopping");
props.add("acknowledgementModeName");
props.add("allowAdditionalHeaders");
Expand Down Expand Up @@ -107,6 +107,7 @@ public class JmsEndpointUriFactory extends org.apache.camel.support.component.En
props.add("subscriptionShared");
props.add("synchronous");
props.add("taskExecutor");
props.add("temporaryQueueResolver");
props.add("testConnectionOnStartup");
props.add("timeToLive");
props.add("transacted");
Expand Down

0 comments on commit e962337

Please sign in to comment.