Concpets of problem solving
Descartes Scientific Methodology
Computer Network
公路是单行道还是双行道?TCP
走迷宫?一条路坏了如何走另一条路?ARP
{width=”1.968503937007874in” height=”2.522354549431321in”}
###
{width=”1.968503937007874in” height=”0.9875995188101487in”}
{width=”1.968503937007874in” height=”1.3388910761154855in”}
###
{width=”1.968503937007874in” height=”0.39137576552930886in”}
• 2\^16: 每一台电脑可以有65535个端口
{width=”1.968503937007874in” height=”0.7523600174978128in”}
###
{width=”1.968503937007874in” height=”1.4701881014873142in”}
###
{width=”1.968503937007874in” height=”1.1035553368328959in”}
###
{width=”1.968503937007874in” height=”0.9438385826771654in”}
{width=”1.968503937007874in” height=”0.9063199912510936in”}
{width=”1.968503937007874in” height=”0.5230993000874891in”}
{width=”1.968503937007874in” height=”0.6614599737532808in”}
{width=”1.968503937007874in” height=”1.6899420384951882in”}
{width=”1.968503937007874in” height=”0.5632589676290464in”}
{width=”1.968503937007874in” height=”0.7294728783902013in”}
{width=”1.968503937007874in” height=”1.3870297462817147in”}
语法:即 构成一句话的元素
语义:即 逻辑上要做什么事情
•
{width=”1.968503937007874in” height=”1.0448392388451444in”}
•
{width=”1.968503937007874in” height=”0.3717060367454068in”}
• Protocol Data UnitService Data Unit
{width=”1.968503937007874in” height=”1.0496270778652668in”}
{width=”1.968503937007874in” height=”4.040917541557305in”}
###
{width=”1.968503937007874in” height=”0.8056747594050744in”}
###
{width=”1.968503937007874in” height=”0.9101399825021872in”}
###
{width=”1.968503937007874in” height=”2.83417104111986in”}
{width=”1.968503937007874in” height=”2.0836679790026245in”}
{width=”0.6988188976377953in” height=”2.982283464566929in”}
{width=”1.968503937007874in” height=”0.5656036745406824in”}
{width=”1.968503937007874in” height=”0.4626224846894138in”}
{width=”1.968503937007874in” height=”0.9171751968503937in”}
{width=”1.968503937007874in” height=”0.7773064304461942in”}
{width=”1.968503937007874in” height=”0.6358442694663167in”}
{width=”1.968503937007874in” height=”0.9563757655293088in”}
{width=”1.968503937007874in” height=”0.8097856517935258in”}
{width=”1.968503937007874in” height=”1.306370297462817in”}
{width=”1.968503937007874in” height=”0.953076334208224in”}
{width=”1.968503937007874in” height=”1.0178608923884513in”}
{width=”1.968503937007874in” height=”1.0229844706911635in”}
{width=”1.968503937007874in” height=”0.926505905511811in”}
.路径选择那么TCP层有做什么吗? todo
{width=”1.968503937007874in” height=”1.149491469816273in”}
{width=”1.968503937007874in” height=”0.5784875328083989in”}
{width=”1.968503937007874in” height=”1.0496795713035871in”}
{width=”1.968503937007874in” height=”0.7149453193350831in”}
1. always newest and same version . ez to control version
2. data centerilizeez to share
3. cross platform
4. reduce client-side reqs such as *heavy computation give to
server *
• transparency用户可以直接f12查看大量内部接口和逻辑C/S架构则是经过编译完成的二进制文件
{width=”1.968503937007874in” height=”0.38916666666666666in”}
{width=”1.968503937007874in” height=”0.48573490813648296in”}
{width=”1.968503937007874in” height=”1.3176596675415573in”}
{width=”1.968503937007874in” height=”1.6050874890638671in”}
•
{width=”1.968503937007874in” height=”1.8667607174103238in”}
parallel /并行 parallelism即AIO 异步IO ,可以是非阻塞式的
{width=”1.968503937007874in” height=”1.5295505249343833in”}
{width=”1.968503937007874in” height=”1.5213374890638671in”}
• 对比session
{width=”1.968503937007874in” height=”1.6209120734908136in”}
• session本质是一个map且线程安全,支持并发
•
{width=”1.968503937007874in” height=”0.2912817147856518in”}
•
{width=”1.968503937007874in” height=”0.1022594050743657in”}
•
{width=”1.968503937007874in” height=”0.2110411198600175in”}
•
{width=”1.968503937007874in” height=”8.710192475940508e-2in”}
• session使用:
•
{width=”1.968503937007874in” height=”0.26272090988626423in”}
• 以及还有redis使用(服务器端)
• 子主题 1
{width=”1.968503937007874in” height=”1.012840113735783in”}
• 子主题 1
{width=”1.968503937007874in” height=”1.7964173228346456in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.6261373578302712in”}
• 子主题 1
{width=”1.968503937007874in” height=”1.4240244969378828in”}
• 是否不必存在?因为都可以通过后端调用?
{width=”1.968503937007874in” height=”0.17485236220472442in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.8195231846019247in”}
• 子主题 2
{width=”1.968503937007874in” height=”0.20669291338582677in”}
• 子主题 1
{width=”1.968503937007874in” height=”1.271956474190726in”}
对称加密:共享秘钥
非对称加密:1.公钥
• 是否是hash(private key ) 然后得到 pub key?
{width=”1.968503937007874in” height=”1.3869006999125109in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”1.5365660542432196in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.4055282152230971in”}
• 子主题 1
• 1.确定双方身份
• 2.确定线路安全:可以被偷听,但是无法解析即可
• 子主题 3
todohttps://www.youtube.com/watch?v=a-sBfyiXysI&ab_channel=ByteByteGo
• 子主题 1
{width=”1.968503937007874in” height=”0.8489009186351706in”}
• 1
• 每次都要建立连接
{width=”1.968503937007874in” height=”3.137409230096238in”}
• 1.1
• keep-alive 和 pipeline 同样重要的两个特性
{width=”1.968503937007874in” height=”0.7080774278215223in”}
• 子主题 1
{width=”1.968503937007874in” height=”1.0428160542432197in”}
• 子主题 2
{width=”1.968503937007874in” height=”1.3828051181102363in”}
• 子主题 3
{width=”1.968503937007874in” height=”2.2541393263342084in”}
• 2
• 子主题 1
{width=”1.968503937007874in” height=”0.8051531058617672in”}
• 3
• 子主题 1
{width=”1.968503937007874in” height=”1.3624114173228346in”}
• 在设备切换网络即换了IP层网路时,不用反复重建TCP连接
{width=”1.968503937007874in” height=”1.6881321084864391in”}
###
{width=”1.968503937007874in” height=”1.8321423884514436in”}
{width=”1.968503937007874in” height=”0.5005380577427821in”}
###
{width=”1.968503937007874in” height=”3.2484055118110238in”}
###
{width=”1.968503937007874in” height=”2.5272812773403324in”}
{width=”0.23622047244094488in” height=”0.23622047244094488in”}
{width=”1.968503937007874in” height=”0.6723950131233596in”}
{width=”1.968503937007874in” height=”1.5376968503937007in”}
{width=”1.968503937007874in” height=”1.2927952755905512in”}
{width=”1.968503937007874in” height=”1.0637051618547682in”}
{width=”1.968503937007874in” height=”2.3692246281714784in”}
{width=”1.968503937007874in” height=”1.6199726596675414in”}
{width=”1.968503937007874in” height=”2.545136701662292in”}
{width=”1.968503937007874in” height=”0.17833114610673667in”}
{width=”0.23622047244094488in” height=”0.23622047244094488in”}
{width=”1.968503937007874in” height=”0.9630096237970254in”}
{width=”1.968503937007874in” height=”0.5347692475940508in”}
{width=”1.968503937007874in” height=”0.3843821084864392in”}
{width=”1.968503937007874in” height=”0.6037084426946632in”}
###
{width=”1.968503937007874in” height=”1.63253280839895in”}
{width=”1.968503937007874in” height=”1.631596675415573in”}
{width=”1.968503937007874in” height=”0.9864785651793526in”}
{width=”1.968503937007874in” height=”0.9324496937882765in”}
{width=”1.968503937007874in” height=”0.9409492563429571in”}
{width=”1.968503937007874in” height=”0.984251968503937in”}
{width=”1.968503937007874in” height=”0.8746314523184602in”}
{width=”1.968503937007874in” height=”0.8356583552055993in”}
•
{width=”1.968503937007874in” height=”1.5894181977252844in”}
{width=”1.968503937007874in” height=”0.2824015748031496in”}
{width=”1.968503937007874in” height=”1.5603477690288714in”}
•
{width=”1.968503937007874in” height=”0.6244181977252843in”}
{width=”1.968503937007874in” height=”0.398581583552056in”}
你可以把它想象成排水管道中的水流。
{width=”1.968503937007874in” height=”1.2959897200349957in”}
{width=”1.968503937007874in” height=”0.6396751968503936in”}
为什么要三次握手?三次握手的目的是建立可靠的通信信道,说到通讯,简单来说就是数据的发送与接收,
而三次握手最主要的目的就是双方确认自己与对方的发送与接收是正常的。
确认了对方发送正常,自己接收正常第二次握手:Client 确认了:自己发送、接收正常,对方发送、接收正常;Server 确认了:对方发送正常,自己接收正常第三次握手:Client 确认了:自己发送、接收正常,对方发送、接收正常;Server 确认了:自己发送、接收正常,对方发送、接收正常所以三次握手就能确认双方收发功能都正常,缺一不可
C端视角:自己的发送接收是否正常?S端的发送和接收是否正常?
S端视角:自己的发送接收是否正常?C端的发送和接收是否正常?
{width=”1.968503937007874in” height=”0.7535958005249344in”}
{width=”1.968503937007874in” height=”1.9025207786526683in”}
• 超时
{width=”1.968503937007874in” height=”1.8310389326334209in”}
{width=”1.968503937007874in” height=”3.9532097550306213in”}
{width=”1.968503937007874in” height=”1.4582994313210849in”}
NACK: Negative Acknowledgement
ACK
•
{width=”1.968503937007874in” height=”0.5368646106736658in”}
• 滑动窗口
• 即指定变长的传输包组合量
• https://www.bilibili.com/video/BV1c4411d7jb?p=60&spm_id_from=pageDriver&vd_source=d074d0576b6cbd56f8b807d99f34ed18p60
•
{width=”1.968503937007874in” height=”0.9770505249343832in”}
•
{width=”1.968503937007874in” height=”1.0967377515310586in”}
{width=”0.23622047244094488in” height=”0.23622047244094488in”}
###
{width=”1.968503937007874in” height=”1.1767213473315836in”}
###
{width=”1.968503937007874in” height=”2.615774278215223in”}
• 由4个8位bit组成
###
{width=”1.968503937007874in” height=”0.9332874015748032in”}
{width=”1.968503937007874in” height=”1.968503937007874in”}
• goal
• 子主题 1
{width=”1.968503937007874in” height=”0.9308639545056868in”}
• impl
• 子主题 1
{width=”1.968503937007874in” height=”0.8130129046369203in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”0.8645614610673665in”}
• 子主题 3
• 一种是用表的报文.查表然后转发给下个地址一种是更新表的报文.则更新表,然后可能发给下个路由器让他也更新路由表
{width=”1.968503937007874in” height=”0.9896183289588801in”}
• RIP最重要,核心的路径选择权重: 距离最短?容量最大?有时不可兼得所以要根据上层提出的需求选择链路如做FTP选择的路线做UDP实时游戏选择的路线
• 子主题 1
{width=”1.968503937007874in” height=”0.98293416447944in”}
• 子主题 2
• 以链路点数量作为唯一权重
{width=”1.968503937007874in” height=”1.1171828521434821in”}
• 自动负载均衡
{width=”1.968503937007874in” height=”0.9770680227471567in”}
• 子主题 3
• 子主题 1
{width=”1.968503937007874in” height=”0.965323709536308in”}
• 例子
• 子主题 1
{width=”1.968503937007874in” height=”1.0094247594050743in”}
• 子主题 2
{width=”1.968503937007874in” height=”0.7585553368328959in”}
• 子主题 2
{width=”1.968503937007874in” height=”1.0520199037620297in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.8953324584426947in”}
• 子主题 3
{width=”1.968503937007874in” height=”0.7229111986001749in”}
• 子主题 5
{width=”1.968503937007874in” height=”1.0438046806649168in”}
• 子主题 6
{width=”1.968503937007874in” height=”1.110084208223972in”}
• OSPF
• 子主题 1
• 子主题 1
{width=”1.968503937007874in” height=”0.9094149168853893in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”1.0508880139982502in”}
• 子主题 3
• 子主题 1
{width=”1.968503937007874in” height=”1.1642224409448818in”}
• 子主题 4
• 子主题 1
{width=”1.968503937007874in” height=”1.1035553368328959in”}
• beautiful!
• 抽象为图,然后计算加权的最短路径;用来构建路由表
{width=”1.968503937007874in” height=”1.0620669291338583in”}
• 子主题 6
• 子主题 1
{width=”1.968503937007874in” height=”0.9210629921259843in”}
• 子主题 7
• 子主题 1
{width=”1.968503937007874in” height=”0.9266371391076116in”}
• 子主题 8
• 子主题 1
{width=”1.968503937007874in” height=”0.9544258530183727in”}
• BGP
• 把洪泛限制在Area中
• 子主题 1
{width=”1.968503937007874in” height=”0.9378357392825897in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”0.8695374015748032in”}
• 子主题 3
• zzz
{width=”1.968503937007874in” height=”0.8508114610673666in”}
• 子主题 4
• 子主题 1
{width=”1.968503937007874in” height=”0.5215496500437445in”}
• 子主题 5
• 子主题 1
{width=”1.968503937007874in” height=”1.2328521434820647in”}
• IPv4数据报格式简称ip数据报
• 子主题 1
• 子主题 1
{width=”1.968503937007874in” height=”1.2583869203849518in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.6410214348206474in”}
• 子主题 2
{width=”1.968503937007874in” height=”0.4962849956255468in”}
• 为什么DF位不在MF位前面.要先能分片,再考虑MF分片情况呀!
{width=”1.968503937007874in” height=”0.4843558617672791in”}
• 直接整成无限大.污染整个网络.当然不可能.有检查最大数机制的哈哈
{width=”1.968503937007874in” height=”0.41720581802274714in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.9412718722659668in”}
• 子主题 5
{width=”1.968503937007874in” height=”0.6309820647419072in”}
• 子主题 1
• 子主题 6
{width=”1.968503937007874in” height=”0.4968066491688539in”}
• 子主题 7
{width=”1.968503937007874in” height=”0.18202318460192476in”}
• 分片例子
• 子主题 1
{width=”1.968503937007874in” height=”0.995323709536308in”}
• 子主题 2
{width=”1.968503937007874in” height=”0.9944991251093613in”}
• ICMPInternet Control Message Protocol
• 子主题 6
• 子主题 3
• 子主题 1
{width=”1.968503937007874in” height=”0.8098928258967629in”}
• 子主题 4
• 也可能是H2满了
{width=”1.968503937007874in” height=”0.7942180664916886in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.9211187664041994in”}
• 子主题 5
• 子主题 1
{width=”1.968503937007874in” height=”0.832069116360455in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.8001618547681539in”}
• 子主题 1
• 子主题 1
{width=”1.968503937007874in” height=”0.8200382764654418in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”0.8281430446194226in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”0.6001115485564305in”}
• app
• 子主题 1
• 子主题 1
{width=”1.968503937007874in” height=”0.9459317585301837in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”0.957846675415573in”}
• 子主题 1
{width=”1.968503937007874in” height=”1.1659919072615923in”}
• 原理.设置1到X的TTL来获取路径上面的每一个路由器
• 子主题 1
{width=”1.968503937007874in” height=”0.8652766841644794in”}
• 子主题 2
{width=”1.968503937007874in” height=”0.9467410323709536in”}
• 子主题 4
{width=”1.968503937007874in” height=”1.066003937007874in”}
• VPN
• 子主题 1
• 子主题 1
{width=”1.968503937007874in” height=”1.0348764216972879in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.9958792650918635in”}
• 子主题 2
• 子主题 1
{width=”1.968503937007874in” height=”1.0301706036745406in”}
• 子主题 1
{width=”1.968503937007874in” height=”0.9678937007874016in”}
• 子主题 3
• 子主题 1
• NAT
• 早期用的网关.现代采用路由 术语
{width=”1.968503937007874in” height=”0.6372211286089239in”}
###
{width=”1.968503937007874in” height=”0.9383912948381452in”}
{width=”1.968503937007874in” height=”1.921634951881015in”}
•
{width=”1.968503937007874in” height=”0.2703357392825897in”}
{width=”1.968503937007874in” height=”1.1037281277340332in”}
{width=”1.968503937007874in” height=”1.162742782152231in”}
{width=”1.6633858267716535in” height=”0.7874015748031497in”}
•
{width=”1.1811023622047243in” height=”0.8366141732283464in”}
###
{width=”1.968503937007874in” height=”0.9069903762029746in”}
###
{width=”1.968503937007874in” height=”0.44291338582677164in”}
###
{width=”1.968503937007874in” height=”0.942843394575678in”}
{width=”0.23622047244094488in” height=”0.23622047244094488in”}
{width=”0.23622047244094488in” height=”0.23622047244094488in”}
{width=”0.23622047244094488in” height=”0.23622047244094488in”}
Descartes Scientific Methodology
Why: Some app is doing unnecessary things or even steal privacy. Monitoring user behaviour: sensitive io files,sensitive upload user privacy file. addin...
ref: https://space.bilibili.com/4848323
Bugs to fix:
What is Software Architect
epub here: 点击下载认知天性
rpc local procedure call to rpc
区块链:
最近读书收获的Take Home Message(better into 4 mem-chunks ) : 非技术类书籍 最喜欢的序:序二 心流人生:一曲冰与火之歌 心熵:心中的信息熵状态: 混乱的时候: 潜意识里,却有多得多的念头在相互冲突,在争夺 你的注意力,在抢夺你大脑的控制权...
Java
业务驱动开发,驱动学习
bytecode 字节码
注册中心的Take Home Message
Computer Network
每日的计划和执行: 搜集所有todo 排序重要和紧急程度 ![[ Eisenhower_matrix.png]] 执行 分配时间片: Schedule time for things that normally distract you. Balance your work and leisur...
The Pragmatic Programmer
Descartes’ scientific methodology, which is a useful way to approach complex problems and seek the truth. However, I understand that sometimes you may encoun...
url: https://youtu.be/DxL2HoqLbyA
“你好同志!请问列宁格勒与斯大林格勒在哪里?我在地图上找不到了” “不会再有了,同志,白匪和资本家重新骑到了我们头上,工人被赶回了工厂,农民被重新戴上了镣铐” “不落的红旗终究也要…” “同志!去东方吧!跨过那第聂伯河!翻过那乌拉尔山!在那遥远的契丹,还有那一丝红星的微光尚存”
年轻永远是最宝贵的财富
Welcome