1 - Installing Stand Alone Context Service
Requirements
To install 'Context Manager' make sure you have:
Apache Tomcat and
Maven 1.0.2 installed
CATALINA_HOME and
JAVA_HOME environment variables properly set
Installing Context Manager
- Download ws_context.tar
- Extract the archive. (e.g. /home/<user name>/tar -xvf
ws_context.tar) This will create a directory called "ws_context"
- Update "tomcat.home" variable to point your tomcat installation (e.g.
tomcat.home=${user.home}/tomcat/jakarta-tomcat-5.0.28) in the "project.properties"
located under "ws_context" directory.
- Run "maven war:war -Dmaven.test.skip=true" in the "ws_context" directory.
- Run "maven deploy-context-service". (This will also create a context space
".context" which will then be used by Context Service)
- Restart your Jakarta Tomcat installation.
- This will deploy the ContextManagerPortType service into your Jakarta
Tomcat installation as a web application (<jakarta-tomcat-home>/webapps/ws_context)
- To see a list of deployed web services go to
http://<your-server-name>:<portnum>/ws_context/servlet/AxisServlet
- In order to test whether Context Service is running OK, please run
"maven test" under "ws_context" directory
2 - Installing Stand Alone Context Response Handler Service
Requirements
To install 'Context Respond Handler' make sure you have:
Apache Tomcat and
Maven 1.0.2 installed
CATALINA_HOME and
JAVA_HOME environment variables properly set
Installing Context Response Handler Service
- Download ws_context_respondent.tar
- Extract the archive. (e.g. /home/<user name>/tar -xvf
ws_context_respondent.tar) This will create a directory called "ws_context_respondent"
- Update "tomcat.home" variable to point your tomcat installation (e.g.
tomcat.home=${user.home}/tomcat/jakarta-tomcat-5.0.28) in the "project.properties"
located under "ws_context_respondent" directory.
- Update <host_name> and <port_number> in both "wsctxWSDL" and "wsctxRespondWSDL"
variables in the "wsctx_bootstrap.properties" file located at
"ws_context_respondent/src/java/". (Please use I.P. address of your
machine instead of localhost.)
- Run "maven war:war -Dmaven.test.skip=true" in the "ws_context_respondent" directory.
- Run "maven deploy-context-respondent-service" (This will also create a context space
".context" which will then be used by Context Response Handler Service)
- Restart your Jakarta Tomcat installation.
- This will deploy the ContextResponseHandlerPortType service into your
Jakarta Tomcat installation as a web application (<jakarta-tomcat-home>/webapps/ws_context_respondent)
- To see a list of deployed web services go to
http://<your-server-name>:<portnum>/ws_context_respondent/servlet/AxisServlet
- In order to test whether Context Response Handler Service is running
OK, please run "maven test" under "ws_context_respondent" directory
NOTE: Please note that, your application will need to deploy and run
this service, Context Response Handler, in order to interact with
Context Service. Also, you should know that, implementation of Context
Response Handler may also be up to developers. I introduce my
implementation, so that users can simply use the Context Service as if
it is synchronous Service.
3 - JUnit Test Clients for both Context and
Context Response Handler Services
- Please find the JUnit Test Clients under "../src/tests/" directory
for both installation packages
- In order to test whether Context Service is running OK, please run
"maven test" under "ws_context" directory
- In order to test whether Context Response Handler Service is running
OK, please run "maven test" under "ws_context_respondent" directory
4 - Example Clients for Context Service
- Please find the example Clients to Context Service under "ws_context_respondent/src/java"
directory structure
- There are two example Clients a) TestSetContext.java b)
TestGetContext.java
- In order to test both Context and Context Response Handler Services
are running
OK, please run "maven TestSetContext" under "ws_context_respondent" directory
(By doing this, you will be setting a context (metadata) into Context
Service)
- Then you can run "maven TestGetContext" under "ws_context_respondent" directory.
(By doing this, you will be retrieving the context that you set earlier
from Context Service. See the output.)
- You can find these clients at "project.zip".
In this archive, you will also find required library that you might want
to include your project.
- If you are a JBuilder IDE user, you could simply open this project
as JBuilder project.
- Please note: Context Response Handler Service MUST run on the
same machine where your application (that interacts with Context Service)
resides.
Note: Maven
Repository Problems
- If you experience problems downloading jars with maven, you can download
the required maven repositories below, in .zip format. Unpack either
one in your home directory to create a .maven subdirectory.
dot_maven.zip
|