diff --git a/src/Appwrite/Mqtt/Handler.php b/src/Appwrite/Mqtt/Handler.php index e398931d87..5cc162da25 100644 --- a/src/Appwrite/Mqtt/Handler.php +++ b/src/Appwrite/Mqtt/Handler.php @@ -166,6 +166,14 @@ class Handler implements MqttHandler $grantedTopics[$filter->topic] = [$document, $grantedQos]; } + \Utopia\CLI\Console::error('MQTT_SUB_DBG prefix=' . $connection->prefix + . ' uid=' . ($identity['userId'] ?? '(none)') + . ' roles=' . \json_encode($roles) + . ' filters=' . \json_encode(\array_map(fn ($f) => [$f->topic, $f->qos], $subscribe->filters())) + . ' allowed=' . \json_encode(\array_keys($allowed)) + . ' foundTopics=' . \json_encode(\array_keys($topicsById)) + . ' codes=' . \json_encode($suback->codes())); + if ($grantedTopics !== []) { $this->replayBacklog($connection, $projectDB, $grantedTopics); }