Skip to content

Commit a894a95

Browse files
committed
Refactoring from pool to populator
Signed-off-by: aavarghese <avarghese@us.ibm.com>
1 parent 8a995a0 commit a894a95

6 files changed

Lines changed: 12 additions & 11 deletions

File tree

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ import (
2626
"time"
2727

2828
"github.com/llm-d-incubation/llm-d-fast-model-actuation/pkg/common"
29-
launcherpool "github.com/llm-d-incubation/llm-d-fast-model-actuation/pkg/controller/launcher-pool"
29+
launcherpopulator "github.com/llm-d-incubation/llm-d-fast-model-actuation/pkg/controller/launcher-populator"
3030
"github.com/spf13/pflag"
3131

3232
kubeinformers "k8s.io/client-go/informers"
@@ -76,17 +76,17 @@ func main() {
7676
klog.Fatal(err)
7777
}
7878
if len(restConfig.UserAgent) == 0 {
79-
restConfig.UserAgent = launcherpool.ControllerName
79+
restConfig.UserAgent = launcherpopulator.ControllerName
8080
} else {
81-
restConfig.UserAgent += "/" + launcherpool.ControllerName
81+
restConfig.UserAgent += "/" + launcherpopulator.ControllerName
8282
}
8383

8484
kubeClient := kubernetes.NewForConfigOrDie(restConfig)
8585
kubePreInformers := kubeinformers.NewSharedInformerFactoryWithOptions(kubeClient, 0, kubeinformers.WithNamespace(overrides.Context.Namespace))
8686
fmaClient := fmaclient.NewForConfigOrDie(restConfig)
8787
fmaPreInformers := fmainformers.NewSharedInformerFactoryWithOptions(fmaClient, 0, fmainformers.WithNamespace(overrides.Context.Namespace))
8888

89-
ctlr, err := launcherpool.NewController(
89+
ctlr, err := launcherpopulator.NewController(
9090
logger,
9191
kubeClient.CoreV1(),
9292
overrides.Context.Namespace,

pkg/controller/launcher-pool/interface.go renamed to pkg/controller/launcher-populator/interface.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,14 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package launcherpool
17+
package launcherpopulator
1818

1919
const (
2020
ComponentLabelKey = "app.kubernetes.io/component"
2121
LauncherComponentLabelValue = "launcher"
2222

2323
LauncherGeneratedByLabelKey = "dual-pods.llm-d.ai/generated-by"
24-
LauncherGeneratedByLabelValue = "launcher-pool"
24+
LauncherGeneratedByLabelValue = "launcher-populator"
2525

2626
LauncherConfigNameLabelKey = "dual-pods.llm-d.ai/launcher-config-name"
2727
)

pkg/controller/launcher-pool/node-launcher-key.go renamed to pkg/controller/launcher-populator/node-launcher-key.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package launcherpool
17+
package launcherpopulator
1818

1919
import (
2020
"fmt"

pkg/controller/launcher-pool/node-matcher.go renamed to pkg/controller/launcher-populator/node-matcher.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package launcherpool
17+
package launcherpopulator
1818

1919
import (
2020
fmav1alpha1 "github.com/llm-d-incubation/llm-d-fast-model-actuation/api/fma/v1alpha1"

pkg/controller/launcher-pool/node-matcher_test.go renamed to pkg/controller/launcher-populator/node-matcher_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package launcherpool
1+
package launcherpopulator
22

33
import (
44
"testing"

pkg/controller/launcher-pool/populator.go renamed to pkg/controller/launcher-populator/populator.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
package launcherpool
17+
package launcherpopulator
1818

1919
import (
2020
"context"
@@ -24,6 +24,7 @@ import (
2424
apierrors "k8s.io/apimachinery/pkg/api/errors"
2525
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
2626
"k8s.io/utils/ptr"
27+
2728
//apierrors "k8s.io/apimachinery/pkg/api/errors"
2829
//metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
2930
"k8s.io/apimachinery/pkg/labels"
@@ -41,7 +42,7 @@ import (
4142
genctlr "github.com/llm-d-incubation/llm-d-fast-model-actuation/pkg/controller/generic"
4243
)
4344

44-
const ControllerName = "launcher-pool-populator"
45+
const ControllerName = "launcher-populator"
4546

4647
type Controller interface {
4748
Start(context.Context) error

0 commit comments

Comments
 (0)