Written by

IT Senior Consultant & Systems Arquitect at Services, Internet & Consulting
Question Hansel Rudy Stange Gaete · Dec 20, 2017

Business Operation SOAP WebClient

Hi,

I create a WebService in Machine One, with some process, i tested this webservice with SOAPUI, worked.

After that i create a simple Business Operation, SOAP Adapter, based on WebClient created with SOAP Wizzard, the problem with that is on response var, i have empty var on my operation, somebody have some Ideas ? 

Comments

Hansel Rudy Stange Gaete  Dec 20, 2017 to Eduard Lebedyuk
Set tSC = $System.Status.OK()
Try{
	Set tRequest = ##class(PortalPaciente.s0.ConsultaPaciente1).%New()
	Set tResponse = ##class(PortalPaciente.s0.InformacionPaciente).%New()
	Set pResponse = ##class(PortalPaciente.Msg.OInformacionPaciente).%New()
	Set tRequest.RUT = pRequest.RUT
	Set tSC = ..Adapter.InvokeMethod("ConsultaPaciente",.tResponse,tRequest)
	if '$IsObject(tResponse)
	{
		Set tSC = $System.Status.Error(5001,"The method ConsultaPaciente did not return anything!")
		Quit
	}
	Set pResponse.EstadoConsulta = tResponse.EstadoConsulta
}
catch(tException)
{
	Set tSC = tException.AsStatus()
}
Quit tSC
0
Hansel Rudy Stange Gaete  Dec 20, 2017 to Hansel Rudy Stange Gaete

in tResponse i can only get "1"

the object i spect is formed by 3 properties :

One %String

One Object

One list Of Objects

0
Hansel Rudy Stange Gaete  Dec 20, 2017 to Hansel Rudy Stange Gaete

I'm working on it, add file debug in operation and webClient, in webClient i can get the full and correct object, but don't  pass to operation.

0
Eduard Lebedyuk  Dec 20, 2017 to Hansel Rudy Stange Gaete

1. There's no need to instantiate tResponse, it would be reinstantiated later anyway.

2. Please post ConsultaPaciente method from your class specified in WebServiceClientClass setting.

0
Hansel Rudy Stange Gaete  Dec 21, 2017 to Eduard Lebedyuk

I get the trace, mi web service is generated only with (%RegisteredObject, %XML.Adaptor) Objects, this generate some problem for wizard on ensemble machine, changing to %Persistent have the solution

0
Thembelani Mlalazi  Sep 25, 2019 to Hansel Rudy Stange Gaete

@Hansel Rudy Stange Gaete 
Was wondering did you get this problem solved I also have an object with a stream property that I am trying to return in a soap response and is blank but in the trace on the production is populated  any help appreciated 

0
Hansel Rudy Stange Gaete  Sep 25, 2019 to Thembelani Mlalazi

@Thembelani Mlalazi 

Hi, thanks,
1 how bigger is this stream ? xml message have normal limitation to 32k or 64k related to system config
2 can you separate this files and serve on links ?
3 can you encrypt like base64 html images?

i'm not sure have the answer, but i think this questions can help you to get the right path to solution

0
Hansel Rudy Stange Gaete  Jun 30, 2020 to Thembelani Mlalazi

Finally, wizard created methods and objects not create as persistent by default, i change that and everything works.

0
Tahnin Tisha · Dec 26, 2017

I think there is some issue in WebServiceClientClass .

Please post ConsultaPaciente method from your class specified in WebServiceClientClass setting!

Hope it will help you to fix the issue.

0