summaryrefslogtreecommitdiff
path: root/sync_worker.go
diff options
context:
space:
mode:
authorValery Piashchynski <[email protected]>2020-10-27 16:01:31 +0300
committerValery Piashchynski <[email protected]>2020-10-27 16:01:31 +0300
commitac5a89d63dbed7e0318c7e70ec1b0fa9c98c198a (patch)
treefe0d5674a7e011f2a5f1c4d117503c978f509546 /sync_worker.go
parentc9af916ae4d78334d348ed1ef7238206f3ecb7a1 (diff)
Merge changes, pool comments add
Diffstat (limited to 'sync_worker.go')
-rwxr-xr-xsync_worker.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/sync_worker.go b/sync_worker.go
index 6dd8d8e8..d933077b 100755
--- a/sync_worker.go
+++ b/sync_worker.go
@@ -20,6 +20,7 @@ type SyncWorker interface {
// Exec used to execute payload on the SyncWorker, there is no TIMEOUTS
Exec(rqs Payload) (Payload, error)
+ // ExecWithContext used to handle Exec with TTL
ExecWithContext(ctx context.Context, p Payload) (Payload, error)
}
@@ -94,7 +95,7 @@ func (tw *syncWorker) ExecWithContext(ctx context.Context, p Payload) (Payload,
rsp, err := tw.execPayload(p)
if err != nil {
- if _, ok := err.(JobError); !ok {
+ if _, ok := err.(ExecError); !ok {
tw.w.State().Set(StateErrored)
tw.w.State().RegisterExec()
}