目录背景代码实现测试背景 最近在学习Redis,想到了之前的写的一个案例demo,实现了接口的流量防刷。主要是为了防止爬虫爬取接口,当然可以适用于那些需要进行流控的系统,shigen画了一张草图展示主要的原理和过程:
i\'ve got 3 Log classes that all implements iLog interface: DatabaseLog FileLog ScreenLog there can only be one instance of them. initially i though of using single pattern for each class but then