外部(java)应用程序将消息发送到我们的Web服务.此消息包含多个名称空间:
<StUF:Fo01Bericht xmlns:StUF="http://www.egem.nl/StUF/StUF0300">
<LVO:stuurgegevens xmlns:LVO="http://www.vrom.nl/StUF/sector/lvo/0305">
<StUF:versieStUF>0300</StUF:versieStUF>
<StUF:berichtcode>Fo01</StUF:berichtcode>
</LVO:stuurgegevens>
<StUF:body>
<StUF:code>200</StUF:code>
<StUF:plek>LVO</StUF:plek>
<StUF:omschrijving>test</StUF:omschrijving>
</StUF:body>
</StUF:Fo01Bericht>
Run Code Online (Sandbox Code Playgroud)
由于第二行上的LVO前缀(根据WSDL应该是StUF),WCF服务无法反序列化此消息.
我想让我们的Web服务接受这些消息.有没有办法做到这一点 - 最好是使用属性?
在后期构建步骤中,我们创建 nuget 包。由于某些原因,这在我的机器上总是失败,而它在其他开发人员的机器上工作。
执行的命令是:
nuget.exe pack "$(ProjectPath)" -Properties Configuration=$(ConfigurationName) -OutputDir "$(ProjectDir)..\Apps"
Run Code Online (Sandbox Code Playgroud)
我得到的输出是:
Packing files from ''.
Using 'Organisation.AppName.Modules.Kcs.nuspec' for metadata.
The path is not of a legal form.
Run Code Online (Sandbox Code Playgroud)
对于其他开发人员,第一行包含目录。它在我的盒子上的工作方式不同的原因是什么?我可以设置选项来改变这种行为吗?
编辑: 我下载了 nuget 源,发现事情开始出错了。通过一个小的测试程序,我可以模拟它:
using System;
using Microsoft.Build.Evaluation;
namespace CheckTarget
{
class Program
{
static void Main(string[] args)
{
if (args.Length == 0)
{
Console.WriteLine("usage: CheckTarget projectfile.csproj");
Console.WriteLine();
return;
}
string path = args[0];
var project = new Project(path);
Console.WriteLine("TargetDir = {0}", project.GetProperty("TargetDir") != null ? project.GetProperty("TargetDir").EvaluatedValue : string.Empty);
Console.WriteLine("TargetPath = …Run Code Online (Sandbox Code Playgroud)