Provides step-by-step instructions that guide you through the process of generating all components of the Reverse CICS Web
service provider from JSON.
Use the
New CICS Web Service wizard to generate the components of your Web service provider.
- From the
Application Explorer view, click the
ReverseJSON project to select it.
- Click
File > New > CICS Web Service. This starts the
New CICS Web Service Wizard.
Note: If
CICS Web Service is not listed:
- Select
Other.
- Expand
Micro Focus Service Interface.
- Select
CICS Web Service; then click
Next.
- Under
Service type, select
JSON message processing.
- From the drop-down list, select
CICS Web Service Provider (Top-Down, Request-Response); then click
Next.
The
Project field is already populated with the name of the current project,
ReverseJSON.
- Click the
Browse button that corresponds to the
JSON request field.
- Navigate to and select the
reverse.json file, located in your project's
schema folder.
- Click the
Browse button that corresponds to the
JSON response field.
- Navigate to and select the
reverse.json file, located in your project's
schema folder.
You need to provide a URI that
Enterprise Server can use to identify and locate the appropriate Web service upon receiving a request or a response. This information goes
into the
Service location field.
- In the
Service location field, type
/cics/services/json/reverse.
- Select
CHANNEL from the
Program interface drop-down list.
The default container name is
DFHWS-DATA, which is the top-level container used in service provider applications for CICS Web services.
- Click
Next.
- In the
Output artifacts group, type
reverseJ into the
Program name field. This is the name of the generated COBOL skeleton program.
The file prefixes you supply for the
Request file prefix and
Response file prefix fields become the first part of the filenames of the generated copybooks that support the generated skeleton program file;
one for request data structures, and one for response data structures.
- In the
Request file prefix field, type
REQ.
- In the
Response file prefix field, type
RESP.
Enterprise Developer generates a WSBIND file that maps the JSON request to the data structure in the generated request copybook and maps the JSON
response to the data structure in the generated response copybook. You need to provide a folder and filename for this file.
- Click the
Browse button that corresponds to the
WSBIND file field.
- On the
Browse for WSBIND file dialog box, click
New folder.
- In the field for the folder name, overwrite
New folder with
loadlib; then press
Enter.
- Double-click the
loadlib folder.
- In the
File name field, type
ReverseJ; then click
Open.
- Click
Finish.
Enterprise Developer generates the following CICS Web service components:
- reverseJ.cbl
- A skeleton CICS program.
- reverseJ.svi
- A service interface file.
- REQ01.CPY
- A copybook containing the COBOL data structures required to send a JSON request as input. This file is generated but does
not appear in the
Solution Explorer.
- RESP01.CPY
- A copybook containing the COBOL data structures required to receive a JSON response message as output.