Skip to content

Commit 27436f6

Browse files
ebembi-crdbebembi-crdbclaude
authored
DOC-17063: Replace source file/directory links (#23299)
* Remove cockroach source file/directory links Unlink 111 pages that reference github.com/cockroachdb/cockroach/blob or /tree paths. These links pointed to cockroach source code files and directories that are not useful for docs readers. Part of DOC-17063. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Fix pre-existing cross-version link violations Replace hardcoded images/v24.2/raw-status-endpoints.png with images/{{ page.version.version }}/raw-status-endpoints.png in monitoring-and-alerting.md for v25.1, v25.2, and v25.3. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Fix image path syntax in monitoring-and-alerting.md Use absolute /docs/images/ path with {{ page.version.version }} instead of nesting {{ }} inside {{ }} (which Liquid can't evaluate). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Address PR #23299 review feedback Per reviewer comments: - Remove FIPS Dockerfile bullet from fips.md (all versions) - Remove CockroachDB Source Code line from essential-metrics.md - Remove Encoding Tech Note and DistSQL RFC references from sql-layer.md - Remove Admission Control tech note references from admission-control.md - Remove RFC links from restore.md (keep text, unlink) - Remove "Tracking GitHub Issue" text from restore.md - Replace GitHub links with {% link %} for vendored K8s config files in kubernetes-performance.md - Fix image paths in monitoring-and-alerting.md (hardcode version) - Replace GitHub links with {% link %} for alerts.rules.yml in monitoring-and-alerting.md - Replace GitHub links with {% link %} in schedule-cockroachdb-*.md - Remove Read Committed RFC references from read-committed.md - Vendor K8s config files and alerts.rules.yml for {% link %} usage - Apply all changes to v26.3 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: ebembi-crdb <ebembi@cockroachlabs.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
1 parent d55bac6 commit 27436f6

123 files changed

Lines changed: 1347 additions & 277 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/current/_includes/v23.1/essential-metrics.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,5 +180,4 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
180180
- [Visualize metrics in Grafana]({% link {{ page.version.version }}/monitor-cockroachdb-with-prometheus.md %}#step-5-visualize-metrics-in-grafana)
181181
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
182182
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
183-
- [Events to alert on]({% link {{ page.version.version }}/monitoring-and-alerting.md %}#events-to-alert-on)
184-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)
183+
- [Events to alert on]({% link {{ page.version.version }}/monitoring-and-alerting.md %}#events-to-alert-on)

src/current/_includes/v23.2/essential-metrics.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,5 +180,4 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
180180
- [Visualize metrics in Grafana]({% link {{ page.version.version }}/monitor-cockroachdb-with-prometheus.md %}#step-5-visualize-metrics-in-grafana)
181181
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
182182
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
183-
- [Events to alert on]({% link {{ page.version.version }}/monitoring-and-alerting.md %}#events-to-alert-on)
184-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)
183+
- [Events to alert on]({% link {{ page.version.version }}/monitoring-and-alerting.md %}#events-to-alert-on)

src/current/_includes/v24.1/essential-metrics.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,4 +201,3 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
201201
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
202202
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
203203
- [Essential Alerts]({% link {{ page.version.version }}/essential-alerts-{{ include.deployment}}.md %})
204-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)

src/current/_includes/v24.2/essential-metrics.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,4 +194,3 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
194194
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
195195
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
196196
- [Essential Alerts]({% link {{ page.version.version }}/essential-alerts-{{ include.deployment}}.md %})
197-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)

src/current/_includes/v24.3/essential-metrics.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,4 +201,3 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
201201
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
202202
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
203203
- [Essential Alerts]({% link {{ page.version.version }}/essential-alerts-{{ include.deployment}}.md %})
204-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)

src/current/_includes/v25.1/essential-metrics.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,4 +201,3 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
201201
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
202202
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
203203
- [Essential Alerts]({% link {{ page.version.version }}/essential-alerts-{{ include.deployment}}.md %})
204-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)

src/current/_includes/v25.2/essential-metrics.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,4 +201,3 @@ If [Row-Level TTL]({% link {{ page.version.version }}/row-level-ttl.md %}) is co
201201
- [Custom Chart Debug Page]({% link {{ page.version.version }}/ui-custom-chart-debug-page.md %})
202202
- [Cluster API]({% link {{ page.version.version }}/cluster-api.md %})
203203
- [Essential Alerts]({% link {{ page.version.version }}/essential-alerts-{{ include.deployment}}.md %})
204-
- [CockroachDB Source Code - DB Console metrics to graphs mappings (in *.tsx files)](https://github.com/cockroachdb/cockroach/tree/master/pkg/ui/workspaces/db-console/src/views/cluster/containers/nodeGraphs/dashboards)
Lines changed: 285 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,285 @@
1+
apiVersion: v1
2+
kind: ServiceAccount
3+
metadata:
4+
name: cockroachdb
5+
labels:
6+
app: cockroachdb
7+
---
8+
apiVersion: rbac.authorization.k8s.io/v1
9+
kind: Role
10+
metadata:
11+
name: cockroachdb
12+
labels:
13+
app: cockroachdb
14+
rules:
15+
- apiGroups:
16+
- ""
17+
resources:
18+
- secrets
19+
verbs:
20+
- create
21+
- get
22+
---
23+
apiVersion: rbac.authorization.k8s.io/v1
24+
kind: ClusterRole
25+
metadata:
26+
name: cockroachdb
27+
labels:
28+
app: cockroachdb
29+
rules:
30+
- apiGroups:
31+
- certificates.k8s.io
32+
resources:
33+
- certificatesigningrequests
34+
verbs:
35+
- create
36+
- get
37+
- watch
38+
---
39+
apiVersion: rbac.authorization.k8s.io/v1
40+
kind: RoleBinding
41+
metadata:
42+
name: cockroachdb
43+
labels:
44+
app: cockroachdb
45+
roleRef:
46+
apiGroup: rbac.authorization.k8s.io
47+
kind: Role
48+
name: cockroachdb
49+
subjects:
50+
- kind: ServiceAccount
51+
name: cockroachdb
52+
namespace: default
53+
---
54+
apiVersion: rbac.authorization.k8s.io/v1
55+
kind: ClusterRoleBinding
56+
metadata:
57+
name: cockroachdb
58+
labels:
59+
app: cockroachdb
60+
roleRef:
61+
apiGroup: rbac.authorization.k8s.io
62+
kind: ClusterRole
63+
name: cockroachdb
64+
subjects:
65+
- kind: ServiceAccount
66+
name: cockroachdb
67+
namespace: default
68+
---
69+
apiVersion: v1
70+
kind: Service
71+
metadata:
72+
# This service is meant to be used by clients of the database. It exposes a ClusterIP that will
73+
# automatically load balance connections to the different database pods.
74+
name: cockroachdb-public
75+
labels:
76+
app: cockroachdb
77+
spec:
78+
ports:
79+
# The main port, served by gRPC, serves Postgres-flavor SQL, internode
80+
# traffic and the cli.
81+
- port: 26257
82+
targetPort: 26257
83+
name: grpc
84+
# The secondary port serves the UI as well as health and debug endpoints.
85+
- port: 8080
86+
targetPort: 8080
87+
name: http
88+
selector:
89+
app: cockroachdb
90+
---
91+
apiVersion: v1
92+
kind: Service
93+
metadata:
94+
# This service only exists to create DNS entries for each pod in the stateful
95+
# set such that they can resolve each other's IP addresses. It does not
96+
# create a load-balanced ClusterIP and should not be used directly by clients
97+
# in most circumstances.
98+
name: cockroachdb
99+
labels:
100+
app: cockroachdb
101+
annotations:
102+
# Use this annotation in addition to the actual publishNotReadyAddresses
103+
# field below because the annotation will stop being respected soon but the
104+
# field is broken in some versions of Kubernetes:
105+
# https://github.com/kubernetes/kubernetes/issues/58662
106+
service.alpha.kubernetes.io/tolerate-unready-endpoints: "true"
107+
# Enable automatic monitoring of all instances when Prometheus is running in the cluster.
108+
prometheus.io/scrape: "true"
109+
prometheus.io/path: "_status/vars"
110+
prometheus.io/port: "8080"
111+
spec:
112+
ports:
113+
- port: 26257
114+
targetPort: 26257
115+
name: grpc
116+
- port: 8080
117+
targetPort: 8080
118+
name: http
119+
# We want all pods in the StatefulSet to have their addresses published for
120+
# the sake of the other CockroachDB pods even before they're ready, since they
121+
# have to be able to talk to each other in order to become ready.
122+
publishNotReadyAddresses: true
123+
clusterIP: None
124+
selector:
125+
app: cockroachdb
126+
---
127+
apiVersion: policy/v1
128+
kind: PodDisruptionBudget
129+
metadata:
130+
name: cockroachdb-budget
131+
labels:
132+
app: cockroachdb
133+
spec:
134+
selector:
135+
matchLabels:
136+
app: cockroachdb
137+
maxUnavailable: 1
138+
---
139+
apiVersion: apps/v1
140+
kind: StatefulSet
141+
metadata:
142+
name: cockroachdb
143+
spec:
144+
serviceName: "cockroachdb"
145+
replicas: 3
146+
selector:
147+
matchLabels:
148+
app: cockroachdb
149+
template:
150+
metadata:
151+
labels:
152+
app: cockroachdb
153+
spec:
154+
serviceAccountName: cockroachdb
155+
# Init containers are run only once in the lifetime of a pod, before
156+
# it's started up for the first time. It has to exit successfully
157+
# before the pod's main containers are allowed to start.
158+
initContainers:
159+
# The init-certs container sends a certificate signing request to the
160+
# kubernetes cluster.
161+
# You can see pending requests using: kubectl get csr
162+
# CSRs can be approved using: kubectl certificate approve <csr name>
163+
#
164+
# All addresses used to contact a node must be specified in the --addresses arg.
165+
#
166+
# In addition to the node certificate and key, the init-certs entrypoint will symlink
167+
# the cluster CA to the certs directory.
168+
- name: init-certs
169+
image: cockroachdb/cockroach-k8s-request-cert:0.4
170+
imagePullPolicy: IfNotPresent
171+
command:
172+
- "/bin/ash"
173+
- "-ecx"
174+
- "/request-cert -namespace=${POD_NAMESPACE} -certs-dir=/cockroach-certs -type=node -addresses=localhost,127.0.0.1,$(hostname -f),$(hostname -f|cut -f 1-2 -d '.'),cockroachdb-public,cockroachdb-public.$(hostname -f|cut -f 3- -d '.'),cockroachdb-public.$(hostname -f|cut -f 3-4 -d '.'),cockroachdb-public.$(hostname -f|cut -f 3 -d '.') -symlink-ca-from=/var/run/secrets/kubernetes.io/serviceaccount/ca.crt"
175+
env:
176+
- name: POD_NAMESPACE
177+
valueFrom:
178+
fieldRef:
179+
fieldPath: metadata.namespace
180+
volumeMounts:
181+
- name: certs
182+
mountPath: /cockroach-certs
183+
affinity:
184+
podAntiAffinity:
185+
preferredDuringSchedulingIgnoredDuringExecution:
186+
- weight: 100
187+
podAffinityTerm:
188+
labelSelector:
189+
matchExpressions:
190+
- key: app
191+
operator: In
192+
values:
193+
- cockroachdb
194+
topologyKey: kubernetes.io/hostname
195+
containers:
196+
- name: cockroachdb
197+
image: cockroachdb/cockroach:latest
198+
imagePullPolicy: IfNotPresent
199+
# TODO: Change these to appropriate values for the hardware that you're running. You can see
200+
# the resources that can be allocated on each of your Kubernetes nodes by running:
201+
# kubectl describe nodes
202+
# Note that requests and limits should have identical values.
203+
resources:
204+
requests:
205+
cpu: "2"
206+
memory: "8Gi"
207+
limits:
208+
cpu: "2"
209+
memory: "8Gi"
210+
ports:
211+
- containerPort: 26257
212+
name: grpc
213+
- containerPort: 8080
214+
name: http
215+
# We recommend that you do not configure a liveness probe on a production environment, as this can impact the availability of production databases.
216+
# livenessProbe:
217+
# httpGet:
218+
# path: "/health"
219+
# port: http
220+
# scheme: HTTPS
221+
# initialDelaySeconds: 30
222+
# periodSeconds: 5
223+
readinessProbe:
224+
httpGet:
225+
path: "/health?ready=1"
226+
port: http
227+
scheme: HTTPS
228+
initialDelaySeconds: 10
229+
periodSeconds: 5
230+
failureThreshold: 2
231+
volumeMounts:
232+
- name: datadir
233+
mountPath: /cockroach/cockroach-data
234+
- name: certs
235+
mountPath: /cockroach/cockroach-certs
236+
env:
237+
- name: COCKROACH_CHANNEL
238+
value: kubernetes-secure
239+
- name: GOMAXPROCS
240+
valueFrom:
241+
resourceFieldRef:
242+
resource: limits.cpu
243+
divisor: "1"
244+
- name: MEMORY_LIMIT_MIB
245+
valueFrom:
246+
resourceFieldRef:
247+
resource: limits.memory
248+
divisor: "1Mi"
249+
command:
250+
- "/bin/bash"
251+
- "-ecx"
252+
# The use of qualified `hostname -f` is crucial:
253+
# Other nodes aren't able to look up the unqualified hostname.
254+
# Memory caches are set as a fraction of the pod's memory limit.
255+
- exec
256+
/cockroach/cockroach
257+
start
258+
--logtostderr
259+
--certs-dir /cockroach/cockroach-certs
260+
--advertise-host $(hostname -f)
261+
--http-addr 0.0.0.0
262+
--join cockroachdb-0.cockroachdb,cockroachdb-1.cockroachdb,cockroachdb-2.cockroachdb
263+
--cache $(expr $MEMORY_LIMIT_MIB / 4)MiB
264+
--max-sql-memory $(expr $MEMORY_LIMIT_MIB / 4)MiB
265+
# No pre-stop hook is required, a SIGTERM plus some time is all that's
266+
# needed for graceful shutdown of a node.
267+
terminationGracePeriodSeconds: 60
268+
volumes:
269+
- name: datadir
270+
persistentVolumeClaim:
271+
claimName: datadir
272+
- name: certs
273+
emptyDir: {}
274+
podManagementPolicy: Parallel
275+
updateStrategy:
276+
type: RollingUpdate
277+
volumeClaimTemplates:
278+
- metadata:
279+
name: datadir
280+
spec:
281+
accessModes:
282+
- "ReadWriteOnce"
283+
resources:
284+
requests:
285+
storage: 100Gi

0 commit comments

Comments
 (0)