Command Line Arguments
« Back to User Guide
Navigation
ProductClient.jar Arguments
When run without arguments, the product client displays usage.
One of
--send
, or
--receive
is required.
- --configFile=<configFile>
-
Optional. Override the default configuration file location, which is
config.ini
in the current working directory.
- --help
-
Optional. Display usage information and exit. For help with
--send
, use the combination
--send --help
.
- --send
-
Optional. Create a product using the
Command Line API
. The product is sent using all configured senders.
- --receive
- Optional. Start a persistent client to receive products.
ProductClient.jar Sender exit codes
- 0
-
Normal exit, the product was built and send without any problems. In
addition to this exit code, the ID of the built product is output to
STDOUT.
- 1
-
Invalid arguments, either an invalid combination or invalid value. This
is usually accompanied by text describing what was invalid.
- 2
- Unable to build product. Rare.
- 3
-
Total send failure. Every configured product sender had an exception.
The product was likely not received by anyone.
- 4
-
Partial send failure. At least one configured product sender succeeded,
which is often sufficient for distribution. Check the logs for more
information about the senders that had exceptions.
Command Line Sender/Receiver API
The Command Line API is used to create new products, and by external
listeners to receive products.
- --source=<source>
-
Network that generated this product, as a two character network code.
Examples include
us
,
nc
, and
ci
.
- --type=<type>
-
Product type. A short identifier that is shared by all sources of a type
of product.
Examples include
shakemap
,
pager
, and
dyfi
.
- --code=<code>
-
Full event code: 2 character network code followed by up to 8 character
network event code.
Examples include
us2009abcd
and
nc12345678
- --updateTime=<updateTime>
-
Optional. Default is now. When this version of source+type+code was
updated.
An example is
2010-01-14T14:11:28.691-07:00
.
- --status=<status>
-
Optional. Default is
UPDATE
. Product generators may use any status without spaces. However, the
status must be used consistently for all products of that type.
Examples include
UPDATE
, and
DELETE
.
- --delete
-
Optional. A synonym for
--status=DELETE
. This updates the status to delete. Product generators may send content
along with a "deleted" product.
NOTE: ProductDistribution makes no attempt to remove earlier versions
of the product, and only attempts to deliver this update.
- --property-<name>=<value>
-
Optional. Product property. Each property may have only one value. Name
and value must not contain an equals (=).
- --eventtime=<eventtime>
-
Optional. When the event with which this product is associated
occurred.
Examples include
2010-01-14T14:11:28.691-07:00
and
2010-01-14T21:11:28.691Z
.
Synonym for
--property-eventtime=<eventtime>
.
- --latitude=<latitude>
-
Optional. Latitude (in decimal degrees) of event with which this
product is associated.
Synonym for
--property-latitude=<latitude>
.
- --longitude=<longitude>
-
Optional. Longitude (in decimal degrees) of event with which this
product is associated.
Synonym for
--property-longitude=<longitude>
.
- --eventsource=<eventsource>
-
Network that generated event with which this product is associated.
Examples include
us
,
nc
, and
ci
.
Synonym for
--property-eventsource=<eventsource>
- --eventsourcecode=<eventsourcecode>
-
Code assigned by network that generated event with which this
product is associated.
Examples include
2008abcd
and
12345678
.
Synonym for
--property-eventsourcecode=<eventsourcecode>
- --magnitude=<magnitude>
-
Optional. Magnitude of event with which this product is associated.
Synonym for
--property-magnitude=<magnitude>
.
- --depth=<depth>
-
Optional. Depth (in kilometers) of event with which this product is
associated.
Synonym for
--property-depth=<depth>
.
- --version=<version>
-
Optional. Product generator version. This is independent of the
Product updateTime, which is used by distribution for versioning.
Synonym for
--property-version=<version>
.
- --eventid=<eventid>
-
Deprecated. Use the --eventsource and --eventsourcecode arguments
instead.
Optional. Full 10 character eventid with which this product is
associated.
An example is
us2008abcd
.
Synonym for
--property-eventid=<eventid>
.
- --link-<relation>=<uri>
-
Optional. Represent a relationship between this product and another
product or resource. Each relation may have many uris.
<uri>
must be a valid URI as defined by RFC2396 or RFC2732.
Example: --link-related=urn:usgs-product
- --content
-
Optional. Non-file product content is available via standard input.
- --contentType=<contentType>
-
Optional, used with
--content
. Content mime-type for content read from standard input.
- --file=<file>
-
Optional.
<file>
is a path to a file that is product content. The file's name and
modification date are preserved. The mime type is inferred from the file
extension. The file is added at the root level of the product.
- --directory=<directory>
-
Optional.
<directory>
is a path to a directory that contains product contents. Any directory
hierarchy within
<directory>
is preserved.
- --privateKey=<privateKey>
-
Optional. Path to a file containing a PKCS#8 encoded private key in PEM
or DER format. When present, the key will be used to generate a
signature for this product.
- --servers=<servers>
-
Optional. A comma separated list of server:port combinations. Overrides
any configured servers.
- --connectTimeout=<timeout>
-
Optional, default 15000. Connect timeout in milliseconds. NOTE: only
affects servers specified using the --servers argument, and must appear
before the --servers argument on the command line.
- --binaryFormat
-
Optional, default uses xml format. Send to hub using binary format.
NOTE: only affects servers specified using the --servers argument, and
must appear before the --servers argument on the command line.
- --disableDeflate
-
Optional, default uses deflate compression. Send to hub without using
deflate compression. NOTE: only affects servers specified using the
--servers argument, and must appear before the --servers argument on the
command line.
External Indexer Listener Arguments
The external indexer listener provides these additional arguments:
- --action=<action>
-
The
indexer change type
.
After the indexer updates an event, these additional arguments with
preferred event information are included:
- --preferred-eventid=<eventid>
- The full, unique event id for the event.
- --preferred-eventsource=<eventsource>
- The preferred eventsource for the event.
- --preferred-eventsourcecode=<eventsourcecode>
- The preferred eventsourcecode for the event.
- --preferred-eventtime=<eventtime>
- The preferred eventtime for the event.
- --preferred-latitude=<latitude>
- The preferred latitude for the event.
- --preferred-longitude=<longitude>
- The preferred longitude for the event.
- --preferred-depth=<depth>
- The preferred depth for the event.
- --preferred-magnitude=<magnitude>
- The preferred magnitude for the event.
- --eventids=<eventids>
- A comma separated list of all eventids associated with the event.