From 001378d8075be1bd96c430fa04998ba100bb1786 Mon Sep 17 00:00:00 2001 From: blueueueueue <1926373770@qq.com> Date: Thu, 7 May 2026 11:15:43 +0800 Subject: [PATCH] Add Notation to Release in pkg/ddc/base/portallocator/random_allocator.go Signed-off-by: blueueueueue <1926373770@qq.com> --- pkg/ddc/base/portallocator/random_allocator.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pkg/ddc/base/portallocator/random_allocator.go b/pkg/ddc/base/portallocator/random_allocator.go index c70601707b7..65ff4814375 100644 --- a/pkg/ddc/base/portallocator/random_allocator.go +++ b/pkg/ddc/base/portallocator/random_allocator.go @@ -54,6 +54,15 @@ func (r *RandomAllocator) Allocate(port int) error { } +// Release releases the resource associated with the given index. +// For the RandomAllocator, no actual resource is allocated per index, +// so this method does nothing and always returns a nil error. +// +// Parameters: +// - i: the index of the resource to release (unused). +// +// Returns: +// - error: always nil, indicating success with no action. func (r *RandomAllocator) Release(i int) error { // no need to release return nil