incubator-connectors-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache Connectors Framework > REST API proposal
Date Sun, 12 Sep 2010 23:29:00 GMT
Space: Apache Connectors Framework (https://cwiki.apache.org/confluence/display/CONNECTORS)
Page: REST API proposal (https://cwiki.apache.org/confluence/display/CONNECTORS/REST+API+proposal)


Edited by Karl Wright:
---------------------------------------------------------------------
h1.  Proposal for making ACF API fully RESTful

Making the API fully RESTful involves three changes:

* Using HTTP verbs in an appropriate manner
* Defining a URL for every object
* Not passing arguments other than a path to GET methods

This is the proposal for mapping the current functionality to RESTful functionality.

The actual current commands are as follows.  Note that NO changes are proposed for the output
objects of the commands at this time.  Also, note that all connection_name fields in URLs
are encoded such that "/" characters do not appear in them; specifically, the sequences ".."
and ".+" represent "." and "/", respectively.



|| Current command || Current argument format || Proposed verb || Proposed command ||
| outputconnector/list | N/A | GET | outputconnectors |
| authorityconnector/list | N/A | GET | authorityconnectors |
| repositoryconnector/list | N/A | GET | repositoryconnectors |
| outputconnection/list | N/A | GET | outputconnections |
| outputconnection/get | \{"connection_name":_<connection_name>_\} | GET | outputconnections/_<output_connection_name>_
|
| outputconnection/save | \{"outputconnection":_<output_connection_object>_\} | PUT
| outputconnections/_<output_connection_name>_ \[note: the connection name is optional,
since the object contains the name as well\] |
| outputconnection/delete | \{"connection_name":_<connection_name>_\} | DELETE | outputconnections/_<output_connection_name>_
|
| outputconnection/checkstatus | \{"connection_name":_<connection_name>_\} | GET | status/outputconnections/_<output_connection_name>_
|
| outputconnection/execute/_<command>_ | \{"connection_name":_<connection_name>_,
_<argument_data>_\} | GET | info/outputconnections/_<output_connection_name>_/_<command>_
|
| authorityconnection/list | N/A | GET | authorityconnections |
| authorityconnection/get | \{"connection_name":_<connection_name>_\} | GET | authorityconnections/_<authority_connection_name>_
|
| authorityconnection/save | \{"authorityconnection":_<authority_connection_object>_\}
| PUT | authorityconnections/_<authority_connection_name>_ |
| authorityconnection/delete | \{"connection_name":_<connection_name>_\} | DELETE |
authorityconnections/_<authority_connection_name>_ |
| authorityconnection/checkstatus | \{"connection_name":_<connection_name>_\} | GET
| status/authorityconnections/_<authority_connection_name>_ |
| repositoryconnection/list | N/A | GET | repositoryconnections |
| repositoryconnection/get | \{"connection_name":_<connection_name>_\} | GET | repositoryconnections/_<repository_connection_name>_
|
| repositoryconnection/save | \{"repositoryconnection":_<repository_connection_object>_\}
| PUT | repositoryconnection/_<repository_connection_name>_ |
| repositoryconnection/delete | \{"connection_name":_<connection_name>_\} | DELETE |
repositoryconnections/_<repository_connection_name>_ |
| repositoryconnection/checkstatus | \{"connection_name":_<connection_name>_\} | GET
| status/repositoryconnections/_<repository_connection_name>_ |
| repositoryconnection/execute/_<command>_ | \{"connection_name":_<connection_name>_,
_<argument_data>_\} | GET | info/repositoryconnections/_<repository_connection_name>_/_<command>_
|
| job/list | N/A | GET | jobs |
| job/get | \{"job_id":_<job_identifier>_\} | GET | jobs/_<job_identifier>_ |
| job/save | \{"job":_<job_object>_\} | PUT | jobs/_<job_identifier>_ \[Save existing\]
|
| job/save | \{"job":_<job_object>_\} | POST | jobs \[Create new, returning job identifier\]
|
| job/delete | \{"job_id":_<job_identifier>_\} | DELETE | jobs/_<job_identifier>_
|
| jobstatus/list | N/A | GET | jobstatuses |
| jobstatus/get | \{"job_id":_<job_identifier>_\} | GET | jobstatuses/_<job_identifier>_
|
| jobstatus/start | \{"job_id":_<job_identifier>_\} | PUT | start/_<job_identifier>_
|
| jobstatus/abort | \{"job_id":_<job_identifier>_\} | PUT | abort/_<job_identifier>_
|
| jobstatus/restart | \{"job_id":_<job_identifier>_\} | PUT | restart/_<job_identifier>_
|
| jobstatus/pause | \{"job_id":_<job_identifier>_\} | PUT | pause/_<job_identifier>_
|
| jobstatus/resume | \{"job_id":_<job_identifier>_\} | PUT | resume/_<job_identifier>_
|




Change your notification preferences: https://cwiki.apache.org/confluence/users/viewnotifications.action
   

Mime
View raw message