Skip to main content



      Home
Home » Archived » Eclipse SmartHome » Items REST API - Add formatting flag
Items REST API - Add formatting flag [message #1775927] Wed, 08 November 2017 05:11 Go to next message
Eclipse UserFriend
Hi,

I am sending a query to get a list of items from openhab from a low resource device. The problem is that the returned response is very big (comparing the total memory I have in the device). I already use tagging and type in the query but even though the returned size is very big.

If possible, I suggest to add a format flag that will support different formatting, e.g., compact & full (others ?). In full mode the returned list will be the same as today. In compact mode the returned list will only be the names of the items. Using the names I can manually get each item full configuration.

Other option will be to add extra REST API but I am not sure it is needed here.

What do you think?
Re: Items REST API - Add formatting flag [message #1775928 is a reply to message #1775927] Wed, 08 November 2017 05:58 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

we have a similar issue regarding REST query with filters already open on github, see https://github.com/eclipse/smarthome/issues/4302. It would be nice to have your feature request also in the issue. It would be even nicer if you could have a look on how an implementation could look like :-)

Cheers,
Henning
Re: Items REST API - Add formatting flag [message #1775930 is a reply to message #1775928] Wed, 08 November 2017 06:09 Go to previous messageGo to next message
Eclipse UserFriend
Hi Henning

Seems that the issue there is for things and not for items, so maybe I should open separate issue?

Note that the reason for this request is not filtering (as items do have filtering) but it is because of limited resources on embedded devices.

I will try to take a look on the code side but I it will take some time :-(
Re: Items REST API - Add formatting flag [message #1775970 is a reply to message #1775930] Wed, 08 November 2017 11:54 Go to previous message
Eclipse UserFriend
I had the same requirement a couple of times also and therefore agree it would make sense.
So I took this as an opportunity to experiment a little and turned it into a little PR.
How about something along the lines of #4517?
Previous Topic:Identical Things provided by different ThingProviders
Next Topic:adding channels conditionally
Goto Forum:
  


Current Time: Sat May 17 21:51:57 EDT 2025

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

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

Back to the top