SlideShare a Scribd company logo
© 2016 IBM Corporation
DB2 Native REST Services and
Integration with z/OS Connect
Cécile Benhamou
DB2 z/OS TechSales
cecile_benhamou@fr.ibm.com
What is REST ?
HTTP POST HTTP GET HTTP PUT HTTP DELETE
Create Read/List Update Delete
http://my.cics.example/resources/
http://my.cics.example/resources/specific_resource
URIs Examples : CollectionCollection
MemberMember
URI Conventions
…/Collection
…/Collection/Member
http://www.books.are.us/JKRowling avec GET --> liste of books of JK Rowling
http://www.books.are.us/JKRowling/HarryPotterAndThePhilosophersStonewith avec GET  info on 1er book of JK Rowling
RESTful services base
• REST is an architecture style, compared to SOAP which is a protocol
• Uses generally JSON for data format
• Uses HTTP verbs to indicate operation type (Method)
• Uses URI to indicate invoked resource
Comparison on REST and RESTful
POST /account/create + (JSON with informations for account creation)
POST /account/balance + (JSON with account number)
POST /account/update + (JSON with account number and deposit amount)
REST:
Basic Support, enough for some usage, mais not enough to create REST APIs
RESTful:
POST /account?name=Fred + (JSON with Fred’s information)
GET /account?number=1234
PUT /account?number=1234 + (JSON with deposit amount)
URI transmits used
resource, for example:
Fred’s account number 1234
JSON flow body contains specific
data for action (verb) for resource
(URI)
Corresponds to API REST developers’ needs
HTTP verb transmits method to use
on resource, for example POST to
create, GET to obtain the balance, …
DB2 REST Services
 Implementation of REST Services within DB2
 Uses DDF (Distributed Data Facility)
 Brings a new HTTP listener to process HTTP requests at JSON format
 Provides system services
 Discover DB2 Rest Services (DB2ServiceDiscover)
 Create/Drop DB2 Rest Services (DB2ServiceManager)
 DB2 maps a Service with an SQL request (ex. SELECT, CALL) through a DB2 REST service
package => SQL request DB2 REST Service is executed statically
 advantages : security, authorization, accounting, audit, …
SQL
Applications
REST
JSON
Service Discovery
Data Transformation
Service Invocation
Access Control
Tracing and Auditing (SMF)
Authentication
DDF
DB2 for z/OS
DB2 REST Services
Prerequisites :
• APAR DB2
– V11: PI66828 and PI70477
– V12: PI70652
• Job DSNTIJRS : creation of table SYSIBM.DSNSERVICE in db DSNSVCDB
• Create a profile DB2 REST into DSNR class and authorize users to have access
to DB2 REST services
Documentation :
• DB2 Knowledge Center : DB2 REST Services
https://www.ibm.com/support/knowledgecenter/en/SSEPEK_11.0.0/restserv/src/tpc/d
b2z_restservices.html
• IBM® developerWorks : Getting Started with RESTful Web Services Support in
the Distributed Data Facility of DB2 for z/OS
https://developer.ibm.com/recipes/tutorials/getting-started-with-restful-web-services-
support-in-the-distributed-data-facility-of-db2-for-zos/
Integration with z/OS Connect
 z/OS Connect Enterprise Edition V3 (zCEE) uses native REST Services support in DB2
 DDF Native REST Services are called by zCEE through the zCEE REST Client Service
Provider
 APAR Information : II14827
z/OS Connect Enterprise Edition V3
z/OS Connect
Enterprise Edition V3
z/OS Connect
REST Client
Service
Provider
Authentication
Authorization
Encryption
Service
Discovery
Data
Transformation
Service Invocation
Access Control
(SAF)
Tracing and
Auditing (SMF)
IMS
DB2
CICS
Batch
HTTP
RESTREST APIs
Applications
DB2 REST Service with zCEE V3
DB2
DB2 REST
Service JSON
Request &
Response
Schemas
POST http://<host>:<port>/services/DB2ServiceManager
{“requestType”:“createService“,
“serviceName”:“EmployeeLookup“,
“sqlStmt”:”select * from employee where empno=:empno”,
“description”:”Query employee for the input empno”
}
DB2
Service Creation
with’API
DB2ServiceManager
zCEE Service
Archive (SAR) file
1
23
SQL requests
zCEE V3
Service
Archive Toolkit
zconbt
DB2
Discovery of JSON schemas
associated to the Service
with API
DB2ServiceDiscover
DB2 REST Service with zCEE V3
56
Deploy DB2 Service
In zCEE
Create API &
Deploy
zCEE Service
Archive (SAR) file
zCEE API Archive
(AAR) file
4
Configure REST
Service Provider
Environment: Needs
• REST/JSON Client
– Choice of POSTMAN (Google Chrome extension) for examples
• z/OS Explorer
– To be installed on worktation
– https://developer.ibm.com/mainframe/2017/06/16/whats-new-in-zos-
explorer-aqua-v310/
– Graphical Interface to access z/OS Connect
• Remark : z/OS Connect should be installed and configured
• This will not be addressed in this presentation
Operations to be done on DB2
• Execute DSNTIJRS job (in SDSNSAMP)
– DSNTIJRS cretaes objects for ‘REST Services’
• CREATE DATABASE DSNSVCDB
• CREATE TABLESPACE DSNSVCTS IN DSNSVCDB
• CREATE TABLE SYSIBM.DSNSERVICE
– 2 Services created
• DB2ServiceDiscover : list with existing services description
• DB2ServiceManager : to create or drop a service
• Remark:
– A RACF class has to be created : DSNR (API REST security)
• DSNR ssid.REST
• RDEFINE DSNR (DB2T.REST) OWNER(DB2OWNER) UACC(NONE)
– Userids has to be authorized in READ for the connection to be OK
PERMIT DB2T.REST CLASS(DSNR) ID(DB2USER1) ACCESS(READ)
Scenario
• DB2 Stored Procedure Creation
• DB2 REST Service Creation
• Service Creation in z/OS Connect
• API Creation in z/OS Connect
DB2 Stored Procedure Creation
• Native Stored Procedure GETPROJINFO
– 1 input parameter: PROJNO
– 4 output parameters: PROJNAME, DEPTNO, RESPEMP, PRSTAFF
• SELECT * FROM SYSIBM.SYSROUTINES
WHERE NAME=‘GETPROJINFO’;
SCHEMA OWNER NAME LANGUAGE COLLID
-------------------------------------------------------------
DB2TECH DB2TECH GETPROJINFO SQL DB2TECH
DB2 REST Service Creation
• In POSTMAN
"requestType": "createService“,
"serviceName": "<serviceName>",
"sqlStmt": "<sqlStatement>",
"collectionID": "<serviceCollectionID>", optional
"description": "<serviceDescription>", optional
"<bindOption>": "<bindOption>" optional
Service cretaed in default collection = SYSIBMSERVICE
DB2 REST Service Creation
• In POSTMAN, after SEND
SELECT * FROM SYSIBM.DSNSERVICE
WHERE NAME = 'ProcGetProjInfo’;
NAME COLLID CONTOKEN
---------------------------------------------
ProcGetProjInfo SYSIBMSERVICE HTTPREST
SELECT * FROM SYSIBM.SYSPACKAGE
WHERE OWNER = 'DB2TECH’ AND COLLID = 'SYSIBMSERVICE’
AND NAME = 'ProcGetProjInfo’;
COLLID NAME HOSTLANG
------------------------------------------------
SYSIBMSERVICE ProcGetProjInfo R
DB2 REST Services Visualization
• In POSTMAN
…
ProcGetProjInfo DB2 service call
• In REST POSTMAN
• Result:
The « Body » must contain input parameter
Service Creation in z/OS Connect
• Collect information on DB2 service
• Result
Service Creation in z/OS Connect
• Result
Etc…
Service Creation in z/OS Connect
• SAR file Creation
– To create a service in z/OS Connect, a SAR file has to be
created
– To create this file, following has to be created first:
• A file containing RequestSchema informations
 RequestSchemaPROCPROJINFO.json
• A file containing ResponseSchema informations
 ResponseSchemaPROCPROJINFO.json
• A properties fie
 ProcGetProjInfo.properties
provider=rest
name=ProcGetProjInfo
version=1.0
description=Exemple DB2 service ProcGetProjInfo
requestSchemaFile=RequestSchemaPROCPROJINFO.json
responseSchemaFile=ResponseSchemaPROCPROJINFO.json
verb=POST
uri=/services/ProcGetProjInfo
connectionRef=restEmpConn references server.xml file content
in z/OS Connect
Configure REST service provider in
zCEE
<zosconnect_zosConnectServiceRestClientConnection
id="restEmpConn"
connectionTimeout="30s"
host="9.212.143.76"
port="4740"
basicAuthRef="restBasicAuth"
receiveTimeout="60s" />
File : server.xml
File : ProcGetProjInfo.properties
provider=rest
name=ProcGetProjInfo
version=1.0
description=Exemple DB2 service ProcGetProjInfo
requestSchemaFile=RequestSchemaPROCPROJINFO.json
responseSchemaFile=ResponseSchemaPROCPROJINFO.json
verb=POST
uri=/services/ProcGetProjInfo
connectionRef=restEmpConn
Service Creation in z/OS Connect
• SAR Fiel Creation
– Utility zconbt.bat (Build Toolkit) provided to create SAR file
C:directory where is the file>C: directory where is the utility zconbt.bat zconbt.bat --
properties=ProcGetProjInfo.properties --file= ProcGetProjInfo.sar
Result
directory where is the file>C: directory where is the utility zconbt.bat zconbt.batdirectory where is the file>C: directory where is the utility zconbt.bat zconbt.bat
directory where is the file>C: directory where is the utility zconbt.bat zconbt.batdirectory where is the file>C: directory where is the utility zconbt.bat zconbt.bat
Service Creation in z/OS Connect
• In z/OS Explorer
– « Remote Desktop » Perspective to find SAR file
– To be copied in z/OS Connect « services » directory
Service Visualization in z/OS Connect
• Call for Service Visualization
• Result
z/OS Connect Port
Service Invocation in z/OS Connect
• Invocation
• Result
The « Body » must contain input parameter
API Creation in z/OS Connect
• In z/OS Explorer, « Project Explorer » perspective
Creation of a
new project
API Creation in z/OS Connect
• In z/OS Explorer, new project creation
Give a name to
the project
(to API)
API Creation in z/OS Connect
• Define Path and input parameter
– /apiproj/{projno}
• Suppress POST, PUT and DELETE methods
API Creation in z/OS Connect
• Service: select SAR file
API Creation in z/OS Connect
• Mapping: Request: correspondance between parameters
paramterrrespondre le paramètre en entrée
API Creation in z/OS Connect
• Mapping: Response
We can choose to suppress output
parameter
API Creation in z/OS Connect
• API deployment in z/OS Connect
– Package.xml => right click droit on API in Project Explorer to Deploy in z/OS
Connect
Package.xml
API
API Creation in z/OS Connect
• Deployment result
API Call in z/OS Connect
• Call
• Result
No more « Body ». Input parameter is directly in the Call
zCEE Port
API Parameter
Pres Db2 native rest json and z/OS connect

More Related Content

What's hot

Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版
Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版
Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版IBM Analytics Japan
 
再考、3つの仮想デスクトップイメージ管理と比較
再考、3つの仮想デスクトップイメージ管理と比較再考、3つの仮想デスクトップイメージ管理と比較
再考、3つの仮想デスクトップイメージ管理と比較Citrix Systems Japan
 
XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説
XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説 XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説
XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説 Citrix Systems Japan
 
デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編
デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編
デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編Citrix Systems Japan
 
AWSによるWebサイト構築と運用 - concrete5 編 -
AWSによるWebサイト構築と運用 - concrete5 編 -AWSによるWebサイト構築と運用 - concrete5 編 -
AWSによるWebサイト構築と運用 - concrete5 編 -Shuji Watanabe
 
[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証
[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証
[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証Wataru Unno
 
XenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとは
XenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとはXenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとは
XenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとはCitrix Systems Japan
 
[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항
[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항
[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항Ji-Woong Choi
 
IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証
IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証
IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証TAKUYA OHTA
 
La virtualisation de_serveurs
La virtualisation de_serveursLa virtualisation de_serveurs
La virtualisation de_serveursNidhal Fersi
 
IBM Cloud: Direct Link Guide (Japanese)
IBM Cloud: Direct Link Guide (Japanese)IBM Cloud: Direct Link Guide (Japanese)
IBM Cloud: Direct Link Guide (Japanese)Tomoyuki Niijima
 
WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)ejlp12
 
NetApp XCP データ移行ツールインストールと設定
NetApp XCP データ移行ツールインストールと設定NetApp XCP データ移行ツールインストールと設定
NetApp XCP データ移行ツールインストールと設定Kan Itani
 
AD設計の基礎から読み解くIaaS On AD
AD設計の基礎から読み解くIaaS On ADAD設計の基礎から読み解くIaaS On AD
AD設計の基礎から読み解くIaaS On ADNaoki Abe
 
Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開
Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開
Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開Citrix Systems Japan
 
Sql server のバックアップとリストアの基礎
Sql server のバックアップとリストアの基礎Sql server のバックアップとリストアの基礎
Sql server のバックアップとリストアの基礎Masayuki Ozawa
 
IBM DB2 LUW UDB DBA Training by www.etraining.guru
IBM DB2 LUW UDB DBA Training by www.etraining.guruIBM DB2 LUW UDB DBA Training by www.etraining.guru
IBM DB2 LUW UDB DBA Training by www.etraining.guruRavikumar Nandigam
 
オンプレ回帰も簡単実現!自由自在なデータベース運用とは
オンプレ回帰も簡単実現!自由自在なデータベース運用とはオンプレ回帰も簡単実現!自由自在なデータベース運用とは
オンプレ回帰も簡単実現!自由自在なデータベース運用とは株式会社クライム
 
VMware vSphere Networking deep dive
VMware vSphere Networking deep diveVMware vSphere Networking deep dive
VMware vSphere Networking deep diveVepsun Technologies
 
Architecture des Systèmes Logiciels
Architecture des Systèmes LogicielsArchitecture des Systèmes Logiciels
Architecture des Systèmes LogicielsGhazouani Mahdi
 

What's hot (20)

Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版
Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版
Db2 Warehouse on Cloud Flex テクニカルハンドブック 2020年3月版
 
再考、3つの仮想デスクトップイメージ管理と比較
再考、3つの仮想デスクトップイメージ管理と比較再考、3つの仮想デスクトップイメージ管理と比較
再考、3つの仮想デスクトップイメージ管理と比較
 
XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説
XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説 XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説
XenDesktop 7.6とXenApp 7.6の移行および注意点について徹底解説
 
デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編
デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編
デスクトップ仮想化入門 VMware ESXi + XenDesktop 7 編
 
AWSによるWebサイト構築と運用 - concrete5 編 -
AWSによるWebサイト構築と運用 - concrete5 編 -AWSによるWebサイト構築と運用 - concrete5 編 -
AWSによるWebサイト構築と運用 - concrete5 編 -
 
[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証
[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証
[Citrix on Nutanix] LoginVSI による MCSとPVS の比較検証
 
XenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとは
XenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとはXenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとは
XenDesktop / XenAppの可用性を最大化するポッドアーキテクチャとは
 
[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항
[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항
[오픈소스컨설팅]클라우드기반U2L마이그레이션 전략 및 고려사항
 
IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証
IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証
IT エンジニアのための 流し読み Windows - Windows のライセンス認証 & サブスクリプションのライセンス認証
 
La virtualisation de_serveurs
La virtualisation de_serveursLa virtualisation de_serveurs
La virtualisation de_serveurs
 
IBM Cloud: Direct Link Guide (Japanese)
IBM Cloud: Direct Link Guide (Japanese)IBM Cloud: Direct Link Guide (Japanese)
IBM Cloud: Direct Link Guide (Japanese)
 
WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)WebSphere Application Server Family (Editions Comparison)
WebSphere Application Server Family (Editions Comparison)
 
NetApp XCP データ移行ツールインストールと設定
NetApp XCP データ移行ツールインストールと設定NetApp XCP データ移行ツールインストールと設定
NetApp XCP データ移行ツールインストールと設定
 
AD設計の基礎から読み解くIaaS On AD
AD設計の基礎から読み解くIaaS On ADAD設計の基礎から読み解くIaaS On AD
AD設計の基礎から読み解くIaaS On AD
 
Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開
Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開
Xen desktop5.6provisioning servicesによる仮想デスクトップの効率的な展開
 
Sql server のバックアップとリストアの基礎
Sql server のバックアップとリストアの基礎Sql server のバックアップとリストアの基礎
Sql server のバックアップとリストアの基礎
 
IBM DB2 LUW UDB DBA Training by www.etraining.guru
IBM DB2 LUW UDB DBA Training by www.etraining.guruIBM DB2 LUW UDB DBA Training by www.etraining.guru
IBM DB2 LUW UDB DBA Training by www.etraining.guru
 
オンプレ回帰も簡単実現!自由自在なデータベース運用とは
オンプレ回帰も簡単実現!自由自在なデータベース運用とはオンプレ回帰も簡単実現!自由自在なデータベース運用とは
オンプレ回帰も簡単実現!自由自在なデータベース運用とは
 
VMware vSphere Networking deep dive
VMware vSphere Networking deep diveVMware vSphere Networking deep dive
VMware vSphere Networking deep dive
 
Architecture des Systèmes Logiciels
Architecture des Systèmes LogicielsArchitecture des Systèmes Logiciels
Architecture des Systèmes Logiciels
 

Similar to Pres Db2 native rest json and z/OS connect

Docker Advanced registry usage
Docker Advanced registry usageDocker Advanced registry usage
Docker Advanced registry usageDocker, Inc.
 
Scaling Docker Containers using Kubernetes and Azure Container Service
Scaling Docker Containers using Kubernetes and Azure Container ServiceScaling Docker Containers using Kubernetes and Azure Container Service
Scaling Docker Containers using Kubernetes and Azure Container ServiceBen Hall
 
RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개
RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개
RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개r-kor
 
Tech Talk: DevOps at LeanIX @ Startup Camp Berlin
Tech Talk: DevOps at LeanIX @ Startup Camp BerlinTech Talk: DevOps at LeanIX @ Startup Camp Berlin
Tech Talk: DevOps at LeanIX @ Startup Camp BerlinLeanIX GmbH
 
High quality ap is with api platform
High quality ap is with api platformHigh quality ap is with api platform
High quality ap is with api platformNelson Kopliku
 
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...MongoDB
 
WebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and DockerWebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and DockerDavid Currie
 
Was liberty profile and docker
Was liberty profile and dockerWas liberty profile and docker
Was liberty profile and dockersflynn073
 
REST Development made Easy with ColdFusion Aether
REST Development made Easy with ColdFusion AetherREST Development made Easy with ColdFusion Aether
REST Development made Easy with ColdFusion AetherPavan Kumar
 
Important work-arounds for making ASS multi-lingual
Important work-arounds for making ASS multi-lingualImportant work-arounds for making ASS multi-lingual
Important work-arounds for making ASS multi-lingualAxel Faust
 
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto Docker, Inc.
 
Deployment ibm connections - No Http Server required
Deployment ibm connections - No Http Server requiredDeployment ibm connections - No Http Server required
Deployment ibm connections - No Http Server requiredSarwar Javaid
 
Intro to node and mongodb 1
Intro to node and mongodb   1Intro to node and mongodb   1
Intro to node and mongodb 1Mohammad Qureshi
 
Native REST Web Services with Oracle 11g
Native REST Web Services with Oracle 11gNative REST Web Services with Oracle 11g
Native REST Web Services with Oracle 11gMarcelo Ochoa
 
Easing ASP.NET Web and SQL Server Database Deployment with VS 2010 and MsDeploy
Easing ASP.NET Web and  SQL Server Database Deployment withVS 2010 and MsDeployEasing ASP.NET Web and  SQL Server Database Deployment withVS 2010 and MsDeploy
Easing ASP.NET Web and SQL Server Database Deployment with VS 2010 and MsDeployEduardo Castro
 
The goodies of zope, pyramid, and plone (2)
The goodies of zope, pyramid, and plone (2)The goodies of zope, pyramid, and plone (2)
The goodies of zope, pyramid, and plone (2)Dylan Jay
 
web2py:Web development like a boss
web2py:Web development like a bossweb2py:Web development like a boss
web2py:Web development like a bossFrancisco Ribeiro
 

Similar to Pres Db2 native rest json and z/OS connect (20)

Docker Advanced registry usage
Docker Advanced registry usageDocker Advanced registry usage
Docker Advanced registry usage
 
Scaling Docker Containers using Kubernetes and Azure Container Service
Scaling Docker Containers using Kubernetes and Azure Container ServiceScaling Docker Containers using Kubernetes and Azure Container Service
Scaling Docker Containers using Kubernetes and Azure Container Service
 
RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개
RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개
RUCK 2017 R에 날개 달기 - Microsoft R과 클라우드 머신러닝 소개
 
Tech Talk: DevOps at LeanIX @ Startup Camp Berlin
Tech Talk: DevOps at LeanIX @ Startup Camp BerlinTech Talk: DevOps at LeanIX @ Startup Camp Berlin
Tech Talk: DevOps at LeanIX @ Startup Camp Berlin
 
High quality ap is with api platform
High quality ap is with api platformHigh quality ap is with api platform
High quality ap is with api platform
 
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
Securing MongoDB to Serve an AWS-Based, Multi-Tenant, Security-Fanatic SaaS A...
 
WebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and DockerWebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and Docker
 
Was liberty profile and docker
Was liberty profile and dockerWas liberty profile and docker
Was liberty profile and docker
 
Soap Toolkit Dcphp
Soap Toolkit DcphpSoap Toolkit Dcphp
Soap Toolkit Dcphp
 
REST Development made Easy with ColdFusion Aether
REST Development made Easy with ColdFusion AetherREST Development made Easy with ColdFusion Aether
REST Development made Easy with ColdFusion Aether
 
Important work-arounds for making ASS multi-lingual
Important work-arounds for making ASS multi-lingualImportant work-arounds for making ASS multi-lingual
Important work-arounds for making ASS multi-lingual
 
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
Orchestrating Docker with Terraform and Consul by Mitchell Hashimoto
 
ITB2017 - Keynote
ITB2017 - KeynoteITB2017 - Keynote
ITB2017 - Keynote
 
Deployment ibm connections - No Http Server required
Deployment ibm connections - No Http Server requiredDeployment ibm connections - No Http Server required
Deployment ibm connections - No Http Server required
 
Intro to node and mongodb 1
Intro to node and mongodb   1Intro to node and mongodb   1
Intro to node and mongodb 1
 
How to debug IoT Agents
How to debug IoT AgentsHow to debug IoT Agents
How to debug IoT Agents
 
Native REST Web Services with Oracle 11g
Native REST Web Services with Oracle 11gNative REST Web Services with Oracle 11g
Native REST Web Services with Oracle 11g
 
Easing ASP.NET Web and SQL Server Database Deployment with VS 2010 and MsDeploy
Easing ASP.NET Web and  SQL Server Database Deployment withVS 2010 and MsDeployEasing ASP.NET Web and  SQL Server Database Deployment withVS 2010 and MsDeploy
Easing ASP.NET Web and SQL Server Database Deployment with VS 2010 and MsDeploy
 
The goodies of zope, pyramid, and plone (2)
The goodies of zope, pyramid, and plone (2)The goodies of zope, pyramid, and plone (2)
The goodies of zope, pyramid, and plone (2)
 
web2py:Web development like a boss
web2py:Web development like a bossweb2py:Web development like a boss
web2py:Web development like a boss
 

Recently uploaded

Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPsWebinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPsCEPTES Software Inc
 
Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...
Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...
Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...Domenico Conte
 
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单ewymefz
 
2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...
2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...
2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...elinavihriala
 
一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单ewymefz
 
Q1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year ReboundQ1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year ReboundOppotus
 
社内勉強会資料_LLM Agents                              .
社内勉強会資料_LLM Agents                              .社内勉強会資料_LLM Agents                              .
社内勉強会資料_LLM Agents                              .NABLAS株式会社
 
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单nscud
 
一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单enxupq
 
Computer Presentation.pptx ecommerce advantage s
Computer Presentation.pptx ecommerce advantage sComputer Presentation.pptx ecommerce advantage s
Computer Presentation.pptx ecommerce advantage sMAQIB18
 
Uber Ride Supply Demand Gap Analysis Report
Uber Ride Supply Demand Gap Analysis ReportUber Ride Supply Demand Gap Analysis Report
Uber Ride Supply Demand Gap Analysis ReportSatyamNeelmani2
 
Tabula.io Cheatsheet: automate your data workflows
Tabula.io Cheatsheet: automate your data workflowsTabula.io Cheatsheet: automate your data workflows
Tabula.io Cheatsheet: automate your data workflowsalex933524
 
Supply chain analytics to combat the effects of Ukraine-Russia-conflict
Supply chain analytics to combat the effects of Ukraine-Russia-conflictSupply chain analytics to combat the effects of Ukraine-Russia-conflict
Supply chain analytics to combat the effects of Ukraine-Russia-conflictJack Cole
 
tapal brand analysis PPT slide for comptetive data
tapal brand analysis PPT slide for comptetive datatapal brand analysis PPT slide for comptetive data
tapal brand analysis PPT slide for comptetive datatheahmadsaood
 
一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单
一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单
一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单ewymefz
 
How can I successfully sell my pi coins in Philippines?
How can I successfully sell my pi coins in Philippines?How can I successfully sell my pi coins in Philippines?
How can I successfully sell my pi coins in Philippines?DOT TECH
 
Opendatabay - Open Data Marketplace.pptx
Opendatabay - Open Data Marketplace.pptxOpendatabay - Open Data Marketplace.pptx
Opendatabay - Open Data Marketplace.pptxOpendatabay
 
Criminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdfCriminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdfCriminal IP
 
Investigate & Recover / StarCompliance.io / Crypto_Crimes
Investigate & Recover / StarCompliance.io / Crypto_CrimesInvestigate & Recover / StarCompliance.io / Crypto_Crimes
Investigate & Recover / StarCompliance.io / Crypto_CrimesStarCompliance.io
 
一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单enxupq
 

Recently uploaded (20)

Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPsWebinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
Webinar One View, Multiple Systems No-Code Integration of Salesforce and ERPs
 
Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...
Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...
Professional Data Engineer Certification Exam Guide  _  Learn  _  Google Clou...
 
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
一比一原版(IIT毕业证)伊利诺伊理工大学毕业证成绩单
 
2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...
2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...
2024-05-14 - Tableau User Group - TC24 Hot Topics - Tableau Pulse and Einstei...
 
一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单一比一原版(NYU毕业证)纽约大学毕业证成绩单
一比一原版(NYU毕业证)纽约大学毕业证成绩单
 
Q1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year ReboundQ1’2024 Update: MYCI’s Leap Year Rebound
Q1’2024 Update: MYCI’s Leap Year Rebound
 
社内勉強会資料_LLM Agents                              .
社内勉強会資料_LLM Agents                              .社内勉強会資料_LLM Agents                              .
社内勉強会資料_LLM Agents                              .
 
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
一比一原版(CBU毕业证)不列颠海角大学毕业证成绩单
 
一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单一比一原版(QU毕业证)皇后大学毕业证成绩单
一比一原版(QU毕业证)皇后大学毕业证成绩单
 
Computer Presentation.pptx ecommerce advantage s
Computer Presentation.pptx ecommerce advantage sComputer Presentation.pptx ecommerce advantage s
Computer Presentation.pptx ecommerce advantage s
 
Uber Ride Supply Demand Gap Analysis Report
Uber Ride Supply Demand Gap Analysis ReportUber Ride Supply Demand Gap Analysis Report
Uber Ride Supply Demand Gap Analysis Report
 
Tabula.io Cheatsheet: automate your data workflows
Tabula.io Cheatsheet: automate your data workflowsTabula.io Cheatsheet: automate your data workflows
Tabula.io Cheatsheet: automate your data workflows
 
Supply chain analytics to combat the effects of Ukraine-Russia-conflict
Supply chain analytics to combat the effects of Ukraine-Russia-conflictSupply chain analytics to combat the effects of Ukraine-Russia-conflict
Supply chain analytics to combat the effects of Ukraine-Russia-conflict
 
tapal brand analysis PPT slide for comptetive data
tapal brand analysis PPT slide for comptetive datatapal brand analysis PPT slide for comptetive data
tapal brand analysis PPT slide for comptetive data
 
一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单
一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单
一比一原版(UPenn毕业证)宾夕法尼亚大学毕业证成绩单
 
How can I successfully sell my pi coins in Philippines?
How can I successfully sell my pi coins in Philippines?How can I successfully sell my pi coins in Philippines?
How can I successfully sell my pi coins in Philippines?
 
Opendatabay - Open Data Marketplace.pptx
Opendatabay - Open Data Marketplace.pptxOpendatabay - Open Data Marketplace.pptx
Opendatabay - Open Data Marketplace.pptx
 
Criminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdfCriminal IP - Threat Hunting Webinar.pdf
Criminal IP - Threat Hunting Webinar.pdf
 
Investigate & Recover / StarCompliance.io / Crypto_Crimes
Investigate & Recover / StarCompliance.io / Crypto_CrimesInvestigate & Recover / StarCompliance.io / Crypto_Crimes
Investigate & Recover / StarCompliance.io / Crypto_Crimes
 
一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单一比一原版(YU毕业证)约克大学毕业证成绩单
一比一原版(YU毕业证)约克大学毕业证成绩单
 

Pres Db2 native rest json and z/OS connect

  • 1. © 2016 IBM Corporation DB2 Native REST Services and Integration with z/OS Connect Cécile Benhamou DB2 z/OS TechSales cecile_benhamou@fr.ibm.com
  • 2. What is REST ? HTTP POST HTTP GET HTTP PUT HTTP DELETE Create Read/List Update Delete http://my.cics.example/resources/ http://my.cics.example/resources/specific_resource URIs Examples : CollectionCollection MemberMember URI Conventions …/Collection …/Collection/Member http://www.books.are.us/JKRowling avec GET --> liste of books of JK Rowling http://www.books.are.us/JKRowling/HarryPotterAndThePhilosophersStonewith avec GET  info on 1er book of JK Rowling RESTful services base • REST is an architecture style, compared to SOAP which is a protocol • Uses generally JSON for data format • Uses HTTP verbs to indicate operation type (Method) • Uses URI to indicate invoked resource
  • 3. Comparison on REST and RESTful POST /account/create + (JSON with informations for account creation) POST /account/balance + (JSON with account number) POST /account/update + (JSON with account number and deposit amount) REST: Basic Support, enough for some usage, mais not enough to create REST APIs RESTful: POST /account?name=Fred + (JSON with Fred’s information) GET /account?number=1234 PUT /account?number=1234 + (JSON with deposit amount) URI transmits used resource, for example: Fred’s account number 1234 JSON flow body contains specific data for action (verb) for resource (URI) Corresponds to API REST developers’ needs HTTP verb transmits method to use on resource, for example POST to create, GET to obtain the balance, …
  • 4. DB2 REST Services  Implementation of REST Services within DB2  Uses DDF (Distributed Data Facility)  Brings a new HTTP listener to process HTTP requests at JSON format  Provides system services  Discover DB2 Rest Services (DB2ServiceDiscover)  Create/Drop DB2 Rest Services (DB2ServiceManager)  DB2 maps a Service with an SQL request (ex. SELECT, CALL) through a DB2 REST service package => SQL request DB2 REST Service is executed statically  advantages : security, authorization, accounting, audit, … SQL Applications REST JSON Service Discovery Data Transformation Service Invocation Access Control Tracing and Auditing (SMF) Authentication DDF DB2 for z/OS
  • 5. DB2 REST Services Prerequisites : • APAR DB2 – V11: PI66828 and PI70477 – V12: PI70652 • Job DSNTIJRS : creation of table SYSIBM.DSNSERVICE in db DSNSVCDB • Create a profile DB2 REST into DSNR class and authorize users to have access to DB2 REST services Documentation : • DB2 Knowledge Center : DB2 REST Services https://www.ibm.com/support/knowledgecenter/en/SSEPEK_11.0.0/restserv/src/tpc/d b2z_restservices.html • IBM® developerWorks : Getting Started with RESTful Web Services Support in the Distributed Data Facility of DB2 for z/OS https://developer.ibm.com/recipes/tutorials/getting-started-with-restful-web-services- support-in-the-distributed-data-facility-of-db2-for-zos/
  • 6. Integration with z/OS Connect  z/OS Connect Enterprise Edition V3 (zCEE) uses native REST Services support in DB2  DDF Native REST Services are called by zCEE through the zCEE REST Client Service Provider  APAR Information : II14827 z/OS Connect Enterprise Edition V3 z/OS Connect Enterprise Edition V3 z/OS Connect REST Client Service Provider Authentication Authorization Encryption Service Discovery Data Transformation Service Invocation Access Control (SAF) Tracing and Auditing (SMF) IMS DB2 CICS Batch HTTP RESTREST APIs Applications
  • 7. DB2 REST Service with zCEE V3 DB2 DB2 REST Service JSON Request & Response Schemas POST http://<host>:<port>/services/DB2ServiceManager {“requestType”:“createService“, “serviceName”:“EmployeeLookup“, “sqlStmt”:”select * from employee where empno=:empno”, “description”:”Query employee for the input empno” } DB2 Service Creation with’API DB2ServiceManager zCEE Service Archive (SAR) file 1 23 SQL requests zCEE V3 Service Archive Toolkit zconbt DB2 Discovery of JSON schemas associated to the Service with API DB2ServiceDiscover
  • 8. DB2 REST Service with zCEE V3 56 Deploy DB2 Service In zCEE Create API & Deploy zCEE Service Archive (SAR) file zCEE API Archive (AAR) file 4 Configure REST Service Provider
  • 9. Environment: Needs • REST/JSON Client – Choice of POSTMAN (Google Chrome extension) for examples • z/OS Explorer – To be installed on worktation – https://developer.ibm.com/mainframe/2017/06/16/whats-new-in-zos- explorer-aqua-v310/ – Graphical Interface to access z/OS Connect • Remark : z/OS Connect should be installed and configured • This will not be addressed in this presentation
  • 10. Operations to be done on DB2 • Execute DSNTIJRS job (in SDSNSAMP) – DSNTIJRS cretaes objects for ‘REST Services’ • CREATE DATABASE DSNSVCDB • CREATE TABLESPACE DSNSVCTS IN DSNSVCDB • CREATE TABLE SYSIBM.DSNSERVICE – 2 Services created • DB2ServiceDiscover : list with existing services description • DB2ServiceManager : to create or drop a service • Remark: – A RACF class has to be created : DSNR (API REST security) • DSNR ssid.REST • RDEFINE DSNR (DB2T.REST) OWNER(DB2OWNER) UACC(NONE) – Userids has to be authorized in READ for the connection to be OK PERMIT DB2T.REST CLASS(DSNR) ID(DB2USER1) ACCESS(READ)
  • 11. Scenario • DB2 Stored Procedure Creation • DB2 REST Service Creation • Service Creation in z/OS Connect • API Creation in z/OS Connect
  • 12. DB2 Stored Procedure Creation • Native Stored Procedure GETPROJINFO – 1 input parameter: PROJNO – 4 output parameters: PROJNAME, DEPTNO, RESPEMP, PRSTAFF • SELECT * FROM SYSIBM.SYSROUTINES WHERE NAME=‘GETPROJINFO’; SCHEMA OWNER NAME LANGUAGE COLLID ------------------------------------------------------------- DB2TECH DB2TECH GETPROJINFO SQL DB2TECH
  • 13. DB2 REST Service Creation • In POSTMAN "requestType": "createService“, "serviceName": "<serviceName>", "sqlStmt": "<sqlStatement>", "collectionID": "<serviceCollectionID>", optional "description": "<serviceDescription>", optional "<bindOption>": "<bindOption>" optional Service cretaed in default collection = SYSIBMSERVICE
  • 14. DB2 REST Service Creation • In POSTMAN, after SEND SELECT * FROM SYSIBM.DSNSERVICE WHERE NAME = 'ProcGetProjInfo’; NAME COLLID CONTOKEN --------------------------------------------- ProcGetProjInfo SYSIBMSERVICE HTTPREST SELECT * FROM SYSIBM.SYSPACKAGE WHERE OWNER = 'DB2TECH’ AND COLLID = 'SYSIBMSERVICE’ AND NAME = 'ProcGetProjInfo’; COLLID NAME HOSTLANG ------------------------------------------------ SYSIBMSERVICE ProcGetProjInfo R
  • 15. DB2 REST Services Visualization • In POSTMAN …
  • 16. ProcGetProjInfo DB2 service call • In REST POSTMAN • Result: The « Body » must contain input parameter
  • 17. Service Creation in z/OS Connect • Collect information on DB2 service • Result
  • 18. Service Creation in z/OS Connect • Result Etc…
  • 19. Service Creation in z/OS Connect • SAR file Creation – To create a service in z/OS Connect, a SAR file has to be created – To create this file, following has to be created first: • A file containing RequestSchema informations  RequestSchemaPROCPROJINFO.json • A file containing ResponseSchema informations  ResponseSchemaPROCPROJINFO.json • A properties fie  ProcGetProjInfo.properties provider=rest name=ProcGetProjInfo version=1.0 description=Exemple DB2 service ProcGetProjInfo requestSchemaFile=RequestSchemaPROCPROJINFO.json responseSchemaFile=ResponseSchemaPROCPROJINFO.json verb=POST uri=/services/ProcGetProjInfo connectionRef=restEmpConn references server.xml file content in z/OS Connect
  • 20. Configure REST service provider in zCEE <zosconnect_zosConnectServiceRestClientConnection id="restEmpConn" connectionTimeout="30s" host="9.212.143.76" port="4740" basicAuthRef="restBasicAuth" receiveTimeout="60s" /> File : server.xml File : ProcGetProjInfo.properties provider=rest name=ProcGetProjInfo version=1.0 description=Exemple DB2 service ProcGetProjInfo requestSchemaFile=RequestSchemaPROCPROJINFO.json responseSchemaFile=ResponseSchemaPROCPROJINFO.json verb=POST uri=/services/ProcGetProjInfo connectionRef=restEmpConn
  • 21. Service Creation in z/OS Connect • SAR Fiel Creation – Utility zconbt.bat (Build Toolkit) provided to create SAR file C:directory where is the file>C: directory where is the utility zconbt.bat zconbt.bat -- properties=ProcGetProjInfo.properties --file= ProcGetProjInfo.sar Result directory where is the file>C: directory where is the utility zconbt.bat zconbt.batdirectory where is the file>C: directory where is the utility zconbt.bat zconbt.bat directory where is the file>C: directory where is the utility zconbt.bat zconbt.batdirectory where is the file>C: directory where is the utility zconbt.bat zconbt.bat
  • 22. Service Creation in z/OS Connect • In z/OS Explorer – « Remote Desktop » Perspective to find SAR file – To be copied in z/OS Connect « services » directory
  • 23. Service Visualization in z/OS Connect • Call for Service Visualization • Result z/OS Connect Port
  • 24. Service Invocation in z/OS Connect • Invocation • Result The « Body » must contain input parameter
  • 25. API Creation in z/OS Connect • In z/OS Explorer, « Project Explorer » perspective Creation of a new project
  • 26. API Creation in z/OS Connect • In z/OS Explorer, new project creation Give a name to the project (to API)
  • 27. API Creation in z/OS Connect • Define Path and input parameter – /apiproj/{projno} • Suppress POST, PUT and DELETE methods
  • 28. API Creation in z/OS Connect • Service: select SAR file
  • 29. API Creation in z/OS Connect • Mapping: Request: correspondance between parameters paramterrrespondre le paramètre en entrée
  • 30. API Creation in z/OS Connect • Mapping: Response We can choose to suppress output parameter
  • 31. API Creation in z/OS Connect • API deployment in z/OS Connect – Package.xml => right click droit on API in Project Explorer to Deploy in z/OS Connect Package.xml API
  • 32. API Creation in z/OS Connect • Deployment result
  • 33. API Call in z/OS Connect • Call • Result No more « Body ». Input parameter is directly in the Call zCEE Port API Parameter