function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
joystickjoystick 

Outbound Messaging Delivery Status - SOAP response was a nack

Hi, I need some help in understanding what's going on with the outbound messaging in our case.

The web service we have built on the other end is able to receive the msg from SFDC and sends a true acknowldgement as well, but SFDC shows it as a failure with a reason "SOAP response was a nack" Anybody would know what could possibly be the reason?

Any help would be really appreciated.

Thank you!

 

 Request message 

 

<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:m0="urn:sobject.enterprise.soap.sforce.com">
<SOAP-ENV:Body>
<m:notifications xmlns:m="http://soap.sforce.com/2005/09/outbound">
<m:OrganizationId>000000000000000000</m:OrganizationId>
<m:ActionId>000000000000000000</m:ActionId>
<m:SessionId>String</m:SessionId>
<m:EnterpriseUrl>String</m:EnterpriseUrl>
<m:PartnerUrl>String</m:PartnerUrl>
<m:Notification>
<m:Id>000000000000000000</m:Id>
<m:sObject>
<m0:fieldsToNull>String</m0:fieldsToNull>
<m0:Id>000000000000000000</m0:Id>
<m0:AccountId>000000000000000000</m0:AccountId>
<m0:Name>String</m0:Name>
</m:sObject>
</m:Notification>
</m:notifications>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

 

 

 

 Responce

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns3:notificationsResponse xmlns:ns3="http://soap.sforce.com/2005/09/outbound">
<ns3:Ack>true</ns3:Ack>
</ns3:notificationsResponse>
</soapenv:Body>
</soapenv:Envelope>

 

 

 

Message Edited by joystick on 11-11-2009 07:36 AM
LosintikfosLosintikfos

Is the remote service you're invoking returning primitive type?

 

for example:

 

public String Service(String param){ //Process param return "Success"; } or public Boolean Service(String param){ //Process param return true; }

 

Reason i am asking this, is because  your SOAP response document seems to have native acknowledgement instead of service acknowledgement.

 

Confirm.

 

joystickjoystick

The remote service looks like

 

 

public boolean notifications(Object params[]){ ..... ..... ..... return true; }

 

 

Message Edited by joystick on 11-12-2009 04:13 AM
LosintikfosLosintikfos
Try change it from boolean to String and return a String and see what happend. For debug reasons.
joystickjoystick

Hello ,

 

If i change my remote service i'll shouldc hange my generated stubs files.

In my generated workflowOutboundMessage.wsdl definition of attrbute with name "notificationsResponse" looks like:

 

<element name="notificationsResponse">
<complexType>
<sequence>
<element name="Ack" type="xsd:boolean"/>
</sequence>
</complexType>
</element>

 

 should i change it ?

 

 

Message Edited by joystick on 11-12-2009 04:43 AM
LosintikfosLosintikfos

It looks to me you've declared a variable called Ack in your service which does acknowledgement. To make your debugging easier in this case, i would suggest you remove the variable and return a raw acknowledgement. This will make your future debug and life cycle control easier.

 

Your current case resemble:

 

 

public class Service{ private boolean Ack; public Boolean Service(Object[] params){ //Process param return Ack; } } Change this to: public class Service{ public String Service(Object[] params){ //Process param return "Something"; } }

 And then re-generate your WSDL and WSDL2Apex again to debug. Doing above will mean if the future you dont need to regenerate again to debug.