Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove $Changed from logical flow of emitter #1394

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Commits on Nov 13, 2024

  1. Remove $Changed from logical flow of emitter

    Previously we were providing the ActionContext of the emitter to $Changed handlers.  The transaction was destroyed in this case so was not really useful.  Now we instead just provide metadata about the subject that triggered the change.
    
    Also, the emitter was awaiting $Changed handlers if they were async.  There are advantages and disadvantages to doing this:
    
    * Advantage is that the logical flow is more deterministic and we track the promise as a normal part of node activity
    * The disadvantage is that the emitter blocks until an independent process completes
    
    This commit makes it so $Changed handlers operate independently of the emitter.  Tests pass but effects will be subtle so will need to keep an eye on this.
    lauckhart committed Nov 13, 2024
    Configuration menu
    Copy the full SHA
    b298fdb View commit details
    Browse the repository at this point in the history
  2. Rewrite AccessControlServer event triggering

    Untested as yet
    lauckhart committed Nov 13, 2024
    Configuration menu
    Copy the full SHA
    9375f6c View commit details
    Browse the repository at this point in the history