This document describes how to operate the Registry Tools software. The following topics can be found in this document:
Note: The command-line examples in this section may have been broken into multiple lines for readability. The commands should be reassembled into a single line prior to execution.
This software package consists of a set of Python scripts for interacting with a Registry Service instance. This software does have a dependency on the pds.registry package which must be deployed to the local Python environment prior to operation of this software.
This script replaces a slot value where the source-string is replaced by the replace-string for a list of extrinsics filtered optionally by Object Type and LID wildcard.
% python extrinsic-slot-replace.py <registry-url> <slot-name> <source-string> <replace-string> [<object-type> [<lid-prefix>]]
The following table describes the command-line options available:
Command-Line Option | Description |
---|---|
registry-url | The URL of the Registry Service instance (e.g., http://localhost:8080/registry). This option is required. |
slot-name | The name of the slot to have its value replaced. |
source-string | The string in the named slot value to be replaced. |
replace-string | The replacement string. |
object-type | The object type of the extrinsics to be queried (e.g., Product_Collection, Product_Observational, etc.). This option is optional. |
lid-prefix | A portion of the logical identifier (e.g., urn:nasa:pds:example) to further filter the results. This option is optional. |
This script queries a registry service instance for a list of extrinsics filtered optionally by Object Type and LID wildcard. The extrinsics are listed in CSV format to standard out with fields: lid, version_id, name and status.
% python list-extrinsics.py <registry-url> [<object-type> [<lid-prefix>]]
The following table describes the command-line options available:
Command-Line Option | Description |
---|---|
registry-url | The URL of the Registry Service instance (e.g., http://localhost:8080/registry). This option is required. |
object-type | The object type of the extrinsics to be queried (e.g., Product_Collection, Product_Observational, etc.). This option is optional. |
lid-prefix | A portion of the logical identifier (e.g., urn:nasa:pds:example) to further filter the results. This option is optional. |
This script queries a registry service instance and generates a report of the extrinsics registered with that instance.
% python report-extrinsics.py <registry-url>
The following table describes the command-line options available:
Command-Line Option | Description |
---|---|
registry-url | The URL of the Registry Service instance (e.g., http://localhost:8080/registry). This option is required. |
This script tests the various aspects of creating, putting, retrieving and deleting extrinsics.
% python test-extrinsics.py <registry-url>
The following table describes the command-line options available:
Command-Line Option | Description |
---|---|
registry-url | The URL of the Registry Service instance (e.g., http://localhost:8080/registry). This option is required. |