src/server/daemon/threadpools.c

changeset 67
50505dc3f8a6
parent 44
3da1f7b6847f
child 77
f1cff81e425a
equal deleted inserted replaced
66:74babc0082b7 67:50505dc3f8a6
51 threadpool_t *pool = ucx_map_sstr_get(thread_pool_map, name); 51 threadpool_t *pool = ucx_map_sstr_get(thread_pool_map, name);
52 if(pool) { 52 if(pool) {
53 /* TODO: reconfig thread pool */ 53 /* TODO: reconfig thread pool */
54 return 0; 54 return 0;
55 } else { 55 } else {
56 threadpool_t *tp = threadpool_new(cfg->min_threads); 56 threadpool_t *tp = threadpool_new(cfg->min_threads, cfg->max_threads);
57 57
58 int ret = ucx_map_sstr_put(thread_pool_map, name, tp); 58 int ret = ucx_map_sstr_put(thread_pool_map, name, tp);
59 59
60 if(ret == 0) { 60 if(ret == 0) {
61 numthrpools++; 61 numthrpools++;

mercurial