RSS ChinarenWei's shared items in Google Reader
哪吒推荐该订阅
原站:http://www.google.com/reader/shared/weizhonghua.ati
点击立即订阅,“ChinarenWei's shared ...”的内容有更新,哪吒第一时间提醒您
“ChinarenWei's shared items in Google Reader”的内容更新
累计:22 篇(自 2011-02-11 起)
更新:约1篇/月,最后更新305 天前
ChinarenWei's shared items in Google Reader
问题背景web 上,凡是有价值的接口页面、接口,在利益的驱动下,总有被犯罪分子刷的可能;对方少数几个 ip 还好说,直接封 ip 了事,要是人家有肉鸡,有几千几万的 pc 资源,源源不断,封 ip 即便是自动检测自动封 ip 仍然是显的乏力,被欺负心里很不爽。解决办法其实很简单,在处理每个请求前,先检测下这个 ip 是否是恶意攻击的 ip,如果是直接返回个不知所云的页面给对方就好了。要... (305 天前)
ChinarenWei's shared items in Google Reader
摘自 wiki 上 malloc 页: http://en.wikipedia.org/wiki/malloc#implementationssince the v2.3 release, the gnu c library (glibc) uses a modified ptmalloc2, which itself is based on dlmalloc v2.7.0.本来还担心内存碎片问题,要选择一个好的内存分配器,现在不用了。... (406 天前)
ChinarenWei's shared items in Google Reader
非常普通的 hash 算法,无特别之处。如何解决 hash 冲突hash table 的每一个 entry 是一个链表,hash 值相同的 entry 放在这个链表内;查询时,先用 hash key 定位到链表头,然后遍历这个链表执行查找或者插入操作。hash 表扩容方案1) 新 hash table size 的计算每次执行 add entry 操作时,先进行 hash 表的扩容检测,算法如下: /* if we reached the 1:1 ratio, and we are allo... (406 天前)
ChinarenWei's shared items in Google Reader
locations 数据结构及初始化1) 先看看 ngx_http_core_loc_conf_t 这个结构体 struct ngx_http_core_loc_conf_s { ??? // location 名称 ??? ngx_str_t???? name; ??? // 如果是 re location,这里存储 re 信息??? #if (ngx_pcre) ??? ngx_http_regex_t? *regex; #endif ??? //... ??? ??? // 是否是精确匹配 location =xxx ??? unsigned????? exact_match:1; ??? unsigned?????... (406 天前)
ChinarenWei's shared items in Google Reader
本文主要分析从upstream 读取数据、数据报文解析和向客户端输出这三部分功能。 从 upstream 读取的 fastcgi 报文主要有三种:upstream 处理正常的话,返回 fcgi_stdout 报文有错误,则返回 fastcgi_stderr? 报文。结尾会有个 fcgi_end_request 报文将 upstream 请求报文发送出去后,nginx 会随即绑定 read event,等待处理 upstream 的返回。 u->read_event_handler = ngx_http_up... (406 天前)
ChinarenWei's shared items in Google Reader
英国某小镇。有一个青年人,整日以沿街为小镇的人说唱为生;这儿,有一个华人妇女,远离家人,在这儿打工。他们总是在同一个小餐馆用餐,于是他们屡屡相遇。时间长了,彼此已十分的熟悉。有一日,我们的女同胞,关切地对那个小伙子说:“不要沿街卖唱了,去做一个正当的职业吧。我介绍你到中国去教书,在那儿,你完全可以拿到比你现在高得多的薪水。” 小伙子听后,先是一愣,然后反... (406 天前)
ChinarenWei's shared items in Google Reader
给自己找了很多理由尽量减少在电脑前看电子书的时间,保护眼睛。4g 空间,可以装大量电子书,随时想看都行,移动图书馆。很多内容没实体书,或者有免费的电子版。不买书,不用花钱还环保,多好。原生支持中文,内置浏览器,偶尔用它来看下新闻,屏幕比手机大,呵呵。有这玩意的人少,装下字母挺管用。咱今天不谈不败的理由。最后来个杀手锏,挨踢人士怎么能没有 kindle 呢?于是,下狠... (406 天前)
相关订阅源