@@ -6,7 +6,7 @@ Licensed under the MIT License.
6
6
package key
7
7
8
8
import (
9
- "path/filepath "
9
+ "path"
10
10
"strconv"
11
11
)
12
12
@@ -38,30 +38,30 @@ func New(opts Options) *Key {
38
38
39
39
// JobKey returns the job key for the given job name.
40
40
func (k * Key ) JobKey (name string ) string {
41
- return filepath .Join (k .namespace , "jobs" , name )
41
+ return path .Join (k .namespace , "jobs" , name )
42
42
}
43
43
44
44
// CounterKey returns the counter key for the given job name.
45
45
func (k * Key ) CounterKey (name string ) string {
46
- return filepath .Join (k .namespace , "counters" , name )
46
+ return path .Join (k .namespace , "counters" , name )
47
47
}
48
48
49
49
// LeadershipNamespace returns the namespace key for the leadership keys.
50
50
func (k * Key ) LeadershipNamespace () string {
51
- return filepath .Join (k .namespace , "leadership" )
51
+ return path .Join (k .namespace , "leadership" )
52
52
}
53
53
54
54
// LeadershipKey returns the leadership key for this partition ID.
55
55
func (k * Key ) LeadershipKey () string {
56
- return filepath .Join (k .namespace , "leadership" , k .partitionID )
56
+ return path .Join (k .namespace , "leadership" , k .partitionID )
57
57
}
58
58
59
59
// JobNamespace returns the job namespace key.
60
60
func (k * Key ) JobNamespace () string {
61
- return filepath .Join (k .namespace , "jobs" )
61
+ return path .Join (k .namespace , "jobs" )
62
62
}
63
63
64
64
// JobName returns the job name from the given key.
65
65
func (k * Key ) JobName (key []byte ) string {
66
- return filepath .Base (string (key ))
66
+ return path .Base (string (key ))
67
67
}
0 commit comments