WCF - WAS Hosting

To understand the concept of WAS hosting, we need to comprehend how a system is configured and how a service contract is created, enabling different binding to the hosted service.

为了明白WAS托管的概念,我们需要理解一个系统是如何配置的,以及一个服务契约如何被创建的。确保托管服务可以接受不同的绑定

First of all, enable WCF for non-protocols. Before we start creating the service, we need to configure the system to support WAS. Following are the steps to configure WAS:

首先,确保wcf是无协议的。在我们开始创建服务之前,我们需要配置系统来支持WAS。配置WAS的步骤如下

  • Click Start Menu ≫ Control Panel ≫ Programs and Features, and click "Turn Windows Components On or Off" in the left pane.

  • Expand "Microsoft .Net Framework 3.0" and enable "Windows Communication Foundation HTTP Activation" and "Windows Communication Foundation Non- HTTP Activation".

  • Next, we need to add Binding to the default website. As an example, we will bind the default website to the TCP protocol. Go to Start Menu ≫ Programs ≫ Accessories. Right click on the "Command Prompt", and select "Run as administrator" from the context menu.

  • Execute the following command:

1.开始菜单-->控制面板-->程序和功能,打开或关闭windows功能。

2.展开.net3.0,启用WCF HTTP Activation和WCF Non- HTTP Activation

3.需要给默认的网站添加绑定,例如,我们可以给默认的网站绑定TCP协议。以管理员权限启动命令提示符

4.执行以下命令

appcmd.exe set site "Default Web Site" -+bindings.[protocol='net.tcp',bindingInformation='808:*']     //吐槽下,这个命令执行出错了,我都不知道该怎么解决

This command adds the net.tcp site binding to the default website by modifying the applicationHost.config file located in the "C:\Windows\system32\inetsrv\config" directory. Similarly, we can add different protocols to the default website.

Create WAS Hosted Service

Step-1: Open Visual Studio 2008 and click New → WebSite and select WCF Service from the template and Location as HTTP, as shown below:

无力吐槽,后面的是IIS的差不多,关键是配置文件看不懂

WCF - WAS Hosting的更多相关文章

  1. WCF - Self Hosting

    WCF - Self Hosting Here, the WCF service is hosted in a console application. Given below is the proc ...

  2. WCF - IIS Hosting

    WCF - IIS Hosting Hosting a WCF service in IIS (Internet Information Services) is a step-by-step pro ...

  3. Learning WCF Chapter1 Hosting a Service in IIS

    How messages reach a service endpoint is a matter of protocols and hosting. IIS can host services ov ...

  4. (WCF) WCF Service Hosting.

    3 Options. 1. Host inside of an application. 2. Host into Windows service. 3. Host into IIS 参考: http ...

  5. WCF - Hosting WCF Service

    After creating a WCF service, the next step is to host it so that the client applications can consum ...

  6. WCF - Hosting WCF Service 四种托管方式

    https://www.tutorialspoint.com/wcf/wcf_hosting_service.htm After creating a WCF service, the next st ...

  7. WCF学习系列汇总

    最近在学习WCF,打算把一整个系列的文章都”写“出来,包括理论和实践,这里的“写”是翻译,是国外的大牛写好的,我只是搬运工外加翻译.翻译的不好,大家请指正,谢谢了.如果觉得不错的话,也可以给我点赞,这 ...

  8. WCF学习系列二---【WCF Interview Questions – Part 2 翻译系列】

    http://www.topwcftutorials.net/2012/09/wcf-faqs-part2.html WCF Interview Questions – Part 2 This WCF ...

  9. WCF 入门(29)

    前言 最近工作比较忙,加了会班就不想再写东西了,就想洗洗睡. 但是这个视频真的不能断,不能像过去一样写了几集就停了. 现在公司在做一个MVC框架的项目,话说已经一年没有写MVC了,重新上手的感觉还可以 ...

随机推荐

  1. wamp优化

    友情链接:IT狂人博客 转载请注明作者:浮沉雄鹰 和本文链接:http://www.cnblogs.com/xby1993/p/3342085.html 一.修改php.ini, 修改上传文件大小限制 ...

  2. MBR与分区表备份与恢复

    常用工具列表 dd                   数据复制,转换实用工具 tar                  GNU磁盘存档实用工具 cpio                数据存档实用工 ...

  3. cocos2d-x实战 C++卷 学习笔记--第6章 场景与层

    前言: 一个场景(Scene)是由多个层(Layer)组成,而且层的个数要至少是1,不能为0. 场景切换 场景切换相关函数 1)void  runWithScene(Scene*  scene) 该函 ...

  4. ACM学习

    转:ACM大量习题题库   ACM大量习题题库 现在网上有许多题库,大多是可以在线评测,所以叫做Online Judge.除了USACO是为IOI准备外,其余几乎全部是大学的ACM竞赛题库.   US ...

  5. HTML5 canvas绘制雪花飘落动画(需求分析、知识点、程序编写分布详解)

    看到网上很多展示html5雪花飞动的效果,确实非常引人入胜,我相信大家也跟我一样看着心动的同时,也很好奇,想研究下代码如何实现:虽然哦很多地方也能下载这些源码,不过也不知道别人制作此类动画时的思路及难 ...

  6. MySQL基础学习之视图

    创建新的视图 CREATE VIEW 视图名  AS SELECT  属性,属性1,属性2  FROM 表名 创建新的视图并指定数据名 CREATE VIEW 视图名(新属性,新属性1,新属性2)   ...

  7. CentOS 最小化安装后安装桌面

    通过yum的方式安装: yum groupinstall -y   "Desktop"   "Desktop Platform"   "Desktop ...

  8. PHP联合sqlserver2008使用的全过程 ( 原创 亲测)

    一.环境 php5.2.5 sqlserver2008 win7 二.配置PHP 1.打开php.in将extension=php_mssql.dll的注释符号去掉. 2.打开php.in将mssql ...

  9. 一个月时间整理《深入浅出Node.js》

    今天终于把朴灵老师写的<深入浅出Node.js>给学习完了, 这本书不是一本简单的Node入门书籍,它没有停留在Node介绍或者框架.库的使用层面上,而是从不同的视角来揭示Node自己内在 ...

  10. 视图--bai

    /*视图的必要性 create view population_all_view as select xxxx 详细信息 from qgck where rownum<500 -- sql语句不 ...