码迷,mamicode.com
首页 >  
搜索关键字:thread safe    ( 15119个结果
Effective Java 66 Synchronize access to shared mutable data
When multiple threads share mutable data, each thread that reads or writes the data must perform synchronization. Without synchronization, there is no...
分类:数据库   时间:2014-05-01 09:14:25    阅读次数:506
mysql 限制并发select patch
限制并发select的patch,代码量很少,主要是为了学习mysql的源码,yy一下。增加两个全局控制变量: thread_limit_min thread_limit_max增加一个条件变量: COND_thread_running_limit增加一个新的错误码: concurr...
分类:数据库   时间:2014-05-01 07:14:13    阅读次数:576
Memcached source code analysis (threading model)--reference
Look under the start memcahcedthreadingprocessmemcached multi-threaded mainly by instantiating multiple libevent, are a main thread and n workers thre...
分类:其他好文   时间:2014-05-01 06:15:27    阅读次数:356
Memcached source code analysis -- Analysis of change of state--reference
This article mainly introduces the process of Memcached, libevent structure of the main thread and worker thread based on the processing of the connec...
分类:其他好文   时间:2014-05-01 02:44:07    阅读次数:571
在Windows系统上实现轻量级的线程间及进程间消息队列
Windows没有message queue累世的IPC内核对象,使得在在处理IPC时少了一种传递消息的手段。利用Windows的Naming Object可以实现一套简单的Inter-Thread消息队列。这里并不使用socket,因为一旦使用socket,就得负责port管理,很麻烦,另外在对外...
分类:编程语言   时间:2014-05-01 02:30:44    阅读次数:555
FFMPEG + SDL音频播放分析
目录[hide]1抽象流程:2关键实现:2.1main()函数2.2decode_thread()读取文件信息和音频包2.3stream_component_open():设置音频参数和打开设备2.4audio_callback(): 回调函数,向SDL缓冲区填充数据2.5audio_decode_...
分类:其他好文   时间:2014-05-01 00:48:04    阅读次数:325
C# 线程
//创建1个线程对象 并为这个线程对象指定要执行的方法.             Thread thread = new Thread(TestThread);             //设置线程为后台线程.             thread.IsBackground = true;             //开启线程             thread.Start();  ...
分类:编程语言   时间:2014-04-29 13:32:23    阅读次数:363
进程与线程的一个简单解释
进程(process)和线程(thread)是操作系统的基本概念,但是它们比较抽象,不容易掌握。 最近,我读到一篇材料,发现有一个很好的类比,可以把它们解释地清晰易懂。 1. 计算机的核心是CPU,它承担了所有的计算任务。它就像一座工厂,时刻在运行。 2. 假定工厂的电力有限,一次只能供给一个车间使用。也就是说,一个车间开工的时候,其他车间都必须停工。...
分类:编程语言   时间:2014-04-29 13:17:20    阅读次数:276
org.hibernate.HibernateException: No Hibernate Session bound to thread, and configuration does not
org.hibernate.HibernateException: No Hibernate Session bound to thread, and configuration does not...
分类:系统相关   时间:2014-04-29 13:15:20    阅读次数:411
分布式数据库中间件–(2) Cobar与客户端的握手认证
Cobar启动完成,监听特定端口。整个认证的流程图:NIOAcceptor类继承自Thread类,该类的对象会以线程的方式运行,进行连接的监听。NIOAcceptor启动的初始化过程如下:1 、打开一个selector,获取一个ServerSocketChannel对象,对该对象的socket绑定特定的监听端口,并设置该channel为非阻塞模式,然后想selector注册该channel,绑定感...
分类:数据库   时间:2014-04-27 21:47:07    阅读次数:462
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!