[ 
https://issues.apache.org/jira/browse/CAMEL-7914?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Davy De Waele updated CAMEL-7914:
---------------------------------
    Description: 
When an error occurs in the Camel MQTT endpoint, the CallbackConnection 
onFailure callback simply disconnects the connection.

At that point there doesn't seem to be any mechanism to reconnect to the broker.

{noformat}
            public void onFailure(Throwable value) {
                connection.disconnect(new Callback<Void>() {
                    public void onSuccess(Void value) {
                    }

                    public void onFailure(Throwable e) {
                        LOG.debug("Failed to disconnect from " + 
configuration.getHost() + ". This exception is ignored.", e);
                    }
                });
            }
{noformat}

  was:
When an error occurs in the Camel MQTT endpoint, the CallbackConnection 
onFailure callback simply disconnects the session.

At that point there doesn't seem to be any mechanism to reconnect to the broker.

{noformat}
            public void onFailure(Throwable value) {
                connection.disconnect(new Callback<Void>() {
                    public void onSuccess(Void value) {
                    }

                    public void onFailure(Throwable e) {
                        LOG.debug("Failed to disconnect from " + 
configuration.getHost() + ". This exception is ignored.", e);
                    }
                });
            }
{noformat}


> MQTT Endpoint disconnects on failure. Does not reconnect
> --------------------------------------------------------
>
>                 Key: CAMEL-7914
>                 URL: https://issues.apache.org/jira/browse/CAMEL-7914
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-mqtt
>    Affects Versions: 2.14.0
>            Reporter: Davy De Waele
>
> When an error occurs in the Camel MQTT endpoint, the CallbackConnection 
> onFailure callback simply disconnects the connection.
> At that point there doesn't seem to be any mechanism to reconnect to the 
> broker.
> {noformat}
>             public void onFailure(Throwable value) {
>                 connection.disconnect(new Callback<Void>() {
>                     public void onSuccess(Void value) {
>                     }
>                     public void onFailure(Throwable e) {
>                         LOG.debug("Failed to disconnect from " + 
> configuration.getHost() + ". This exception is ignored.", e);
>                     }
>                 });
>             }
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to