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

Bump concurrency of the transition events #966

Merged
merged 1 commit into from Sep 5, 2018

Conversation

Projects
None yet
2 participants
@mjangda
Member

mjangda commented Sep 5, 2018

With lots of publishing activity on a site, we can end up with a backlog. Enabling some concurrency allows that to be cleared a bit faster.

Main caveat is that the events are no longer atomic and anything relying on post state should check the current value in the event callback.

Related #964

Checklist

  • This change works and has been tested locally (or has an appropriate fallback).
  • This change works and has been tested on a Go sandbox.
  • This change has relevant unit tests (if applicable).
  • This change has relevant documentation additions / updates (if applicable).

Steps to Test

n/a

Bump concurrency of the transition events.
With lots of publishing activity on a site, we can end up with a
backlog. Enabling some concurrency allows that to be cleared a bit
faster.

@mjangda mjangda requested review from mdbitz, pkevan and emrikol Sep 5, 2018

@mjangda

This comment has been minimized.

Member

mjangda commented Sep 5, 2018

Main caveat is that the events are no longer atomic and anything relying on post state should check the current value in the event callback.

Docs have been updated to prepare for this: https://vip.wordpress.com/documentation/vip-go/asynchronous-publishing-actions-on-vip-go/#caveats

@emrikol

emrikol approved these changes Sep 5, 2018

Looks good to me! The code looks pretty simple. Do you think we would ever need this as a dedicated function, rather than an anonymous function?

@mjangda

This comment has been minimized.

Member

mjangda commented Sep 5, 2018

Do you think we would ever need this as a dedicated function, rather than an anonymous function?

If we do, we can switch it up pretty easily.

@mjangda mjangda merged commit 2d4ca5b into master Sep 5, 2018

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@mjangda mjangda deleted the update/async-transition-concurrency branch Sep 5, 2018

@mjangda

This comment has been minimized.

Member

mjangda commented Sep 5, 2018

r117733-deploy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment