/** * Convenience for {@link #jmsQueueBuilder(DistributedSupplier)}. This * version creates a connection without any authentication parameters and * uses non-transacted sessions with {@code Session.AUTO_ACKNOWLEDGE} mode. * JMS {@link Message} objects are emitted to downstream. * <p> * <b>Note:</b> {@link javax.jms.Message} might not be serializable. In * that case you can use {@linkplain #jmsQueueBuilder(DistributedSupplier) * the builder} and add a projection. * * @param factorySupplier supplier to obtain JMS connection factory * @param name the name of the queue */ @Nonnull public static StreamSource<Message> jmsQueue( @Nonnull DistributedSupplier<? extends ConnectionFactory> factorySupplier, @Nonnull String name ) { return jmsQueueBuilder(factorySupplier) .destinationName(name) .build(); }
/** * Convenience for {@link #jmsTopicBuilder(DistributedSupplier)}. This * version creates a connection without any authentication parameters and * uses non-transacted sessions with {@code Session.AUTO_ACKNOWLEDGE} mode. * JMS {@link Message} objects are emitted to downstream. * <p> * <b>Note:</b> {@link javax.jms.Message} might not be serializable. In * that case you can use {@linkplain #jmsTopicBuilder(DistributedSupplier) * the builder} and add a projection. * * @param factorySupplier supplier to obtain JMS connection factory * @param name the name of the topic */ @Nonnull public static StreamSource<Message> jmsTopic( @Nonnull DistributedSupplier<? extends ConnectionFactory> factorySupplier, @Nonnull String name ) { return jmsTopicBuilder(factorySupplier) .destinationName(name) .build(); }