You can configure the eXtreme Scale REST data service
on WebSphere® Application Server Community Edition Version 2.1.1.3 or
later.
Before you begin
- An IBM® (recommended) or
Oracle JRE or JDK, Version 6 or later is
installed and the JAVA_HOME environment variable is set.
- Download and install WebSphere Application Server Community Edition Version 2.1.1.3 or later
to the wasce_root directory, for example the /opt/IBM/wasce directory.
Read the installation instructions for information on version 2.1.1 or other versions.
Procedure
- Configure and start a data grid.
- For details on configuring an eXtreme Scale data grid for use
with the REST data service, read about Starting a stand-alone data grid for REST data services.
- Verify that an eXtreme Scale client can connect
to and access entities in the data grid. For an example, see Tutorial: Getting started with WebSphere eXtreme Scale.
- Build the eXtreme Scale REST
service configuration JAR or directory. See the packaging and deployment
information in the Installing the REST data service topic for
details.
- Start the WebSphere Application Server Community Edition server:
- To start the server without Java™ SE security enabled, run the following
command:
![[Unix]](./icons/ngunix.gif)
wasce_root/bin/startup.sh
wasce_root/bin/startup.bat
- To start the server with Java SE
security enabled, follow these steps:
![[Unix]](./icons/ngunix.gif)
- Open a command-line or terminal window and
run the following copy
command (or copy the contents of the specified policy file into your
existing policy): cp restservice_home/gettingstarted/wasce/geronimo.policy
wasce_root/bin
- Edit the wasce_root/bin/setenv.sh file
- After the line that contains "WASCE_JAVA_HOME=",
add the following: export JAVA_OPTS="-Djava.security.manager
-Djava.security.policy=geronimo.policy"
- Open a command-line window and run the following
copy command
or copy the contents of the specified policy file into your existing
policy:
copy restservice_home\gettingstarted\wasce\geronimo.policy\bin
- Edit the wasce_root\bin\setenv.bat file
- After the line that contains "set WASCE_JAVA_HOME=",
add the following:
set
JAVA_OPTS="-Djava.security.manager -Djava.security.policy=geronimo.policy"
- Add
the ObjectGrid client runtime JAR to the WebSphere Application Server Community Edition repository:
- Open the WebSphere Application Server Community Edition administration
console and log in. The default URL is: http://localhost:8080/console and
the default userid is system and password is manager.
- Click the Repository link on the left side
of the console window, in the Services folder.
- In the Add Archive to Repository section,
fill in the following into the input text boxes:
Table 1. Add
Archive to RepositoryText box |
Value |
File |
wxs_home/lib/ogclient.jar |
Group |
com.ibm.websphere.xs |
Artifact |
ogclient |
Version |
7.1 |
Type |
JAR |
- Click the Install button
See the following tech note
for details on different ways
class and library dependencies can be configured: Specifying external dependencies to applications
running on WebSphere Application
Server Community Edition.
- Deploy
and start the REST data service module, the wxsrestservice.war file,
to the WebSphere Application Server Community Edition server.
- Copy and edit the sample deployment plan XML
file: restservice_home/gettingstarted/wasce/geronimo-web.xml to
include path dependencies to your REST data service configuration
JAR or directory. See section for an example on setting the classpath
to include your wxsRestService.properties file
and other configuration files and metadata classes.
- Open the WebSphere Application Server Community Edition administration
console and log in.
Tip: The default URL is: http://localhost:8080/console.
The default userid is system and password is manager.
- Click on
the Deploy Newlink on
the left side of the console window.
- On the Install New Applications page,
enter the following values into the text boxes:
Table 2. Install New ApplicationsText box |
Value |
Archive |
restservice_home/lib/wxsrestservice.war |
Plan |
restservice_home/gettingstarted/wasce/geronimo-web.xml |
Tip: Use the path
to the geronimo-web.xml file
that you copied and edited in step 3.
- Click on the Install button. The console page then indicates
that the application was successfully installed and started.
- Examine the WebSphere Application Server Community Edition system
output log or console to verify that the REST data service has started
successfully. The following message must appear:
CWOBJ4000I:
The WebSphere eXtreme Scale REST data service has been started.
- Start the WebSphere Application Server Community Edition server
by running the following command:
![[Unix]](./icons/ngunix.gif)
wasce_root/bin/startup.sh
wasce_root/bin/startup.bat
- Install the eXtreme Scale REST
data service and the provided sample into the WebSphere Application Server Community Edition server:
- Add the ObjectGrid client runtime JAR to the WebSphere Application Server Community Edition repository:
- Open the WebSphere Application Server Community Edition administration
console and log in. The default URL is: http://localhost:8080/console.
The default userid is system and password is manager.
- Click the Repository link on the left side
of the console window, in the Services folder.
- In the Add Archive to Repository section,
fill in the following into the input text boxes:
Table 3. Add
Archive to RepositoryText box |
Value |
File |
wxs_home/lib/ogclient.jar |
Group |
com.ibm.websphere.xs |
Artifact |
ogclient |
Version |
7.1 |
Type |
JAR |
- Click the install button.
- Deploy the REST data service module: wxsrestservice.war to
the WebSphere Application Server Community Edition server.
- Edit the sample restservice_home/gettingstarted/wasce/geronimo-web.xml deployment
XML file to include path dependencies to the getting started sample
classpath directories:
- Change the "classesDirs" for the two
getting started client GBeans:
The "classesDirs" path for
the GettingStarted_Client_SharedLib
GBean should be set to: restservice_home/gettingstarted/restclient/binThe
"classesDirs" path for the GettingStarted_Common_SharedLib GBean should
be set to: restservice_home/gettingstarted/common/bin
- Open the WebSphere Application Server Community Edition administration
console and log in.
- Click on the Deploy New link on the left
side of the console window.
- On the Install New
Applications page, enter
the following values into the text boxes:
Table 4. Install New
ApplicationsText box |
Value |
Archive |
restservice_home/lib/wxsrestservice.war |
Plan |
restservice_home/gettingstarted/wasce/geronimo-web.xml |
- Click the Install button.
The console
page then indicates that the application has successfully installed
and started.
- Examine the WebSphere Application Server Community Edition system
output log to verify that the REST data service has started successfully
by verifying that the following message is present:
CWOBJ4000I:
The WebSphere eXtreme Scale REST data service has been started.
- Verify
that the REST data service is working:
Open
a Web browser and navigate to the following URL: http://<host>:<port>/<context
root>/restservice/<Grid Name>
The default
port for WebSphere Application Server Community Edition is 8080 and
is defined using the "HTTPPort" property in the /var/config/config-substitutions.properties file.
For
example: http://localhost:8080/wxsrestservice/restservice/NorthwindGrid/
Results
The AtomPub service document is displayed.