December 22th Tuesday 2009

来源:互联网 发布:golang http 反向代理 编辑:程序博客网 时间:2024/06/14 00:41

    In nginx, during parsing the configure file the function ngx_mail_block() is called.  The function ngx_mail_block() allocate buffer for main configure information and server configure information.  At one time the create_main_conf() and the create_srv_conf() hooks in all mail module are invoked.  And so on, the init_main_conf() and the merge_srv_conf() are both called.  At the end of the function ngx_mail_block(), ngx_mail_optimize_servers() is called.

 

   In the function ngx_mail_optimize_servers(), the following code is so important.

 

            ...

            ls = ngx_create_listening(cf, addr[i].sockaddr, addr[i].socklen);
            if (ls == NULL) {
                return NGX_CONF_ERROR;
            }

            ls->addr_ntop = 1;
            ls->handler = ngx_mail_init_connection;
            ls->pool_size = 256;

            ...

 

   The ngx_mail_init_connection() is set.  OK.  The function ngx_mail_init_connection() is started for a connection.

 

   The above is for the mail module.  The http module is similar to it.

原创粉丝点击
热门问题 老师的惩罚 人脸识别 我在镇武司摸鱼那些年 重生之率土为王 我在大康的咸鱼生活 盘龙之生命进化 天生仙种 凡人之先天五行 春回大明朝 姑娘不必设防,我是瞎子 qq空间无法回复怎么办 入职年龄不够怎么办 鱼生病了怎么办 急救 打错电话怎么办 礼仪 脚脱皮有臭味怎么办 想做淘宝手模怎么办 办模特卡被骗怎么办 上菜时台面已摆满菜怎么办 幼儿园发现疑似水痘怎么办 幼儿园孩子长水痘怎么办 穿高跟鞋大腿疼怎么办 穿高跟鞋走路难看怎么办 小妙招鞋跟响怎么办 高跟鞋子大了怎么办 高跟鞋走路很响怎么办 小妙招鞋后跟响怎么办 高跟鞋后面磨脚怎么办 穿高跟鞋崴着脚了怎么办 亚麻裤缩水了怎么办 怎么办一个人保定损点 淘宝遇到职业敲诈怎么办 三无燕窝被打假怎么办 碰上职业打假的怎么办 遇到专业打假的怎么办 手机wifi被劫持怎么办 手机网页乱跳怎么办 老公说话不算话怎么办 编曲接不到活怎么办 电表显示跳闸黄灯怎么办 硫酸铬钾中毒怎么办 门锁能扭动却打不开怎么办 防盗门保险坏了怎么办 厦门工会卡过期怎么办 阴雨天被子受潮怎么办 衣服晾臭了怎么办 喷砂机油水分离泵有油怎么办 水太烫玻璃瓶盖打不开怎么办 玻璃罐的玻璃盖打不开怎么办? 开红酒没有开瓶器怎么办 手机卡突然坏了怎么办 滚筒洗衣机打不开门怎么办