Opened 9 years ago

Closed 9 years ago

#300 closed enhancement (fixed)

Bind10: create one process list and use it to kill all processes in that list

Reported by: zhanglikun Owned by: UnAssigned
Priority: medium Milestone:
Component: ~Boss of BIND (obsolete) Version:
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity:
Sub-Project: Feature Depending on Ticket:
Estimated Difficulty: 0.0 Add Hours to Ticket: 0
Total Hours: 1.0 Internal?: no


The following comment was copied from ticket #289, which was inputted by stephen.

Remark: the section around this change (lines 350 - 430) start the processes in sequence. If there is a problem, all previous processes are killed via an explicit set of xxx.process.kill() statements. So adding a new process into the list means modifying code further down the module to make sure it is killed if a subsequent process fails to start. As each process starts, can't it be added to a list and a single function defined to kill all processes in that list?


Change History (5)

comment:1 Changed 9 years ago by zhanglikun

  • Add Hours to Ticket changed from 0.0 to 1.0
  • Total Hours changed from 0.0 to 1.0

comment:2 Changed 9 years ago by vorner

  • Owner set to vorner
  • Status changed from new to accepted

comment:3 Changed 9 years ago by vorner

  • Owner changed from vorner to UnAssigned
  • Status changed from accepted to reviewing

I created a rollback transaction and put it into library, because it seemed to me this kind of thing might be useful somewhere else as well and it wasn't much more work. I let BoB use that to kill the processes.

The transaction has tests, but the code in BoB didn't have them before and I do not see a reasonable way to test it automatically, as it starts many processes and we would need to make them fail in the fork or somewhere there. Do you think it is a problem? Any idea how it could be tested? I tested that functionality manually at last.

The changes are in branches/trac300, branch point is r3075, head is r3092.

The suggested changelog:

[func]             Michal Vaner
Implemented a rollback transaction - simple list of cleanup actions that is run
in case of exception. Used in BoB to kill processes if there's error on startup.

comment:4 Changed 9 years ago by jelte

is this still a separate thing or is this part of #412 now?

comment:5 Changed 9 years ago by stephen

  • Resolution set to fixed
  • Status changed from reviewing to closed

This was included as part of #412, which was added to the trunk in r3676.

Note: See TracTickets for help on using tickets.