General presentation
Web services implement business logic that is made "consumable" through the use of standards (mainly TCP/IP, URI/URN/URL, MIME, HTTP/SMTP, SOAP, SSL/TLS for data transport, and XML for SOAP Services, WML / JSON content or any other format for RESTful Services content. This enables the logic to be used by any technology that supports these standards, thereby facilitating application interoperability.
The creation of Web services is justified by their service-focused architecture, reflecting the desire to provide a service that uses business logic that is hidden to users.
With Business-to-Business and Business-to-Consumer data exchange agreements, the fact that Web services use the HTTP protocol (via port 80 by default) is another argument in their favor. Port 80 is generally open at all times, allowing Web services to be used even if the company has closed its ports using firewalls.
Reportless VADELIA batch programs can be generated as Web services (provided you have an Adelia Web Studio license). The VADELIA batch program's external entry points (INIT_PGM paragraph and public procedure) can be used to define the operations performed by the Web service.
VADELIA batch programs generated as Web services will be placed in the Web application, if their visibility permits. The visibility is set on the environment's Attributes Web page, in the case of public programs, or on the Attributes Web page (logical level) of the program's attachment application area in the case of private programs.
A VADELIA batch program generated as a Web service operates in pooled mode for its client/server accesses. The program uses the default pool.
If you want to use a particular named pool, you must create a file named <Program object file name>config.properties in the WEB-INF/classes/$(package) folder (i.e. the folder in which the program's .class file was generated) of the program's Web application. The key called PoolName in the new file must be set with the name of the named pool that you want to use for the program.
There arefamilies of Web services:
Adelia Studio can be used to produce Web services of both families: The user chooses either family by selecting the required style (REST or another) as follows (three possibilities):
- From the Environment attributes > Web tab > Web - Web Services tab
- From the Application Area attributes > Web tab > Web - Web Services tab
- From the Program generation options
Click here for more information about:
4GL instructions on Web services ( Adelia Web programs and Visual Adelia programs)
the DLL VaToolBx functions related to Web services ( VaToolBxGetWebServiceConfigFile, VaToolBxSetWebServiceConfigFile) .