Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ListenerClass docs #466

Merged
merged 5 commits into from
Sep 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion deploy/helm/druid-operator/crds/crds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8225,13 +8225,15 @@ spec:
listenerClass:
default: cluster-internal
description: |-
In the future this setting will control, which ListenerClass <https://docs.stackable.tech/home/stable/listener-operator/listenerclass.html> will be used to expose the service. Currently only a subset of the ListenerClasses are supported by choosing the type of the created Services by looking at the ListenerClass name specified, In a future release support for custom ListenerClasses will be introduced without a breaking change:
This field controls which type of Service the Operator creates for this DruidCluster:

* cluster-internal: Use a ClusterIP service

* external-unstable: Use a NodePort service

* external-stable: Use a LoadBalancer service

This is a temporary solution with the goal to keep yaml manifests forward compatible. In the future, this setting will control which ListenerClass <https://docs.stackable.tech/home/stable/listener-operator/listenerclass.html> will be used to expose the service, and ListenerClass names will stay the same, allowing for a non-breaking change.
enum:
- cluster-internal
- external-unstable
Expand Down
17 changes: 17 additions & 0 deletions docs/modules/druid/pages/usage-guide/listenerclass.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
= Service exposition with ListenerClasses

Apache Druid offers a web UI and an API, both are exposed by the `router` role. Other roles also expose API endpoints such as the `broker` and `coordinator`. The Operator deploys services called `<name>-<role>` (where `<name>` is the name of the DruidCluster and `<role>` is the role for the Service) through which Druid can be reached.

These services can have three different types: `cluster-internal`, `external-unstable` and `external-stable`. Read more about the types in the xref:concepts:service-exposition.adoc[service exposition] documentation at platform level.

This is how the listener class is configured:

[source,yaml]
----
spec:
clusterConfig:
listenerClass: cluster-internal # <1>
----
<1> The default `cluster-internal` setting.

This setting affects all role Services at once.
1 change: 1 addition & 0 deletions docs/modules/druid/partials/nav.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
** xref:druid:getting_started/first_steps.adoc[]
* xref:druid:usage-guide/index.adoc[]
** xref:druid:usage-guide/pod-placement.adoc[]
** xref:druid:usage-guide/listenerclass.adoc[]
** xref:druid:usage-guide/ingestion.adoc[]
** xref:druid:usage-guide/deep-storage.adoc[]
** xref:druid:usage-guide/resources-and-storage.adoc[]
Expand Down
10 changes: 5 additions & 5 deletions rust/crd/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -242,17 +242,17 @@ pub struct DruidClusterConfig {
/// These volumes will be mounted into all pods below `/stackable/userdata/{volumename}`
#[serde(default, skip_serializing_if = "Vec::is_empty")]
pub extra_volumes: Vec<Volume>,
/// In the future this setting will control, which ListenerClass <https://docs.stackable.tech/home/stable/listener-operator/listenerclass.html>
/// will be used to expose the service.
/// Currently only a subset of the ListenerClasses are supported by choosing the type of the created Services
/// by looking at the ListenerClass name specified,
/// In a future release support for custom ListenerClasses will be introduced without a breaking change:
/// This field controls which type of Service the Operator creates for this DruidCluster:
///
/// * cluster-internal: Use a ClusterIP service
///
/// * external-unstable: Use a NodePort service
///
/// * external-stable: Use a LoadBalancer service
///
/// This is a temporary solution with the goal to keep yaml manifests forward compatible.
/// In the future, this setting will control which ListenerClass <https://docs.stackable.tech/home/stable/listener-operator/listenerclass.html>
/// will be used to expose the service, and ListenerClass names will stay the same, allowing for a non-breaking change.
#[serde(default)]
pub listener_class: CurrentlySupportedListenerClasses,
}
Expand Down