商讯信箱
用户名: @
密  码:   注册|忘记密码
登录
个人用户经销商
您的位置:首页 > 技术频道 > 正文

化零为整WCF - 会话状态(Session)

  Web.config
<?xml version="1.0"?> <configuration> <system.serviceModel> <client> <!--address - 服务地址--> <!--binding - 通信方式--> <!--contract - 服务契约--> <!--bindingConfiguration - 指定相关的绑定配置--> <endpoint address="http://localhost:3502/ServiceHost/SessionManagement/Hello.svc" binding="wsHttpBinding" contract="SessionManagemenSvc.IHello" bindingConfiguration="SessionManagementBindingConfiguration" /> </client> <bindings> <wsHttpBinding> <binding name="SessionManagementBindingConfiguration"> <!--指示是否在通道终结点之间建立 WS-RM (WS-ReliableMessaging) 可靠会话。默认值为 false。--> <reliableSession enabled="true"/> <security> <!--此属性控制安全上下文令牌是否通过客户端与服务之间的 WS-SecureConversation 交换建立。将它设置为 true 要求远程方支持 WS-SecureConversation。--> <message establishSecurityContext="true"/> </security> </binding> </wsHttpBinding> </bindings> </system.serviceModel> </configuration>
1 2 3 4 5
【内容导航】
第1页: 概述 第2页: 第2页
第3页: 第3页 第4页: 第4页
第5页: 第5页
©版权所有。未经许可,不得转载。
[责任编辑:nancy]
[an error occurred while processing this directive]