This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 236309 - Allow to Register JSON based REST resources in IDE
Summary: Allow to Register JSON based REST resources in IDE
Status: NEW
Alias: None
Product: webservices
Classification: Unclassified
Component: REST (show other bugs)
Version: 7.4
Hardware: All All
: P2 normal (vote)
Assignee: Milan Kuchtiak
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-09-24 08:34 UTC by Milan Kuchtiak
Modified: 2013-09-24 22:06 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Milan Kuchtiak 2013-09-24 08:34:43 UTC
The idea is to "register" some REST resources in IDE, to allow consumption of those resources in HTML5/JavaScript code.

The outline of the feature:

1. The User should be able, step by step, generate some REST resource METADATA, usable for JavaScript code generator.

The limitation: only for the resources providing response in JSON format. 

2. This REST resorce META-DATA will be presented in IDE under Services->REST Resources node.

3. The goal is to use this METADATA to create a JavaScript data-model, together with sample HTML code.
Note: start with Knockout+JQuery model, later extend to other framework (e.g. AngularJS etc.) 

4. The User is providing the "Abstract REST Resources METADATA", in dialog steps, just based on the "Test" response, and on the REST API documentation from service provider:

 - define HTTP methods (on rest resource and its subresources)
 - define Query and Path params
 - customize the Data Structure of the request/response
   - allow to specify properties' Description,Type and Key properties (Unique ID), needed later for code generator
   - allow to add/remove additional properties
   - allow to modify the primary datastructure (taken from Ad-Hoc Test response)
 - the METADATA shouldn't depend on particular JavaScript framework
 
5. The user should be able to customize those METADATA any time from Services->Resources node

6. Implement HTHL5 editor context actions (Table from REST Resource, Form from Rest Resource). 
These actions should allow to select the REST Resource node (or subnodes) and the JavaScript technology used for data-model generation (start with Knockout and JQuery)

Note: The step 6 this is quite vaguely specified for now. Perhaps also D&D from Services->REST Resources into JavaScript code should work.

7 Pre-Populate REST-Resources node with one or two resorces from the web, e.g. Delicious or Twitter.