question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can not subscribe to a reserved topic

See original GitHub issue

Hi, I am trying to subscribe a topic from a web app and get an error message "Uncaught cannot subscribe to topic array since one of them is a reserved topic ‘$aws/things/xxxxxxxxxxxxxxxxx/shadow/get/accepted’. Here is my code: this.thingShadow.on("connect", () => { this.thingShadow.subscribe(["$aws/things/xxxxxxxxxxxxxxxxx/shadow/get/accepted"], {}, (error: any) => { console.log("subscribe ", error); });

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
bentranmyriotacommented, Jun 29, 2017

Hi, Thanks for the advice. I have moved to use aws/aws-sdk-js a while back. FYI, the web app is not on the Iot Device. I tried to subscribe to the iot server in a hope of getting notifications whenever the iot Device pushes an update to the server

0reactions
groteworldcommented, Jun 29, 2017

@bentranmyriota, is this a web app that is on the IoT device? If not, it is probably best to use aws/aws-sdk-js and its IotData API. From that you can use getThingShadow() to retrieve the shadow

Hope that helps as well!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Reserved topics - AWS IoT Core
Unsupported publish or subscribe operations to reserved topics can result in a terminated connection.
Read more >
Cannot publish to reserved topic using AWS IoT SDK
By looking at the source code of the SDK, I see that it is not possible to publish on a reserved topic using...
Read more >
Reserved topics - Amazon IoT Core - 亚马逊云科技
You can subscribe and publish to these reserved topics as they allow; however, you can't create new topics that begin with a dollar...
Read more >
Reserved Topics - Solace
Indicates that this subscription is not to be advertised (exported) by the local node (through MNR or DMR) to other nodes in the...
Read more >
MQTT Topics, Wildcards, & Best Practices - HiveMQ
A wildcard can only be used to subscribe to topics, not to ... The $-symbol topics are reserved for internal statistics of the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found