| OLD | NEW |
| 1 // Copyright 2015 The LUCI Authors. All rights reserved. | 1 // Copyright 2015 The LUCI Authors. All rights reserved. |
| 2 // Use of this source code is governed under the Apache License, Version 2.0 | 2 // Use of this source code is governed under the Apache License, Version 2.0 |
| 3 // that can be found in the LICENSE file. | 3 // that can be found in the LICENSE file. |
| 4 | 4 |
| 5 package mutate | 5 package mutate |
| 6 | 6 |
| 7 import ( | 7 import ( |
| 8 "google.golang.org/grpc/codes" | 8 "google.golang.org/grpc/codes" |
| 9 | 9 |
| 10 ds "github.com/luci/gae/service/datastore" | 10 ds "github.com/luci/gae/service/datastore" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 | 48 |
| 49 ar := &model.AttemptResult{ | 49 ar := &model.AttemptResult{ |
| 50 Attempt: model.AttemptKeyFromID(c, &atmpt.ID), | 50 Attempt: model.AttemptKeyFromID(c, &atmpt.ID), |
| 51 Data: *f.Data, | 51 Data: *f.Data, |
| 52 } | 52 } |
| 53 | 53 |
| 54 rslt := *f.Data | 54 rslt := *f.Data |
| 55 atmpt.Result.Data = &rslt | 55 atmpt.Result.Data = &rslt |
| 56 atmpt.Result.Data.Object = "" | 56 atmpt.Result.Data.Object = "" |
| 57 | 57 |
| 58 » err = errors.Annotate(ds.Put(c, atmpt, ar)).Tag(grpcutil.Tag.With(codes.
Internal)). | 58 » err = errors.Annotate(ds.Put(c, atmpt, ar), "during Put").Tag(grpcutil.T
ag.With(codes.Internal)).Err() |
| 59 » » Reason("during Put").Err() | |
| 60 return | 59 return |
| 61 } | 60 } |
| 62 | 61 |
| 63 func init() { | 62 func init() { |
| 64 tumble.Register((*FinishAttempt)(nil)) | 63 tumble.Register((*FinishAttempt)(nil)) |
| 65 } | 64 } |
| OLD | NEW |