Affects Version/s: None
Fix Version/s: None
Component/s: User Interface
It is somewhat a waste to use HDFS file to host widget information because HDFS files are designed to be big data blocks, and namenode RAM is too expensive to host meta data that is only a few bytes. Therefore, it would be more efficient to store widget information on HBase.
The current widget information looks like this:
However, it is possible to reduce the required information to only:
Title is already the unique identifier of a subject at hand. URL is necessary to load an iframe. The rest like version, description, id, category. They are useful to organize the data, if a tree structure make sense to organize the data. However, in BigData environment, the tree structure is too limited to help user to find the information. Hence, we promote usage of search box to find the widget base on title. Parameters were used to customize the look and feel of the widget. Those parameters are stored in server side to improve efficiency of client and server communication.
We need the following REST API:
1. GET /hicc/v2/widget/list?limit=1000&offset=0 - List all widgets with pagination
2. GET /hicc/v2/widget/search/[query] - find widget based on title matching
3. GET /hicc/v2/widget/view/[title] - get a single widget
4. POST /hicc/v2/widget/create - create a new widget
5. PUT /hicc/v2/widget/update/[title] - update a widget
6. DELETE /hicc/v2/widget/delete/[title] - delete a widget