Skip to content

privateai - Allow user-defined annotations for Public LoadBalancer by removing PaiInternalLB condition #228

@TheKoguryo

Description

@TheKoguryo

Description

Currently, annotations for the Service are only applied when instance.Spec.PaiInternalLB is set to true.

# oracle-database-operator / commons / privatewai / aibuiler.go

461 if status, err := strconv.ParseBool(instance.Spec.PaiInternalLB); err == nil && status {
            ...
476 }

This logic restricts annotation usage to Internal LoadBalancer scenarios only.

Problem

When instance.Spec.PaiInternalLB=false (i.e., using a Public LoadBalancer), users are unable to apply custom annotations, even though annotations are often required for configuring Public LoadBalancers (e.g., shape, bandwidth, networking options, etc.).

This results in:

  • Limited configurability for Public LoadBalancer
  • Inconsistent behavior between Internal and Public LB
  • Users being unable to leverage OCI-specific annotations when using Public LB

Proposed Change

Remove the condition to always allow user-defined annotations (instance.Spec.PailbAnnotation)

if status, err := strconv.ParseBool(instance.Spec.PaiInternalLB); err == nil && status {

Summary

Decouple user annotation handling from PaiInternalLB condition to ensure flexibility and consistency across both Public and Internal LoadBalancer configurations.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions