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 Hyrax::Actors::TransactionalRequest from default middleware #3482

Merged
merged 1 commit into from
Jan 29, 2019

Conversation

no-reply
Copy link
Contributor

The actor stack involves writing to several diffrent persistence layers; at
least:

  • ActiveRecord
  • ActiveFedora (Fedora/Solr)
  • ActiveJob

The transactionality provided by Hyrax::Actors::TransactionalRequest addresses
only one of these (ActiveRecord). Routinely, failures in the actor stack that
trigger transaction rollback there lead to broken states across the various data
stores.

Additionally, this rollback is not triggered for the main documented failure API
for the stack (returning false). Rollback only happens when uncaught errors
are propagated to the top of the stack.

Since this middleware is problematic and doesn't have a clear documented use
case, this proposes its removal.

Fixes #3128.

@samvera/hyrax-code-reviewers

The actor stack involves writing to several diffrent persistence layers; at
least:

  - ActiveRecord
  - ActiveFedora (Fedora/Solr)
  - ActiveJob

The transactionality provided by `Hyrax::Actors::TransactionalRequest` addresses
only one of these (ActiveRecord). Routinely, failures in the actor stack that
trigger transaction rollback there lead to broken states across the various data
stores.

Additionally, this rollback is not triggered for the main documented failure API
for the stack (returning `false`). Rollback only happens when uncaught errors
are propagated to the top of the stack.

Since this middleware is problematic and doesn't have a clear documented use
case, this proposes its removal.

Fixes #3128.
@jeremyf jeremyf merged commit 355770a into master Jan 29, 2019
@jeremyf jeremyf deleted the never-rollback-actor-stack branch January 29, 2019 14:39
cjcolvar added a commit that referenced this pull request Feb 13, 2019
cjcolvar added a commit that referenced this pull request Feb 18, 2019
no-reply pushed a commit that referenced this pull request Feb 20, 2019
no-reply pushed a commit that referenced this pull request Mar 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants