Servlet与会话Bean 之间的关系 The Relationship Between Servlet and SessionBean

Servlet与会话Bean 的之间关系

今天终于通过《EJB 3.0专家编程》得知了Servlet 与 SessionBean 之间的关系。

原来Servlet 与 SessionBean 不是一回事。HTTP会话是关联一个会话id的数据的map。当应用请求创建一个会话时,服务器生成一个新的id,返回一个HTTPSession对象,应用可以用它来存储键/值数据对。然后它使用诸如浏览器Cookies的技术把会话id与客户端关联起来,把两者捆绑到一次会话中。对于Web应用,客户端很大程度上不会知道服务器端追踪的对话状态。

———————————————————————————————————————

TheRelationship Between Servlet and SessionBean

Not to be confused with the session bean, the HTTP session is a map of data associated with a session id. When the application requests that a session be created, the server generates a new id and returns an HTTPSession object that the application can use to store key/value pairs of data. It then uses techniques such as browser cookies to link the session id with the client, tying the two together into a conversation. For web applications, the client is largely ignorant of the conversational state that is tracked by the server.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值