Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [hono-dev] connect Hono and Ditto sandboxes

That is exactly what is already contained in the example in the blogpost :)
Not all incoming messages are processed:

if (contentType !== "application/json") {
    return null; // only handle messages with content-type application/json
}

Sure, it could be more advanced by filtering for a vendor specific content-type or doing different mappings for different content-types.
But I think that the reader should get to those ideas by himself by these 3 lines of code.


Regards
Thomas


-----Original Message-----
From: hono-dev-bounces@xxxxxxxxxxx <hono-dev-bounces@xxxxxxxxxxx> On Behalf Of Hudalla Kai (INST/ECS4)
Sent: Montag, 7. Mai 2018 08:48
To: hono-dev@xxxxxxxxxxx
Subject: Re: [hono-dev] connect Hono and Ditto sandboxes

On Thu, 2018-05-03 at 07:12 +0000, Jaeckle Thomas (INST/ECS1) wrote:
> Hi Kai.
> 
> Yes, I already figured that it must be vacation time. But no problem, 
> I thought we would need more help on figuring out the used Hono ports/credentials, etc.
> 
> > At the end of the blog you encourage the readers to provide some 
> > feedback. Is there a specific functionality on the blog page to do 
> > that which I missed or is the idea to use the Ditto mailing list? A 
> > hint in the text would be helpful.
> 
> Ah, you're right. We have disabled the commenting function in the blog 
> as we only can and want to have static content on the site.
> I will add the link to our https://www.eclipse.org/ditto/feedback.html 
> site and the Hono mailing-list.
> 
> > I do have some comments and proposals for improvement of the 
> > scenario as well.
> > Would you like me to provide them here in this thread on the Ditto 
> > mailing list etc?
> 
> Cool, looking forward for them.
> We can discuss the improvements here -> broader audience :)
> 

It is great that Ditto provides means to apply transformations on incoming messages! In the example, all incoming messages are assumed to be targeted at Ditto (which makes sense in this context). However, in real world scenarios, I believe that it will be much harder to "filter" out the relevant messages. One approach for this is to take a look at the content-type header of a message in order to determine if a transformation for this content-type exists (has been
registered) and otherwise discard the message.

Hono's HTTP adapter simply includes the incoming HTTP request's Content-Type in the downstream AMQP 1.0 message for that purpose. However, it is also possible to register a "default" content type for a device [1], which will then be used in downstream messages if the incoming message does not contain a content type, which for example is the case with data published via the MQTT protocol adapter.
It would be cool to see this in practice in the example as well :-)

[1] https://www.eclipse.org/hono/api/device-registration-api/#request-payload

> Thanks Kai for reviewing the post and the kind words.
> 
> 
> Regards
> Thomas
> 
> 
> -----Original Message-----
> From: hono-dev-bounces@xxxxxxxxxxx <hono-dev-bounces@xxxxxxxxxxx> On 
> Behalf Of Hudalla Kai (INST/ECS4)
> Sent: Donnerstag, 3. Mai 2018 09:03
> To: hono-dev@xxxxxxxxxxx
> Subject: Re: [hono-dev] connect Hono and Ditto sandboxes
> 
> On Wed, 2018-05-02 at 15:25 +0000, Jaeckle Thomas (INST/ECS1) wrote:
> > Hi Hono devs.
> > 
> 
> Hi Thomas,
> 
> sorry for the late reply. As you may have reckoned already, most 
> people are on vacation or on their way to RedHat Summit in SF.
> 
> >  
> > We did that finger exercise on Monday and succeeded, the sandboxes 
> > work together really well.
> 
> That's great to hear :-)
> 
> > You can find the blog-post here: 
> > https://www.eclipse.org/ditto/2018-05-02-
> > connecting-ditto-hono.html
> >  
> > Any feedback would be really appreciated.
> >  
> 
> Awesome blog! I immediately had the feeling that I would be able to do 
> it in ten minutes :-) I like the detailed description of the steps 
> necessary and the example code. At the end of the blog you encourage 
> the readers to provide some feedback. Is there a specific 
> functionality on the blog page to do that which I missed or is the 
> idea to use the Ditto mailing list? A hint in the text would be helpful.
> 
> I do have some comments and proposals for improvement of the scenario as well.
> Would you like me to provide them here in this thread on the Ditto 
> mailing list etc?
> 
> >  
> > Regards
> > Thomas
> > 
> > From: hono-dev-bounces@xxxxxxxxxxx <hono-dev-bounces@xxxxxxxxxxx> On 
> > Behalf Of Jaeckle Thomas (INST/ECS1)
> > Sent: Freitag, 27. April 2018 09:49
> > To: hono-dev@xxxxxxxxxxx
> > Subject: [hono-dev] connect Hono and Ditto sandboxes
> >  
> > Hi Hono developers.
> >  
> > We, the Eclipse Ditto team, just released our milestone 0.3.0-M1 in 
> > which we stabilized the connectivity to Hono.
> > See also our blog posts about that if you are interested:
> > ·         https://www.eclipse.org/ditto/2018-04-25-connectivity-service.html
> > ·         https://www.eclipse.org/ditto/2018-04-26-milestone-announcement-030
> > -M
> > 1.html
> >  
> > What do you think about connecting our two sandboxes to demonstrate 
> > Hono and Ditto working together?
> >  
> > We are already connecting the commercial Bosch services in our 
> > commercial Bosch IoT Suite setup, so it should not be a problem to 
> > do the same in the sandboxes.
> >  
> > With Ditto’s JavaScript based payload mapping feature the 
> > south-bound device must no longer send in Ditto protocol, we can 
> > create a connection which maps some arbitrary JSON to a format Ditto can understand.
> >  
> > Who wants to collaborate in setting this up?
> > Maybe also as a blog post so that others may reproduce the setup.
> >  
> > One more thing: I read your 0.6 release review: 
> > https://projects.eclipse.org/pr ojects/iot.hono/releases/0.6/review
> > Does it make sense to include Ditto as related project and mention 
> > in the “Communities” section?
> > As far as I can tell Ditto has the best out of the box integration 
> > with Hono in Eclipse IoT :-)
> >  
> >  
> > Best regards
> > Thomas
> > 
> > _______________________________________________
> > hono-dev mailing list
> > hono-dev@xxxxxxxxxxx
> > To change your delivery options, retrieve your password, or 
> > unsubscribe from this list, visit 
> > https://dev.eclipse.org/mailman/listinfo/hono-dev
> 
> _______________________________________________
> hono-dev mailing list
> hono-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or 
> unsubscribe from this list, visit 
> https://dev.eclipse.org/mailman/listinfo/hono-dev
> _______________________________________________
> hono-dev mailing list
> hono-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or 
> unsubscribe from this list, visit 
> https://dev.eclipse.org/mailman/listinfo/hono-dev
_______________________________________________
hono-dev mailing list
hono-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit https://dev.eclipse.org/mailman/listinfo/hono-dev

Back to the top