在.NET 4中用IIS部署WCF就这么简单 http://www.cnblogs.com/dudu/archive/2011/01/18/1938490.html

win8.1怎么安装iis http://jingyan.baidu.com/article/fcb5aff78c584aedab4a7178.html

Window8.1 IIS8.5 运行WCF http://www.yneit.com/?p=282

部署时的问题:

出现异常:未能加载文件或程序集“System.ServiceModel.DomainServices.Hosting, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35”或它的某一个依赖项。系统找不到指定的文件。只需拷贝开发机以下文件到网站bin目录即可: System.ServiceModel.DomainServices.。。。.dll

http://blog.csdn.net/codefighting/article/details/7361393

无法激活服务,因为它不支持 ASP.NET 兼容性。已为此应用程序启用了 ASP.NET 兼容性。请在 web.config 中关闭 ASP.NET 兼容性模式,或将 AspNetCompatibilityRequirements 特性添加到服务类型且同时将 RequirementsMode 设置为“Allowed”或“Required”。

默认情况下ASP.NET兼容性支持是关闭的,但很多时候需要打开Asp.Net的兼容性来利用Asp.Net的一些特性(使用session,上下文等),具体可参考http://msdn.microsoft.com/zh-cn/library/ms752234.aspx

如果要打开兼容性,需要做两步:一是在服务类加上如下标记:

[AspNetCompatibilityRequirements(RequirementsMode = AspNetCompatibilityRequirementsMode.Required)]     public class AppRuntimeStateSvc : IAppRuntimeStateSvc     {

//服务代码.

}

二是在web.config中的<system.serviceModel>段里加: <serviceHostingEnvironment multipleSiteBindingsEnabled="true"  aspNetCompatibilityEnabled="true" />

注意框架3.5以前都是默认就支持的,4.0以后默认就是没有打开兼容性支持的.

Windows8.1,IIS,WCF的更多相关文章

  1. 64位windows8的 IIS运行32位COM组件报错的解决

    浏览时报错如下: Microsoft VBScript 运行时错误 错误 '800a01ad'ActiveX 部件不能创建对象: 'sqlcomp.FileSystemObject'/config.a ...

  2. windows8 安装IIS 和 添加网站(转)

    Internet Information Services(IIS,互联网信息服务),是由微软公司提供的基于运行Microsoft Windows的互联网基本服务.最初是Windows NT版本的可选 ...

  3. Difference between WCF and Web API and WCF REST and Web Service

    The .Net framework has a number of technologies that allow you to create HTTP services such as Web S ...

  4. WCF 、Web API 、 WCF REST 和 Web Service 的区别

    WCF .Web API . WCF REST 和 Web Service 的区别 The .Net framework has a number of technologies that allow ...

  5. Service Station - An Introduction To RESTful Services With WCF

    Learning about REST An Abstract Example Why Should You Care about REST? WCF and REST WebGetAttribute ...

  6. Webservce、WCF、WebApi的区别

    Web Service It is based on SOAP and return data in XML form. It support only HTTP protocol. It is no ...

  7. 转 Difference between WCF and Web API and WCF REST and Web Service

    http://www.dotnet-tricks.com/Tutorial/webapi/JI2X050413-Difference-between-WCF-and-Web-API-and-WCF-R ...

  8. WCF,WebAPI,WCFREST和WebService的区别

    Web ServiceIt is based on SOAP and return data in XML form.It support only HTTP protocol.It is not o ...

  9. WCF、Web API、WCF REST、Web Service

    WCF.Web API.WCF REST.Web Service 区别 Web Service It is based on SOAP and return data in XML form. It ...

随机推荐

  1. spring boot 启动错误:Could not resolve placeholder

    在启动整个spring boot项目时,出现错误: Could not resolve placeholder 原因:没有指定好配置文件,因为src/main/resources下有多个配置文件,例如 ...

  2. centos7安装zabbix3.5

    安装centos7 自带MariaDB数据库(或者安装mysql) yum -y install mariadb-server mariadb-devel systemctlstartmariadb. ...

  3. cisco 交换机通过console 导入 IOS

    准备说明: 电脑上安装有 SecureCRT 软件 导入 IOS: 第一步:使用 SecureCRT 连接上交换机.进入rommon 模式(Ctrl+Break组合键) 第二部:设置波特率为11520 ...

  4. TOJ3955: NKU ACM足球赛(并查集+map+细节题)

    时间限制(普通/Java):5000MS/15000MS     内存限制:65536KByte 描述 NKU ACM最近要举行足球赛,作为此次赛事的负责人,Lee要对报名人员进行分队.分队要遵循如下 ...

  5. String int 相互转换

    String->int: int i = Integer.parseInt(s) int->String: String s = Integer.toString(i)

  6. 微信小程序开发——设置默认图片、错误加载图片

    小程序不支持h5中的onerrorimg,只开放了binderror属性,当错误发生时,会发布到 AppService,事件对象event.detail = {errMsg: 'something w ...

  7. TZOJ 3295 括号序列(区间DP)

    描述 给定一串字符串,只由 “[”.“]” .“(”.“)”四个字符构成.现在让你尽量少的添加括号,得到一个规则的序列. 例如:“()”.“[]”.“(())”.“([])”.“()[]”.“()[( ...

  8. RPC 框架之 Goole protobuf

    Goole 的 protobuf  即 Protocol Buffers  是一个很好的RPC 框架,支持 c++ python  java 接下来进行官方文档的解读,然后你会对protobuf 会有 ...

  9. day 06 列表去重, 数据类型的补充,编码,深浅copy

    因为重要,所以放前面 列表去重 l1 = [1, 2, 3, 4, 5] l2 = [3, 4, 5, 6, 7] set = list(set(l1 + l2)) # set自动去重,然后变成lis ...

  10. redis集群的ruby环境

    redis-4.0.3.gem 下载 https://rubygems.org/gems/redis/ 按照视频在这个地方出错: [root@lx opt]# gem install redis- E ...