Skip to main content



      Home
Home » Eclipse Projects » Kura » How to make sure that Kura's publishing data already sent
How to make sure that Kura's publishing data already sent [message #1760879] Wed, 03 May 2017 17:17 Go to next message
Eclipse UserFriend
Hello,

I am newly implementing Kura and I try the "Heater" demo example for publishing application. Now, I wanna make sure that Kura, with Heater demo publish apps, succeeded to sent the data to the broker and it's ready to be subscribed. i used mqtt://iot.eclipse.org:1883 for broker url in Kura web mqtt data transport configuration.

once i used mosquitto_sub ( mosquitto_sub -h iot.eclipse.org -t data ) for trying subscribe data, but the data from Kura won't showed.

i tried to check from publisher side use wireshark and the result like this [1]. this is looks like the data was sent from publisher, so maybe the problem is the way I subscribe.

So can anyone here help me to tell how to subscribe the data sent from kura ?? is it different from subscrabing in common way ?? or maybe somone here tried subscribe service in Kura itself so there is two client as Pubs and Subs are both using Kura ??

Thanks

[Updated on: Wed, 03 May 2017 17:20] by Moderator

Re: How to make sure that Kura's publishing data already sent [message #1760902 is a reply to message #1760879] Thu, 04 May 2017 03:59 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

the Heater demo bundle publishes mqtt messages under the <account-name>/<client-id>/heater/data topic.
On mosquitto you should subscribe on this full topic, not only "data".

Best,
Pier
Re: How to make sure that Kura's publishing data already sent [message #1760986 is a reply to message #1760902] Thu, 04 May 2017 19:56 Go to previous messageGo to next message
Eclipse UserFriend
Hello,

Thanks Pier for your helping, its really help me and I got the data that sent from my Kura. but i get the new problem now for data what i get.

the data I got showed like this [1], can you tell me what kind of that data i get from broker ?

Thanks
Iqbal
Re: How to make sure that Kura's publishing data already sent [message #1761370 is a reply to message #1760986] Wed, 10 May 2017 05:31 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

indeed the results is not so readable Smile
The messages Kura sends to the broker are encoded in a ProtoBuffer, so when you subscribe to a specific topic, you get a binary data.

BTW, in Kura 3.0.0 (coming soon), you will be able to encode the data in Kura messages also in a (more readable) json format.
Re: How to make sure that Kura's publishing data already sent [message #1761432 is a reply to message #1761370] Thu, 11 May 2017 02:12 Go to previous messageGo to next message
Eclipse UserFriend
Hello Pier,

Thanks a lot for replying and answer my issue.

So in your answer, you meant that I have to decode the massage sent by kura from its ProtoBuffer in my subscriber, so that I can read the decoded message well. is it right ?

is that ProtoBuffer encoding is the only way the massage sent by Kura, or maybe there is some tricks to modify message to simplifying the transmission ??

Thanks,
Iqbal
Re: How to make sure that Kura's publishing data already sent [message #1763309 is a reply to message #1761432] Fri, 12 May 2017 10:00 Go to previous messageGo to next message
Eclipse UserFriend
Hello Iqbal,

All messages sent through the CloudService will be encoded using Google Protobuf. In this case, yes, you would need to decode the message on the receiving client. You can instead use the DataService directly to send messages, in which case the messages will not be encoded. There are advantages to using the CloudService, so I would encourage you to review the differences between the two services [1][2].

[1] http://download.eclipse.org/kura/docs/api/2.1.0/apidocs/org/eclipse/kura/cloud/CloudService.html
[2] http://download.eclipse.org/kura/docs/api/2.1.0/apidocs/org/eclipse/kura/data/DataService.html

Thanks,
--Dave
Re: How to make sure that Kura's publishing data already sent [message #1763389 is a reply to message #1763309] Mon, 15 May 2017 03:29 Go to previous messageGo to next message
Eclipse UserFriend
Hello David,

Thanks a lot for replying. I'll try your advise for trying DataService for sending message in Kura. And i'll report soon the result when i'm done.

Thanks
Iqbal
Re: How to make sure that Kura's publishing data already sent [message #1763391 is a reply to message #1763309] Mon, 15 May 2017 03:41 Go to previous message
Eclipse UserFriend
Hallo David,

Thanks for your replying. I'll try your advise for using DataService to send data from Kura. And soon I'll report for the result when I'm done.

Thanks
Iqbal
Previous Topic:Kura's data that sent to broker Problem
Next Topic:Kura Data Service Dependencies
Goto Forum:
  


Current Time: Wed Jul 30 16:02:36 EDT 2025

Powered by FUDForum. Page generated in 0.05467 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top