Web Service Template
Template
Template web service is a web service implemented in Java for training purposes, but can also be used as a starting point to develop actual web services for Enterprise applications. Being a template should be theoretically possible to develop any web service by modifying or adding a small number of Java classes to this template, while maintaining the overall architecture of the web service.
The Template web service was developed using the following technologies:
The Template web service is ready to handle connections to the Oracle, PostegreSQL and MySQL database and includes all the required drivers.
To connect the web service to another database, you must:
1) Modifiy the class adriani.jws.template.db.Database
2) Include the required JDBC drivers into the lib
directory of the deploy enviroment
3) Specify the custom connection string to the database in the configuration.properties
file
The downloadable ZIP package containes:
build.xml
file useful to build the web service
Please read the design document (service_design_ita.pdf
) before attempting to change the Java source or develop a new web service from
the Template project.
In particular it is crucial to understand how to customize the wrappers in the adriani.jws.template.wrappers
package
which shape the structure of the elements produced by the ADBBean
plugin of the Eclipse WTP IDE or the wsdl2java tool.
The aim of these wrappers is to convert the SOAP request in the Java objects used by the business logic and, conversely,
to map the results of the business logic in the SOAP response.
This mechanism grants the loose coupling between the web service logic and the WSDL structure.
The current version of Template web service provides following features:
SimpleClient
)JDBCConnectionPool
)MockConnectionPool
)adriani.jws.template.wrappers
)SystemLogger
)ErrorMessage
)GeneralAnalyzer
)service.benchmark
)