#24 Pool_handling process & collection child IPC ( #20 #22 )

已关闭
yannweb4 年前创建 · 2 条评论
yannweb 评论于 4 年前

Two solutions :

  1. if no other data than a worker counter a simple pipe with Pool_handling sending the counter when it changes

  2. if more data to be shared/inspected by collection child shared memory seems to be the solution

Two solutions : 1. if no other data than a worker counter a simple pipe with Pool_handling sending the counter when it changes 2. if more data to be shared/inspected by collection child shared memory seems to be the solution
yannweb 4 年前 添加了里程碑 BETA version
yannweb 添加了标签
enhancement
4 年前
yannweb 添加了标签
question
4 年前
yannweb 添加了标签
_core
4 年前
yannweb 评论于 4 年前
所有者

The shared memory solution is the more extensible one. But it implies synchronization mechanism. The pool handling proc can update shared memory at each loop, and the collection process can read them using a POSIX timer.

An elegant one should have been to make collection child to SIGSTOP the pool handler pro, to read the data and then, to SIGCONT the pool handler proc. But in this case the pool handler loop will have to deal with EINTR failures….

A simplest solution is to use a semaphore and locking the data when accessing them.

The shared memory solution is the more extensible one. But it implies synchronization mechanism. The pool handling proc can update shared memory at each loop, and the collection process can read them using a POSIX timer. An elegant one should have been to make collection child to SIGSTOP the pool handler pro, to read the data and then, to SIGCONT the pool handler proc. But in this case the pool handler loop will have to deal with EINTR failures.... A simplest solution is to use a semaphore and locking the data when accessing them.
yannweb 开始工作 4 年前
yannweb 取消时间跟踪 4 年前
yannweb4 年前 指派给自己
yannweb 开始工作 4 年前
yannweb 停止工作 4 年前
1h 17min 44s
"yannweb 添加了新的依赖项 4 年前"
"yannweb 添加了新的依赖项 4 年前"
yannweb 添加耗时 4 年前
1h
yannweb 评论于 4 年前
所有者

closed by b3af92459e

closed by b3af92459e
yannweb4 年前 关闭
登陆 并参与到对话中。
未选择里程碑
未指派成员
1 名参与者
总花费时间:2h 17min 44s
Yann Weber
2h 17min 44s
到期时间

未设置到期时间。

正在加载...
取消
保存
这个人很懒,什么都没留下。