Kubernetes - #107
Conversation
|
Important Review skippedNo new commits to review since the last review. ⚙️ Run configurationConfiguration used: Repository UI (base), Organization UI (inherited) Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
📝 WalkthroughWalkthroughKubernetes plugin configuration, data streams, normalization scripts, indexed resources, relationships, scopes, dashboards, and documentation were added. The plugin supports bearer-token API access, cluster resource monitoring, live metrics, and resource-focused perspectives. ChangesKubernetes plugin contract and resource types
Data collection and normalization
Object relationships and indexed resources
Perspectives and dashboards
Documentation
Sequence Diagram(s)sequenceDiagram
participant KubernetesAPI
participant KubernetesDataStream
participant TransformationScript
participant PerspectiveDashboard
KubernetesAPI->>KubernetesDataStream: Return resource or metrics data
KubernetesDataStream->>TransformationScript: Pass response and filter configuration
TransformationScript->>PerspectiveDashboard: Provide normalized records and health values
PerspectiveDashboard->>PerspectiveDashboard: Apply resource scope and render tiles
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (3 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
Comment |
There was a problem hiding this comment.
Actionable comments posted: 29
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@plugins/Kubernetes/v1/configValidation.json`:
- Around line 4-10: Update the Kubernetes config validation for the Authenticate
data stream so it no longer relies on the non-resource `/version` endpoint in
the dataStream.name field. Use a protected read-only resource path or add an
explicit RBAC permission check in the validation flow around the Authenticate
configuration so success only means the cluster can actually read a protected
resource.
In `@plugins/Kubernetes/v1/correlationRules/relate-ingress-to-service.json`:
- Around line 9-14: Update the conditions arrays in
plugins/Kubernetes/v1/correlationRules/relate-ingress-to-service.json (lines
9-14) and plugins/Kubernetes/v1/correlationRules/relate-service-to-pod.json
(lines 9-14) to add a second condition matching sourceProperty "namespace" to
targetProperty "namespace" in addition to the existing name-based condition.
In `@plugins/Kubernetes/v1/dataStreams/daemonsets.json`:
- Around line 5-7: Replace the plugin-name tag "Kubernetes" with the applicable
existing reusable category in the tags arrays for
plugins/Kubernetes/v1/dataStreams/daemonsets.json lines 5-7, deployments.json
lines 5-7, events.json lines 5-7, ingresses.json lines 5-7, limitranges.json
lines 5-7, namespaceContents.json lines 5-7, and namespaces.json lines 5-7;
preserve the existing tags structure and do not use the plugin name as a
category.
In `@plugins/Kubernetes/v1/dataStreams/limitranges.json`:
- Around line 39-76: Update the limit-range fields defaultMemoryMi,
defaultRequestMemoryMi, maxMemoryMi, and minMemoryMi in
plugins/Kubernetes/v1/dataStreams/limitranges.json (lines 39-76) to byte-based
names, emit raw numeric byte values, and use shape "bytes". Apply the same field
renaming and bytes-shape contract in
plugins/Kubernetes/v1/dataStreams/namespaceContents.json (lines 254-357), and
update the namespaceContents script to emit byte values for those fields.
In `@plugins/Kubernetes/v1/dataStreams/namespaceContents.json`:
- Line 11: Replace the nested detailType ternary in endpointPath with a
dedicated map that explicitly associates each supported resource type with its
API-group path, including the core api/v1 fallback as appropriate. Update the
endpoint construction to look up the mapped path, making unsupported detailType
values explicit while preserving the existing namespace and resource suffixes.
In `@plugins/Kubernetes/v1/dataStreams/nodeMetrics.json`:
- Around line 5-7: Replace the plugin-name value in the tags array with an
existing non-plugin category, keeping the tag structure unchanged and following
the repository’s established category vocabulary.
- Around line 36-50: Update the cpuUsageMillicores field to emit raw numeric
values by removing its suffix and decimal formatting from shape, leaving only
the numeric semantic. Change the memory field contract from memoryUsageMi to a
byte-based field name such as memoryUsageBytes and set its shape to bytes.
Update every dependent dashboard column to use the renamed field and apply CPU
and memory presentation formatting there.
In `@plugins/Kubernetes/v1/dataStreams/nodes.json`:
- Around line 5-7: Replace the plugin-name tag "Kubernetes" with applicable
existing repository category tags in the tags arrays for
plugins/Kubernetes/v1/dataStreams/nodes.json:5-7,
plugins/Kubernetes/v1/dataStreams/persistentvolumes.json:5-7,
plugins/Kubernetes/v1/dataStreams/podMetrics.json:5-7,
plugins/Kubernetes/v1/dataStreams/pods.json:5-7,
plugins/Kubernetes/v1/dataStreams/podsByParent.json:5-7, and
plugins/Kubernetes/v1/dataStreams/pvClaims.json:5-7. Keep tags mandatory, reuse
established categories consistently across these data streams, and do not use
the plugin name.
In `@plugins/Kubernetes/v1/dataStreams/podsByParent.json`:
- Around line 11-14: Replace the conditional mustache expressions in the
pods-by-parent data stream’s endpointPath and getArgs with supported map
transformations, preserving the namespace-specific versus cluster-wide pod
endpoint and the node fieldSelector behavior. Use the schema’s mapped-value form
for both request variants and keep the resulting requests declarative.
In `@plugins/Kubernetes/v1/dataStreams/replicasets.json`:
- Around line 5-7: Replace the plugin-name tag "Kubernetes" with an applicable
existing generic category in the tags arrays for
plugins/Kubernetes/v1/dataStreams/replicasets.json lines 5-7,
plugins/Kubernetes/v1/dataStreams/resourcequotas.json lines 5-7,
plugins/Kubernetes/v1/dataStreams/services.json lines 5-7, and
plugins/Kubernetes/v1/dataStreams/statefulsets.json lines 5-7; keep tags present
and use the same suitable category consistently without introducing new
categories.
In `@plugins/Kubernetes/v1/dataStreams/resourcequotas.json`:
- Around line 44-71: The Kubernetes resource quota memory fields currently
expose Mi values under a megabytes contract. Rename the memory quota fields to
their ...Bytes equivalents, convert values to raw bytes in resourcequotas.js,
and change their shapes to bytes; update all consumers including
namespaceContents, index definitions, and dashboards. Preserve v1 and add the
contract change in a new major-version folder with the corresponding
metadata.json version increment.
In `@plugins/Kubernetes/v1/dataStreams/scripts/ingresses.js`:
- Around line 15-28: Add a brief intent comment immediately above
primaryBackendServiceName explaining that it exposes only the default backend or
the service from the first rule path, and does not select later rules or paths.
In `@plugins/Kubernetes/v1/dataStreams/scripts/limitranges.js`:
- Around line 1-30: Update the Kubernetes Quantity parsers in
plugins/Kubernetes/v1/dataStreams/scripts/limitranges.js:1-30,
namespaceContents.js:1-30, nodeMetrics.js:1-30, and nodes.js:1-30, plus the
memory parser in persistentvolumes.js:1-18, to support exponential notation,
valid binary/decimal suffixes, and milli semantics for CPU and memory; return
undefined or raise an error for unknown suffixes instead of treating them as
dimensionless. Add the requested fixtures for 129e6, 400m, 1Ei, 1k, and 250m,
document the conversion logic with a comment, and increment the plugin version
in plugins/Kubernetes/v1/metadata.json from 1.0.0.
In `@plugins/Kubernetes/v1/dataStreams/scripts/podMetrics.js`:
- Around line 13-56: Retain all v1 files unchanged, including
plugins/Kubernetes/v1/dataStreams/scripts/podMetrics.js:13-56,
plugins/Kubernetes/v1/dataStreams/podMetrics.json:43-57,
plugins/Kubernetes/v1/dataStreams/nodes.json:149-171,
plugins/Kubernetes/v1/dataStreams/persistentvolumes.json:50-52,
plugins/Kubernetes/v1/dataStreams/pods.json:102-114, and
plugins/Kubernetes/v1/dataStreams/pvClaims.json:51-53. Add the next
major-version folder with copied equivalents, update parseMemoryMi and the
affected summation/field names to produce byte values with correct decimal
conversions, rename *Mi fields to *Bytes, and use bytes shapes in all listed
streams and dashboard metadata. Remove the CPU display-format tuple from the new
podMetrics.json and update the new metadata.json version.
In `@plugins/Kubernetes/v1/dataStreams/scripts/pods.js`:
- Around line 1-29: Replace the ad hoc parsing in parseCpuMillicores and
parseMemoryMi with a shared Kubernetes Quantity parser that accepts exponent
notation and all valid decimal/binary SI suffixes, including milli-byte values.
Convert parsed quantities to millicores or Mi using the correct base-unit
semantics, especially treating memory suffix m as 0.001 byte, and reuse the same
parser across all duplicated resource parsing paths. Add fixtures covering
exponent, decimal-SI, binary-SI, and milli-byte quantities.
In `@plugins/Kubernetes/v1/dataStreams/scripts/replicasets.js`:
- Around line 2-8: Update the owner selection in the replicasets mapping to
search item.metadata.ownerReferences for the reference whose controller field is
true, rather than taking the first entry. Keep ownerUid undefined when no
controller reference exists so the existing filter behavior remains correct.
In `@plugins/Kubernetes/v1/dataStreams/scripts/resourcequotas.js`:
- Around line 1-30: Replace the duplicate parseCpuMillicores and parseMemoryMi
logic in plugins/Kubernetes/v1/dataStreams/scripts/resourcequotas.js (lines
1-30) and plugins/Kubernetes/v1/dataStreams/scripts/pvClaims.js (lines 1-18)
with complete Kubernetes Quantity parsing that accepts signed values, decimals,
and scientific notation and correctly handles n, u, m, k, and all binary and
decimal memory suffixes through E/Ei. Apply the same parser update to any other
Kubernetes data-stream scripts containing these helpers, then increment
plugins/Kubernetes/v1/metadata.json.
In `@plugins/Kubernetes/v1/defaultContent/Perspectives/node.dash.json`:
- Line 144: Update the tile titles in node.dash.json (line 144),
daemonset.dash.json (line 106), and statefulset.dash.json (line 106) to
capitalize “This”: use “Pods on This Node,” “Pods on This DaemonSet,” and “Pods
on This StatefulSet.”
- Around line 36-73: Update the metadata and tile overrides for every Mi-valued
field returned by parseMemoryMi to convert values to bytes and use the
binary-accurate "bytes" shape instead of "megabytes". Apply this consistently in
node.dash.json (lines 36-73), pod.dash.json (lines 36-55), and
persistentvolume.dash.json (lines 118-128), covering all three dashboards.
In `@plugins/Kubernetes/v1/docs/README.md`:
- Around line 64-66: Update the code fence immediately preceding the kubectl
create token command to specify the shell language as ```shell, leaving the
command and surrounding documentation unchanged.
- Line 1: Prepend the README content with a descriptive level-one Markdown
heading for the Kubernetes plugin, and keep the existing introductory paragraph
immediately below it unchanged.
- Line 118: Update the Pod row in the Kubernetes API documentation table to
describe the indexed population as a Kubernetes Pod regardless of phase,
replacing the inaccurate “A running pod” wording while preserving the existing
endpoint.
- Around line 132-133: Update the RBAC documentation in the README to
distinguish permission scopes: state that unscoped object and metrics streams
require cluster-wide list permissions, while Namespace Contents, namespaced Pods
by Parent, and Persistent Volume Claims use namespaced requests and require
access in every target namespace.
- Around line 62-68: Update the ServiceAccount token documentation around the
`kubectl create token` command to state that `--duration=8760h` is limited by
the API server’s effective token lifetime. Add concise rotation and
compromise-response guidance for both TokenRequest tokens and Secret-based
tokens, including deleting or replacing the Secret where applicable.
- Line 9: Update the setup instructions in the README to replace the
cluster-admin requirement with the specific RBAC prerequisites: the setup
identity needs get and create/patch access for the manifest objects, plus either
the granted permissions or escalate on clusterroles and bind on the
squaredup-reader ClusterRole. Keep the kubectl apply command unchanged.
- Around line 92-93: Update the README feature description to rename “Real
control-plane health” to “cluster and resource health,” preserving the existing
node, workload, and pod/container health details. Do not claim API-server,
scheduler, controller-manager, or etcd readiness unless documented readiness
signals are added.
- Line 85: Update the “Ignore certificate errors” entry in the configuration
table to warn that disabling TLS verification can enable man-in-the-middle
attacks and expose the Bearer Token on untrusted networks. Explicitly advise
against enabling it for internet-reachable clusters, and document the supported
trusted-CA alternative; if none exists, recommend a CA-signed server certificate
or relay agent mode.
In `@plugins/Kubernetes/v1/ui.json`:
- Around line 3-10: Add a validation.pattern to the host field in the Kubernetes
UI configuration that accepts only non-whitespace HTTPS URLs, such as
^https://[^\s]+$. Add or update validation coverage to confirm an http:// host
is rejected before any request is sent, while preserving required-field
validation.
- Around line 23-27: Update the Kubernetes plugin auth flow so bearer-token
requests are not sent when ignoreCertificateErrors is enabled. Use the
ignoreCertificateErrors setting from the UI config to gate any Authorization
header creation in the Kubernetes plugin’s request/metadata path, and ensure all
credential-bearing calls respect the same check. Keep the existing
self-signed-certificate UX, but prevent token transmission whenever TLS
validation is disabled.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 86556307-a637-4f1e-92e9-8799f0dc2bc7
⛔ Files ignored due to path filters (1)
plugins/Kubernetes/v1/icon.svgis excluded by!**/*.svg
📒 Files selected for processing (64)
plugins/Kubernetes/v1/configValidation.jsonplugins/Kubernetes/v1/correlationRules/relate-daemonset-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-deployment-to-replicaset.jsonplugins/Kubernetes/v1/correlationRules/relate-ingress-to-service.jsonplugins/Kubernetes/v1/correlationRules/relate-namespace-to-objects.jsonplugins/Kubernetes/v1/correlationRules/relate-node-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-replicaset-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-service-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-statefulset-to-pod.jsonplugins/Kubernetes/v1/custom_types.jsonplugins/Kubernetes/v1/dataStreams/daemonsets.jsonplugins/Kubernetes/v1/dataStreams/deployments.jsonplugins/Kubernetes/v1/dataStreams/events.jsonplugins/Kubernetes/v1/dataStreams/ingresses.jsonplugins/Kubernetes/v1/dataStreams/limitranges.jsonplugins/Kubernetes/v1/dataStreams/namespaceContents.jsonplugins/Kubernetes/v1/dataStreams/namespaces.jsonplugins/Kubernetes/v1/dataStreams/nodeMetrics.jsonplugins/Kubernetes/v1/dataStreams/nodes.jsonplugins/Kubernetes/v1/dataStreams/persistentvolumes.jsonplugins/Kubernetes/v1/dataStreams/podMetrics.jsonplugins/Kubernetes/v1/dataStreams/pods.jsonplugins/Kubernetes/v1/dataStreams/podsByParent.jsonplugins/Kubernetes/v1/dataStreams/pvClaims.jsonplugins/Kubernetes/v1/dataStreams/replicasets.jsonplugins/Kubernetes/v1/dataStreams/resourcequotas.jsonplugins/Kubernetes/v1/dataStreams/scripts/daemonsets.jsplugins/Kubernetes/v1/dataStreams/scripts/deployments.jsplugins/Kubernetes/v1/dataStreams/scripts/events.jsplugins/Kubernetes/v1/dataStreams/scripts/ingresses.jsplugins/Kubernetes/v1/dataStreams/scripts/limitranges.jsplugins/Kubernetes/v1/dataStreams/scripts/namespaceContents.jsplugins/Kubernetes/v1/dataStreams/scripts/namespaces.jsplugins/Kubernetes/v1/dataStreams/scripts/nodeMetrics.jsplugins/Kubernetes/v1/dataStreams/scripts/nodes.jsplugins/Kubernetes/v1/dataStreams/scripts/persistentvolumes.jsplugins/Kubernetes/v1/dataStreams/scripts/podMetrics.jsplugins/Kubernetes/v1/dataStreams/scripts/pods.jsplugins/Kubernetes/v1/dataStreams/scripts/podsByParent.jsplugins/Kubernetes/v1/dataStreams/scripts/pvClaims.jsplugins/Kubernetes/v1/dataStreams/scripts/replicasets.jsplugins/Kubernetes/v1/dataStreams/scripts/resourcequotas.jsplugins/Kubernetes/v1/dataStreams/scripts/services.jsplugins/Kubernetes/v1/dataStreams/scripts/statefulsets.jsplugins/Kubernetes/v1/dataStreams/scripts/version.jsplugins/Kubernetes/v1/dataStreams/services.jsonplugins/Kubernetes/v1/dataStreams/statefulsets.jsonplugins/Kubernetes/v1/dataStreams/version.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/daemonset.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/deployment.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/ingress.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/manifest.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/namespace.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/node.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/persistentvolume.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/pod.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/service.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/statefulset.dash.jsonplugins/Kubernetes/v1/defaultContent/manifest.jsonplugins/Kubernetes/v1/defaultContent/scopes.jsonplugins/Kubernetes/v1/docs/README.mdplugins/Kubernetes/v1/indexDefinitions/default.jsonplugins/Kubernetes/v1/metadata.jsonplugins/Kubernetes/v1/ui.json
9629b74 to
c912494
Compare
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
|
There was a problem hiding this comment.
Actionable comments posted: 15
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@plugins/Kubernetes/v1/correlationRules/relate-namespace-to-objects.json`:
- Around line 7-17: Add the exact indexed persistent volume claim source type
declared by the pvClaims data stream and default index definition to the
target.types list in the namespace relationship rule, preserving all existing
Kubernetes resource types.
In `@plugins/Kubernetes/v1/dataStreams/scripts/daemonsets.js`:
- Around line 6-13: In the daemonSetHealth calculation, add a short intent
comment next to the desiredNumberScheduled === 0 branch explaining that a
zero-target DaemonSet is intentionally considered healthy. Leave the existing
health logic unchanged.
In `@plugins/Kubernetes/v1/dataStreams/scripts/limitranges.js`:
- Around line 1-30: Update parseK8sQuantity in
plugins/Kubernetes/v1/dataStreams/scripts/limitranges.js, namespaceContents.js,
nodeMetrics.js, nodes.js, persistentvolumes.js, podMetrics.js, pods.js, and
pvClaims.js at the specified ranges so the Quantity expression accepts uppercase
E exponents and trailing decimal forms such as 1E3 and 1.; preserve existing
suffix and numeric conversion behavior. Add a brief comment explaining these
Kubernetes Quantity forms, and add regression fixtures covering both values.
In `@plugins/Kubernetes/v1/dataStreams/scripts/podsByParent.js`:
- Around line 28-41: Update the selector filtering branch guarded by
ownerNamespace and selectorAppLabel in the podsByParent logic to require
item.metadata.namespace to equal ownerNamespace before matching podAppLabel.
Preserve the existing label precedence and equality behavior for Pods in the
parent namespace.
In `@plugins/Kubernetes/v1/dataStreams/scripts/resourcequotas.js`:
- Around line 3-10: Update the quantity regex in the resource quantity parser to
accept uppercase or lowercase exponent markers and mantissas ending with a
decimal point, while preserving existing suffix handling and numeric conversion.
Ensure exponent parsing remains correct for both e/E forms, and add parser tests
covering 1E3, 1., and 1.E3.
In `@plugins/Kubernetes/v1/dataStreams/scripts/services.js`:
- Around line 17-25: Add a short intent comment immediately above or beside the
unwrap helper explaining that object-picker field values may be arrays and are
normalized to their first value before backend-key comparison. Keep the existing
normalization behavior unchanged.
In `@plugins/Kubernetes/v1/defaultContent/Perspectives/deployment.dash.json`:
- Around line 216-226: Update the Deployment page ReplicaSets table
configuration around the hiddenColumns list to also hide ownerUid, matching the
equivalent namespace perspective while retaining uid and namespace as hidden
columns.
In `@plugins/Kubernetes/v1/defaultContent/Perspectives/namespace.dash.json`:
- Around line 130-139: Confirm the column emitted for namespaceContents pods
matches the configured name, then update the pod entry in the namespace
dashboard’s columnOrder from podPhase to phase if the stream emits phase. Keep
the ordering and other column identifiers unchanged.
In
`@plugins/Kubernetes/v1/defaultContent/Perspectives/persistentvolume.dash.json`:
- Around line 33-36: Update the Details tile configuration for the
datastream-properties stream to add a metadata override assigning the bytes
semantic shape to capacityBytes. Match the existing Capacity tile and the
analogous node dashboard configuration, leaving other field rendering unchanged.
In `@plugins/Kubernetes/v1/docs/README.md`:
- Around line 83-90: Extend the “Configuration fields” table in the Kubernetes
README to document the connection method/relay-agent control and the “Restrict
access to this data source” option shown in the Add data source form. If either
field is platform-wide, link to the relevant platform documentation instead of
duplicating its details.
- Line 103: Update the dashboard documentation around the Cluster Overview and
resource perspectives to match the shipped dashboard count: inspect the manifest
files under defaultContent, then either add the omitted dashboard to the list or
correct the stated count so it accurately reflects all 11 out-of-box dashboards.
- Line 127: Update the Persistent Volume description in the documentation table
to state that it is optionally bound to a claim, while preserving the existing
cluster-scoped storage volume wording.
- Line 5: Update the CPU/memory usage note in the Kubernetes plugin README to
remove the claim that EKS, AKS, and GKE include metrics-server by default.
Replace that provider-specific statement with the requested guidance to verify
that kubectl top nodes works, and instruct users to install metrics-server when
it reports “Metrics API not available.”
- Line 72: Update the token-compromise guidance in the README paragraph to
distinguish RBAC removal from token invalidation: state that deleting
ClusterRoleBinding objects removes permissions but does not invalidate tokens,
and advise removing all bindings during containment. Specify that Secret-based
tokens require deleting their Secret, while TokenRequest tokens require deleting
and recreating the ServiceAccount to invalidate them before expiry, allowing for
control-plane propagation delay.
In `@plugins/Kubernetes/v1/indexDefinitions/default.json`:
- Around line 12-17: Update the source type value in the namespaces definition
from the plugin-prefixed label to the upstream Kubernetes kind, and apply the
same unprefixed naming to the other Kubernetes object type values in this file.
Add "uid" to the namespaces step’s properties array so it matches the other
object definitions; use a separate display-name setting only if the UI requires
the longer label.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: 8f1f43b6-fe1d-4d7d-a81b-1e603967831c
⛔ Files ignored due to path filters (1)
plugins/Kubernetes/v1/icon.svgis excluded by!**/*.svg
📒 Files selected for processing (62)
plugins/Kubernetes/v1/configValidation.jsonplugins/Kubernetes/v1/correlationRules/relate-daemonset-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-deployment-to-replicaset.jsonplugins/Kubernetes/v1/correlationRules/relate-ingress-to-service.jsonplugins/Kubernetes/v1/correlationRules/relate-namespace-to-objects.jsonplugins/Kubernetes/v1/correlationRules/relate-node-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-replicaset-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-service-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-statefulset-to-pod.jsonplugins/Kubernetes/v1/custom_types.jsonplugins/Kubernetes/v1/dataStreams/daemonsets.jsonplugins/Kubernetes/v1/dataStreams/deployments.jsonplugins/Kubernetes/v1/dataStreams/events.jsonplugins/Kubernetes/v1/dataStreams/ingresses.jsonplugins/Kubernetes/v1/dataStreams/limitranges.jsonplugins/Kubernetes/v1/dataStreams/namespaceContents.jsonplugins/Kubernetes/v1/dataStreams/namespaces.jsonplugins/Kubernetes/v1/dataStreams/nodeMetrics.jsonplugins/Kubernetes/v1/dataStreams/nodes.jsonplugins/Kubernetes/v1/dataStreams/persistentvolumes.jsonplugins/Kubernetes/v1/dataStreams/podMetrics.jsonplugins/Kubernetes/v1/dataStreams/pods.jsonplugins/Kubernetes/v1/dataStreams/podsByParent.jsonplugins/Kubernetes/v1/dataStreams/pvClaims.jsonplugins/Kubernetes/v1/dataStreams/replicasets.jsonplugins/Kubernetes/v1/dataStreams/resourcequotas.jsonplugins/Kubernetes/v1/dataStreams/scripts/daemonsets.jsplugins/Kubernetes/v1/dataStreams/scripts/deployments.jsplugins/Kubernetes/v1/dataStreams/scripts/events.jsplugins/Kubernetes/v1/dataStreams/scripts/ingresses.jsplugins/Kubernetes/v1/dataStreams/scripts/limitranges.jsplugins/Kubernetes/v1/dataStreams/scripts/namespaceContents.jsplugins/Kubernetes/v1/dataStreams/scripts/namespaces.jsplugins/Kubernetes/v1/dataStreams/scripts/nodeMetrics.jsplugins/Kubernetes/v1/dataStreams/scripts/nodes.jsplugins/Kubernetes/v1/dataStreams/scripts/persistentvolumes.jsplugins/Kubernetes/v1/dataStreams/scripts/podMetrics.jsplugins/Kubernetes/v1/dataStreams/scripts/pods.jsplugins/Kubernetes/v1/dataStreams/scripts/podsByParent.jsplugins/Kubernetes/v1/dataStreams/scripts/pvClaims.jsplugins/Kubernetes/v1/dataStreams/scripts/replicasets.jsplugins/Kubernetes/v1/dataStreams/scripts/resourcequotas.jsplugins/Kubernetes/v1/dataStreams/scripts/services.jsplugins/Kubernetes/v1/dataStreams/scripts/statefulsets.jsplugins/Kubernetes/v1/dataStreams/services.jsonplugins/Kubernetes/v1/dataStreams/statefulsets.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/daemonset.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/deployment.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/ingress.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/manifest.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/namespace.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/node.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/persistentvolume.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/pod.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/service.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/statefulset.dash.jsonplugins/Kubernetes/v1/defaultContent/manifest.jsonplugins/Kubernetes/v1/defaultContent/scopes.jsonplugins/Kubernetes/v1/docs/README.mdplugins/Kubernetes/v1/indexDefinitions/default.jsonplugins/Kubernetes/v1/metadata.jsonplugins/Kubernetes/v1/ui.json
c912494 to
b3596ac
Compare
|
Note GitHub couldn't provide a complete incremental comparison for this pull request, so CodeRabbit is performing a full review instead. This review may take a little longer. |
There was a problem hiding this comment.
Actionable comments posted: 6
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@plugins/Kubernetes/v1/correlationRules/relate-service-to-pod.json`:
- Around line 9-20: Update the relationship rule’s conditions to prevent
undefined selector/label values from matching and to validate the complete
Service selector rather than the reduced selectorAppLabel value. Require every
selector label to match the Pod while preserving namespace matching, and
increment the plugin version in metadata.json.
In `@plugins/Kubernetes/v1/dataStreams/scripts/namespaceContents.js`:
- Around line 93-100: Document the non-obvious edge-case rules near their
implementations: add a short intent comment explaining why a DaemonSet with zero
desired targets is considered successful, and add another explaining that
primaryBackendServiceName exposes only the default backend or the first rule
path. Place each comment directly beside the corresponding logic without
changing behavior.
In `@plugins/Kubernetes/v1/dataStreams/scripts/podMetrics.js`:
- Around line 72-82: Document the array normalization performed by unwrap with
short intent comments at
plugins/Kubernetes/v1/dataStreams/scripts/podMetrics.js:72-82,
plugins/Kubernetes/v1/dataStreams/scripts/podsByParent.js:21-24, and
plugins/Kubernetes/v1/dataStreams/scripts/replicasets.js:16-20; state
respectively that object-picker values, scoped object values, and object-picker
values can be arrays before pod-key, parent, and owner-ID comparisons.
In `@plugins/Kubernetes/v1/dataStreams/services.json`:
- Around line 9-13: Update the Services stream request configuration under
config to match the token-based pagination settings used by the pods stream,
adding Kubernetes limit/continue paging while preserving the existing GET
endpoint and postRequestScript.
In `@plugins/Kubernetes/v1/docs/README.md`:
- Line 5: Update the metrics-server guidance in the README known limitations
section to state that installing it enables the CPU/memory usage tiles, rather
than making installation a prerequisite for adding the plugin. Preserve the
existing explanation that other plugin functionality works without
metrics-server.
- Line 83: Update the relay agent documentation reference in the README
paragraph to link the text “relay agent documentation” to
https://docs.squaredup.com/features/connect-and-explore/relay-agents, leaving
the surrounding cloud-mode and relay-agent guidance unchanged.
🪄 Autofix
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI (base), Organization UI (inherited)
Review profile: ASSERTIVE
Plan: Pro
Run ID: c1825a18-4ca1-4aaf-9862-267b5b3a3e46
⛔ Files ignored due to path filters (1)
plugins/Kubernetes/v1/icon.svgis excluded by!**/*.svg
📒 Files selected for processing (62)
plugins/Kubernetes/v1/configValidation.jsonplugins/Kubernetes/v1/correlationRules/relate-daemonset-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-deployment-to-replicaset.jsonplugins/Kubernetes/v1/correlationRules/relate-ingress-to-service.jsonplugins/Kubernetes/v1/correlationRules/relate-namespace-to-objects.jsonplugins/Kubernetes/v1/correlationRules/relate-node-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-replicaset-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-service-to-pod.jsonplugins/Kubernetes/v1/correlationRules/relate-statefulset-to-pod.jsonplugins/Kubernetes/v1/custom_types.jsonplugins/Kubernetes/v1/dataStreams/daemonsets.jsonplugins/Kubernetes/v1/dataStreams/deployments.jsonplugins/Kubernetes/v1/dataStreams/events.jsonplugins/Kubernetes/v1/dataStreams/ingresses.jsonplugins/Kubernetes/v1/dataStreams/limitranges.jsonplugins/Kubernetes/v1/dataStreams/namespaceContents.jsonplugins/Kubernetes/v1/dataStreams/namespaces.jsonplugins/Kubernetes/v1/dataStreams/nodeMetrics.jsonplugins/Kubernetes/v1/dataStreams/nodes.jsonplugins/Kubernetes/v1/dataStreams/persistentvolumes.jsonplugins/Kubernetes/v1/dataStreams/podMetrics.jsonplugins/Kubernetes/v1/dataStreams/pods.jsonplugins/Kubernetes/v1/dataStreams/podsByParent.jsonplugins/Kubernetes/v1/dataStreams/pvClaims.jsonplugins/Kubernetes/v1/dataStreams/replicasets.jsonplugins/Kubernetes/v1/dataStreams/resourcequotas.jsonplugins/Kubernetes/v1/dataStreams/scripts/daemonsets.jsplugins/Kubernetes/v1/dataStreams/scripts/deployments.jsplugins/Kubernetes/v1/dataStreams/scripts/events.jsplugins/Kubernetes/v1/dataStreams/scripts/ingresses.jsplugins/Kubernetes/v1/dataStreams/scripts/limitranges.jsplugins/Kubernetes/v1/dataStreams/scripts/namespaceContents.jsplugins/Kubernetes/v1/dataStreams/scripts/namespaces.jsplugins/Kubernetes/v1/dataStreams/scripts/nodeMetrics.jsplugins/Kubernetes/v1/dataStreams/scripts/nodes.jsplugins/Kubernetes/v1/dataStreams/scripts/persistentvolumes.jsplugins/Kubernetes/v1/dataStreams/scripts/podMetrics.jsplugins/Kubernetes/v1/dataStreams/scripts/pods.jsplugins/Kubernetes/v1/dataStreams/scripts/podsByParent.jsplugins/Kubernetes/v1/dataStreams/scripts/pvClaims.jsplugins/Kubernetes/v1/dataStreams/scripts/replicasets.jsplugins/Kubernetes/v1/dataStreams/scripts/resourcequotas.jsplugins/Kubernetes/v1/dataStreams/scripts/services.jsplugins/Kubernetes/v1/dataStreams/scripts/statefulsets.jsplugins/Kubernetes/v1/dataStreams/services.jsonplugins/Kubernetes/v1/dataStreams/statefulsets.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/daemonset.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/deployment.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/ingress.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/manifest.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/namespace.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/node.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/persistentvolume.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/pod.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/service.dash.jsonplugins/Kubernetes/v1/defaultContent/Perspectives/statefulset.dash.jsonplugins/Kubernetes/v1/defaultContent/manifest.jsonplugins/Kubernetes/v1/defaultContent/scopes.jsonplugins/Kubernetes/v1/docs/README.mdplugins/Kubernetes/v1/indexDefinitions/default.jsonplugins/Kubernetes/v1/metadata.jsonplugins/Kubernetes/v1/ui.json
🧩 Plugin PR Summary📦 Modified Plugins
📋 Results
🔍 Validation Details✅
|
|
🔌 Plugin overview
🖼️ Plugin screenshots
Plugin configuration
Default dashboards
🧪 Testing
Tested end-to-end against a real cluster (OrbStack locally / GKE remotely). Created disposable test workloads (DaemonSet, StatefulSet, PVC + consuming pod, Ingress) to exercise object types the base cluster didn't otherwise have.
metrics-server(with--kubelet-insecure-tlsfor the local cluster's self-signed kubelet certs) and verified live CPU/memory usage tiles on Node and Pod perspectivesobjectsUI filter, reducing the stream count while keeping the same dashboard behaviormetrics-serverin the cluster (standard lightweight Kubernetes Metrics API, not Prometheus) — usage tiles show no data without it, rest of the plugin unaffectedapp/app.kubernetes.io/name/k8s-app), not full subset matching📚 Checklist
Summary by CodeRabbit