Skip to content

Commit 31a3250

Browse files
author
Per Goncalves da Silva
committed
next little change
Signed-off-by: Per Goncalves da Silva <[email protected]>
1 parent e016e73 commit 31a3250

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

pkg/lib/queueinformer/queueinformer_operator.go

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -276,15 +276,19 @@ func (o *operator) processNextWorkItem(ctx context.Context, loop *QueueInformer)
276276
var event = item
277277
if item.Type() != kubestate.ResourceDeleted {
278278
// Get the key
279-
key, keyable := loop.key(item)
280-
if !keyable {
281-
logger.WithField("item", item).Warn("could not form key")
282-
queue.Forget(item)
283-
return true
279+
//key, keyable := loop.key(item)
280+
//if !keyable {
281+
// logger.WithField("item", item).Warn("could not form key")
282+
// queue.Forget(item)
283+
// return true
284+
//}
285+
key, ok := item.Resource().(string)
286+
if !ok {
287+
panic(fmt.Sprintf("unexpected item resource type: %T", item.Resource()))
284288
}
285289

286290
logger = logger.WithField("cache-key", key)
287-
291+
288292
// Get the current cached version of the resource
289293
var exists bool
290294
var err error

0 commit comments

Comments
 (0)