网络基本概念——会话(session)

这是摘自维基百科的篇章,对于计算机学科中“会话”的解释如下:

In computer science, in particular networking, a session is a temporary and interactive information interchange between two or more communicating devices, or between a computer and user (see login session). A session is established at a certain point in time, and then torn down - brought to an end - at some later point. An established communication session may involve more than one message in each direction. A session is typically stateful, meaning that at least one of the communicating parties needs to hold current state information and save information about the session history in order to be able to communicate, as opposed to stateless communication, where the communication consists of independent requests with responses.
翻译为:在计算机科学中,特别是在网络中,会话是两个或多个通信设备之间,或计算机与用户之间临时的、交互式的信息交换(请参阅登录会话)。会话在某个时间点建立,然后在稍后的某个时间点被结束。已建立的通信会话可能涉及每个方向的多个消息。会话通常是有状态的,这意味着至少有一个通信方需要保存当前状态信息并保存关于会话历史的信息,以便能够进行通信,而不是无状态通信,在无状态通信中,通信由具有响应的独立请求组成。

因此“会话”可以理解为一个信息交互的过程,如客户端与服务器建立链接后数据传输的过程。这个过程从建立连接开始,到断开连接结束,期间可能涉及某一方多次信息的传递。

你可能感兴趣的:(网络编程,计算机网络,网络编程,computer,science)