此集合已经采用方案 http 的地址。此集合中每个方案中最多只能包含一个地址。

错误信息:此集合已经采用方案 http 的地址。此集合中每个方案中最多只能包含一个地址。如果服务承载于 IIS 中,则可以通过将“system.serviceModel/serviceHostingEnvironment/multipleSiteBindingsEnabled”设置为 true,或指定“system.serviceModel/serviceHostingEnvironment/baseAddressPrefixFilters”来解决此问题。
参数名: item
异常类型:System.ArgumentException
程序集:System.ServiceModel
方法:Void InsertItem(Int32, System.Uri)
跟踪栈信息:
在 System.ServiceModel.UriSchemeKeyedCollection.InsertItem(Int32 index, Uri item)
在 System.Collections.Generic.SynchronizedCollection`1.Add(T item)
在 System.ServiceModel.UriSchemeKeyedCollection..ctor(Uri[] addresses)
在 System.ServiceModel.ServiceHost..ctor(Type serviceType, Uri[] baseAddresses)
在 Host.Program.StartUp() 位置 d:\Colleague\BaiYongsheng\Server\Host\Program.cs:行号 85

 

 

这个问题百度下,可以找到很多解决方案

但是目前使用的代码中,同一个类型的基地址,只要有一个就可以了

作者:Chuck Lu    GitHub    
posted @   ChuckLu  阅读(2734)  评论(1编辑  收藏  举报
编辑推荐:
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
· 理解Rust引用及其生命周期标识(上)
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
· 没有源码,如何修改代码逻辑?
阅读排行:
· 全程不用写代码,我用AI程序员写了一个飞机大战
· DeepSeek 开源周回顾「GitHub 热点速览」
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 记一次.NET内存居高不下排查解决与启示
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
历史上的今天:
2014-08-04 关于消息队列
点击右上角即可分享
微信分享提示