3

A machine has connected to solace, and I want another machine to connect, but it alerts the Exception as below:

org.eclipse.paho.client.mqttv3.internal.ExceptionHelper.createMqttException(ExceptionHelper.java:28)

org.eclipse.paho.client.mqttv3.internal.ClientState.notifyReceivedAck(ClientState.java:885)

org.eclipse.paho.client.mqttv3.internal.CommsReceiver.run(CommsReceiver.java:118) java.lang.Thread.run(Unknown Source)

If I disconnect one machine,the another machine could connect. Whether only one machine can be connected default? If so, how to set it so that many machines are able to connect.

Russell Sim
  • 1,693
  • 2
  • 14
  • 22
Jeffrey
  • 105
  • 3
  • 11

1 Answers1

3

It is likely that both instances of your application is trying to connect using the same clientId. The MQTT protocol requires that each client connection use an unique clientId.

3.1.3.1 Client Identifier

The Client Identifier (ClientId) identifies the Client to the Server. Each Client connecting to the Server has a unique ClientId. The ClientId MUST be used by Clients and by Servers to identify state that they hold relating to this MQTT Session between the Client and the Server [MQTT-3.1.3-2].

For Solace Systems Implementation,

  • ClientIds can be up to 128 bytes in length
  • ClientIds can contain any UTF-8 characters as allowed by Section 1.5.3
Community
  • 1
  • 1
Russell Sim
  • 1,693
  • 2
  • 14
  • 22