Opened 7 years ago

Closed 6 years ago

#4356 enhancement closed fixed (fixed)

Add a ProcessMonitor plugin for twistd

Reported by: rwall Owned by:
Priority: normal Milestone:
Component: runner Keywords:
Cc: Branch: branches/procmon-plugin-4365
branch-diff, diff-cov, branch-cov, buildbot
Author: rwall


It would be useful to be able to launch t.r.procmon.ProcessMonitor from the command line as a simple way to monitor and automatically restart another (unreliable) process. eg

twistd procmon squid -N

A plugin would also provide a nice example of procmon use and replace the ugly main function currently at the bottom of the module.

Attachments (1)

procmon-plugin-4365.1.patch (6.4 KB) - added by rwall 6 years ago.
A procmon plugin and tests.

Download all attachments as: .zip

Change History (8)

Changed 6 years ago by rwall

A procmon plugin and tests.

comment:1 Changed 6 years ago by rwall

  • Author set to rwall
  • Keywords review added
  • Owner rwall deleted

Ready for review in attachment:procmon-plugin-4365.1.patch

  • NB this patch is against source:branches/parameterize-procmon-3775-2

comment:2 Changed 6 years ago by rwall

Looks like this isn't a new idea. Tv added a ProcMon plugin in 2003 which was later removed by moshez:

comment:3 Changed 6 years ago by glyph

Applied patch to a branch so we can see build results.

comment:4 Changed 6 years ago by glyph

  • Branch set to branches/procmon-plugin-4365

Gave the branch the wrong number, unfortunately. I'll fix it if I merge forward.

comment:5 Changed 6 years ago by cyli

  • Keywords review removed
  • Owner set to cyli

The tests pass, and running twistd procmon sleep 10 works - sleep 10 is restarted over and over.

Made two small changes:

  1. Gave t.r.test.test_procmontap.ProcessMonitorTapTest a class (unittest.TestCase) level docstring.
  2. Reflowed some of the text in's and's lines wrapped to 79 columns. Also put in extra newlines so that has the right number of newlines between methods/class and methods.

comment:6 Changed 6 years ago by cyli

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

(In [29212]) Merge procmon-plugin-4365: Add a ProcessMonitor plugin for twistd

Author: rwall Reviewer: cyli Fixes: #4356

Added a twistd plugin to launch twisted.runner.procmon.ProcessMonitor from the command line.

comment:7 Changed 6 years ago by <automation>

  • Owner cyli deleted
Note: See TracTickets for help on using tickets.