1. IOC容器的初始化过程:IOC容器的初始化由refresh()方法启动,这个启动包括:BeanDifinition的Resource定位,加载和注册三个过程。初始化的过程不包含Bean依赖注入的实现。 第一个过程是Resource的定位过程。这个Resource的定位指的是BeanDefini ...
分类:
编程语言 时间:
2017-10-15 17:40:24
阅读次数:
265
项目中使用Redis来记录用户的上线和下线信息,其中用到了集合(sets)类型,某用户上线时,向sets中添加数据,下线时将相应数据从sets中删除,考虑当该用户的所有实例都下线时,需要将sets删除。 因为是并发操作,就考虑到判断为空后进行删除操作的原子性,查了一堆资料,都已经写好了相应的lua脚 ...
分类:
其他好文 时间:
2017-10-13 12:27:25
阅读次数:
1498
1.首先我们需要了解什么是apns auth key,下面是官方的描述 Use the Apple Push Notification service for your notification requests. One key is used for all of your apps.(使用苹果 ...
分类:
其他好文 时间:
2017-10-10 16:45:08
阅读次数:
212
一、Benchmark简介Benchmark是一个评价方式,在整个计算机领域有着长期的应用。正如维基百科上的解释“As computer architecture advanced, it became more difficult to compare the performance of var ...
分类:
其他好文 时间:
2017-10-09 20:58:52
阅读次数:
194
Air Raid Consider a town where all the streets are one-way and each street leads from one intersection to another. It is also known that starting from ...
分类:
其他好文 时间:
2017-10-06 10:36:08
阅读次数:
229
1 def pk(ref, hyp, k=None, boundary='1'): 2 """ 3 Compute the Pk metric for a pair of segmentations A segmentation 4 is any sequence over a vocabulary ...
分类:
其他好文 时间:
2017-10-03 21:35:30
阅读次数:
266
1086. Tree Traversals Again (25) 时间限制 200 ms 内存限制 65536 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue 时间限制 200 ms 时间限制 200 ms 内存限制 65536 kB 内存限制 65536 ...
分类:
其他好文 时间:
2017-10-03 18:35:44
阅读次数:
231
1006. Sign In and Sign Out (25) 时间限制 400 ms 内存限制 65536 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue 时间限制 400 ms 时间限制 400 ms 内存限制 65536 kB 内存限制 65536 k ...
分类:
其他好文 时间:
2017-10-03 16:55:57
阅读次数:
155
Variables As Properties When you declare a global JavaScript variable, what you are actually doing is defining a property of the global object . If yo ...
分类:
Web程序 时间:
2017-09-29 16:29:31
阅读次数:
227
首先是线上出现了连接池满的异常 项目采用mysql+spring+hibernate,spring的事务配置如下: 后有同事发现一个定时脚本里直接调了dao而不是service导致spring的事务管理没起作用,这个定时脚本每3分钟跑一次,执行的是update语句,结果把连接池的资源都耗光了,后改成 ...
分类:
数据库 时间:
2017-09-27 19:05:18
阅读次数:
556