mobilize-base 1.26 → 1.27
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -2
- data/lib/mobilize-base/handlers/gsheet.rb +1 -1
- data/lib/mobilize-base/models/stage.rb +2 -3
- data/lib/mobilize-base/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4ac112f2c8588a6618fd9f5651a0ade005705b98
|
4
|
+
data.tar.gz: c3d717a7cb1ed1325c96e3f5abb3ac298a25a805
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 620813a7bb33e88f1359f64d9461e5b574cb5222ebd09b9581c7564e78609b192da9f55f25454dcd98c3b80e77ae27ad7d92b25dcb07b2d5df173da7f699f2eb
|
7
|
+
data.tar.gz: 8f660078e0d359368162eeca6b49af99d21274da994911ae8a7cabb35fdcd50dff0ddd20880cbbad2fae790e2a63f460a8824545096649f914fd81eaf06e96e1
|
data/README.md
CHANGED
@@ -564,8 +564,10 @@ the Runner itself.
|
|
564
564
|
and "base1.out" for the second test. The first
|
565
565
|
takes the output from the first stage and the second reads it straight
|
566
566
|
from the referenced sheet.
|
567
|
-
* All stages accept
|
568
|
-
giving up.
|
567
|
+
* All stages accept retry parameters:
|
568
|
+
* retries: an integer specifying the number of times that the system will try it again before giving up.
|
569
|
+
* delay: an integer specifying the number of seconds between retries.
|
570
|
+
* always_on: if true, keeps the job on regardless of stage failures. The job will retry from the beginning with the same frequency as the Runner refresh rate.
|
569
571
|
* If a stage fails after all retries, it will output its standard error to a tab in the Runner with the name of the job, the name of the stage, and a ".err" extension
|
570
572
|
* The tab will be headed "response" and will contain the exception and backtrace for the error.
|
571
573
|
* The test uses "Requestor_mobilize(test)/base1.out" and
|
@@ -108,7 +108,7 @@ module Mobilize
|
|
108
108
|
#only give the user edit permissions if they're the ones
|
109
109
|
#creating it
|
110
110
|
target_sheet = Gsheet.find_or_create_by_path(target_path,gdrive_slot)
|
111
|
-
target_sheet.spreadsheet.update_acl(
|
111
|
+
target_sheet.spreadsheet.update_acl(u.email,"writer") unless target_sheet.spreadsheet.acl_entry(u.email).ie{|e| e and e.role=="owner"}
|
112
112
|
target_sheet.delete_sheet1
|
113
113
|
end
|
114
114
|
#pass it crop param to determine whether to shrink target sheet to fit data
|
@@ -145,7 +145,7 @@ module Mobilize
|
|
145
145
|
j = s.job
|
146
146
|
r = j.runner
|
147
147
|
u = r.user
|
148
|
-
j.update_attributes(:active=>false)
|
148
|
+
j.update_attributes(:active=>false) unless s.params['always_on']
|
149
149
|
s.update_attributes(:failed_at=>Time.now.utc,:response=>response)
|
150
150
|
stage_name = "#{j.name}_stage#{s.idx.to_s}.err"
|
151
151
|
target_path = (r.path.split("/")[0..-2] + [stage_name]).join("/")
|
@@ -162,10 +162,9 @@ module Mobilize
|
|
162
162
|
err_txt = ["response","\n",err_txt].join
|
163
163
|
err_sheet.write(err_txt,u.name)
|
164
164
|
#exception will be first row below "response" header
|
165
|
-
exc_to_s,backtrace = err_txt.split("\n").ie{|ea| [ea[1], ea[2..-1]]}
|
166
165
|
s.update_status(status_msg)
|
167
166
|
#raise the exception so it bubbles up to resque
|
168
|
-
raise Exception,
|
167
|
+
raise Exception,err_txt
|
169
168
|
end
|
170
169
|
|
171
170
|
def enqueue!
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mobilize-base
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '1.
|
4
|
+
version: '1.27'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Cassio Paes-Leme
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-03-
|
11
|
+
date: 2013-03-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|