jsbc
StreamBase Client — starts the StreamBase Client, Java implementation
DESCRIPTION
jsbc runs a Java implementation of the StreamBase client utility, which lets you send requests to a running StreamBase Server (sbd). For example, the jsbc list streams command requests the server to list available streams.
OPTIONS
With a few exceptions, the jsbc command has the same options as the sbc command, as described in sbc. The exceptions are:
- No space after -u or -p
-
For jsbc, there must be no space between
-uand the following URI, and no space between-pand the following port number:jsbc -usb://localhost:10000 listConnections jsbc -p9900 listConnections
- enqueue and dequeue support the --json option
-
The jsbc subcommands enqueue and dequeue support the
--jsonoption. For dequeue, this prints all tuples in the form of a JSON object (as defined on http://www.json.org) instead of the default CSV format. For enqueue,--jsonspecifies that the tuples to be enqueued are in JSON object format. Use this option after the enqueue or dequeue subcommand:jsbc enqueue --json InputPort jsbc dequeue --json OutputPort
- enqueue supports sending no-fields tuples
-
A no-fields tuple is the input format you send to an input stream defined with an empty schema, as described in Using Empty Schemas. Send a no-fields tuple as a line with one or more spaces or tabs, or, using the
--jsonoption, as one or more spaces or tabs surrounded by braces. - -J option supported
-
The jsbc command accepts the
-Joption, but sbc does not.-
-Jjvm-option -
Specifies a system property setting or other JVM argument to be passed to the JVM that runs this jsbc command. Use this option to specify temporary settings that affect only the current invocation of jsbc. You must specify multiple
-Joptions to specify multiple JVM arguments.A space between the
-Jand its argument is optional. Use the full option syntax forjvm-optionthat you would use at the Java command line, including the initial hyphen. For example, specify-J-Dstreambase.log-level=2to increase the log level for this invocation of jsbc.Your
jvm-optionargument might require surrounding quotes, depending on the characters it contains and the shell you are using. However, do not use quotes to escape the spaces between separate JVM arguments; instead use separate-Joptions. For example:-J-Xms512M -J-Xmx2G
-
- No arguments for -h and --help
-
Unlike the sbc command, this jsbc command's
-hand--helpoptions do not take subcommand arguments.
ENVIRONMENT
-
STREAMBASE_SERVER -
Optional. Contains the URI for a StreamBase Server instance. Use this variable to set a default StreamBase URI for StreamBase commands that take the
-uoption. If set, commands use the URI in this variable, overriding their built-in default URI, which issb://localhost:10000.If this variable is set, you must use the-uoption to communicate with any server other than the one specified in this variable. See the sburi page in the Reference Guide for more on StreamBase URIs. -
STREAMBASE_RETITLE_TERMINALS -
Optional. If set to any value, StreamBase programs assign a terminal window title to match the name of the executable being run. By default terminal titles are not affected. Applies to jsbc dequeue and jsbc enqueue only.
-
STREAMBASE_LOG_LEVEL -
Optional. Sets the minimum severity of messages that StreamBase writes to logging output. Default is 0, which gets NOTICE level messages and higher. Reasonable values are -1 (which disables NOTICE messages and shows only WARN, ERROR and FATAL messages), 1 (which adds INFO messages to the standard messages), and 2 (which adds DEBUG messages).
