pds4-product-registry
v0.2.5
Published
Extract information from a PDS4 label and generate index files suitable to load into a Level database.
Downloads
39
Readme
PDS4 Product Registry
A data product level registry and related tools.
Installation
npm install pds4-product-registry -g
Tools
pds-reg-build-index: Build a product index. Extract information from a PDS4 label and generate index files suitable to load into a Level database.
pds-reg-find-index: Search the index of a database. Search the index of a database for entries that begin with a value.
pds-reg-load-index: Load index into database. Load an index generated with "build-index" into a database.
pds-reg-check-inventory: Scan a collection or bundle inventory and check that each entry is valid.
pds-reg-status: Check the status of one or more product registries. A valid responses includes the number of keys present.
pds-reg-product-server: Run the product-server web services.
Getting Started
- Run pds-build-index on a collection of PDS4 labeled products
pds-build-index -o listing.txt -p http://some.where.org/data
- Load index into a database (example "./db")
pds-load-index -d ./db listing.txt
- Perform a search
pds-find-index -d ./db some-key-to-find-index
Run the product-registry service
Run service on port 3130
pds-product-server -n brand-name -p 3130 -d ./db
Running with pm2 on port 8800
sudo pm2 start pds-product-server -- -p 8800 -d /var/product/db -n "My"
End points
\find?lidvid={lidvid}
Retrieve information on a product given it's {lidvid}. A partial {lidvid} will return all products that match. Return and array of JSON records.
\label?lidvid={lidvid}
Return the label for a product with a specific {lidvid}.
\product?lidvid={lidvid}[&format=zip|tar]
Retrieve a product with a specific {lidvid} as a zip or tar bundle. Default is to return a zip file.
\lookup
Perform a search through a web browser.
Project Requirements
- Query of product registry for LIDs with common collection.
- Output of collection query in collection inventory format
- Command Line Features
- Load product registry
- Inventory query product registry
- Collection label generation
- Web Interface
- Load product registry.
- Query and list contents of product registry
- Web API
- Resolve LID or LIDVID to product metadata
- Resolve LID or LID to product URL
- Supports Registry API (TBD)
- Given LID or LIDVID provide product metadata (label)
- Given LID or LIDVID provide URL to product
- Scaleable to 10s of millions of products in the product registry
License
This repository is licensed under Apache 2.0.
Contributors and Acknowledgments
This package has been developed by T. A. King.
Work on this project is sponsored by NASA.