Building DataFlow Applications : Building DataFlow Applications Using RushScript : Running from the Command Line
 
Share this page                  
Running from the Command Line
When a RushScript source file is ready to execute, it can be run from the command line. This will work in either a Windows or a Linux/UNIX command shell. See Installing DataFlow for Use with Java for more information about installing the DataFlow release and configuring the environment for executing DataFlow applications.
The command line executable used to run RushScript scripts is named dr. After you have set up your environment, the dr command should be in your current path and ready to execute. See the Command Line Usage: dr for more information about all of the options supported by the dr command.
The following simple example demonstrates executing a RushScript source file within a command shell using the dr command. This example runs the agg-ratings.js file, executing the DataFlow applications composed by the script.
$ dr agg-ratings.js
Pass JVM options on the command line before any dr command options.
The following example shows how to set the amount of memory allocated to the JVM used to run DataFlow. The maximum amount of memory the JVM can allocate is implicitly set to 2 Gigabytes (-Xmx2g). It also sets the parallelism engine setting. By default the parallelism is set to the number of CPU cores on the executing system, but here we are explicitly setting the engine parallelism to 16.
$ dr -Xmx2g --engine parallelism=16 agg-ratings.js
See Engine Configuration Settings for a listing of available engine settings.