REST gateway: REST operations

You use HTTP POST, GET, and DELETE operations to insert or update, get, and remove data from the data grid. The REST gateway also supports HTTP requests to manage a grid alias that points to your data grid. Grid aliases are useful when you need to populate more than one data grid at a time and need to switch between them. Grid aliases can be created, queried, and deleted and uses the REST resource/resource/gridalias.

REST operations to populate the data grids

Table 1. Operations with equivalent HTTP methods and response code definitions
Operation HTTP Method Response Code
Insert or update POST
  • 200 CREATED: The data was successfully inserted or updated into the data grid.
  • 400 BAD REQUEST: The data insert or update operation did not complete successfully.
Get GET
  • 200 OK: The response body and content-type are retrieved from a previous insert or update operation.
  • 404 NOT FOUND: The specified key is not present in the data grid.
  • 400 BAD REQUEST: The appliance was unable to process the request.
Delete DELETE
  • 200 NO CONTENT: The entry was deleted from the data grid.
  • 400 BAD REQUEST: The appliance was unable to process the request.
[Version 2.5 and later]

REST operations to manage a aliases for a data grid

Table 2. Operations with equivalent HTTP methods and response code definitions
Operation HTTP Method Response Code
Add or update an alias POST /resources/gridalias/<aliasname>?src=<sourceGridName>
  • 204 SUCCESS: The grid alias was successfully created.
  • 401 SOURCE GRID DOES NOT EXIST: The alias could not be created because the data grid it points to does not exist.
  • 409 DATA GRID EXISTS: The alias could not be created because a data grid with that name already exists.
Get the current data grid for an alias GET /resources/gridalias/<aliasname>
  • 200 OK
Get a list of all aliases GET /resources/gridalias/
  • 200 OK
Delete an alias DELETE /resources/gridalias/<aliasname>
  • 204 SUCCESS: The alias is deleted.
  • 404 BAD REQUEST: The alias does not exist.