Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OperationFormatUse.Encoded not adding "encodingStyle" attribute to generated SOAP message #3870

Closed
2 tasks done
maheshnlrb opened this issue Sep 3, 2019 · 4 comments
Closed
2 tasks done
Assignees
Labels
NET Core 3.1 Release Issues for the NET Core 3.1 release.
Milestone

Comments

@maheshnlrb
Copy link
Contributor

maheshnlrb commented Sep 3, 2019

I have a soap service that needs RPC encoded messages as input.
The generated reference.cs class correctly added the following attribute to definition
[XmlSerializerFormatAttribute(Style=OperationFormatStyle.Rpc, SupportFaults=true, Use=OperationFormatUse.Encoded)]

BUT generated SOAP message does not contain the required s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" attribute.

This is the generated message body.
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <q1:eServContactQueryById xmlns:q1="http://siebel.com/asi/"> <PrimaryRowId xsi:type="xsd:string">1-14UFS15</PrimaryRowId> </q1:eServContactQueryById> </s:Body>

For testing, I changed the XmlSerializerFormatAttribute to [XmlSerializerFormatAttribute(SupportFaults=true )] and this is what I got in body

<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <eServContactQueryById xmlns="http://siebel.com/asi/"> <PrimaryRowId>1-14UFS15</PrimaryRowId> </eServContactQueryById> </s:Body>

Searching in source code, I did find a method GetEncoding in class XmlSerializerOperationFormatter that should give the correct value for the attribute, but this method is not being called from anywhere.

NOTE: This seems to be related to bug #2359

M

@StephenBonikowsky
Copy link
Member

@maheshnlrb thanks for reporting this.
Looks like we are missing some lines of code, it should be a fairly simple fix.
Adding to our next release milestone.

@StephenBonikowsky
Copy link
Member

PR exists...
#3891

Just need to fix the commit history.

@StephenBonikowsky StephenBonikowsky self-assigned this Oct 28, 2019
@StephenBonikowsky
Copy link
Member

Closed PR #3891 and opened #4001 instead.

@StephenBonikowsky
Copy link
Member

Completed.

@StephenBonikowsky StephenBonikowsky added the NET Core 3.1 Release Issues for the NET Core 3.1 release. label Jan 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NET Core 3.1 Release Issues for the NET Core 3.1 release.
Projects
None yet
Development

No branches or pull requests

2 participants