- Ashok Kumar Pattanaik
- PowerBuilder
- Friday, 17 May 2019 05:15 PM UTC
Hi,
Recently we migrated our application from PB12.5 to PB2017 R3 in order to support TLS1.2. We are following easySOAP method and connecting SOAP based webservice. Due to lots of efforts and budget we are not converting SOAP webservice to REstful service. As per instruction provided in appeon site, I am modifying service request replacing SOAPCONNECTION with HTTPCLIENT.
But I am confusing how to accommodate below line of codes in HTTPCLIENT based call.
PB12.5 SOAP
==============
tns3__osarequestheader GenericWBHdr
intf__retrievegenericparamdetailsout GenericDetailsOut[]
intf__genericparmvalue GenericDetailsValue[]
GenericWBHdr = of_get_web_header(li_reqno)
intf__retrievegenericparamdetailsin GenericParmIn
GenericParmIn.osarequestheader = GenericWBHdr
GenericParmIn.osarequestheader.task = "GenericDetails"
GenericDetailsOut = webservice.retrievegenericparamdetails( GenericParmIn)
of_get_web_header()
tns3__osarequestheader osareqhdr
osareqhdr.isreplyexpected = True
osareqhdr.timestamp = Datetime(Today(), Now())
osareqhdr.applicationid = "TEMP"
osareqhdr.channel = ""
osareqhdr.component = ""
osareqhdr.revision = ""
osareqhdr.role = "MGR"
osareqhdr.traceid = of_get_traceid( )
osareqhdr.userid = user
osareqhdr.providerservice.name = "TEMP222"
osareqhdr.providerservice.operation = "test"
osareqhdr.requestorservice.name = "Tier"
PB2017 R3
============
ls_url = "http://temphost/RewardsAdministrationServiceV002"
How will I pass above mandatory header data(of_get_web_header()) to HTTPCLIENT?
ls_body = ''+&
'http://www.w3.org/2001/XMLSchema-instance" '+&
'xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="'+&
' '+&
' '+&
' '+&
' '+&
' '+&
''
lnv_HttpClient = Create httpClient
lnv_HttpClient.SetRequestHeader("Content-Type", "text/xml")
lnv_HttpClient.sendrequest('POST',ls_url,ls_body)
How will I replace below line of codes into HTTPCLIENT?
PB12.5 SOAPBASED WEbSErvice.
intf__retrievegenericparamdetailsout GenericDetailsOut[]
GenericDetailsOut = webservice.retrievegenericparamdetails( GenericParmIn)
Please help me to migrate those lines of codes using HTTPCLIENT compatible to TLS1.2.
Thanks,
Ashok
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.