@Override public void setTimeToLive(long timeToLive) throws JMSException { delegate.setTimeToLive(timeToLive); }
@Override public JMSProducer setTimeToLive(long timeToLive) { try { producer.setTimeToLive(timeToLive); return this; } catch (JMSException e) { JMSRuntimeException e2 = new JMSRuntimeException(e.getMessage()); e2.initCause(e); throw e2; } }
producer = session.createProducer(destination); producer.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT); producer.setTimeToLive(msgTTL); initPayLoad(); running = true;
producer.setTimeToLive(ttl > 0 ? ttl : 0); producer.send(msg);
final Message message = createMessage(jmsSession, context, messageContent, flowFile, replyToQueue, priority); if (ttl == null) { producer.setTimeToLive(0L); } else { producer.setTimeToLive(ttl);
public void setTimeout(long timeout) { this.timeout = timeout; if (timeout >= 0 && producer != null) try { producer.setTimeToLive(timeout); } catch (Exception e) { } }
public FeedbackQueue(Session jmsSession, String queueName, int timeToLive) throws JMSException { this.jmsSession = jmsSession; Queue queue = jmsSession.createQueue(queueName); sender = jmsSession.createProducer(queue); sender.setTimeToLive(timeToLive); }
public void setTimeToLive(long timeToLive) throws ProducerException { try { this.producer.setTimeToLive(timeToLive); } catch (Exception e) { throw new ProducerException("Failed to set TimeToLive"); } }
/** Delegates the call to the wrapped producer. */ public void setTimeToLive(long timeToLive) throws JMSException { checkValidity(); producer.setTimeToLive(timeToLive); }
/** * Sets the maximum time to live for requests * * @throws JMSException */ public void setTimeToLive(long timeToLive) throws JMSException { getMessageProducer().setTimeToLive(timeToLive); }
/** Delegates the call to the wrapped producer. */ public void setTimeToLive(long timeToLive) throws JMSException { checkValidity(); producer.setTimeToLive(timeToLive); }
/** * Set the ttl * * @param timeToLive The value * @throws JMSException Thrown if an error occurs */ @Override public void setTimeToLive(final long timeToLive) throws JMSException { if (ActiveMQRALogger.LOGGER.isTraceEnabled()) { ActiveMQRALogger.LOGGER.trace("setTimeToLive(" + timeToLive + ")"); } producer.setTimeToLive(timeToLive); }
@Override public JMSProducer setTimeToLive(long timeToLive) { try { producer.setTimeToLive(timeToLive); return this; } catch (JMSException e) { JMSRuntimeException e2 = new JMSRuntimeException(e.getMessage()); e2.initCause(e); throw e2; } }
@Override public JMSProducer setTimeToLive(long timeToLive) { try { producer.setTimeToLive(timeToLive); return this; } catch (JMSException e) { JMSRuntimeException e2 = new JMSRuntimeException(e.getMessage()); e2.initCause(e); throw e2; } }
@Override public JMSProducer setTimeToLive(long timeToLive) { try { producer.setTimeToLive(timeToLive); return this; } catch (JMSException e) { JMSRuntimeException e2 = new JMSRuntimeException(e.getMessage()); e2.initCause(e); throw e2; } }
@Override public JMSProducer setTimeToLive(final long timeToLive) { try { producer.setTimeToLive(timeToLive); return this; } catch (final JMSException e) { final JMSRuntimeException e2 = new JMSRuntimeException(e.getMessage()); e2.initCause(e); throw e2; } }
@Override public JMSProducer setTimeToLive(long timeToLive) { try { producer.setTimeToLive(timeToLive); return this; } catch (JMSException e) { JMSRuntimeException e2 = new JMSRuntimeException(e.getMessage()); e2.initCause(e); throw e2; } }
public CollectDispatcher(TimeoutWatch timeoutWatch, JmsConnection jmsConnection, RunnerConfiguration runnerConfiguration, CollectorJobSchedulerService collectorJobScheduler, RunIndexWrapper<?> runIndexWrapper) throws JMSException { super(timeoutWatch, jmsConnection, runIndexWrapper.get().getCorrelationId(), runnerConfiguration.getMttl()); this.urlPackageSize = runnerConfiguration.getUrlPackageSize(); this.collectorJobScheduler = collectorJobScheduler; this.runIndexWrapper = runIndexWrapper; sender = session.createProducer(null); sender.setTimeToLive(runnerConfiguration.getMttl()); }
@Test public void testSetTimeToLive() throws Exception { Connection pconn = createConnection(); Session ps = pconn.createSession(false, Session.AUTO_ACKNOWLEDGE); MessageProducer p = ps.createProducer(ActiveMQServerTestCase.topic1); p.setTimeToLive(100L); ProxyAssertSupport.assertEquals(100L, p.getTimeToLive()); p.setTimeToLive(0L); ProxyAssertSupport.assertEquals(0L, p.getTimeToLive()); }
public static MessageProducer createMessageProducer( Session session, Destination destination, MessageProducerOption producerOption) throws JMSException { MessageProducer producer = session.createProducer(destination); producer.setDeliveryDelay(producerOption.getDeliveryDelay()); producer.setDeliveryMode(producerOption.getDeliveryMode()); producer.setDisableMessageTimestamp(producerOption.isDisableMessageTimestamp()); producer.setDisableMessageID(producerOption.isDisableMessageId()); producer.setPriority(producerOption.getPriority()); producer.setTimeToLive(producerOption.getTimeToLive()); return producer; }