Operation

This document describes how to operate the Transport Proxy software contained in the transport-proxy package. The Transport Proxy software is a web application for retrieving product files from the the Transport Services that are located at the various Discipline Nodes. The following topics can be found in this section:

Interface

The Transport Proxy provides a REST-based interface accessible via HTTP for interacting with the service. Because the REST-based interface operates over HTTP, there are several options for interacting with the Transport Proxy:

  • Web Browser

    Any standard web browser (e.g., Firefox, Safari, Internet Explorer, etc.) will allow interaction with the service.

  • cURL

    The cURL utility offers the most flexible means for interacting with the application. The utility comes installed on most UNIX-based platforms and is available for download for the Windows platform. The examples in the sections that follow utilize cURL to interact with the application. If cURL is not installed on the local machine but Wget is, see the Using Wget section for converting cURL commands to Wget commands.

The examples below use http://localhost:8080 as the default base end point for the service.

Product Query

The Transport Proxy web application provides functionality for retrieving directory listings and files from a Transport Service instance. The following table details the parameters available:

ParameterDescription
objectThe identifier of the Transport Service specified as a full URN (i.e., urn:eda:rmi:PDS.CN.Product) or just the name (i.e., PDS.CN.Product). This parameter is required.
keywordQueryThe DIS-Style query expression identifying the product (or set of files) to retrieve from the Transport Service. This parameter is required. Additional information regarding the DIS-Style query format can be found at the Apache OODT DIS-Style Query page.
idThe identifier of the product to return in the case where multiple products match the query criteria. This parameter is optional.
mimeTypeThe desired MIME type of the product to return. This parameter may be specified multiple times to show an in-order preference for MIME types. This parameter is optional.

The following is an example query:

% curl -X GET -o results.out -v \
"http://localhost:8080/prod?object=<object>&keywordQuery=<keywordQuery>"
      

Note: If the above example generates a 302 Moved Temporarily message, an additional "/" is likely required after "/prod" and before the question mark in the example above. The following is an example query for the OFSN implementation of the Transport Service:

% curl -X GET -v \
"http://localhost:8080/prod?object=PDS.Img.Product&\
keywordQuery=OFSN+EQ+data/+AND+RT+EQ+DIRLIST1"
      

The above query should return a directory listing. The following is an example query for the Registry Service implementation of the Transport Service:

% curl -X GET -o package.zip -v \
http://localhost:8080/prod?object=PDS.Atmos.Transport&\
keywordQuery=identifier+EQ+<LID|LIDVID>
      

Assuming the LID or LIDVID was specified correctly, the above query should return a ZIP package containing the products associated with the specified product. See the respective Operation documents for the Transport Services for more details regarding supported queries.