Skip to content

Commit 16d75d2

Browse files
authored
workqueue: Actually implement GetKeyState in real server (#1111)
This was accidentally omitted from the rest of the implementation.
1 parent e429d8e commit 16d75d2

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

modules/workqueue/cmd/inmem/main.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,3 +102,7 @@ func (y *enq) Process(ctx context.Context, req *workqueue.ProcessRequest) (*work
102102
}
103103
return &workqueue.ProcessResponse{}, nil
104104
}
105+
106+
func (y *enq) GetKeyState(ctx context.Context, req *workqueue.GetKeyStateRequest) (*workqueue.KeyState, error) {
107+
return y.wq.Get(ctx, req.Key)
108+
}

modules/workqueue/cmd/receiver/main.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,3 +89,7 @@ func (y *enq) Process(ctx context.Context, req *workqueue.ProcessRequest) (*work
8989
}
9090
return &workqueue.ProcessResponse{}, nil
9191
}
92+
93+
func (y *enq) GetKeyState(ctx context.Context, req *workqueue.GetKeyStateRequest) (*workqueue.KeyState, error) {
94+
return y.wq.Get(ctx, req.Key)
95+
}

0 commit comments

Comments
 (0)