Skip to content

Commit 6e15461

Browse files
committed

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

Diff for: polycode/model.go

+9-9
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,18 @@ import (
55
)
66

77
type BackoffStrategy struct {
8-
InitialInterval time.Duration // Initial retry interval
9-
MaxInterval time.Duration // Maximum interval between retries
10-
Multiplier float64 // Multiplier to apply to the interval after each failure
8+
InitialInterval time.Duration `json:"initialInterval"`
9+
MaxInterval time.Duration `json:"maxInterval"`
10+
Multiplier float64 `json:"multiplier"`
1111
}
1212

1313
type TaskOptions struct {
14-
Timeout time.Duration // Maximum time allowed for the task to complete
15-
Retries int // Number of times to retry the task upon failure
16-
RetryOnFail bool // Whether to retry the task automatically on failure
17-
BackoffStrategy BackoffStrategy // Backoff strategy for handling retries
18-
PartitionKey string
19-
TenantId string
14+
Timeout time.Duration `json:"timeout"`
15+
Retries int `json:"retries"`
16+
RetryOnFail bool `json:"retryOnFail"`
17+
BackoffStrategy BackoffStrategy `json:"backoffStrategy"`
18+
PartitionKey string `json:"partitionKey"`
19+
TenantId string `json:"tenantId"`
2020
}
2121

2222
func (t TaskOptions) WithPartitionKey(partitionKey string) TaskOptions {

0 commit comments

Comments
 (0)