Skip to content

Commit

Permalink
feat: create service for extensions
Browse files Browse the repository at this point in the history
Signed-off-by: Ankit152 <ankitkurmi152@gmail.com>
  • Loading branch information
Ankit152 committed Oct 28, 2024
1 parent 34b8ee8 commit 3a5a2ee
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion apis/v1beta1/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,8 @@ func (c *Config) getPortsForComponentKinds(logger logr.Logger, componentKinds ..
case KindProcessor:
continue
case KindExtension:
continue
retriever = extensions.ParserFor
cfg = *c.Extensions
}
for componentName := range enabledComponents[componentKind] {
// TODO: Clean up the naming here and make it simpler to use a retriever.
Expand Down Expand Up @@ -282,6 +283,10 @@ func (c *Config) GetExporterPorts(logger logr.Logger) ([]corev1.ServicePort, err
return c.getPortsForComponentKinds(logger, KindExporter)
}

func (c *Config) GetExtensionPorts(logger logr.Logger) ([]corev1.ServicePort, error) {
return c.getPortsForComponentKinds(logger, KindExtension)
}

func (c *Config) GetAllPorts(logger logr.Logger) ([]corev1.ServicePort, error) {
return c.getPortsForComponentKinds(logger, KindReceiver, KindExporter)
}
Expand Down

0 comments on commit 3a5a2ee

Please sign in to comment.