Skip to content
Open
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
19 changes: 19 additions & 0 deletions .chloggen/restore-crd-field-descriptions.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement

# The name of the component, or a single word describing the area of concern, (e.g. collector, target allocator, auto-instrumentation, opamp, github action)
component: operator

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Restore CRD field descriptions for operator-owned types by setting maxDescLen=128.

# One or more tracking issues related to the change
issues: [2737]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext: |
The `make install` target now uses `kubectl apply --server-side` to support the larger
CRD payloads that include field descriptions. This allows `kubectl explain` and similar
tools to show useful documentation for operator-defined fields.
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,11 @@ ifeq ($(USE_IMAGE_DIGESTS), true)
endif
MANIFEST_DIR ?= config/crd/bases

# kubectl apply does not work on large CRDs.
CRD_OPTIONS ?= "crd:generateEmbeddedObjectMeta=true,maxDescLen=0"
# Use a moderate description length to restore CRD field descriptions for operator-owned
# types while keeping total CRD size within etcd limits. Use kubectl apply --server-side
# when applying CRDs to accommodate the larger payload.
# See: https://github.com/open-telemetry/opentelemetry-operator/issues/2737
CRD_OPTIONS ?= "crd:generateEmbeddedObjectMeta=true,maxDescLen=128"

# Choose which version to generate
BUNDLE_VARIANT ?= community
Expand Down Expand Up @@ -242,9 +245,10 @@ run: generate fmt vet manifests
ENABLE_WEBHOOKS=$(ENABLE_WEBHOOKS) go run -ldflags "${OPERATOR_LDFLAGS}" ./main.go --zap-devel

# Install CRDs into a cluster
# Use --server-side to support the larger CRDs that include field descriptions.
.PHONY: install
install: manifests kustomize
$(KUSTOMIZE) build config/crd | kubectl apply -f -
$(KUSTOMIZE) build config/crd | kubectl apply --server-side -f -

# Uninstall CRDs from a cluster
.PHONY: uninstall
Expand Down
95 changes: 95 additions & 0 deletions config/crd/bases/opentelemetry.io_clusterobservabilities.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,123 +29,211 @@ spec:
name: v1alpha1
schema:
openAPIV3Schema:
description: ClusterObservability is the Schema for the clusterobservabilities
API.
properties:
apiVersion:
description: APIVersion defines the versioned schema of this representation
of an object.
type: string
kind:
description: Kind is a string value representing the REST resource this
object represents.
type: string
metadata:
type: object
spec:
description: ClusterObservabilitySpec defines the desired state of ClusterObservability.
properties:
exporter:
description: Exporter defines the OTLP HTTP exporter configuration
for all signals.
properties:
compression:
description: |-
Compression defines the compression algorithm to use.
By default gzip compression is enabled. Use "none" to disable.
enum:
- gzip
- none
- ""
type: string
encoding:
description: |-
Encoding defines the encoding to use for the messages.
Valid options: proto, json. Default is proto.
enum:
- proto
- json
type: string
endpoint:
description: Endpoint is the target base URL to send data to (e.g.,
https://example.com:4318).
type: string
headers:
additionalProperties:
type: string
description: Headers defines additional headers to be sent with
each request.
type: object
logs_endpoint:
description: LogsEndpoint is the target URL to send log data to
(e.g., https://example.com:4318/v1/logs).
type: string
metrics_endpoint:
description: MetricsEndpoint is the target URL to send metric
data to (e.g., https://example.com:4318/v1/metrics).
type: string
profiles_endpoint:
description: ProfilesEndpoint is the target URL to send profile
data to (e.g., https://example.com:4318/v1/development/profiles).
type: string
read_buffer_size:
description: ReadBufferSize for HTTP client. Default is 0.
minimum: 0
type: integer
retry_on_failure:
description: RetryOnFailure defines retry configuration for failed
requests.
properties:
enabled:
description: Enabled controls whether retry is enabled. Default
is true.
type: boolean
initial_interval:
description: InitialInterval is the initial retry interval
(e.g., "5s"). Default is 5s.
type: string
max_elapsed_time:
description: MaxElapsedTime is the maximum elapsed time for
retries (e.g., "5m"). Default is 5m.
type: string
max_interval:
description: MaxInterval is the maximum retry interval (e.g.,
"30s"). Default is 30s.
type: string
multiplier:
description: Multiplier is the multiplier for retry intervals
(e.g., "1.5"). Default is 1.5.
type: string
randomization_factor:
description: RandomizationFactor is the randomization factor
for retry intervals (e.g., "0.5"). Default is 0.5.
type: string
type: object
sending_queue:
description: SendingQueue defines configuration for the sending
queue.
properties:
enabled:
description: Enabled controls whether the queue is enabled.
Default is true.
type: boolean
num_consumers:
description: NumConsumers is the number of consumers that
dequeue batches. Default is 10.
minimum: 1
type: integer
queue_size:
description: QueueSize is the maximum number of batches allowed
in queue at a given time. Default is 1000.
minimum: 1
type: integer
type: object
timeout:
description: Timeout is the HTTP request time limit (e.g., "30s",
"1m"). Default is 30s.
type: string
tls:
description: TLS defines TLS configuration for the exporter.
properties:
ca_file:
description: CAFile is the path to the CA certificate file
for server verification.
type: string
cert_file:
description: CertFile is the path to the client certificate
file for mutual TLS.
type: string
insecure:
description: Insecure controls whether to use insecure transport.
Default is false.
type: boolean
key_file:
description: KeyFile is the path to the client private key
file for mutual TLS.
type: string
server_name:
description: ServerName for TLS handshake. If empty, uses
the hostname from endpoint.
type: string
type: object
traces_endpoint:
description: TracesEndpoint is the target URL to send trace data
to (e.g., https://example.com:4318/v1/traces).
type: string
write_buffer_size:
description: WriteBufferSize for HTTP client. Default is 512 *
1024.
minimum: 0
type: integer
type: object
required:
- exporter
type: object
status:
description: ClusterObservabilityStatus defines the observed state of
ClusterObservability.
properties:
componentsStatus:
additionalProperties:
description: ComponentStatus represents the status of an individual
component.
properties:
lastUpdated:
description: LastUpdated is the last time this status was updated.
format: date-time
type: string
message:
description: Message provides additional information about the
component status.
type: string
ready:
description: Ready indicates whether the component is ready.
type: boolean
type: object
description: ComponentsStatus provides status information about individual
observability components.
type: object
conditions:
description: Conditions represent the latest available observations
of the ClusterObservability state.
items:
description: ClusterObservabilityCondition represents a condition
of a ClusterObservability.
properties:
lastTransitionTime:
description: Last time the condition transitioned from one status
to another.
format: date-time
type: string
message:
description: A human readable message indicating details about
the transition.
type: string
observedGeneration:
description: ObservedGeneration represents the .metadata.generation
that the condition was set based upon.
format: int64
type: integer
reason:
description: The reason for the condition's last transition.
type: string
status:
description: Status of the condition.
type: string
type:
description: Type of condition.
type: string
required:
- status
Expand All @@ -158,13 +246,20 @@ spec:
configVersions:
additionalProperties:
type: string
description: ConfigVersions tracks the version hashes of the configuration
files used.
type: object
message:
description: Message provides additional information about the current
state.
type: string
observedGeneration:
description: ObservedGeneration is the most recent generation observed
for this ClusterObservability.
format: int64
type: integer
phase:
description: Phase represents the current phase of the ClusterObservability.
type: string
type: object
type: object
Expand Down
Loading
Loading