Res*_*uta 11 iis powershell msmq
我正在尝试为我的IIS网站添加MSMQ绑定,正确的绑定应如下所示:
所以我在PowerShell中执行以下行:
New-WebBinding -Name "My Site" -Protocol net.msmq -HostHeader "localhost"
Run Code Online (Sandbox Code Playgroud)
并创建以下绑定:

使用前缀*:80:,因此我的MSMQ消息不会被WCF服务接收.也许我做错了?如何使用此PowerShell comandlet创建绑定信息设置为"localhost"的绑定?
可以在此处找到Commandlet codumentaiton .
查看cmdlet的反编译代码,看起来像在绑定中添加IPAddress和Port信息,并且没有解决方法.
代码中的相关部分:
private string ipAddress = "*";
...
builder.Append(this.ipAddress);
...
builder.Append(":" + this.sitePort.ToString(CultureInfo.InvariantCulture) + ":");
Run Code Online (Sandbox Code Playgroud)
但您可以执行cmdlet实际执行的操作(从cmdlet下面的代码):
new-itemproperty -path "IIS:\sites\test" -name bindings -value @{protocol="net.msmq"; bindingInformation="localhost"}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
3992 次 |
| 最近记录: |