From 521aeb823bc8fa1f0a91b540cbbac96328185f51 Mon Sep 17 00:00:00 2001 From: Valery Piashchynski Date: Wed, 23 Jun 2021 17:41:51 +0300 Subject: - Add PQ (priority_queue) mock - Add binary heap mock - Connect first sub-plugin (ephemeral) with root jobs plugin Signed-off-by: Valery Piashchynski --- pkg/priority_queue/binary_heap.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 pkg/priority_queue/binary_heap.go (limited to 'pkg/priority_queue/binary_heap.go') diff --git a/pkg/priority_queue/binary_heap.go b/pkg/priority_queue/binary_heap.go new file mode 100644 index 00000000..c660ddb6 --- /dev/null +++ b/pkg/priority_queue/binary_heap.go @@ -0,0 +1,12 @@ +/* +binary heap (min-heap) algorithm used as a core for the priority queue +*/ + +package priorityqueue + +type BinHeap struct { +} + +func NewBinHeap() *BinHeap { + return &BinHeap{} +} -- cgit v1.2.3