beautypg.com

Creating the springinit.java file, Figure 114 – HP Integrity NonStop J-Series User Manual

Page 261

background image

Figure 114 Project Explorer View

Modifying the EmpInfo application involves the following activities:

1.

Creating the SpringInit.java File

2.

Creating the services.xml File

3.

Modifying the applicationContext.xml File

4.

Creating the build.xml File

5.

Adding Dependency JAR Files

Creating the SpringInit.java File

Create a Java class (SpringInit.java) to initialize the EmpInfo application context when the
application is exposed under Axis2/Java.

NOTE:

The SpringInit.java is a ServiceLifeCycle class and its startUp method gets

called when it is being loaded. This is required to expose EmpInfo as a webservice under
Axis2/Java.

To create SpringInit.java , complete the following steps:

1.

Create SpringInit.java in the com.hp.empinfo.service package, as explained in

Creating the Controller for EmpInfo

section in

Getting Started with Spring

section.

2.

Modify the SpringInit.java file to include the startUp method.

After modification, the SpringInit.java file must appear as:

package com.hp.empinfo.service;

Integrating Axis2/Java into Spring

261

This manual is related to the following products: