WCF 发布,本机正常,服务器报错,信息如下:

ServiceMetadataBehavior 的 HttpsGetEnabled 属性设置为 True,而 HttpsGetUrl 属性是相对地址,但没有 https 基址。请提供 https 基址或将 HttpsGetUrl 设置为绝对地址。

说明: 执行当前 Web 请求期间,出现未经处理的异常。请检查堆栈跟踪信息,以了解有关该错误以及代码中导致错误的出处的详细信息。 

异常详细信息: System.InvalidOperationException: ServiceMetadataBehavior 的 HttpsGetEnabled 属性设置为 True,而 HttpsGetUrl 属性是相对地址,但没有 https 基址。请提供 https 基址或将 HttpsGetUrl 设置为绝对地址。

源错误: 

执行当前 Web 请求期间生成了未经处理的异常。可以使用下面的异常堆栈跟踪信息确定有关异常原因和发生位置的信息。

堆栈跟踪: 

[InvalidOperationException: ServiceMetadataBehavior 的 HttpsGetEnabled 属性设置为 True,而 HttpsGetUrl 属性是相对地址,但没有 https 基址。请提供 https 基址或将 HttpsGetUrl 设置为绝对地址。]
System.ServiceModel.Description.ServiceMetadataBehavior.EnsureGetDispatcher(ServiceHostBase host, ServiceMetadataExtension mex, Uri url, String scheme) +
System.ServiceModel.Description.ServiceMetadataBehavior.CreateHttpGetEndpoints(ServiceDescription description, ServiceHostBase host, ServiceMetadataExtension mex) +
System.ServiceModel.Description.ServiceMetadataBehavior.ApplyBehavior(ServiceDescription description, ServiceHostBase host) +
System.ServiceModel.Description.ServiceMetadataBehavior.System.ServiceModel.Description.IServiceBehavior.ApplyDispatchBehavior(ServiceDescription description, ServiceHostBase serviceHostBase) +
System.ServiceModel.Description.DispatcherBuilder.InitializeServiceHost(ServiceDescription description, ServiceHostBase serviceHost) +
System.ServiceModel.ServiceHostBase.InitializeRuntime() +
System.ServiceModel.ServiceHostBase.OnBeginOpen() +
System.ServiceModel.ServiceHostBase.OnOpen(TimeSpan timeout) +
System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout) +
System.ServiceModel.HostingManager.ActivateService(String normalizedVirtualPath) +
System.ServiceModel.HostingManager.EnsureServiceAvailable(String normalizedVirtualPath) + [ServiceActivationException: 由于编译过程中出现异常,无法激活服务“/Rights/RightService.svc”。异常消息为: ServiceMetadataBehavior 的 HttpsGetEnabled 属性设置为 True,而 HttpsGetUrl 属性是相对地址,但没有 https 基址。请提供 https 基址或将 HttpsGetUrl 设置为绝对地址。。]
System.Runtime.AsyncResult.End(IAsyncResult result) +
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult result) +
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.ExecuteSynchronous(HttpApplication context, String routeServiceVirtualPath, Boolean flowContext, Boolean ensureWFService) +
System.ServiceModel.Activation.HttpHandler.ProcessRequest(HttpContext context) +
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() + System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) + 解决办法: <serviceBehaviors>
<behavior>
<!-- 为避免泄漏元数据信息,请在部署前将以下值设置为 false -->
<serviceMetadata httpGetEnabled="true" httpsGetEnabled="true"/>
<!-- 要接收故障异常详细信息以进行调试,请将以下值设置为 true。在部署前设置为 false 以避免泄漏异常信息 -->
<serviceDebug includeExceptionDetailInFaults="true"/>
</behavior> </serviceBehaviors> httpsGetEnabled="true"/ 改为:httpsGetEnabled="false"/ 即可。

ServiceMetadataBehavior 的 HttpsGetEnabled 属性设置为 True,而 HttpsGetUrl 属性是相对地址,但没有 https 基址的更多相关文章

  1. 将Form的AlphaBlend属性设置为True,之后调整Form的AlphaBlendValue属性,255为不透明,数字越小透明度越大~~~想显示文字用l

    将Form的AlphaBlend属性设置为True,之后调整Form的AlphaBlendValue属性,255为不透明,数字越小透明度越大~~~想显示文字用lable就行哈~~~直接在窗体上写字就行 ...

  2. 请将项目文件中的“AutoGenerateBindingRedirects”属性设置为 true 警告!!!

  3. [ html canvas globalCompositeOperation ] canvas绘图属性 设置合成图像如何显示 属性演示

    <!DOCTYPE html> <html lang='zh-cn'> <head> <title>Insert you title</title ...

  4. DEV控件:gridControl常用属性设置(转载)

    特别长,先撸下来再说 1.隐藏最上面的GroupPanel  gridView1.OptionsView.ShowGroupPanel=false; 2.得到当前选定记录某字段的值  sValue=T ...

  5. DEV控件:gridControl常用属性设置

    1.隐藏最上面的GroupPanel  gridView1.OptionsView.ShowGroupPanel=false; 2.得到当前选定记录某字段的值  sValue=Table.Rows[g ...

  6. DEV控件GridControl常用属性设置

    1. 如何解决单击记录整行选中的问题 View->OptionsBehavior->EditorShowMode 设置为:Click 2. 如何新增一条记录 (1).gridView.Ad ...

  7. DEV控件GridControl常用属性设置(转)

      1. 如何解决单击记录整行选中的问题 View->OptionsBehavior->EditorShowMode 设置为:Click 2. 如何新增一条记录 (1).gridView. ...

  8. delphi Form属性设置 设置可实现窗体无最大化,并且不能拖大拖小

    以下设置可实现窗体无最大化,并且不能拖大拖小BorderIcon 设为---biMax[False] biHelp [False]BorderStyle 设为---bsSingle 参考------- ...

  9. elasticsearch的store属性跟_source字段——如果你的文档长度很长,存储了_source,从_source中获取field的代价很大,你可以显式的将某些field的store属性设置为yes,否则设置为no

    转自:http://kangrui.iteye.com/blog/2262860 众所周知_source字段存储的是索引的原始内容,那store属性的设置是为何呢?es为什么要把store的默认取值设 ...

随机推荐

  1. 升级 asp.net core 1.1 到 2.0 preview

    Upgrading to .NET Core 2.0 Preview 1 更新 依赖的类库 改为 标准库 2 web app  更改 csproj 文件---升级版本 <PropertyGrou ...

  2. linux 文件操作库函数

    fopen :打开文件 fread :读文件 fwrite : 写文件 fgetc : 读字符 fputc : 写字符 fscanf : 格式化读 fprintf : 格式化写 fseek : 文件偏 ...

  3. 转载【小程序】: 微信小程序开发---应用与页面的生命周期

    App App() App() 函数用来注册一个小程序.接受一个 object 参数,其指定小程序的生命周期函数等. object参数说明: 属性 类型 描述 触发时机 onLaunch Functi ...

  4. you need to know those webs !

    J2me开发网 http://www.j2medev.com/bbs/index.asp J2me社区 http://www.j2meforums.com/forum/ csdn http://www ...

  5. Java虚拟机学习 - 垃圾收集器 (4)

    HotSpot JVM收集器 上面有7中收集器,分为两块,上面为新生代收集器,下面是老年代收集器.如果两个收集器之间存在连线,就说明它们可以搭配使用. Serial(串行GC)收集器 Serial收集 ...

  6. iOS NSString去除其他字符(空格回车符)

    很多时候大家都需要对字符串进行处理.现在就对字符串删掉特殊字符的处理进行总结一下. 1.stringByTrimmingCharactersInSet  这个方法只能对字符串前后两个部分的特殊字符进行 ...

  7. 4.Java基础:Java对象的内存管理机制

    1.使用new创建对象,在堆内存分配对象空间.初始化: 2.在方法栈中定义局部变量,吃用对堆内存中对象的引用: 3.方法执行完返回,栈内存自动释放,局部变量销毁: 4.如果堆内存中对象没有变量引用它, ...

  8. 使用Xcode、Android Studio将项目链接到Git

    一.使用Android Studio创建本地git仓库: 1.检查本地git环境:在Android Studio中setting-->Version Control 点击Test按钮,提示suc ...

  9. OAF_OAF Framework常用函数汇总(概念)

    2014-12-31 Created By BaoXinjian

  10. Android广播BroadcastReceiver

    Android 系统里定义了各种各样的广播,如电池的使用状态,电话的接收和短信的接收,开机启动都会产生一个广播.当然用户也可以自定义自己的广播. 既然说到广播,那么必定有一个广播发送者,以及广播接收器 ...