StreamBase Feed Simulator — starts the StreamBase Feed Simulator.
The sbfeedsim command starts the StreamBase Feed Simulator, which connects to a running StreamBase application and submits data to it. Use this tool to test the validity and performance of your application.
As with most StreamBase command-line tools, you can specify the StreamBase Server to communicate with by using
-u arguments. In the absence of these arguments, sbfeedsim connects to the server specified in the
STREAMBASE_SERVER environment variable. In the absence of this variable, sbfeedsim attempts to connect to the default StreamBase URI,
If you omit the optional
feedsim-file.sbfs argument, sbfeedsim connects to the specified or default server, determines the schema expected by the input stream of the running StreamBase
application, and generates default data for each data type in the schema. If the running application has more than one input
stream, sbfeedsim determines the expected schema for each stream and generates sample data for all fields in each stream. You can use the
-s option to narrow the list of input streams for which sample data is generated.
sbfeedsim can also populate input streams according to a user-specified statistical distribution, or via a data file that contains data you created to test various streaming scenarios. The data file is typically in comma-separated value (CSV) or tab-delimited format. With sbfeedsim, you have control over tuple values and the input rate of generated data.
Running a feed simulations in StreamBase Studio is functionally equivalent to running one with the sbfeedsim command.
Sets the data rate for this feed simulation to run as fast as possible.
Changes the maximum number of tuples to buffer on each stream to count, when using the default load or a user-specified distribution. This setting adjusts the enqueue client buffer size for each input stream. The default size is 100 tuples. Specify zero to disable buffering.
Changes the maximum number of tuples to buffer when using a data file or JDBC data source. The default buffer in these cases is 40,000 tuples.
Converts a legacy feed simulation file (saved with StreamBase 3.5 and earlier) to the current feed simulator XML format, and prints the result to standard output. You can redirect the converted results to a file, as in the following example:
sbfeedsim -c MyOldFeedsim.sbfs > MyNewFeedsim.sbfs
When using a data file or JDBC data source, completely prefill the tuple buffer before sending the first tuple.
Run this feed simulation even if warnings occur during application compatibility validation.
Displays usage text, then exits.
Specifies a system property setting or other JVM argument to be passed to the JVM that runs this sbfeedsim command. Use this option to specify temporary settings that affect only the current invocation of sbfeedsim. You must specify multiple
-Joptions to specify multiple JVM arguments.
A space between the
-Jand its argument is optional. Use the full option syntax for
jvm-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 sbfeedsim.
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:
Force an on-the-fly conversion and execution of a feed simulation file created with StreamBase 3.5 or earlier.
Limit the feed simulation run by time. Generates data appropriate for the schemas of the input ports of the running StreamBase Server, until
secsseconds have elapsed.
Limit the feed simulation run by number of tuples sent. Generates appropriate data as above up to the number of tuples specified by
Sets the port number for the StreamBase Server instance to connect with. This is useful when the server is
localhostand you only need to specify a non-default port, instead of specifying the full URI with the
-uoption. The default port is
-poption is not supported for applications that have StreamBase authentication enabled (because there is no way to specify a username and password) or in conjunction with the multiple URI syntax.
Does not display tuples (quiet).
Specifies a comma-separated list of input stream names in the application running on the connected StreamBase Server. The
-soption is only valid when no
.sbfsfeed simulation file is specified as an argument.
Specifies the URI of the StreamBase Server to communicate with. The default is
sb://localhost:10000/.The URI can also be set using the
STREAMBASE_SERVERenvironment variable. See the sburi page of the Reference Guide (or see sburi(5) at the UNIX shell prompt) for a discussion of the URI format and its shortcuts.
The sbfeedsim command's
-uoption accepts a comma-separated list of URIs, where each URI specifies a different StreamBase Server in a high availability cluster. See the Multiple URI Syntax for HA Scenarios page in the Reference Guide for details.
Speeds up all streams by a factor specified by
. For example,
-x 2runs the feed simulation at twice the default speed.
Specify a long value for
to be used as the random value generator's seed, when automatically generating values for each field in each stream. Without this option, sbfeedsim uses zero as the seed. The values generated by sbfeedsim are the same for a given seed value, which makes tests with the same seed value repeatable. Specify a seed value other than zero to generate a different set of values than the default setting.
Prints version information and exits.
The optional feed simulation file is
If specified, sbfeedsim generates a load using the specifications in that file.
If you create a data file to contain sample data for testing purposes, it is typically a comma-separated or tab-delimited file.
Optional. Contains the URI for a StreamBase Server instance. Use this variable to set a default StreamBase URI for certain StreamBase commands that take the
-uoption. For example, sbc status honors the variable, but sbc list does not. If set, commands use the URI in this variable
.If this variable is set, you must use the
-uoption to communicate with any server other than the one specified in this variable. You can set a comma-separated list of URIs in the variable, and commands such as sbc status returns status for all listed servers. However, sbc list returns information only for the first listed server. See the sburi(5) page in the Reference Guide for more on StreamBase URIs.
Optional. If set to any value, StreamBase command-line utilities assign a terminal window title to match the name of the executable being run. By default terminal titles are not affected.
When you have saved a feed simulation file that specifies data generation from a JDBC data source, you can run that file with sbfeedsim. For this to work, the JDBC driver JAR file must be in the classpath. You can set the
CLASSPATHenvironment variable, or use another standard classpath setting method. If you use the
CLASSPATHenvironment variable, append to the existing classpath the full path to the JDBC JAR file. See Feed Simulation with a JDBC Data Source for further information.