<div id="home" style="margin-top: 414px;">
<div id="header">
	<div id="blogTitle">
        <a id="lnkBlogLogo" href="https://www.cnblogs.com/tuyang1129/"><img id="blogLogo" src="/skins/custom/images/logo.gif" alt="返回主页"></a>		
		
<!--done-->
<h1><a id="Header1_HeaderTitle" class="headermaintitle HeaderMainTitle" href="https://www.cnblogs.com/tuyang1129/">特务依昂</a>
</h1>
<h2>世界是个球，前方总有路。</h2>




		
	</div><!--end: blogTitle 博客的标题和副标题 -->
	<div id="navigator">
		
<ul id="navList">
<li><a id="blog_nav_sitehome" class="menu" href="https://www.cnblogs.com/">
博客园</a>
</li>
<li>
<a id="blog_nav_myhome" class="menu" href="https://www.cnblogs.com/tuyang1129/">
首页</a>
</li>
<li>

<a id="blog_nav_newpost" class="menu" href="https://i.cnblogs.com/EditPosts.aspx?opt=1">
新随笔</a>
</li>
<li>
<a id="blog_nav_contact" class="menu" href="https://msg.cnblogs.com/send/%E7%89%B9%E5%8A%A1%E4%BE%9D%E6%98%82">
联系</a></li>
<li>
<a id="blog_nav_rss" class="menu" href="javascript:void(0)" data-rss="https://www.cnblogs.com/tuyang1129/rss/">订阅</a>
<!--<partial name="./Shared/_XmlLink.cshtml" model="Model" /></li>--></li>
<li>
<a id="blog_nav_admin" class="menu" href="https://i.cnblogs.com/">
管理</a>
</li>
</ul>


		<div class="blogStats">
			<span id="stats_post_count">随笔 - 97&nbsp; </span>
<span id="stats_article_count">文章 - 13&nbsp; </span>
<span id="stats-comment_count">评论 - 25&nbsp; </span>
<span id="stats-total-view-count">阅读 - 
<span title="总阅读数: 111165">
11万</span></span>

		</div><!--end: blogStats -->
	</div><!--end: navigator 博客导航栏 -->
</div><!--end: header 头部 -->
<div id="main">
	<div id="mainContent">
	<div class="forFlow">
		<div id="post_detail">
    <!--done-->
    <div id="topics">
        <div class="post">
            <h1 class="postTitle">
                
<a id="cb_post_title_url" class="postTitle2 vertical-middle post-del-title" href="https://www.cnblogs.com/tuyang1129/p/12458592.html">
    <span>计算机网络——TCP如何做到可靠数据传输</span>
    


</a>

            </h1>
            <div class="clear"></div>
            <div class="postBody">
                <div id="cnblogs_post_body" class="blogpost-body cnblogs-markdown">
<h2 id="一、前言">一、前言</h2>
<p>  这几天写了四篇<code>TCP</code>系列的博客，这一篇是第五篇，也预计是这段时间的最后一篇了，写完这篇我就要开始进行网络层的研究了。若对于我其他<code>TCP</code>方面的博客感兴趣，可以去我个人博客的计算机网络这一分类中查阅。这篇博客就来谈一谈<code>TCP</code>是通过哪些手段，来保证可靠数据传输的。</p>
<br>
<h2 id="二、正文">二、正文</h2>
<h3 id="21-网络传输存在的问题"> 2.1 网络传输存在的问题</h3>
<p>  研究<code>TCP</code>如何保证可靠数据传输之前，我们先来列举一下网络传输存在什么问题，只有发现了问题，才能对症下药，找出应对的方法。<code>TCP</code>是依靠网络层的<code>IP</code>协议来发送数据，而<code>IP</code>协议是一个不可靠的协议，它仅仅只是尽最大努力传输，但是并不保证数据能够完好地到达，甚至不能保证数据能否到达。同时，网络中允许传输的最大单元（MTU）是有限制的，一般为<code>1500</code>个字节。所以，<code>TCP</code>为了发送比这个大的数据，需要将数据拆分成一个个数据段进行发送。正因为这些原因，网络传输将存在以下问题：</p>
<ol>
<li>数据在传输的过程中被损坏，比特的<code>0</code>变成<code>1</code>，或者<code>1</code>变成<code>0</code>；</li>
<li>数据在传输过程中丢失，没有到达目的地；</li>
<li>多个报文段没有按顺序到达接收方，因此接收方无法正确地将数据组合；</li>
</ol>
<p>  <code>TCP</code>的实现基本上就是围绕上面三个问题，以及如何提高传输速率实现的。下面我们就来说一说<code>TCP</code>为了应对上面这些问题，做了哪些事情。</p>
<br>
<h3 id="22-tcp解决数据损坏"> 2.2 TCP解决数据损坏</h3>
<p>  我们先来讨论第一个问题，数据发生损坏。检验数据是否损坏的方式就是数据校验，以下是TCP报文的格式，可以看到其中有一个<code>16</code>位的字段，叫做<strong>校验和</strong>，这就是接收方用来校验数据是否出错的部分。</p>
<p><a data-fancybox="gallery" href="https://img2020.cnblogs.com/blog/1324014/202003/1324014-20200307173500212-139777617.png"><img src="https://img2020.cnblogs.com/blog/1324014/202003/1324014-20200307173500212-139777617.png" alt="" loading="lazy" class="medium-zoom-image"></a></p>
<p>  这个字段的名称叫做<strong>校验和</strong>，因为<code>TCP</code>对数据校验的方式就是校验和算法，这个算法的过程如下：</p>
<ol>
<li>将校验和字段置为<code>0</code>，然后将数据部分以<code>16</code>位为一个单位，进行拆分；</li>
<li>将拆分后的若干个单元进行二进制相加，若相加结果进位到了第<code>17</code>位，则将<code>17</code>位加到第一位（其实就是<strong>补码和运算</strong>，也称为回卷），最终相加的结果取反（<code>0</code>变成<code>1</code>，<code>1</code>变成<code>0</code>），然后放入校验和字段；</li>
<li>报文段被发送到目的地后，目标主机也进行上面两步，然后将运算的结果与首部中的校验和字段相加，再取反，若结果为<code>0</code>，则认为数据没有出错；</li>
</ol>
<p>  这样是如何起到校验的作用呢？其实很简单，假设在数据传输的过程中，数据没有出错，则在发送端和接收端，求出的结果都是一样的。而校验和字段，就是这个结果的反码，也就是说，结果中为<code>1</code>的位，在反码中就为<code>0</code>，而结果中为<code>0</code>的位，在反码中就是<code>1</code>。也就是说，在数据没有出错的情况下，这个结果与校验和字段相加，一定是全<code>1</code>，而此时再取反，就是<code>0</code>了。所以只要最终求得的结果不是<code>0</code>，接收方就认为数据出错。<strong>若数据出错，则接收方会直接将数据丢弃，发送方在一段时间后，没有接收到ACK报文，就会在超时后，重传这个报文</strong>。</p>
<p>  但是，上面这个算法一定可以校验出数据是否出错吗？答案是不能。因为这个校验的根本，其实不过是将数据求和，然后判断这个和有没有改变而已。而我们都知道，<code>1+2 == 2+1</code>，<code>1 + 4 == 2 + 3</code>，仅仅依靠求和，根本无法保证数据的没有发生改变。只要数据的多处都发生了错误，而且相互抵消，这种算法将无法察觉。但是<code>TCP</code>依然采用了这种算法，我个人认为原因是实现简单，而且网络中数据出错的概率不高，而多处出错并相互抵消的概率就更小了，所以这种算法的可靠性还是比较高的。</p>
<br>
<h3 id="23-tcp解决丢包问题"> 2.3 TCP解决丢包问题</h3>
<p>  <code>TCP</code>解决数据丢失的方法就是<strong>超时重传</strong>。<code>TCP</code>将维护一个计时器，并设置一个超时时间，当发送一个<code>TCP</code>报文段后，没有在超时时间之内得到ACK报文，则发送方将认为数据丢失，于是将重传丢失的报文段，直至接收。由于<code>TCP</code>使用的是<strong>流水线传输</strong>，在同一时间内，可能有多个已经发送但没有接收到<code>ACK</code>的报文段，所以按理来讲，<code>TCP</code>将维护多个计时器，为每一个报文段绑定一个，但是这样做将产生较大的开销，而且对于计时器的管理也很复杂。所以在<code>TCP</code>中，实际上只会维护一个计时器，记录的是当前最早被发送，但是还没有接收到<code>ACK</code>报文的报文段。当这个报文段超时，发送方将重传报文段，并重启计时器；若收到这个报文段的<code>ACK</code>报文，同样重启计时器，不过此时最早被发出但还没有被确认的报文段已经发生了改变，此时记录的就是这个新的报文段的传输时间。除此之外，触发<strong>快速重传</strong>时，计时器也会重新启动。关于<code>TCP</code>的流水线传输，可以参考我的这一篇博客：<a href="https://www.cnblogs.com/tuyang1129/p/12450978.html" target="_blank">https://www.cnblogs.com/tuyang1129/p/12450978.html</a>。</p>
<p>  这里就有一个复杂的问题了，这个超时时间将要如何设定？不难想到，这个超时时间应该要略大于数据的往返时间（RTT），比如数据从发送到接收到<code>ACK</code>报文，共用了<code>200ms</code>，那超时时间应该略大于这个值，比如<code>400ms</code>。但是网络是不稳定的，对于每一个报文，因为所通过的路径不同，网络拥塞程度的不同，往返时间或多或少都会发生改变。所以对于这个超时时间，应该基于平均RTT进行计算。但是直接统计求平均值就太粗糙了，对于<code>TCP</code>来说，有一套复杂的算法来计算这个超时时间。</p>
<p>  要计算<code>RTT</code>的大致平均值，首先得有样本值，假设<strong>样本RTT</strong>定义为<code>SampleRTT</code>。<code>TCP</code>程序在运行期间，可能会在任意时刻测量一次<code>SampleRTT</code>，即测量一个报文从发出到接收<code>ACK</code>所用的时间，然后将它用于计算<code>RTT</code>的加权平均值。然后过一段时间再进行一次，并将新测出的<code>SampleRTT</code>用于更新加权平均值。假设这个加权平均值<code>RTT</code>定义为<code>EstimatedRTT</code>，在<code>TCP</code>规范中，计算<code>EstimatedRTT</code>的公式为：</p>
<p><strong><code>EstimatedRTT = （1- α）*EstimatedRTT + α * SampleRTT</code></strong>（公式一）</p>
<p>  其中<code>SampleRTT</code>就是最新测得的样本<code>RTT</code>，通过以上公式就能动态地确定<code>RTT</code>的加权平均值。由于越晚测量的<code>SampleRTT</code>，越接近网络中当前的状况，所以在更新<code>EstimatedRTT </code>的过程中，最新的<code>SampleRTT</code>应该要占据更多的比重，所以在<code>TCP</code>规范中，建议将<code>α</code>的值设定为<code>1/8</code>，所以上面的公式就是：</p>
<p><strong><code>EstimatedRTT = 0.875 * EstimatedRTT + 0.125 * SampleRTT</code></strong></p>
<p>  而<code>SampleRTT</code>与<code>EstimatedRTT</code>的波动图如下所示：</p>
<p><a data-fancybox="gallery" href="https://img2020.cnblogs.com/blog/1324014/202003/1324014-20200310210046405-1582185603.png"><img src="https://img2020.cnblogs.com/blog/1324014/202003/1324014-20200310210046405-1582185603.png" alt="" loading="lazy" class="medium-zoom-image"></a></p>
<p>  除了求<code>RTT</code>的加权平均值，网络中<code>RTT</code>的变化情况也是很有必要的，毕竟从上图可以看出，样本<code>RTT</code>的波动十分剧烈，只有<code>EstimatedRTT</code>，还不足以让我们准确的估算超时时间。所以我们需要求出<code>SampleRTT</code>与<code>EstimatedRTT</code>的偏离程度，也就是类似于<strong>方差</strong>，根据方差，来动态地设置超时时间。假设这个方差定义为<code>DevRTT</code>，则<code>TCP</code>规范中定义<code>DevRTT</code>的计算公式如下：</p>
<p><strong><code>DevRTT = （1 - β）* DevRTT + β * | SampleRTT - EstimatedRTT |</code></strong>（公式二）</p>
<p>  由上面公式可以看出，如果<code>SampleRTT</code> 的波动很大，<code>DevRTT </code>的值就会很大，反之就会很小。而在<code>TCP</code>规范中<code>β</code>的推荐值是<code>0.25</code>。我们现在知道了<code>RTT</code>的加权平均值，也知道了<code>RTT</code>的波动情况，现在就该考虑怎么设置超时时间了。不难想到，超时时间应该需要比<code>RTT</code>的加权平均值，也就是<code>EstimatedRTT </code>要大一些，让大部分报文段的<code>RTT</code>都小于这个值，以免频繁超时重传。那应该大多少呢？这样考虑，当网络波动较为剧烈时，表示实际<code>RTT</code>应该会离<code>EstimatedRTT</code>远一些，而波动较小时，实际<code>RTT</code>应该会接近于<code>EstimatedRTT</code>，而这个波动情况的数值，我们已经计算过了，就是上一个公式中的<code>DevRTT </code>，所以假设超时时间定义为<code>TimeoutInterval</code>，<code>TCP</code>规范推荐使用以下方式来计算它的值：</p>
<p><strong><code>TimeoutInterval = EstimatedRTT  + 4 * DevRTT </code></strong>（公式三）</p>
<p>  这样，不论是加权平均值还是网络的波动情况就都考虑到了。而<code>TCP</code>规范中推荐的初始<code>TimeoutInterval </code>为<code>1s</code>（当时从书上看到这部分内容，才深刻体会到了数学的强大，真真的将理论应用于实际）。当然，对于超时时间的计算，还有两个特例：</p>
<ul>
<li>当某个报文段超时，发送方将重传这个报文段，同时重新开启定时器，而超时时间将会设置为上一次的<strong>两倍</strong>，而不是使用公式三计算的值；若还是超时，则继续重传，超时时间再次扩大两倍，直到这个报文被成功接收，而成功接收时，才使用公式三重新计算超时时间。这么做的目的是为了防止多次超时导致连续重传，从而导致网络拥塞更加严重，毕竟超时就是网络拥塞的结果。</li>
<li>记录样本<code>RTT</code>时，不会选择重传的报文段作为样本，这是因为，当发生超时事件时，发送方并不知道数据是因为丢失还是因为网络延迟而超时。若报文段是因为延迟而超时，则重传报文后，这时延迟的<code>ACK</code>报文到达，发送方将误以为重传的分组被正确接收，于是将测出一个错误的<code>SampleRTT</code> 。</li>
</ul>
<p>  总之，<code>TCP</code>的超时重传机制，很好地解决了网络中发生数据丢包的问题。而且，为了提高效率，<code>TCP</code>还有一种<strong>快速重传</strong>机制，可以根据特定情况，在超时前就判断报文段丢失，然后进行重传，不过这里就不详细叙述了。</p>
<br>
<h3 id="24-tcp如何解决数据乱序到达"> 2.4 TCP如何解决数据乱序到达</h3>
<p>  第三个问题就是数据的乱序到达问题。由于网络的限制，<code>TCP</code>必须将较大的数据拆分成一个个较小的报文段，封装成<code>TCP</code>报文段，逐个传输。由于网络传输的不确定性（比如所通过的路径不同，某个报文段丢失然后重传等），这些报文段完全有可能不是按照顺序到达。所以，为了在接收方能够完整的接收数据，并能按序将这些报文组合起来，<code>TCP</code>必须有一种机制解决这个问题。</p>
<p>  <code>TCP</code>所使用的方法就是为每一个<code>TCP</code>报文段分配一个序号，每个报文段的序号依次增加，这样接收方就可以根据序号，来确定接收到的报文段是整个数据中的哪一部分，以及是否接收到了所有的部分。从上面那张<code>TCP</code>报文结构图中我们可以看到，其中有一个<code>32位</code>的序号字段。但是，<code>TCP</code>对报文段的编号可不是<code>0，1，2，3</code>....这么简单，下面我们就来说说<code>TCP</code>是如何实现这种序号机制的。</p>
<p>  首先我们要明确一个点，<strong>TCP是对字节进行编号，而不是对报文段进行编号</strong>。<code>TCP</code>对需要发送的数据的每一个字节都赋予了一个编号，比如第一个字节为<code>0</code>号，第二个为<code>1</code>号，以此类推。而每一个报文段一般都不止封装一个字节的数据，所以在<code>TCP</code>报文段中，封装的是这个报文段的数据中，第一个字节的序号。举个例子，比如说发送方要发送<code>250</code>字节的数据，假设初始序号从<code>0</code>开始，则这<code>250</code>个字节的序号分别是<code>0-249</code>。再假设每一个报文段最多允许封装<code>100</code>个字节的数据，所以第一个报文段将封装第<code>1</code>到<code>100</code>个字节，这些字节的序号为<code>0-99</code>，所以第一个报文段会将<code>0</code>放入它首部中的序号部分；而第二个报文段封装<code>100-199</code>号字节，所以它的序号为<code>100</code>；而第三个报文段封装<code>200-249</code>号字节，所以它的序号为<code>200</code>。以上就是<code>TCP</code>发送方对序号的处理方法。</p>
<p>  下面来说一说<code>TCP</code>的接收方如何在这种序号机制中工作。同样以上面三个报文段举例，假设发送方将上面三个报文段发出，接收方接收到第一个报文段，发现这个报文的序号是<code>0</code>，同时包含<code>100</code>个字节的数据，于是接收方将会向发送方确认已经接收到这个报文，而确认的方式就是使用<code>TCP</code>首部中的<strong>确认序号</strong>字段。接收方接收到序号为<code>0</code>，长度为<code>100</code>个字节的报文段后，将会在<code>ACK</code>报文的确认序号中填入<code>100</code>，表示自己已经接收到序号小于<code>100</code>的全部字节，希望下一个接收到的报文段的序号是<code>100</code>；而第二个报文段按序到达，序号为<code>100</code>，长度为<code>100</code>字节，于是接收方再次回送<code>ACK</code>报文，此时确认序号将为<code>200</code>，表示自己接收到<code>200</code>以前的全部字节，希望下一条报文的序号是<code>200</code>；然后接收到序号为<code>200</code>，长度为<code>50</code>字节的报文段，将回送确认序号为<code>250</code>的ACK报文。</p>
<p>  以上是按顺序接收到报文段的情况，假设在上面的情况中，三条报文到达的先后顺序是0 -&gt; 200 -&gt; 100，也就是顺序被打乱，则将发生以下情况：</p>
<ol>
<li>接收方接收到序号<code>0</code>，长度<code>100</code>字节的报文段，回送确认号为<code>100</code>的<code>ACK</code>报文；</li>
<li>接收到序号<code>200</code>，长度为<code>50</code>字节 的报文段，此时接收方希望接收到的是<code>100</code>号报文，于是判断发生了乱序到达的情况，不向上层交付这一段数据，而是将其放入接收缓存；</li>
<li>接收到序号为<code>100</code>，长度为<code>100</code>的报文段，<code>100</code>正是接收方期待接收到的报文段序号，于是将其接收并交付给上层，同时发现在接收缓存中存在序号为<code>200</code>的报文段，这正是接收方期待接收到的下一条报文，于是将其取出，交付上层，同时向发送方发送<code>ACK</code>报文，<code>ACK</code>的确认序号为<code>250</code>，表示自己已经接收到<code>250</code>之前的所有字节，下一条期望到达的报文的序号是<code>250</code>；</li>
</ol>
<p>  通过上面的机制，接收方成功解决了数据乱序到达的问题。当然，对于这种序号机制的使用，其实不止这么简单，这其中还牵涉到TCP的流水线传输机制，若想要了解，可以参考我的另外一篇博客——<a href="https://www.cnblogs.com/tuyang1129/p/12450978.html" target="_blank">https://www.cnblogs.com/tuyang1129/p/12450978.html</a>。</p>
<p>  这里还有一个问题，在上面的例子中，我假设序号是从<code>0</code>开始，但是实际情况并非如此。在实际的实现中，序号一般是一个通过特殊算法计算出的随机值，这样做的原因有两点：</p>
<ol>
<li>假设每一个<code>TCP</code>连接的序号都是从<code>0</code>开始，那么假设客户端先向服务器发送了一个报文，还没有确认接收后，立即断开连接；但是在断开后，它们立刻又建立了一个连接，而此时，第一次发送出去的报文段才刚到达服务器，那会发生什么情况。服务器会以为这是新建立的连接发送的数据，而由于两次连接的初始序号都是<code>0</code>，接收方将会把这个报文段接收。为了减小类似情况发生的概率，<code>TCP</code>采用随机初始序号，这样两次连接的初始序号将大概率不同，再发生这种情况时，接收方也不会接收这个报文段；</li>
<li>第二个原因就是出于安全性考虑，若初始序号都是固定的，那每一个报文段的序号完全可以推测得出，于是就有黑客可以利用这一点，模拟发送方发送TCP报文，做出攻击，比如发送大量连接请求，占用服务器资源；</li>
</ol>
<br>
<h3 id="25-tcp的流量控制与拥塞控制"> 2.5 TCP的流量控制与拥塞控制</h3>
<p>  流量控制与拥塞控制，严格来讲并不是<code>TCP</code>的可靠传输机制，但是也算是有点关系，所以我还是提一下。</p>
<ul>
<li>流量控制：<code>TCP</code>的接收方会维持一个接收缓存，用以接收发送方发送的数据。但是，接收缓存不是无限大的，若接收缓存被占满，此时再接收到数据，将无法进行接收，只能将其丢弃。于是，为了减少这种情况的发生，<code>TCP</code>接收方需要告知发送方，自己最多还能接收多少数据，<code>TCP</code>发送方根据这个信息，有选择的发送数据，这就是流量控制；</li>
<li>拥塞控制：和流量控制类似，但是限制发送数据多少的不是接收方，而是路由器。路由器也有接收缓存，若路由器的接收缓存中存在过多的数据，也会对网络传输造成影响，这就是网络中丢包的原因，而拥塞控制就是根据网络的拥塞状况控制发送数据的速度；</li>
</ul>
<p>  这两种机制中，流量控制相对简单。我们可以看到，在<code>TCP</code>的报文格式中，有一个叫做窗口大小的部分，这部分就是接收方告诉发送方，自己当前最多还能接收多少数据，而发送方将发送小于这个窗口大小的数据长度。但是有一种特殊情况，若这个窗口大小为<code>0</code>，表示当前窗口已满，正常情况下发送方将无法发送数据，但是在实际情况中，发送方还是会发送<strong>一个字节</strong>的数据到接收方，作为一种试探。因为接收方一般不会主动向发送方发送报文，这个窗口大小一般是携带在<code>ACK</code>报文中，若此时窗口大小为<code>0</code>，发送方将不再发送数据，接收方也就无法向发送方发送<code>ACK</code>报文，此时就算缓存被清理，发送方也不会知晓。所以即使这个窗口大小为<code>0</code>，发送方仍然需要发送数据，进行试探，若缓存已经被清理，通过试探报文的<code>ACK</code>报文，发送方就能知晓。</p>
<p>  拥塞控制是<code>TCP</code>中相对复杂的一种机制，不是三言两语说的清楚的，这部分内容我专门写了一篇的博客进行说明，感兴趣的可以阅读一下：<a href="https://www.cnblogs.com/tuyang1129/p/12439862.html" target="_blank">https://www.cnblogs.com/tuyang1129/p/12439862.html</a>。</p>
<br>
<h2 id="三、总结">三、总结</h2>
<p>  对于<code>TCP</code>可靠传输的描述就介绍到这里。上面的内容是对<code>TCP</code>可靠传输原理的基本介绍，但是具体实现可能会在这些基础上进行改进和优化。<code>TCP</code>的各种机制相辅相成，若是对于<code>TCP</code>没有太多了解，可能有些介绍会看不太懂，所以若想真正搞懂<code>TCP</code>以及其他计算机网络的相关知识，建议买一本书系统地研究。希望我的这篇博客对看到的人有所帮助，若博客内容有误，希望可以指正。</p>
<br>
<h2 id="四、参考">四、参考</h2>
<p>  《计算机网络——自顶向下方法（原书第七版）》</p>

<br><p class="essaySuffix-eof">__EOF__</p><div class="essaySuffix-box"><div class="essaySuffix-box-left"><img src="https://pic.cnblogs.com/avatar/1324014/20191130183449.png" alt=""></div><div class="essaySuffix-box-right"><span class="essaySuffix-right-title">本文作者</span>：<strong><span style="font-size: 12px;"><a href="https://www.cnblogs.com/tuyang1129/p/12458592.html" target="_blank">特务依昂</a></span></strong> <br><span style="font-weight: bold; white-space:nowrap;">本文链接</span>：<a href="https://www.cnblogs.com/tuyang1129/p/12458592.html" target="_blank">https://www.cnblogs.com/tuyang1129/p/12458592.html</a><br><span class="essaySuffix-right-title">关于博主</span>：在互联网洋流中垂死挣扎，但依旧乐观的Java小菜鸟一枚！<br><span class="essaySuffix-right-title">版权声明</span>：转载博客请注明出处，并附上原文链接！<br><span class="essaySuffix-right-title">声援博主</span>：如果您觉得文章对您有帮助，可以点击文章右下角<strong><span style="color: #ff0000; font-size: 12pt;">【<a id="post-up" onclick="votePost(12458592,'Digg')" href="javascript:void(0);">推荐</a>】</span></strong>一下。您的鼓励是博主的最大动力！<br></div><div style="clear: both;"></div></div></div>
<div id="MySignature"></div>
<div class="clear"></div>
<div id="blog_post_info_block"><div id="BlogPostCategory">
    分类: 
            <a href="https://www.cnblogs.com/tuyang1129/category/1657502.html" target="_blank"><span class="iconfont icon-marketing_fill"></span>计算机网络</a></div>


    <div id="blog_post_info">
<div id="green_channel">
        <a href="javascript:void(0);" id="green_channel_digg" onclick="DiggIt(12458592,cb_blogId,1);green_channel_success(this,'谢谢推荐！');">好文要顶</a>
        <a id="green_channel_follow" onclick="follow('103b1715-a5bf-43c8-38f4-08d54dba4453');" href="javascript:void(0);">关注我</a>
    <a id="green_channel_favorite" onclick="AddToWz(cb_entryId);return false;" href="javascript:void(0);">收藏该文</a>
    <a id="green_channel_weibo" href="javascript:void(0);" title="分享至新浪微博" onclick="ShareToTsina()"><img src="https://common.cnblogs.com/images/icon_weibo_24.png" alt=""></a>
    <a id="green_channel_wechat" href="javascript:void(0);" title="分享至微信" onclick="shareOnWechat()"><img src="https://common.cnblogs.com/images/wechat.png" alt=""></a>
</div>
<div id="author_profile">
    <div id="author_profile_info" class="author_profile_info">
            <a href="https://home.cnblogs.com/u/tuyang1129/" target="_blank"><img src="https://pic.cnblogs.com/face/1324014/20191130183449.png" class="author_avatar" alt=""></a>
        <div id="author_profile_detail" class="author_profile_info">
            <a href="https://home.cnblogs.com/u/tuyang1129/">特务依昂</a><br>
            <a href="https://home.cnblogs.com/u/tuyang1129/followees/">关注 - 7</a><br>
            <a href="https://home.cnblogs.com/u/tuyang1129/followers/">粉丝 - 53</a>
        </div>
    </div>
    <div class="clear"></div>
    <div id="author_profile_honor"></div>
    <div id="author_profile_follow">
                <a href="javascript:void(0);" onclick="follow('103b1715-a5bf-43c8-38f4-08d54dba4453');return false;">+加关注</a>
    </div>
</div>
<div id="div_digg">
    <div class="diggit" onclick="votePost(12458592,'Digg')">
        <span class="diggnum" id="digg_count">0</span>
    </div>
    <div class="buryit" onclick="votePost(12458592,'Bury')">
        <span class="burynum" id="bury_count">0</span>
    </div>
    <div class="clear"></div>
    <div class="diggword" id="digg_tips">
    </div>
</div>

<script type="text/javascript">
    currentDiggType = 0;
</script></div>
    <div class="clear"></div>
    <div id="post_next_prev">

    <a href="https://www.cnblogs.com/tuyang1129/p/12450978.html" class="p_n_p_prefix">« </a> 上一篇：    <a href="https://www.cnblogs.com/tuyang1129/p/12450978.html" title="发布于 2020-03-09 20:53">计算机网络——TCP的流水线传输（超详细）</a>
    <br>
    <a href="https://www.cnblogs.com/tuyang1129/p/12499181.html" class="p_n_p_prefix">» </a> 下一篇：    <a href="https://www.cnblogs.com/tuyang1129/p/12499181.html" title="发布于 2020-03-15 18:32">浅析JVM的内存分区</a>

</div>
</div>
            </div>
            <div class="postDesc" style="display: block;">posted @ 
<span id="post-date">2020-03-10 21:01</span>&nbsp;
<a href="https://www.cnblogs.com/tuyang1129/">特务依昂</a>&nbsp;
阅读(<span id="post_view_count">734</span>)&nbsp;
评论(<span id="post_comment_count">0</span>)&nbsp;
<a href="https://i.cnblogs.com/EditPosts.aspx?postid=12458592" rel="nofollow">编辑</a>&nbsp;
<a href="javascript:void(0)" onclick="AddToWz(12458592);return false;">收藏</a></div>
        </div>
	    
	    
    </div><!--end: topics 文章、评论容器-->
</div>
<script src="https://common.cnblogs.com/highlight/10.3.1/highlight.min.js"></script>
<script>markdown_highlight();</script>
<script>
    var allowComments = true, cb_blogId = 426004, cb_blogApp = 'tuyang1129', cb_blogUserGuid = '103b1715-a5bf-43c8-38f4-08d54dba4453';
    var cb_entryId = 12458592, cb_entryCreatedDate = '2020-03-10 21:01', cb_postType = 1;
    updatePostStats(
        [cb_entryId],
        function(id, count) { $("#post_view_count").text(count) },
        function(id, count) { $("#post_comment_count").text(count) })
    zoomManager.apply("#cnblogs_post_body img:not(.code_img_closed):not(.code_img_opened)");
</script>
<a name="!comments"></a>
<div id="blog-comments-placeholder"></div>
<div id="comment_form" class="commentform">
    <a name="commentform"></a>
    <div id="divCommentShow"></div>
    <div id="comment_nav"><span id="span_refresh_tips"></span><a href="javascript:void(0);" onclick="return RefreshCommentList();" id="lnk_RefreshComments" runat="server" clientidmode="Static">刷新评论</a><a href="#" onclick="return RefreshPage();">刷新页面</a><a href="#top">返回顶部</a></div>
    <div id="comment_form_container" style="visibility: visible;"><script type="text/javascript" src="https://mention.cnblogs.com/bundles/mention.min.js"></script>
<div id="commentform_title">发表评论</div>
<span id="tip_comment" style="color:Red"></span>
<div class="commentbox_main comment_textarea" style="width: 100%; height: 100%;">
    <div class="commentbox_title">
        <div class="commentbox_title_left">
            <span id="btn_edit_comment" class="commentbox_tab active" title="编辑评论">编辑</span>
            <span id="btn_preview_comment" class="commentbox_tab" title="Markdown 预览">预览</span>
        </div>
        <div class="commentbox_title_right">
            <span id="ubb_bold" class="comment_icon" alt="粗体" title="添加粗体(Ctrl + B)">
                <svg class="comment_svg" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                    <g fill-rule="evenodd">
                        <path d="m13.221 19c1.4414 0 2.5793-0.27451 3.3759-0.82353 0.92931-0.66667 1.4034-1.7059 1.4034-3.1176 0-0.94118-0.22759-1.7059-0.66379-2.2549-0.45517-0.56863-1.119-0.94118-2.0103-1.1176 0.68276-0.27451 1.1948-0.64706 1.5552-1.1569 0.36034-0.54902 0.55-1.2157 0.55-2 0-1.0588-0.36034-1.902-1.0621-2.5294-0.75862-0.66667-1.8207-1-3.1672-1h-6.2017v14h6.2207zm-0.82196-8h-3.3987v-4h3.4367c0.91139 0 1.557 0.15686 1.9747 0.47059 0.37975 0.29412 0.58861 0.78431 0.58861 1.451 0 0.72549-0.20886 1.2549-0.58861 1.5882-0.39873 0.31373-1.0633 0.4902-2.0127 0.4902zm0.52612 6h-3.9249v-4h3.9855c1.052 0 1.8208 0.16216 2.3064 0.48649 0.46532 0.32432 0.70809 0.84685 0.70809 1.5856 0 0.72072-0.3237 1.2252-0.9711 1.5495-0.50578 0.25225-1.2139 0.37838-2.104 0.37838z" fill-rule="nonzero" stroke-width=".35"></path>
                    </g>
                </svg>
            </span>
            <span id="ubb_url" class="comment_icon" title="添加链接(Ctrl + K)" alt="链接">
                <svg class="comment_svg comment_svg_stroke" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                    <g fill-rule="evenodd">
                        <g transform="translate(4 4)" fill-rule="nonzero" stroke-width=".4">
                            <path d="m6.304 9.696c-0.288-0.288-0.512-0.608-0.704-0.992-0.16-0.32-0.032-0.704 0.288-0.864 0.32-0.16 0.704-0.032 0.864 0.288 0.128 0.224 0.256 0.448 0.448 0.64 0.928 0.928 2.432 0.928 3.36 0l3.36-3.328c0.928-0.928 0.928-2.432 0-3.36s-2.432-0.928-3.36 0l-2.272 2.272c-0.256 0.256-0.64 0.256-0.896 0-0.256-0.256-0.256-0.64 0-0.896l2.272-2.272c1.44-1.44 3.744-1.44 5.184 0 1.44 1.44 1.44 3.744 0 5.184l-3.36 3.296c-0.704 0.704-1.632 1.088-2.592 1.088-0.928 0-1.856-0.352-2.592-1.056z"></path>
                            <path d="m3.776 15.808c-0.992 0-1.888-0.384-2.592-1.056-1.44-1.44-1.44-3.744 0-5.184l3.328-3.328c1.44-1.44 3.744-1.44 5.184 0 0.288 0.288 0.544 0.64 0.736 1.024 0.16 0.32 0 0.704-0.32 0.864-0.32 0.16-0.704 0-0.864-0.32-0.128-0.256-0.288-0.48-0.48-0.672-0.928-0.928-2.432-0.928-3.36 0l-3.296 3.328c-0.928 0.928-0.928 2.432 0 3.36 0.448 0.448 1.056 0.704 1.664 0.704 0.608 0 1.248-0.256 1.664-0.704l2.112-2.112c0.256-0.256 0.64-0.256 0.896 0s0.256 0.64 0 0.896l-2.112 2.112c-0.672 0.704-1.568 1.088-2.56 1.088z"></path>
                        </g>
                    </g>
                </svg>
            </span>
            <span id="ubb_code" class="comment_icon" title="添加代码(Ctrl + `)" alt="代码">
                <svg class="comment_svg comment_svg_stroke" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                    <g fill-rule="evenodd">
                        <g transform="translate(16 6)" stroke-linecap="round" stroke-width="2">
                            <line x1=".5" x2="4.5" y1=".7" y2="6.3"></line>
                            <line transform="translate(2.5 9.1) scale(1 -1) translate(-2.5 -9.1)" x1=".5" x2="4.5" y1="6.3" y2="11.9"></line>
                        </g>
                        <g transform="translate(3 6.1)" stroke-linecap="round" stroke-width="2">
                            <line transform="translate(2.5 3.5) scale(-1 1) translate(-2.5 -3.5)" x1=".5" x2="4.5" y1=".7" y2="6.3"></line>
                            <line transform="translate(2.5 9.1) scale(-1) translate(-2.5 -9.1)" x1=".5" x2="4.5" y1="6.3" y2="11.9"></line>
                        </g>
                        <path transform="translate(12 12.5) scale(1 -1) translate(-12 -12.5)" d="m10.778 7.1249c0.50008-0.11366 0.9978 0.16911 1.1643 0.64128l0.032406 0.11223 2 8.8c0.1224 0.53855-0.21496 1.0744-0.75351 1.1968-0.50008 0.11366-0.9978-0.16911-1.1643-0.64128l-0.032406-0.11223-2-8.8c-0.1224-0.53855 0.21496-1.0744 0.75351-1.1968z" fill-rule="nonzero" stroke-width=".25"></path>
                    </g>
                </svg>
            </span>
            <span id="ubb_quote" class="comment_icon" title="添加引用(Ctrl + Q)" alt="引用">
                <svg class="comment_svg" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                    <g fill-rule="evenodd">
                        <g transform="translate(5 4)" fill-rule="nonzero" stroke-width=".25">
                            <path d="m5.0013 15v-5.2702h-2.8008c-0.13413-3.3762 1.2004-6.2143 4.0009-8.5135l-1.2-1.2163c-3.335 2.2996-5.0013 5.8119-5.0013 10.54v4.4595h5.0013-1.285e-5zm8.7987 0v-5.2702h-2.8008c-0.13453-3.3762 1.2-6.2143 4.0009-8.5135l-1.2-1.2163c-3.335 2.2996-5.0013 5.8119-5.0013 10.54v4.4595h5.0013-1.28e-5z"></path>
                        </g>
                    </g>
                </svg>
            </span>
            <span id="ubb_img" class="comment_icon" alt="图片" title="上传图片(Ctrl + I)">
                <svg class="comment_svg" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
                    <g fill-rule="evenodd">
                        <g transform="translate(3 3.8)" fill-rule="nonzero">
                            <path d="m14.1 0.58235h-11.2c-1.32 0-2.4 1.0482-2.4 2.3294v10.871c0 1.2812 1.08 2.3294 2.4 2.3294h11.2c1.32 0 2.4-1.0482 2.4-2.3294v-10.871c0-1.2812-1.08-2.3294-2.4-2.3294zm0.7 13.569-3.63-3.4165 1.33-1.2909c0.21-0.20382 0.59-0.20382 0.8 0l1.6 1.5529v2.7856c0 0.13588-0.04 0.26206-0.1 0.36882zm-11.9-12.016h11.2c0.44 0 0.8 0.34941 0.8 0.77647v5.8915l-0.47-0.45618c-0.84-0.825-2.22-0.825-3.07 0l-1.35 1.3103-2.39-2.2421c-0.85-0.825-2.22-0.825-3.05-0.019412l-2.48 2.2615v-6.7456c0.01-0.42706 0.37-0.77647 0.81-0.77647zm-0.8 11.647v-1.9897l3.6-3.2806c0.21-0.20382 0.58-0.21353 0.81 0.0097059l6.43 6.0371h-10.04c-0.44 0-0.8-0.33971-0.8-0.77647z"></path>
                            <ellipse cx="10.5" cy="6.4059" rx="1" ry="1"></ellipse>
                        </g>
                    </g>
                </svg>
            </span>
        </div>
    </div>
    <div style="display:none">
        <span id="comment_edit_id"></span>
        <span id="span_parentcomment_id"></span>
        <span id="span_parent_id"></span>
        <span id="span_comment_replyto"></span>
        <span id="span_comment_posted"></span>
        <span id="span_current_user_id">38d40057-d889-40f5-f12c-08d7188de755</span>
    </div>
    <textarea id="tbCommentBody" placeholder="支持 Markdown"></textarea>
    <div id="tbCommentBodyPreview" class="feedbackCon" style="display: none">
        <div id="tbCommentBodyPreviewBody" class="blog_comment_body comment_preview cnblogs-markdown"></div>
    </div>
    <div class="commentbox_footer">
        <span>&nbsp;</span>
        <span href="javascript:void(0)" id="ubb_auto_completion" class="comment_option">
            <svg style="display: none" id="comment_auto_completion_on" viewBox="0 0 1080 1080" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2"><path d="M406.724 908.504c-89.02 0-157.885-32.319-206.594-96.957-49.549-64.639-73.903-155.795-73.903-274.299 0-116.017 24.354-206.345 73.903-270.155 48.71-63.81 117.574-95.3 206.594-95.3h19.316l-7.559 72.925h-3.359c-65.505 0-115.054 25.69-150.326 77.069-35.272 50.55-52.908 122.647-52.908 215.461 0 94.472 17.636 168.226 52.908 220.434 35.272 51.379 84.82 77.897 150.326 77.897h3.36l7.558 72.925h-19.316zm266.548 0c89.02 0 157.885-32.319 206.594-96.957 49.55-64.639 73.904-155.795 73.904-274.299 0-116.017-24.355-206.345-73.904-270.155-48.709-63.81-117.573-95.3-206.594-95.3h-19.315l7.558 72.925h3.36c65.505 0 115.054 25.69 150.326 77.069 35.272 50.55 52.908 122.647 52.908 215.461 0 94.472-17.636 168.226-52.908 220.434-35.272 51.379-84.821 77.897-150.327 77.897h-3.359l-7.558 72.925h19.315zm-94.068-65.897c0 31.514.854 54.433 1.708 68.758 1.709 14.325 3.417 25.784 6.835 34.38 2.563 8.594 6.834 14.324 12.814 20.054 5.126 5.73 14.523 11.46 27.337 17.189v34.38H451.914v-34.38c17.086-7.162 29.046-15.757 35.026-24.352 5.126-10.027 9.398-22.92 11.106-38.676 1.709-17.19 2.563-42.974 2.563-77.353V238.109c0-32.947-.854-55.866-1.709-71.623-1.708-14.325-4.271-25.784-6.834-32.947-3.417-8.595-7.689-15.757-12.814-20.054-5.126-5.73-14.523-10.027-27.338-17.19V61.916h175.984v34.38c-11.96 5.73-21.357 11.459-26.483 15.756-5.125 5.73-9.397 11.46-12.814 20.055-3.417 7.162-5.98 18.622-6.834 34.379-1.709 15.757-2.563 38.676-2.563 71.623v604.498z" fill-rule="nonzero"></path></svg>
            <svg id="comment_auto_completion_off" viewBox="0 0 1080 1080" xmlns="http://www.w3.org/2000/svg" fill-rule="evenodd" clip-rule="evenodd" stroke-linejoin="round" stroke-miterlimit="2"><path d="M242.96 223.172l59.627 58.009c-14.277 10.773-26.874 24.032-37.791 40.606-35.272 50.55-52.908 122.647-52.908 215.461 0 94.472 17.636 168.226 52.908 220.434 35.272 51.379 84.82 77.897 150.326 77.897h3.36l7.558 72.925h-19.316c-89.02 0-157.885-32.319-206.594-96.957-49.549-64.639-73.903-155.795-73.903-274.299 0-116.017 24.354-206.345 73.903-270.155 12.597-16.574 26.874-31.49 42.83-43.921zm36.952-23.204c36.112-19.06 78.943-28.175 126.812-28.175h19.316l-7.559 72.925h-3.359c-27.714 0-52.908 4.144-74.743 14.088l-60.467-58.838zM805.123 770.94l60.466 58.01c-47.869 53.036-111.695 79.554-192.317 79.554h-19.315l7.558-72.925h3.36c59.626 0 105.816-21.546 140.248-64.638zm23.515-37.29c26.034-49.723 39.47-115.19 39.47-196.402 0-92.814-17.635-164.91-52.907-215.461-35.272-51.38-84.821-77.069-150.327-77.069h-3.359l-7.558-72.925h19.315c89.02 0 157.885 31.49 206.594 95.3 49.55 63.81 73.904 154.138 73.904 270.155 0 108.56-20.996 194.744-62.146 257.725l-62.986-61.324zM500.609 474.465l78.595 75.92v292.222c0 31.514.854 54.433 1.708 68.758 1.709 14.325 3.417 25.784 6.835 34.38 2.563 8.594 6.834 14.324 12.814 20.054 5.126 5.73 14.523 11.46 27.337 17.189v34.38H451.914v-34.38c17.086-7.162 29.046-15.757 35.026-24.352 5.126-10.027 9.398-22.92 11.106-38.676 1.709-17.19 2.563-42.974 2.563-77.353V474.465zm0-60.164V238.11c0-32.947-.854-55.866-1.709-71.623-1.708-14.325-4.271-25.784-6.834-32.947-3.417-8.595-7.689-15.757-12.814-20.054-5.126-5.73-14.523-10.027-27.338-17.19v-34.38h175.984v34.38c-11.96 5.73-21.357 11.459-26.483 15.756-5.125 5.73-9.397 11.46-12.814 20.055-3.417 7.162-5.98 18.622-6.834 34.379-1.709 15.757-2.563 38.676-2.563 71.623v253.545l-78.595-77.353z"></path><path d="M153.103 132.024l805.45 783.706-44.277 45.505-805.45-783.706z"></path></svg>
            <span class="inline_middle">自动补全</span>
        </span>
    </div>
</div>
<p id="commentbox_opt">
    <input id="btn_comment_submit" type="button" class="comment_btn" title="提交评论(Ctrl + Enter)" value="提交评论">
    <span id="span_comment_canceledit" style="display:none"><a href="javascript:void(0);" onclick="return CancelCommentEdit()">不改了</a></span>
    <a href="javascript:void(0);" onclick="return logout();">退出</a>
            <a id="commentbox_opt_sub" href="javascript:void(0);" title="订阅后有新评论时会邮件通知您" onclick="commentManager.Subscribe()">订阅评论</a>
            <a href="//www.cnblogs.com/yxpailh/" target="_blank">我的博客</a>
</p>
<div id="tip_comment2" style="color:Red"></div>
<p>[Ctrl+Enter快捷键提交]</p>
<script>var commentEditor = initCommentEditor("tbCommentBody");</script>

</div>
    <div class="ad_text_commentbox" id="ad_text_under_commentbox"></div>
    <div id="ad_t2"><a href="https://developer.aliyun.com/topic/haoyun?utm_content=g_1000241555" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-阿里云-好云')">【推荐】开年迎好云，免费领最高6000元好云礼！15种权益祝你云气爆棚</a><br><a href="https://developer.aliyun.com/learning/trainingcamp/java/2?utm_content=g_1000245293" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-阿里云-java2')">【推荐】阿里云Java训练营第二期--就5天，名师带你实战Spring Boot 2.5</a><br><a href="https://developer.aliyun.com/learning/trainingcamp/redis/1?utm_content=g_1000245176" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-阿里云-redis')">【推荐】阿里云 Redis 社区核心成员带你七天深入 Redis 核心技术</a><br><a href="https://www.uccpsoft.com/index.htm" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-ucancode')">【推荐】大型组态、工控、仿真、CAD\GIS 50万行VC++源码免费下载!</a><br><a href="https://brands.cnblogs.com/huawei" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-华为专区')">【推荐】万物互联的时代，由你的代码定义，创建HarmonyOS应用</a><br><a href="https://www.cnblogs.com/cmt/p/14408628.html" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-AWS')">【求助】注册 Amazon Web Services(AWS) 账户，助园子一臂之力</a><br><a href="https://www.javamall.com.cn" target="_blank" onclick="ga('send', 'event', 'Link', 'click', 'T2-javashop')">【推荐】Javashop--基于SPRING BOOT架构的企业级电商系统</a><br></div>
    <div id="opt_under_post"></div>
    <div id="cnblogs_c1" class="under-post-card" style="">
        <div id="div-gpt-ad-1592365906576-0" style="width: 300px; height: 250px;" data-google-query-id="CMjJwZahk-8CFVjAfAodG6sNqA"><div id="google_ads_iframe_/1090369/C1_0__container__" style="border: 0pt none;"><iframe id="google_ads_iframe_/1090369/C1_0" title="3rd party ad content" name="google_ads_iframe_/1090369/C1_0" width="300" height="250" scrolling="no" marginwidth="0" marginheight="0" frameborder="0" srcdoc="" data-google-container-id="1" style="border: 0px; vertical-align: bottom;" data-load-complete="true"></iframe></div></div>
    </div>
    <div id="under_post_card1"><div class="under-post-card"><b>AWS免费产品</b>：<br>· <a onclick="ga(&quot;send&quot;, &quot;event&quot;, &quot;Link&quot;, &quot;click&quot;, &quot;aws-underpost-card&quot;)" href="https://aws.amazon.com/cn/free/webapps/?trk=ba_a134p000006vc6OAAQ&amp;trkCampaign=webapps&amp;sc_channel=ba&amp;sc_campaign=cnblogs&amp;sc_outcome=Acquisition&amp;sc_geo=CHNA&amp;sc_country=CN&amp;sc_publisher=Others" target="_blank">如何在AWS上免费构建网站</a><br>· <a onclick="ga(&quot;send&quot;, &quot;event&quot;, &quot;Link&quot;, &quot;click&quot;, &quot;aws-underpost-card&quot;)" href="https://aws.amazon.com/cn/free/storage/?trk=ba_a134p000006vc7JAAQ&amp;trkCampaign=storage&amp;sc_channel=ba&amp;sc_campaign=cnblogs&amp;sc_outcome=Acquisition&amp;sc_geo=CHNA&amp;sc_country=CN&amp;sc_publisher=Others" target="_blank">AWS免费云存储解决方案</a><br>· <a onclick="ga(&quot;send&quot;, &quot;event&quot;, &quot;Link&quot;, &quot;click&quot;, &quot;aws-underpost-card&quot;)" href="https://aws.amazon.com/cn/free/database/?trk=ba_a134p000006vc7YAAQ&amp;trkCampaign=database&amp;sc_channel=ba&amp;sc_campaign=cnblogs&amp;sc_outcome=Acquisition&amp;sc_geo=CHNA&amp;sc_country=CN&amp;sc_publisher=Others" target="_blank">在AWS上免费构建数据库</a><br>· <a onclick="ga(&quot;send&quot;, &quot;event&quot;, &quot;Link&quot;, &quot;click&quot;, &quot;aws-underpost-card&quot;)" href="https://aws.amazon.com/cn/free/machine-learning/?trk=ba_a134p000006vc7nAAA&amp;trkCampaign=ML&amp;sc_channel=ba&amp;sc_campaign=cnblogs&amp;sc_outcome=Acquisition&amp;sc_geo=CHNA&amp;sc_country=CN&amp;sc_publisher=Others" target="_blank">AWS上的免费机器学习</a></div></div>
    <div id="cnblogs_c2" class="under-post-card" style="">
        <div id="div-gpt-ad-1592366332455-0" style="width: 468px; height: 60px;" data-google-query-id="CMnJwZahk-8CFVjAfAodG6sNqA"><div id="google_ads_iframe_/1090369/C2_0__container__" style="border: 0pt none;"><iframe id="google_ads_iframe_/1090369/C2_0" title="3rd party ad content" name="google_ads_iframe_/1090369/C2_0" width="468" height="60" scrolling="no" marginwidth="0" marginheight="0" frameborder="0" srcdoc="" data-google-container-id="2" style="border: 0px; vertical-align: bottom;" data-load-complete="true"></iframe></div></div>
    </div>
    <div id="under_post_card2"><div class="itnews under-post-card">
    <b>最新新闻</b>：
    <br>
 ·          <a href="//news.cnblogs.com/n/689317/" target="_blank">全球首次！人工智能发现新机制特发性肺纤维化药物</a>
        <br>
 ·          <a href="//news.cnblogs.com/n/689357/" target="_blank">Ignite 2021：微软宣布Visual Studio 2019 16.9版本转正</a>
        <br>
 ·          <a href="//news.cnblogs.com/n/689354/" target="_blank">Chrome 89稳定版发布：修复大量Bug、降低内存占用等！附下载</a>
        <br>
 ·          <a href="//news.cnblogs.com/n/689353/" target="_blank">蔚来年底产能将达30万辆 有BBA的城市就有蔚来店</a>
        <br>
 ·          <a href="//news.cnblogs.com/n/689352/" target="_blank">微软面向Beta频道开放Windows 10 21H1 Build 19043.844更新</a>
        <br>
    » <a href="https://news.cnblogs.com/" title="IT 新闻" target="_blank">更多新闻...</a>
</div></div>
    <div id="HistoryToday" class="under-post-card"></div>
    <script type="text/javascript">
       var commentManager = new blogCommentManager();
       commentManager.renderComments(0);
       fixPostBody();
       deliverBigBanner();
setTimeout(function() { incrementViewCount(cb_entryId); }, 50);       deliverT2();
       deliverC1C2();
       loadNewsAndKb();
       loadBlogSignature();
LoadPostCategoriesTags(cb_blogId, cb_entryId);       LoadPostInfoBlock(cb_blogId, cb_entryId, cb_blogApp, cb_blogUserGuid);
       GetPrevNextPost(cb_entryId, cb_blogId, cb_entryCreatedDate, cb_postType);
       loadOptUnderPost();
       GetHistoryToday(cb_blogId, cb_blogApp, cb_entryCreatedDate);
    </script>
</div>

	</div><!--end: forFlow -->
	</div><!--end: mainContent 主体内容容器-->
	<div id="sideBar">
		<div id="sideBarMain">
			<div id="sidebar_news" class="newsItem"><!--done-->
<h3 class="catListTitle">公告</h3>

<div id="blog-news"><div class="container">    <div class="menu-wrap optiscroll is-enabled has-vtrack" id="menuWrap" style=""><div class=" optiscroll-content" style="right: -16px; bottom: -16px;">        <nav class="menu">            <!-- 个人简介 -->            <div class="introduce-box">                <div class="introduce-head">                    <div class="introduce-via" id="menuBlogAvatar"><img src="https://pic.cnblogs.com/avatar/1324014/20191130183449.png"></div>                </div>                <div id="introduce">
        昵称：
        <a href="https://home.cnblogs.com/u/tuyang1129/">
            特务依昂
        </a>
        <br>
        园龄：
        <a href="https://home.cnblogs.com/u/tuyang1129/" title="入园时间：2018-01-23">
            3年1个月
        </a>
        <br>
        粉丝：
        <a href="https://home.cnblogs.com/u/tuyang1129/followers/">
            53
        </a>
        <br>
        关注：
        <a href="https://home.cnblogs.com/u/tuyang1129/followees/">
            7
        </a>
        <div id="p_b_follow">
<a href="javascript:void(0)" onclick="follow('103b1715-a5bf-43c8-38f4-08d54dba4453')">+加关注</a></div>
        
    </div>            </div>            <!-- 导航 -->            <div class="nav-title"></div>            <div class="icon-list">                <ul id="m-nav-list">                <li><a href="https://www.cnblogs.com/tuyang1129/" target="_self">首页</a></li><li><a href="https://msg.cnblogs.com/send/tuyang1129" target="_blank">联系</a></li><li><a href="https://www.cnblogs.com/tuyang1129/rss" target="_blank">订阅</a></li><li><a href="https://i.cnblogs.com/" target="_blank">管理</a></li></ul>            </div>            <!-- 日历 -->            <span id="calendar-box"><div id="blog-calendar" style="visibility: visible;">

<table id="blogCalendar" class="Cal" cellspacing="0" cellpadding="0" title="Calendar" border="0">
    <tbody>
        <tr>
            <td colspan="7">
                <table class="CalTitle" cellspacing="0" border="0">
                    <tbody>
                        <tr>
                            <td class="CalNextPrev">
                                <a href="javascript:void(0);" onclick="loadBlogCalendar('2021/02/03'); return false;">&lt;</a>
                            </td>
                            <td align="center">2021年3月</td>
                            <td align="right" class="CalNextPrev">
                                <a href="javascript:void(0);" onclick="loadBlogCalendar('2021/04/03'); return false;">&gt;</a>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </td>
        </tr>
    <tr>
        <th class="CalDayHeader" align="center" abbr="日" scope="col">日</th>
        <th class="CalDayHeader" align="center" abbr="一" scope="col">一</th>
        <th class="CalDayHeader" align="center" abbr="二" scope="col">二</th>
        <th class="CalDayHeader" align="center" abbr="三" scope="col">三</th>
        <th class="CalDayHeader" align="center" abbr="四" scope="col">四</th>
        <th class="CalDayHeader" align="center" abbr="五" scope="col">五</th>
        <th class="CalDayHeader" align="center" abbr="六" scope="col">六</th>
    </tr>
            <tr>
                            <td class="CalOtherMonthDay" align="center">28</td>
                        <td class="" align="center">
                            1
                        </td>
                        <td class="" align="center">
                            2
                        </td>
                        <td class="CalTodayDay" align="center">
                            3
                        </td>
                        <td class="" align="center">
                            4
                        </td>
                        <td class="" align="center">
                            5
                        </td>
                    <td class="CalWeekendDay" align="center">
                        6
                    </td>
            </tr>
                <tr>
                        <td class="CalWeekendDay" align="center">
                            7
                        </td>
                            <td class="" align="center">
                                8
                            </td>
                            <td class="" align="center">
                                9
                            </td>
                            <td class="" align="center">
                                10
                            </td>
                            <td class="" align="center">
                                11
                            </td>
                            <td class="" align="center">
                                12
                            </td>
                        <td class="CalWeekendDay" align="center">
                            13
                        </td>
                </tr>
                <tr>
                        <td class="CalWeekendDay" align="center">
                            14
                        </td>
                            <td class="" align="center">
                                15
                            </td>
                            <td class="" align="center">
                                16
                            </td>
                            <td class="" align="center">
                                17
                            </td>
                            <td class="" align="center">
                                18
                            </td>
                            <td class="" align="center">
                                19
                            </td>
                        <td class="CalWeekendDay" align="center">
                            20
                        </td>
                </tr>
                <tr>
                        <td class="CalWeekendDay" align="center">
                            21
                        </td>
                            <td class="" align="center">
                                22
                            </td>
                            <td class="" align="center">
                                23
                            </td>
                            <td class="" align="center">
                                24
                            </td>
                            <td class="" align="center">
                                25
                            </td>
                            <td class="" align="center">
                                26
                            </td>
                        <td class="CalWeekendDay" align="center">
                            27
                        </td>
                </tr>
                <tr>
                        <td class="CalWeekendDay" align="center">
                            28
                        </td>
                            <td class="" align="center">
                                29
                            </td>
                            <td class="" align="center">
                                30
                            </td>
                            <td class="" align="center">
                                31
                            </td>
                            <td class="CalOtherMonthDay" align="center">
                                1
                            </td>
                            <td class="CalOtherMonthDay" align="center">
                                2
                            </td>
                        <td class="CalOtherMonthDay" align="center">
                            3
                        </td>
                </tr>
                <tr>
                        <td class="CalOtherMonthDay" align="center">
                            4
                        </td>
                            <td class="CalOtherMonthDay" align="center">
                                5
                            </td>
                            <td class="CalOtherMonthDay" align="center">
                                6
                            </td>
                            <td class="CalOtherMonthDay" align="center">
                                7
                            </td>
                            <td class="CalOtherMonthDay" align="center">
                                8
                            </td>
                            <td class="CalOtherMonthDay" align="center">
                                9
                            </td>
                        <td class="CalOtherMonthDay" align="center">
                            10
                        </td>
                </tr>
    </tbody>
</table></div></span>            <!-- 找找看 -->            <div class="m-list-title" style="display: block;"><span>找找看</span></div>            <div class="m-icon-list" id="sb-sidebarSearchBox"><div id="sb_widget_my_zzk" class="div_my_zzk"><input id="q" type="text" onkeydown="return zzk_go_enter(event);" class="input_my_zzk"></div></div>            <!-- 积分与排名 -->            <div class="m-list-title"><span>积分排名<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-sidebarScorerank"></div>            <!-- 最新随笔 -->            <div class="m-list-title"><span>最新随笔<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-sidebarRecentposts"></div>            <!-- 我的标签 -->            <div class="m-list-title"><span>我的标签<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-toptags"></div>            <!-- 随笔分类 -->            <div class="m-list-title" style="display: block;"><span>随笔分类<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-classify"><div><ul><li><a href="https://www.cnblogs.com/tuyang1129/category/1450775.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>JavaSE(14)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1446094.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>javaWeb(3)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1655728.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Java容器(7)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1670984.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Java虚拟机(6)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1448468.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Maven(1)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1689928.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>MySQL(1)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1750877.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Redis(3)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1761493.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Spring(6)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1682548.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>并发(7)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1657502.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>计算机网络(11)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1746596.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>面试经验(1)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1677872.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>设计模式(2)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1253747.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>数据结构与算法(13)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/category/1253742.html" rel="" target=""><span class="iconfont icon-marketing_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>算法题(31)</a></li></ul></div></div>            <!-- 文章分类 -->            <div class="m-list-title"><span>文章分类<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-ArticleCategory"></div>            <!-- 阅读排行 -->            <div class="m-list-title" style="display: block;"><span>阅读排行<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-topview"><div><ul><li><a href="https://www.cnblogs.com/tuyang1129/p/9390376.html"><span class="iconfont icon-browse_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>判断两条线段是否相交—（向量叉乘）(35415)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/11960950.html"><span class="iconfont icon-browse_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Java创建List、Map等集合对象的同时进行赋值操作(6181)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/10724898.html"><span class="iconfont icon-browse_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>理解JavaWeb项目中的路径问题——相对路径与绝对路径(5760)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12873492.html"><span class="iconfont icon-browse_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Spring中bean的四种注入方式(5337)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/9140942.html"><span class="iconfont icon-browse_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>数据结构图的两种存储结构（邻接矩阵和邻接表）(3944)</a></li></ul></div></div>            <!-- 推荐排行 -->            <div class="m-list-title" style="display: block;"><span>推荐排行<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-topDiggPosts"><div><ul><li><a href="https://www.cnblogs.com/tuyang1129/p/9390376.html"><span class="iconfont icon-like_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>判断两条线段是否相交—（向量叉乘）(8)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12670014.html"><span class="iconfont icon-like_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>并发——抽象队列同步器AQS的实现原理(5)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12873492.html"><span class="iconfont icon-like_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>Spring中bean的四种注入方式(4)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12776526.html"><span class="iconfont icon-like_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>详细分析Redis的持久化操作——RDB与AOF(4)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12439862.html"><span class="iconfont icon-like_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>计算机网络——TCP的拥塞控制（超详细）(4)</a></li></ul></div></div>            <!-- 最新评论 -->            <div class="m-list-title" style="display: block;"><span>最新评论<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-recentComments"><div><ul><li><a href="https://www.cnblogs.com/tuyang1129/p/11178925.html"><span class="iconfont icon-pinglunzu" style="color: #888;font-size: 15px;margin-right: 5px;"></span>Re:子类能否重写父类的静态方法？</a><div style="padding-left: 1.5em;color: #777;position: relative;top: -5px;">从某种意义来讲,这里不算太严谨,一般子类继承父类并重写方法,需要添加@ovveride注解才算真正意义上的重写,所以这里虽然继承了父类并且申明了同样的方法,但它也只是子类自己的方法,所以这样输出,另外...</div><div style="text-align: right;color: #444;position: relative;top: -10px;">--DMd</div></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12873492.html"><span class="iconfont icon-pinglunzu" style="color: #888;font-size: 15px;margin-right: 5px;"></span>Re:Spring中bean的四种注入方式</a><div style="padding-left: 1.5em;color: #777;position: relative;top: -5px;">现在应该没有人用xml了吧？讲基于xml的方式还不如基于spring boot注解更实用一些
</div><div style="text-align: right;color: #444;position: relative;top: -10px;">--imyourmark</div></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12450978.html"><span class="iconfont icon-pinglunzu" style="color: #888;font-size: 15px;margin-right: 5px;"></span>Re:计算机网络——TCP的流水线传输（超详细）</a><div style="padding-left: 1.5em;color: #777;position: relative;top: -5px;">@特务依昂 懂了，谢谢！...</div><div style="text-align: right;color: #444;position: relative;top: -10px;">--森卜</div></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12450978.html"><span class="iconfont icon-pinglunzu" style="color: #888;font-size: 15px;margin-right: 5px;"></span>Re:计算机网络——TCP的流水线传输（超详细）</a><div style="padding-left: 1.5em;color: #777;position: relative;top: -5px;">aaa
</div><div style="text-align: right;color: #444;position: relative;top: -10px;">--特务依昂</div></li><li><a href="https://www.cnblogs.com/tuyang1129/p/12450978.html"><span class="iconfont icon-pinglunzu" style="color: #888;font-size: 15px;margin-right: 5px;"></span>Re:计算机网络——TCP的流水线传输（超详细）</a><div style="padding-left: 1.5em;color: #777;position: relative;top: -5px;">@森卜 这是markdown语法，markdown语法里面被 包住的字就是这种显示，比如hello`，需要把博客园的编辑器改成markdown。...</div><div style="text-align: right;color: #444;position: relative;top: -10px;">--特务依昂</div></li></ul></div></div>            <!-- 文章档案 -->            <div class="m-list-title"><span>文章档案<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-articlearchive"></div>            <!-- 随笔档案 -->            <div class="m-list-title" style="display: block;"><span>随笔档案<span class="iconfont icon-select m-list-title-select"></span></span></div>            <div class="m-icon-list" id="sb-record"><div><ul><li><a href="https://www.cnblogs.com/tuyang1129/archive/2020/05.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2020年5月(9)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2020/04.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2020年4月(10)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2020/03.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2020年3月(21)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2020/02.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2020年2月(4)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2020/01.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2020年1月(5)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2019/12.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2019年12月(2)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2019/11.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2019年11月(1)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2019/10.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2019年10月(3)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2019/07.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2019年7月(3)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2019/04.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2019年4月(5)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/11.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年11月(1)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/10.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年10月(2)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/09.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年9月(2)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/08.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年8月(3)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/07.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年7月(21)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/06.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年6月(4)</a></li><li><a href="https://www.cnblogs.com/tuyang1129/archive/2018/05.html" rel="" target=""><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>2018年5月(1)</a></li><li><a href="javascript:void(0)" onclick="sideColumnManager.loadMore(this)"><span class="iconfont icon-task_fill" style="color: #888;font-size: 14px;margin-right: 5px;"></span>更多</a></li></ul></div></div>            <!-- 自定义列表 -->            <span id="menuCustomList"></span>        </nav>        <button class="close-button" id="close-button">Close Menu</button>        <div class="morph-shape" id="morph-shape" data-morph-open="M-7.312,0H15c0,0,66,113.339,66,399.5C81,664.006,15,800,15,800H-7.312V0z;M-7.312,0H100c0,0,0,113.839,0,400c0,264.506,0,400,0,400H-7.312V0z">            <svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" viewBox="0 0 100 800" preserveAspectRatio="none">                <path d="M-7.312,0H0c0,0,0,113.839,0,400c0,264.506,0,400,0,400h-7.312V0z"></path>            <desc>Created with Snap</desc><defs></defs></svg>        </div>    </div><div class="optiscroll-v"><b class="optiscroll-vtrack" style="height: 20%; transform: translate(0%, 0%);"></b></div><div class="optiscroll-h"><b class="optiscroll-htrack"></b></div></div>    <button class="menu-button menu-button-scroll" id="open-button"></button>    <div class="content-wrap" id="content-wrap" style="display: none;"></div><!-- /content-wrap --></div><div class="main-header" style="height: 40vh; background: url(&quot;https://cdn.jsdelivr.net/gh/BNDong/Cnblogs-Theme-SimpleMemory@master/img/webp/nothome_top_bg.webp&quot;) center center / cover no-repeat rgb(34, 34, 34);">    <canvas id="notHomeTopCanvas" width="0" height="0"></canvas>    <div class="vertical">        <div class="main-header-content inner" style="max-width: 100vw;">            <h1 class="page-title" id="homeTopTitle" style="display: none;">特务依昂</h1>            <h2 class="page-description" id="hitokoto"></h2>            <h3 class="page-author" id="hitokotoAuthor"></h3>            <h1 class="sb-title" id="sbTitle">
    计算机网络——TCP如何做到可靠数据传输
    


</h1>            <p class="article-info" id="articleInfo"><p class="article-info-text"><span class="postMeta"><i class="iconfont icon-time1"></i>发表于 2020-03-10 21:01<i class="iconfont icon-browse"></i>阅读次数：734<i class="iconfont icon-interactive"></i>评论次数：0</span></p><a href="https://www.cnblogs.com/tuyang1129/category/1657502.html" target="_blank"><span class="article-info-tag article-tag-class-color">计算机网络</span></a></p>        </div>    </div>    <a class="scroll-down" href="javascript:void(0);" data-offset="-45" style="display: none;">        <span class="hidden">Scroll Down</span>        <i class="scroll-down-icon iconfont icon-fanhui"></i>    </a></div><div id="loading" style="display: none;"></div><div id="bottomProgressBar"><div id="top-progress-bar" style="position: relative; top: 0px; left: 0px; right: 0px; background-color: rgb(119, 182, 255); height: 2px; width: 48%; transition: width 0.2s ease 0s, opacity 0.6s ease 0s; opacity: 1;"></div></div><div id="rightMenu"><div id="rightDiggit" clickflg="false" onclick="votePost(12458592,'Digg')"><span class="rightMenuSpan rightDiggitSpan">0</span><i class="iconfont icon-zan1"></i></div><div id="rightBuryit" clickflg="false" onclick="votePost(12458592,'Bury')"><span class="rightMenuSpan rightBuryitSpan">0</span><i class="iconfont icon-buzan"></i></div><div id="attention" onclick="follow('103b1715-a5bf-43c8-38f4-08d54dba4453')" clickflg="false"><span class="rightMenuSpan attentionSpan">关注</span><i class="iconfont icon-dianzan"></i></div><div id="toUpDown" data="up"><span class="rightMenuSpan toUpDownSpan">返回顶部</span><div id="toUpDownI" style="transform: rotate(0deg); transform-origin: 50% 50%;"><i class="iconfont icon-zhiding"></i></div></div></div>
    <script type="text/javascript">window['__document_write_ajax_callbacks__']['4']();</script><script type="text/javascript">window['__document_write_ajax_callbacks__']['1']();</script>
<script type="text/javascript">window['__document_write_ajax_callbacks__']['5']();</script><script type="text/javascript">window['__document_write_ajax_callbacks__']['6']();</script><script>window['__document_write_ajax_callbacks__']['2']();</script>
    <div id="profile_block">
        昵称：
        <a href="https://home.cnblogs.com/u/tuyang1129/">
            特务依昂
        </a>
        <br>
        园龄：
        <a href="https://home.cnblogs.com/u/tuyang1129/" title="入园时间：2018-01-23">
            3年1个月
        </a>
        <br>
        粉丝：
        <a href="https://home.cnblogs.com/u/tuyang1129/followers/">
            53
        </a>
        <br>
        关注：
        <a href="https://home.cnblogs.com/u/tuyang1129/followees/">
            7
        </a>
        <div id="p_b_follow">
<a href="javascript:void(0)" onclick="follow('103b1715-a5bf-43c8-38f4-08d54dba4453')">+加关注</a></div>
        <script type="text/javascript">window['__document_write_ajax_callbacks__']['7']();</script><script>window['__document_write_ajax_callbacks__']['3']();</script>
    </div>
</div>

</div>
<div id="sidebar_c3"></div>
			<script>loadBlogDefaultCalendar();</script>			
			<div id="leftcontentcontainer">
				<div id="blog-sidecolumn"><!-- 搜索 -->
<div id="sidebar_search" class="sidebar-block">
    <div id="sidebar_search" class="mySearch">
        <h3 class="catListTitle">搜索</h3>
        <div id="sidebar_search_box">
            <div id="widget_my_zzk" class="div_my_zzk">
                <input type="text" id="q" onkeydown="return zzk_go_enter(event);" class="input_my_zzk">&nbsp;<input onclick="zzk_go()" type="button" value="找找看" id="btnZzk" class="btn_my_zzk">
            </div>
            <div id="widget_my_google" class="div_my_zzk">
                <input type="text" name="google_q" id="google_q" onkeydown="return google_go_enter(event);" class="input_my_zzk">&nbsp;<input onclick="google_go()" type="button" value="谷歌搜索" class="btn_my_zzk">
            </div>
        </div>
    </div>
</div>

<!-- 常用链接 -->
<div id="sidebar_shortcut" class="sidebar-block"><div class="catListLink">
<h3 class="catListTitle">
常用链接
</h3>
<ul>
    
<li><a href="https://www.cnblogs.com/tuyang1129/p/" title="我的博客的随笔列表">我的随笔</a></li>
<li><a href="https://www.cnblogs.com/tuyang1129/MyComments.html" title="我的发表过的评论列表">我的评论</a></li>
<li><a href="https://www.cnblogs.com/tuyang1129/OtherPosts.html" title="我评论过的随笔列表">我的参与</a></li>
<li><a href="https://www.cnblogs.com/tuyang1129/RecentComments.html" title="我的博客的评论列表">最新评论</a></li>
<li><a href="https://www.cnblogs.com/tuyang1129/tag/" title="我的博客的标签列表">我的标签</a></li>

</ul>
</div>

</div>

<!-- 最新随笔 -->


<!-- 我的标签 -->
<div id="sidebar_toptags" class="sidebar-block"></div>

<!-- 积分与排名 -->


<!-- 随笔分类、随笔档案、文章分类、新闻分类、相册、链接 -->
<div id="sidebar_categories">

    <div id="sidebar_postcategory" class="catListPostCategory sidebar-block">
        <h3 class="catListTitle">
            
随笔分类



        </h3>

        <ul>

                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1450775.html" rel="" target="">
    JavaSE(14)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1446094.html" rel="" target="">
    javaWeb(3)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1655728.html" rel="" target="">
    Java容器(7)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1670984.html" rel="" target="">
    Java虚拟机(6)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1448468.html" rel="" target="">
    Maven(1)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1689928.html" rel="" target="">
    MySQL(1)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1750877.html" rel="" target="">
    Redis(3)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1761493.html" rel="" target="">
    Spring(6)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1682548.html" rel="" target="">
    并发(7)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1657502.html" rel="" target="">
    计算机网络(11)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1746596.html" rel="" target="">
    面试经验(1)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1677872.html" rel="" target="">
    设计模式(2)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1253747.html" rel="" target="">
    数据结构与算法(13)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/category/1253742.html" rel="" target="">
    算法题(31)
</a>
 

                </li>                
            
        </ul>


    </div>    
    <div id="sidebar_postarchive" class="catListPostArchive sidebar-block">
        <h3 class="catListTitle">
            
随笔档案



        </h3>

        <ul>

                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2020/05.html" rel="" target="">
    2020年5月(9)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2020/04.html" rel="" target="">
    2020年4月(10)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2020/03.html" rel="" target="">
    2020年3月(21)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2020/02.html" rel="" target="">
    2020年2月(4)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2020/01.html" rel="" target="">
    2020年1月(5)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2019/12.html" rel="" target="">
    2019年12月(2)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2019/11.html" rel="" target="">
    2019年11月(1)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2019/10.html" rel="" target="">
    2019年10月(3)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2019/07.html" rel="" target="">
    2019年7月(3)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2019/04.html" rel="" target="">
    2019年4月(5)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/11.html" rel="" target="">
    2018年11月(1)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/10.html" rel="" target="">
    2018年10月(2)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/09.html" rel="" target="">
    2018年9月(2)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/08.html" rel="" target="">
    2018年8月(3)
</a>
 

                </li>                
                <li data-category-list-item-visible="true" style="display: block">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/07.html" rel="" target="">
    2018年7月(21)
</a>
 

                </li>                
                <li data-category-list-item-visible="false" style="display: none">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/06.html" rel="" target="">
    2018年6月(4)
</a>
 

                </li>                
                <li data-category-list-item-visible="false" style="display: none">
                    
<a href="https://www.cnblogs.com/tuyang1129/archive/2018/05.html" rel="" target="">
    2018年5月(1)
</a>
 

                </li>                
            <li>
                <a href="javascript:void(0)" onclick="sideColumnManager.loadMore(this)">更多</a>
            </li>
        </ul>


    </div>    
</div>

<!-- 最新评论 -->
<div id="sidebar_recentcomments" class="sidebar-block"><div class="catListComment">
<h3 class="catListTitle">最新评论</h3>

	<div class="RecentCommentBlock">
        <ul>
                    <li class="recent_comment_title"><a href="https://www.cnblogs.com/tuyang1129/p/11178925.html">1. Re:子类能否重写父类的静态方法？</a></li>
                    <li class="recent_comment_body">从某种意义来讲,这里不算太严谨,一般子类继承父类并重写方法,需要添加@ovveride注解才算真正意义上的重写,所以这里虽然继承了父类并且申明了同样的方法,但它也只是子类自己的方法,所以这样输出,另外...</li>
                    <li class="recent_comment_author">--DMd</li>
                    <li class="recent_comment_title"><a href="https://www.cnblogs.com/tuyang1129/p/12873492.html">2. Re:Spring中bean的四种注入方式</a></li>
                    <li class="recent_comment_body"><p>现在应该没有人用xml了吧？讲基于xml的方式还不如基于spring boot注解更实用一些</p>
</li>
                    <li class="recent_comment_author">--imyourmark</li>
                    <li class="recent_comment_title"><a href="https://www.cnblogs.com/tuyang1129/p/12450978.html">3. Re:计算机网络——TCP的流水线传输（超详细）</a></li>
                    <li class="recent_comment_body">@特务依昂 懂了，谢谢！...</li>
                    <li class="recent_comment_author">--森卜</li>
                    <li class="recent_comment_title"><a href="https://www.cnblogs.com/tuyang1129/p/12450978.html">4. Re:计算机网络——TCP的流水线传输（超详细）</a></li>
                    <li class="recent_comment_body"><p><code>aaa</code></p>
</li>
                    <li class="recent_comment_author">--特务依昂</li>
                    <li class="recent_comment_title"><a href="https://www.cnblogs.com/tuyang1129/p/12450978.html">5. Re:计算机网络——TCP的流水线传输（超详细）</a></li>
                    <li class="recent_comment_body">@森卜 这是markdown语法，markdown语法里面被 包住的字就是这种显示，比如hello`，需要把博客园的编辑器改成markdown。...</li>
                    <li class="recent_comment_author">--特务依昂</li>
        </ul>
    </div>
</div>

</div>


<!-- 阅读排行榜 -->
<div id="sidebar_topviewedposts" class="sidebar-block"><div class="catListView">
<h3 class="catListTitle">阅读排行榜</h3>
	<div id="TopViewPostsBlock">
        <ul style="word-break:break-all">
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/9390376.html">
                            1. 判断两条线段是否相交—（向量叉乘）(35415)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/11960950.html">
                            2. Java创建List、Map等集合对象的同时进行赋值操作(6181)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/10724898.html">
                            3. 理解JavaWeb项目中的路径问题——相对路径与绝对路径(5760)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/12873492.html">
                            4. Spring中bean的四种注入方式(5337)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/9140942.html">
                            5. 数据结构图的两种存储结构（邻接矩阵和邻接表）(3944)
                        </a>
                    </li>
        </ul>
    </div>
</div>

</div>

<!-- 评论排行榜 -->
<div id="sidebar_topcommentedposts" class="sidebar-block"><div class="catListFeedback">
<h3 class="catListTitle">评论排行榜</h3>
	<div id="TopFeedbackPostsBlock">
        <ul style="word-break:break-all">
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/10724898.html">
                            1. 理解JavaWeb项目中的路径问题——相对路径与绝对路径(6)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/12450978.html">
                            2. 计算机网络——TCP的流水线传输（超详细）(5)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/12405813.html">
                            3. 计算机网络——多路复用与多路分解(3)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/12873492.html">
                            4. Spring中bean的四种注入方式(2)
                        </a>
                    </li>
                    <li>
                        <a href="https://www.cnblogs.com/tuyang1129/p/12670014.html">
                            5. 并发——抽象队列同步器AQS的实现原理(2)
                        </a>
                    </li>
        </ul>
    </div>
</div>

</div>

<!-- 推荐排行榜 -->
<div id="sidebar_topdiggedposts" class="sidebar-block">
<div id="topdigg_posts_wrap">
    <div class="catListView">
        <h3 class="catListTitle">推荐排行榜</h3>
        <div id="TopDiggPostsBlock">
            <ul style="word-break: break-all">
                        <li>
                            <a href="https://www.cnblogs.com/tuyang1129/p/9390376.html">
                                1. 判断两条线段是否相交—（向量叉乘）(8)
                            </a>
                        </li>
                        <li>
                            <a href="https://www.cnblogs.com/tuyang1129/p/12670014.html">
                                2. 并发——抽象队列同步器AQS的实现原理(5)
                            </a>
                        </li>
                        <li>
                            <a href="https://www.cnblogs.com/tuyang1129/p/12873492.html">
                                3. Spring中bean的四种注入方式(4)
                            </a>
                        </li>
                        <li>
                            <a href="https://www.cnblogs.com/tuyang1129/p/12776526.html">
                                4. 详细分析Redis的持久化操作——RDB与AOF(4)
                            </a>
                        </li>
                        <li>
                            <a href="https://www.cnblogs.com/tuyang1129/p/12439862.html">
                                5. 计算机网络——TCP的拥塞控制（超详细）(4)
                            </a>
                        </li>
            </ul>
        </div>
    </div>
</div></div></div>
                    <script>loadBlogSideColumn();</script>
			</div>			
		</div><!--end: sideBarMain -->
	</div><!--end: sideBar 侧边栏容器 -->
	<div class="clear"></div>
	</div><!--end: main -->
	<div class="clear"></div>
	<div id="footer"><footer><footer-background><figure class="clouds"></figure><figure class="background"></figure><figure class="foreground"></figure></footer-background></footer><div class="footer-box"><div class="footer-text" style="padding-bottom: 0px; border-bottom: none; margin-bottom: 0px;">[ 世界是个球<span class="footer-text-icon">❤️</span>前方总有路 ]</div><div><span id="blogRunTimeSpan">This blog has running : 1135 d 6 h 18 m 30 s</span><span class="my-face">ღゝ◡╹)ノ♡</span></div><div id="blogrollInfo">友情链接：<a href="https://tewuyiang.gitee.io/blog/" target="_blank">我的Hexo博客</a></div><div>
		
Copyright © 2021 特务依昂
Powered by .NET 5.0 on Kubernetes



	</div><div id="cnzzInfo"></div><div id="themeInfo">Theme version: <a href="https://github.com/BNDong/Cnblogs-Theme-SimpleMemory/tree/v1.2.8" target="_blank" style="color: #888;text-decoration: underline;">v1.2.8</a> / Loading theme version: <a href="https://github.com/BNDong/Cnblogs-Theme-SimpleMemory/tree/v1.2.8" target="_blank" style="color: #888;text-decoration: underline;">v1.2.8</a></div></div></div><!--end: footer -->
</div>