https://github.com/tpiros/marklogic-nodejs-binaries
Working with the MarkLogic Node.js Client API and binary documents
https://github.com/tpiros/marklogic-nodejs-binaries
Last synced: 2 months ago
JSON representation
Working with the MarkLogic Node.js Client API and binary documents
- Host: GitHub
- URL: https://github.com/tpiros/marklogic-nodejs-binaries
- Owner: tpiros
- License: mit
- Created: 2016-08-15T15:41:11.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2016-11-16T10:40:09.000Z (over 8 years ago)
- Last Synced: 2025-02-12T21:44:40.944Z (4 months ago)
- Language: JavaScript
- Homepage:
- Size: 8.56 MB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: readme.md
- License: license
Awesome Lists containing this project
README
# MarkLogic Node.js API - working with binary documents
> Please note that the project requires you to have Node.js v6 or above and MarkLogic v8.0 or above.
> This project uses binaries that are openly available. Video file (mp4) taken from: [http://www.sample-videos.com/](http://www.sample-videos.com/). Music file (mp3) taken from [http://freemusicarchive.org/curator/creative_commons/](http://freemusicarchive.org/curator/creative_commons/)
## Setup
First make sure that `connection.js` contains the appropriate host, port number as well as the right username and password combination for a REST API instance.> By default we are using the Documents database.
In order to setup the project dependencies please make sure that you execute `npm install` first.
### Displaying Images
In order to display an image please execute `npm run image`### Displaying a video using range requests
In order to see range requests in action please execute `npm run range`### Displaying metadata for binary documents
In order to display the properties metadata assigned to binaries please execute `npm run metadata`## Example application
A simple example app is also part of this repository that uses [React](https://facebook.github.io/react/) to give some UI components to the UI. The app tries to showcase in a simple way how to display a video and some metadata from the database.To start the application execute `npm run app`.