@@ -530,16 +530,19 @@ public void useSslProtocol(SSLContext context)
530530 }
531531
532532 /**
533- * Returns true if automatic connection recovery is enabled, false otherwise
533+ * Returns true if <a href="http://www.rabbitmq.com/api-guide.html#recovery">automatic connection recovery</a>
534+ * is enabled, false otherwise
534535 * @return true if automatic connection recovery is enabled, false otherwise
536+ * @see <a href="http://www.rabbitmq.com/api-guide.html#recovery">Automatic Recovery</a>
535537 */
536538 public boolean isAutomaticRecoveryEnabled () {
537539 return automaticRecovery ;
538540 }
539541
540542 /**
541- * Enables or disables automatic connection recovery
543+ * Enables or disables <a href="http://www.rabbitmq.com/api-guide.html#recovery"> automatic connection recovery</a>.
542544 * @param automaticRecovery if true, enables connection recovery
545+ * @see <a href="http://www.rabbitmq.com/api-guide.html#recovery">Automatic Recovery</a>
543546 */
544547 public void setAutomaticRecoveryEnabled (boolean automaticRecovery ) {
545548 this .automaticRecovery = automaticRecovery ;
@@ -548,6 +551,7 @@ public void setAutomaticRecoveryEnabled(boolean automaticRecovery) {
548551 /**
549552 * Returns true if topology recovery is enabled, false otherwise
550553 * @return true if topology recovery is enabled, false otherwise
554+ * @see <a href="http://www.rabbitmq.com/api-guide.html#recovery">Automatic Recovery</a>
551555 */
552556 @ SuppressWarnings ("unused" )
553557 public boolean isTopologyRecoveryEnabled () {
@@ -557,6 +561,7 @@ public boolean isTopologyRecoveryEnabled() {
557561 /**
558562 * Enables or disables topology recovery
559563 * @param topologyRecovery if true, enables topology recovery
564+ * @see <a href="http://www.rabbitmq.com/api-guide.html#recovery">Automatic Recovery</a>
560565 */
561566 public void setTopologyRecoveryEnabled (boolean topologyRecovery ) {
562567 this .topologyRecovery = topologyRecovery ;
@@ -567,7 +572,13 @@ protected FrameHandlerFactory createFrameHandlerFactory() throws IOException {
567572 }
568573
569574 /**
570- * Create a new broker connection
575+ * Create a new broker connection, picking the first available address from
576+ * the list.
577+ *
578+ * If <a href="http://www.rabbitmq.com/api-guide.html#recovery">automatic connection recovery</a>
579+ * is enabled, the connection returned by this method will be {@link Recoverable}. Future
580+ * reconnection attempts will pick a random accessible address from the provided list.
581+ *
571582 * @param addrs an array of known broker addresses (hostname/port pairs) to try in order
572583 * @return an interface to the connection
573584 * @throws IOException if it encounters a problem
@@ -577,11 +588,18 @@ public Connection newConnection(Address[] addrs) throws IOException {
577588 }
578589
579590 /**
580- * Create a new broker connection
591+ * Create a new broker connection, picking the first available address from
592+ * the list.
593+ *
594+ * If <a href="http://www.rabbitmq.com/api-guide.html#recovery">automatic connection recovery</a>
595+ * is enabled, the connection returned by this method will be {@link Recoverable}. Future
596+ * reconnection attempts will pick a random accessible address from the provided list.
597+ *
581598 * @param executor thread execution service for consumers on the connection
582599 * @param addrs an array of known broker addresses (hostname/port pairs) to try in order
583600 * @return an interface to the connection
584601 * @throws java.io.IOException if it encounters a problem
602+ * @see <a href="http://www.rabbitmq.com/api-guide.html#recovery">Automatic Recovery</a>
585603 */
586604 public Connection newConnection (ExecutorService executor , Address [] addrs )
587605 throws IOException
@@ -617,7 +635,12 @@ public ConnectionParams params(ExecutorService executor) {
617635 }
618636
619637 /**
620- * Create a new broker connection
638+ * Create a new broker connection.
639+ *
640+ * If <a href="http://www.rabbitmq.com/api-guide.html#recovery">automatic connection recovery</a>
641+ * is enabled, the connection returned by this method will be {@link Recoverable}. Reconnection
642+ * attempts will always use the address configured on {@link ConnectionFactory}.
643+ *
621644 * @return an interface to the connection
622645 * @throws IOException if it encounters a problem
623646 */
@@ -628,7 +651,12 @@ public Connection newConnection() throws IOException {
628651 }
629652
630653 /**
631- * Create a new broker connection
654+ * Create a new broker connection.
655+ *
656+ * If <a href="http://www.rabbitmq.com/api-guide.html#recovery">automatic connection recovery</a>
657+ * is enabled, the connection returned by this method will be {@link Recoverable}. Reconnection
658+ * attempts will always use the address configured on {@link ConnectionFactory}.
659+ *
632660 * @param executor thread execution service for consumers on the connection
633661 * @return an interface to the connection
634662 * @throws IOException if it encounters a problem
0 commit comments