GigaSpaces as Windows Service

Common Scenarios

GigaSpaces infrastructure can be started using a GigaSpaces Grid Service Agent as explained in GSA page. When using Windows based OS for running GigaSpaces infrastructure, users want to convert GSAClosed Grid Service Agent. This is a process manager that can spawn and manage Service Grid processes (Operating System level processes) such as The Grid Service Manager, The Grid Service Container, and The Lookup Service. Typically, the GSA is started with the hosting machine's startup. Using the agent, you can bootstrap the entire cluster very easily, and start and stop additional GSCs, GSMs and lookup services at will. into a windows service for following common reasons,

  1. GSA process should survive a user logoff.
  2. GSA command windows should be hidden so that they are not closed accidentally by users.
  3. GSA process should restart automatically after a machine restart and all GigaSpaces infrastructure should be available without user/administrator intervention.


If your requirement is only item 1 and/or 2 above, you can use psexec (SysInternals/Microsoft tool, http://technet.microsoft.com/en-us/sysinternals/bb897553). When you start the GSA using psexec from a remote machine in the network the process does not open command windows and does not get terminated on a logoff of the user.

Windows Service

If you need to fulfill all 3 reasons above, then you have to create a windows service for GSA.

Easiest way to convert GSA into service is to use the .NET version of the product and create windows service using the instructions that are documented in the XAP.NET installation documentation.

Some users are not comfortable using the .NET version of the product and want to use only Java version of the product. In such cases, there are many software that can help in converting a Java Application (like GigaSpaces) to a Windows Service.


An example GSA windows service configuration created using Java Service Wrapper can be downloaded from here. It was created using the instructions on Tanuki software website.

Other Information