Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pablo-mayrgundter/datahub
A data sharing application framework for AppEngine (Java).
https://github.com/pablo-mayrgundter/datahub
Last synced: about 2 months ago
JSON representation
A data sharing application framework for AppEngine (Java).
- Host: GitHub
- URL: https://github.com/pablo-mayrgundter/datahub
- Owner: pablo-mayrgundter
- Created: 2015-09-03T22:44:38.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-09-03T22:54:50.000Z (over 9 years ago)
- Last Synced: 2024-10-12T22:27:42.346Z (3 months ago)
- Language: JavaScript
- Homepage:
- Size: 2.56 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# DataHub
DataHub is a Google AppEngine library that provides a filesystem view of the GAE datastore via a RESTful web service.
Data payloads currently must be in JSON format, but this restriction will be removed and generic binary data will be supported instead. JSON and XML support will be handled at a higher layer.
Data storage uses the App Engine low-level datastore API via its own abstract Store API that can be implemented with any CRUD persistence layers, such as a SQL database.
DataHub? is being designed as the new low-level framework for DataWiki
Developers
See the GettingStartedGuide, which include an example you can run locally and test with the commands below.REST/CRUD + Search API Example
The following examples use curl on the UNIX command line.
">" means your command prompt, so don't type it in. Just type in "curl ..."
"<" prefixes the expected response.
Create
```
(the "-d '{}'" sends an empty json object as an HTTP POST body):> curl -d '{}' http://localhost:8080/data
< HTTP/1.1 200 OK
< Location: /data/__1__
```Named create
```
> curl -X PUT -d '{}' http://localhost:8080/data/Test
< HTTP/1.1 200 OK
```Retrieve
```
> curl http://localhost:8080/data/__1__
< {
< "updater": "Anonymous at 0:0:0:0:0:0:0:1%0",
< "author": "Anonymous at 0:0:0:0:0:0:0:1%0",
< "updated": "1353281454811",
< "created": "1353281454811",
< }
```Search
```
> curl http://localhost:8080/data?q='foo:bar'
< ... the same as above ...
```Update
(using the above as 1.json after edits)
```
> curl -X PUT -d @1.json http://localhost:8080/data/__1__
Delete
> curl -X DELETE http://localhost:8080/data/__1__
```