Skip to content

Commit 26471c2

Browse files
authored
Use simply old_name in job rename example (#897)
In the docs for `JobArgsWithKindAliases` we walk through an example of renaming `old_name` to `new_name`, but in the phase where aliases are added, we have the old name `old_name_still_recognized`. As I writing up docs for renaming jobs, this didn't really feel like it made much sense to me. We're supposed to be showing that `old_name` gets moved into `KindAliases`, but if `old_name` changes to something else, it defeats the clarity of the example such that it doesn't make all that much sense anymore. Here, use `old_name` in `KindAliases` instead.
1 parent d04b82a commit 26471c2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

job.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ type JobArgs interface {
5454
// type jobArgsBeingRenamed struct{}
5555
//
5656
// func (a jobArgsBeingRenamed) Kind() string { return "new_name" }
57-
// func (a jobArgsBeingRenamed) KindAliases() []string { return []string{"old_name_still_recognized"} }
57+
// func (a jobArgsBeingRenamed) KindAliases() []string { return []string{"old_name"} }
5858
//
5959
// After all jobs inserted under the original name have finished working
6060
// (including all their possible retries, which notably might take up to three

0 commit comments

Comments
 (0)