|
|
|
@ -48,6 +48,7 @@ import org.thingsboard.server.common.data.DeviceProfile; |
|
|
|
import org.thingsboard.server.common.data.DeviceTransportType; |
|
|
|
import org.thingsboard.server.common.data.TransportPayloadType; |
|
|
|
import org.thingsboard.server.common.data.device.profile.MqttTopics; |
|
|
|
import org.thingsboard.server.common.data.id.DeviceId; |
|
|
|
import org.thingsboard.server.common.data.id.OtaPackageId; |
|
|
|
import org.thingsboard.server.common.data.ota.OtaPackageType; |
|
|
|
import org.thingsboard.server.common.data.rpc.RpcStatus; |
|
|
|
@ -928,6 +929,9 @@ public class MqttTransportHandler extends ChannelInboundHandlerAdapter implement |
|
|
|
gatewaySessionHandler.onGatewayDisconnect(); |
|
|
|
} |
|
|
|
deviceSessionCtx.setDisconnected(); |
|
|
|
context.onAuthFailure(address); |
|
|
|
ChannelHandlerContext ctx = deviceSessionCtx.getChannel(); |
|
|
|
ctx.close(); |
|
|
|
} |
|
|
|
deviceSessionCtx.release(); |
|
|
|
} |
|
|
|
@ -1066,4 +1070,9 @@ public class MqttTransportHandler extends ChannelInboundHandlerAdapter implement |
|
|
|
deviceSessionCtx.onDeviceUpdate(sessionInfo, device, deviceProfileOpt); |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public void onDeviceDeleted(DeviceId deviceId) { |
|
|
|
doDisconnect(); |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|