Pretty much. The above has to be called from the storage.write transaction.
That and the active update checks would go into SchedulerThriftInterface
RPC implementation.

On Tue, Aug 2, 2016 at 12:04 PM, Igor Morozov <igm...@gmail.com> wrote:

> you mean just do this:
> unscopedChangeUpdateStatus(
>             key,
>             Functions.compose(createAuditedEvent(auditData),
> Functions.constant(ROLLING_BACK)));
>
> and remove all the checks for active job updates?
>
>
> On Tue, Aug 2, 2016 at 11:27 AM, Maxim Khutornenko <ma...@apache.org>
> wrote:
>
>> This is an automatically generated e-mail. To reply, visit:
>> https://reviews.apache.org/r/50168/
>>
>> On August 2nd, 2016, 1:55 a.m. UTC, *Aurora ReviewBot* wrote:
>>
>> Master (b912e17) is green with this patch.
>>   ./build-support/jenkins/build.sh
>>
>> I will refresh this build result if you post a review containing "@ReviewBot 
>> retry"
>>
>> Inducing a rollback for an active update can be done much easier by 
>> instructing the JobUpdateController to do a user-initiated rollback. I'd 
>> expect a path similar to "pause"[1] that would "fail" the update and inject 
>> a proper user message [2].
>>
>> [1] - 
>> https://github.com/apache/aurora/blob/b24619b28c4dbb35188871bacd0091a9e01218e3/src/main/java/org/apache/aurora/scheduler/updater/JobUpdateControllerImpl.java#L203-L210
>> [2] - 
>> https://github.com/apache/aurora/blob/b24619b28c4dbb35188871bacd0091a9e01218e3/src/main/java/org/apache/aurora/scheduler/updater/JobUpdateControllerImpl.java#L618-L631
>>
>>
>> - Maxim
>>
>> On August 2nd, 2016, 1:26 a.m. UTC, Igor Morozov wrote:
>> Review request for Aurora, Joshua Cohen, Maxim Khutornenko, Bill Farner,
>> and Zameer Manji.
>> By Igor Morozov.
>>
>> *Updated Aug. 2, 2016, 1:26 a.m.*
>> *Bugs: * AURORA-1721 <https://issues.apache.org/jira/browse/AURORA-1721>
>> *Repository: * aurora
>> Description
>>
>> Add rollback functionality to the scheduler
>>
>> Thic change also includes an addition to storage replicated log. I needed a 
>> way to re-insert lock token for an existing job update.
>>
>> Diffs
>>
>>    - CHANGELOG (fc6a46d77ebf889c8f60402c95e8a7472980ba1c)
>>    - RELEASE-NOTES.md (19d7f7e34652d170a7d8eb41a9c6ffdcc67324eb)
>>    - api/src/main/thrift/org/apache/aurora/gen/api.thrift
>>    (1d66208490aff6ea8af4c737845fa2cf13617529)
>>    - api/src/main/thrift/org/apache/aurora/gen/storage.thrift
>>    (9e4213f13255a182df938bea44ca87fa03a25318)
>>    - 
>> src/main/java/org/apache/aurora/scheduler/thrift/SchedulerThriftInterface.java
>>    (b534abf95bab6e1657e3ef993cf34c0d6ec460be)
>>    - 
>> src/main/java/org/apache/aurora/scheduler/thrift/aop/AnnotatedAuroraAdmin.java
>>    (9243c92b11040b68ed6014b3991db69fc08bcddf)
>>    - 
>> src/main/java/org/apache/aurora/scheduler/updater/JobUpdateController.java
>>    (f8357c46df1b025bf4e38a7ce1cb1c13a50c39f9)
>>    - 
>> src/main/java/org/apache/aurora/scheduler/updater/JobUpdateControllerImpl.java
>>    (364c5c753f884a2d89e27802d7bbf3b2b6d3a08e)
>>    - src/main/python/apache/aurora/client/api/__init__.py
>>    (ec2c786d143347a7953f9fe431c6ddc59e1b9854)
>>    - src/main/python/apache/aurora/client/cli/update.py
>>    (bb526f7bf94d7bfe02fe2786493c85be1bfeb86f)
>>    - src/test/java/org/apache/aurora/scheduler/updater/JobUpdaterIT.java
>>    (e157c0dfde5efc418448e138aa008ade742fe816)
>>    - src/test/python/apache/aurora/client/api/test_scheduler_client.py
>>    (afbd385b7eda64cb1f7d118b695e65e4045eac6c)
>>
>> View Diff <https://reviews.apache.org/r/50168/diff/>
>>
>
>
>
> --
> -Igor
>

Reply via email to