G-Research/unicorn-history-server

Bugs in `syncPartitionQueues()` implementation ๐Ÿ›

Closed this issue ยท 0 comments

There are some minor bugs in the syncPartitionQueues() implementation that cause yhs to crash. Please refer to the following code snippet for details:

https://github.com/G-Research/yunikorn-history-server/blob/bb51d30e93a958b1eab52d76712ea628d72c936b/internal/yunikorn/sync.go#L103-L117

Incorrect Parameter on Line 104
Currently, partition.Name is passed as a parameter, but it should be partition.ID. Since we're now using IDs, the partition.ID parameter may be unnecessary, allowing us to refactor the function as follows:

GetQueueInPartition(ctx context.Context, partitionID, queueID string)  =>  GetQueueInPartition(ctx context.Context, queueID string)