Deploying REST service with Command Line
XAP provides an interactive command line tool as part of the product. This can be started using gs.sh/bat command (referred to as GigaSpaces CLI).
This tool provides many commands that can be used to manage and gather information about the various GigaSpaces runtime components. This section describes the commands supported by GigaSpaces CLI.
Deploy Rest service
gs> deploy-rest -spacename [space name] -port [port number]
Deploys a Rest Processing Unit, which starts an embedded jetty and enables interactions with the provided
The processing unit’s name will be
spacename-rest unless the -puname [name] option is provided.
The following deploys rest processing unit and starts a rest service on port 8888 that connects to mySpace.
gs> deploy-rest -spacename mySpace -port 8888
||Required - Name of the Space that the rest should connect to.|
||Required - The port which the rest service will be available on.|
||Specify the processing unit’s name. Defaults to [spacename]-rest|
||The lookup groups to be used when locating the specified space.|
||The lookup locators to be used when locating the specified space.|
||Specify the amount of instances to be deployed. Default to 1|
||Specify the number of instances per VM.|
||Specify the number of instances per machine.|
||Specify the zones that the rest pu can be deployed on|
||Set the primary zone where the processing unit is allowed to be deployed on.|
||Set the timeout for deploying the rest processing unit. Default to 30|