Class Equivalent to BindingConfig of OH1?


I need to develop an addon similar to OH1 MQTT but i have no idea how to extract the multiple item binding configurations similar to Item myItem {mqtt=“direction[broker:topic:type:transformer:regex_filter], direction[broker:topic:type:transformation], …”}

Can someone give me some ideas and flows how to do this on OH2? Basically, I plan to copy some of the codes from OH1. Thanks

Looking at your other posts, I assume that you already answered this question yourself as well, right?
In general, you define Things with multiple channels, where each channel in the end can map to one item.

FTR: A discussion about MQTT for ESH/openHAB2 can be found at

Thank you sir. I didn’t realize tht there was so much talks about this topic. I tried to search this forum and didn’t yield much info abt MQTT in OH2.


Speaking about your suggestion of .thing structure on your above link, could it be better if we define the subtopic and direction in the .xml as tags of the in .Thing file? Or what is the benefit of having it (channel) manually defined it in .thing file?

Felix, I would suggest to keep the MQTT discussion at, so it is all at one place.