#842

Add mechanism to let supervisor react to restart in custom fashion

    • Created on: Fri, May 06 2011 (about 1 year ago)
    • Reported by: rkuhn
    • Assigned to: viktorklang
    • Milestone: 2.0-M1
    • Status: Fixed
    • Priority: Normal (3)
    • Component: actor
    • Estimate: None/Small/Medium/Large None
    Currently the Exit message is swallowed by self.handleTrapExit, which is not customizable beyond OneForOne or AllForOne strategies. It would be quite useful to add a hook/message so that the actual supervisor actor gets a chance to run some code in response to a restart.

    Update

    Add lifecycle observer functionality, e.g. actorA observe actorB, which will notify actorA of start/restart/stop of actorB. Supervisors should directly receive the restart notification after handling the Exit message, if they are also observers.

    It might make sense to implicitly make supervisors also lifecycle observers, but then it should not be an error if they do not handle the corresponding messages, otherwise we break too much code.
  • Followers
     
    Ico-users viktorklang (Assigned To) , Peter Vlugter , rkuhn 
     
    Attachments
    No attachments
    Associations
     
    No associations
    Activity
     
    User picture

          on Jun 05, 2011 @ 08:07am UTC * By rkuhn

    Milestone changed from 1.2 to 2.0
    Viktor said: “I want 0..1 supervisors and 0..n lifecycle observers on an Actor”. This would certainly solve this problem, but is rather 2.0 material.
    User picture

          on Jul 05, 2011 @ 10:13am UTC * By rkuhn

    Component changed from None to actor
    Description changed from Currently the Exit message ... to Currently the Exit message ...
    User picture

          on Oct 04, 2011 @ 06:51am UTC * By viktorklang

    Assigned to changed from rkuhn to viktorklang
    Status changed from New to Fixed
    User picture

          on Dec 14, 2011 @ 09:52pm UTC * By viktorklang

    Milestone changed from 2.0 to 2.0-M1
    Time Expenditure
    Loading