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

[5.4] roll back to a given transaction level (savepoint) #15876

Merged
merged 1 commit into from Oct 13, 2016

Conversation

halaei
Copy link
Contributor

@halaei halaei commented Oct 12, 2016

  • DB::rollBack(0) rolls back the outer most transaction.
  • DB::rollBack(1) rollback to savepoint trans2
  • DB::rollBack(2) rollback to savepoint trans3
  • ...
  • Redundant calls to DB::rollBack(), e.g. when not in a transaction, don't fire 'rollingBack' event anymore.

@taylorotwell
Copy link
Member

I'm curious what is the use case for this? Not trying to downplay it but I just am genuinely curious when a developer would do this 😄

@halaei
Copy link
Contributor Author

halaei commented Oct 13, 2016

Maybe only rolling back the entire transaction makes sence. But in laravel
5.3 the the user have to rollback step by step. No other choise at all. Do
you feel this PR is flexible?

On Oct 13, 2016 8:01 PM, "Taylor Otwell" notifications@github.com wrote:

I'm curious what is the use case for this? Not trying to downplay it but I
just am genuinely curious when a developer would do this 😄


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#15876 (comment),
or mute the thread
https://github.com/notifications/unsubscribe-auth/AGwr9MqRHyQ1MaDUT0RjOGYjbplvrNTmks5qzlzRgaJpZM4KVLa5
.

@taylorotwell taylorotwell merged commit 342578b into laravel:master Oct 13, 2016
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.

None yet

2 participants