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

Support MessageVersion Soap12WSAddressingAugust2004 (in System.ServiceModel.Channels) #2096

Closed
davidreher opened this issue Jul 24, 2017 · 5 comments
Labels
feature request Adding new functionality requiring adding an API to the public contract.
Milestone

Comments

@davidreher
Copy link
Contributor

davidreher commented Jul 24, 2017

We are relying on a software which still provides old asmx services which require me to use Soap12WSAddressingAugust2014, which is available in .NET, but not in .NET Core.

Please provide this if possible. I am also happy to contribute, but I don't know which parts to change exactly ...

Currently only Soap12WSAddressing10, Soap12WSAddressing10, Soap11 and Soap12 are supported.

@mconnew
Copy link
Member

mconnew commented Jul 24, 2017

@zhenlan, I did I quick analysis of what this would take and there doesn't look to be any functionality that Soap12WSAddressingAugust2014 would need in WCF that the other existing MessageVersion's don't use. This version simply uses a slightly different addressing convention. This task should simply be a case of adding the message version and corresponding addressing version and fixing up a dozen places where we handle reading or writing the address to a SOAP message.
@davidreher, unfortunately you just missed our feature freeze for the 2.0 release so this will need to go into the next release which will be in a few months. Once this is done, you could take a pre-release build if you need it sooner rather than later.
As for contributing, there are 3 pieces to make this change:

  1. Add it to the contract. This involves adding the relevant items to the reference definitions here. MessageVersion.Soap12WSAddressingAugust2014 and AddressingVersion.WSAddressingAugust2004 would both need to be added. It would be a good idea to add MessageVersion.Soap11WSAddressingAugust2014 at the same time. The only difference in implementation is in MessageVersion itself and one place where it's referenced elsewhere.
  2. Add the message version and addressing version implementations. The full framework implementations can be found here and here. The layout of the code has changed a little bit but you should still be able to follow how the code needs to be changed for .Net Core.
  3. Wire up the usage of WSAddressingAugust2004 throughout the code base.
  4. Write tests.

Items 1 & 2 need to be done at the same time otherwise the build breaks. If you are wanting to help out, those should be doable without being super familiar with the code base. Item 3 is a bit trickier as the references are in many places, some of which aren't applicable on .Net Core and could end up trying to pull in more code than is needed without context. Having said that, if you want to give item 3 a go you're welcome to and I can help through the code review. If you want to do items 1 & 2 and leave the rest to us, that would be fine too.

@mconnew mconnew added api addition feature request Adding new functionality requiring adding an API to the public contract. labels Jul 24, 2017
@mconnew mconnew added this to the 2.1.0 milestone Jul 24, 2017
@davidreher
Copy link
Contributor Author

@mconnew, thx for the analysis. I am done with 1 & 2 already and will create a pull request shortly. I may also have some time for 3 or 4 later today, will let you know ;)

@mconnew
Copy link
Member

mconnew commented Aug 7, 2017

@davidreher, are you able to use a non-release build of this as it will be a while until our next release date where this will be available to .Net Core.

@davidreher
Copy link
Contributor Author

sure, this will work for me, thx 👍

@davidreher
Copy link
Contributor Author

davidreher commented Aug 29, 2017

@mconnew, I just tried to use a preview build, but I do get an exception when trying to call the service ... I added https://dotnet.myget.org/F/dotnet-core/api/v3/index.json to my nuget feeds and updated my csproj:

<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <TargetFramework>netcoreapp2.0</TargetFramework>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="Microsoft.Extensions.Configuration" Version="2.0.0" />
    <PackageReference Include="Microsoft.Extensions.Configuration.FileExtensions" Version="2.0.0" />
    <PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="2.0.0" />
    <PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="2.0.0" />
    <PackageReference Include="System.ServiceModel.Duplex" Version="4.5.0-preview2-25629-01" />
    <PackageReference Include="System.ServiceModel.Http" Version="4.5.0-preview2-25629-01" />
    <PackageReference Include="System.ServiceModel.NetTcp" Version="4.5.0-preview2-25629-01" />
    <PackageReference Include="System.ServiceModel.Security" Version="4.5.0-preview2-25629-01" />
    <PackageReference Include="System.Xml.XmlSerializer" Version="4.3.0" />
  </ItemGroup>

  <ItemGroup>
    <WCFMetadata Include="Connected Services" />
  </ItemGroup>

</Project>

I am getting:

Could not load file or assembly 'System.Private.ServiceModel, Version=4.1.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'. The system cannot find the file specified.

Any ideas?

Edit: I tried adding <PackageReference Include="System.Private.ServiceModel" Version="4.1.3" /> manually but this only resulted version conflicts while compiling ...

Edit 2: Forget about it ... I had some other libraries which were still depending on 4.1.3 ...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request Adding new functionality requiring adding an API to the public contract.
Projects
None yet
Development

No branches or pull requests

2 participants