Nginx中fastcgi_pass直接写unix和使用upstream

2017-03-26 21:48:47

[服务器开发] , ,

这两天虽然很忙,但是由于某些情况需要折腾一个反向代理服务器。解决了我一个困扰了很久的问题——为什么nginx不能检测后面php-fpm或者hhvm运行的状态;如果php-fpm或者hhvm挂了为什么nginx的fastcgi_cache_use_stale的参数不起作用?

我一直想当php-fpm或者hhvm挂掉的时候nginx能够提供cache的旧页面,但是fastcgi_cache_use_stale的参数似乎不起作用,今天仔细地读了一个nginx的文档。为了实现这个目的,我们需要用的是fastcgi_cache_use_stale 中 error这个参数,然而error这个参数的说明中提到了一句话

EECS3214 Computer Network Protocols and Applications

2017-01-10 9:49:23

[专业笔记] , , ,

This course includes TCP/IP architecture. 这是一门有关网络的基础课程,主要涉及Layer3-5。

This course introduce very fundamental network knowledges. It covers some old technology but that is very critical.

We will study the TCP/IP protocol through out the whole course. Advance topics includes P2P system, multimedia communication (VoIP), network security(IPSec SSL), wireless sensor networks. Top-down approach. Start from top(Application) to bot(Network). More algorithmic. More programming.

Simple core, but complex edges.

EECS2011 Fundamentals of Data Structures

2016-12-08 17:22:52

[专业笔记] , , ,

数据结构课程,其实用Java而不是用C / PASCAL来讲让我有点不太适应。

This content is for YorkU EECS 2011. As usual, I will post some "interesting" course note. This course is not that difficult. And our prof's ppt is so nice. Try not to miss any lecture and you will learn a lot from him. My professor is Andy Mirzaian.

 

CloudKit开发手记——队列管理

2016-12-07 15:02:25

[App开发] , , , ,

网上现在大部分的教程(包括苹果官方的CloudKit Quick Start)讲述的都是一种简易的方法(convience methods),我这里将要讲述的是如何有效使用队列进行数据库操作,使得操作更加有效规范可控。

 

EECS2031 Software Tools

2016-09-12 14:44:06

[专业笔记] , , ,

This course introduces very very fundamental C/shell programming skills on linux.

We are using C89 standard in this  EECS 2031 course. That means you cannot declare the iterator variable in a for loop. And you should be very careful when you are trying to copy any C code from Google or Stack Overflow. Because those code fragments might be written in C with C99 standard or Cpp. Professor is very nice but TAs are not that efficient. We have to wait a long time for the grading.

EECS2030 Advanced Object Oriented Programming

2016-06-11 23:24:31

[专业笔记] , ,

EECS2030课程的笔记

This content is for YorkU EECS 2030. I took this course in summer 2016. My professor Navid Mohaghegh is a very nice professor. I do strongly recommend his course.

 

定制XCode的UI控件

2016-05-17 14:54:16

[App开发] , , ,

有时候我们需要一些深度定制的并且多次多次复用的UI控件,为了模块化程序,在iOS8 及以后,我们可以将常用的定制UI控件放到自己的Kit里面,在不同的项目中重复使用。

本文主要记录怎样定制UI控件

 

CloudKit 开发手记——读写查询

2016-04-21 14:25:11

[App开发] , , , ,

服务器还是很有维护成本,对于小团队来说,不可能将各种。用AppStore进行分发,其实就是将销售方面交由Apple管理;换而言之,如果是用CloudKit进行开发,可以理解是将后端的也交由Apple管理。Apple为小团队们节省了很多不必要的开支。关于CloudKit网上有很多翻译苹果提供的最新文档,但是个人总感觉那些人并没有理解就进行翻译(Markdown程序员?),根本没有什么用。这篇文章是基于原版的英文文档,以及2014和2015年WWDC的视频整理而成的。

本篇文章不适合初心者,并不会升面试效果。