Skip to content

Commit 1d16de2

Browse files
authored
fix formatting
1 parent 970e2da commit 1d16de2

File tree

1 file changed

+59
-52
lines changed

1 file changed

+59
-52
lines changed

src/content/docs/synthetics/synthetic-monitoring/private-locations/job-manager-configuration.mdx

Lines changed: 59 additions & 52 deletions
Original file line numberDiff line numberDiff line change
@@ -1917,7 +1917,10 @@ FROM SyntheticCheck SELECT rate(uniqueCount(id), 1 minute) AS 'job rate per minu
19171917
This query calculates the average per-minute growth of the `jobManagerHeavyweightJobs` queue on a time series chart. A line above zero indicates the queue is growing, while a line below zero means it's shrinking.
19181918
19191919
```nrql
1920-
FROM SyntheticsPrivateLocationStatus SELECT derivative(jobManagerHeavyweightJobs, 1 minute) AS 'queue growth rate per minute' WHERE name = 'YOUR_PRIVATE_LOCATION' TIMESERIES SINCE 1 day ago
1920+
FROM SyntheticsPrivateLocationStatus
1921+
SELECT derivative(jobManagerHeavyweightJobs, 1 minute) AS 'queue growth rate per minute'
1922+
WHERE name = 'YOUR_PRIVATE_LOCATION'
1923+
TIMESERIES SINCE 1 day ago
19211924
```
19221925
19231926
<Callout variant="tip">
@@ -1928,16 +1931,20 @@ FROM SyntheticsPrivateLocationStatus SELECT derivative(jobManagerHeavyweightJobs
19281931
This query finds the unique count of heavyweight monitors.
19291932
19301933
```nrql
1931-
1932-
FROM SyntheticCheck SELECT uniqueCount(monitorId) AS 'monitor count' WHERE location = 'YOUR_PRIVATE_LOCATION' AND type != 'SIMPLE' SINCE 1 day ago
1933-
1934+
FROM SyntheticCheck
1935+
SELECT uniqueCount(monitorId) AS 'monitor count'
1936+
WHERE location = 'YOUR_PRIVATE_LOCATION' AND type != 'SIMPLE'
1937+
SINCE 1 day ago
19341938
```
19351939
19361940
**4. Find average job duration in minutes ($D_{avg,m}$):**
19371941
This query finds the average execution duration of completed non-ping jobs and converts the result from milliseconds to minutes. `executionDuration` represents the time the job took to execute on the host.
19381942
19391943
```nrql
1940-
FROM SyntheticCheck SELECT average(executionDuration)/60e3 AS 'avg job duration (m)' WHERE location = 'YOUR_PRIVATE_LOCATION' AND type != 'SIMPLE' SINCE 1 day ago
1944+
FROM SyntheticCheck
1945+
SELECT average(executionDuration)/60e3 AS 'avg job duration (m)'
1946+
WHERE location = 'YOUR_PRIVATE_LOCATION' AND type != 'SIMPLE'
1947+
SINCE 1 day ago
19411948
```
19421949
19431950
**5. Find average heavyweight monitor period ($P_{avg,m}$):**
@@ -1972,15 +1979,15 @@ Your goal is to configure enough parallelism to handle your job load without exc
19721979
19731980
First, determine your private location's average job execution duration and job rate. Use `executionDuration` as it most accurately reflects the pod's active runtime.
19741981
1975-
```
1982+
```nrql
19761983
-- Get average job execution duration (in seconds)
19771984
FROM SyntheticCheck
19781985
SELECT average(executionDuration / 1e3) AS 'D_avg_s'
19791986
WHERE type != 'SIMPLE' AND location = 'YOUR_PRIVATE_LOCATION'
19801987
FACET typeLabel SINCE 1 hour ago
19811988
```
19821989
1983-
```
1990+
```nrql
19841991
-- Get jobs per 5 minutes
19851992
FROM SyntheticCheck
19861993
SELECT rate(uniqueCount(id), 5 minutes) AS 'N_m'
@@ -2018,7 +2025,7 @@ A key consideration is that a **single SJM instance has a maximum throughput of
20182025
20192026
First, get your average job execution duration in **minutes**:
20202027
2021-
```
2028+
```nrql
20222029
-- Get average job execution duration (in minutes)
20232030
FROM SyntheticCheck
20242031
SELECT average(executionDuration / 60e3) AS 'D_avg_m'
@@ -2059,7 +2066,7 @@ Compare your **required** parallelism ($P_{req}$) from Step 1 to the **maximum**
20592066
* **Action:**
20602067
20612068
1. You must **scale out by deploying multiple, separate SJM Helm releases**.
2062-
2. See the **"Scaling Out with Multiple SJM Deployments"** section below for the correct procedure.
2069+
2. See the **[Scaling Out with Multiple SJM Deployments](#scaling-out-with-multiple-sjm-deployments)** section below for the correct procedure.
20632070
3. **Do not** increase the `replicaCount` in your Helm chart.
20642071
20652072
##### Step 4: Monitor Your Queue
@@ -2068,7 +2075,7 @@ After applying your changes, you must verify that your job queue is stable and n
20682075
20692076
Run this query to check the queue's growth rate:
20702077
2071-
```
2078+
```nrql
20722079
-- Check for queue growth (a positive value means the queue is growing)
20732080
SELECT derivative(checksPending, 1 minute) AS 'Queue Growth Rate (per min)'
20742081
FROM SyntheticsPrivateLocationStatus
@@ -2083,45 +2090,45 @@ If the "Queue Growth Rate" is consistently positive, you need to install more SJ
20832090
The `parallelism` setting directly affects how many synthetics jobs per minute can be run. Too small a value and the queue may grow. Too large a value and nodes may become resource constrained.
20842091
20852092
<table>
2086-
<thead>
2087-
<tr>
2088-
<th style={{ width: "300px" }}>
2089-
Example
2090-
</th>
2091-
<th>
2092-
Description
2093-
</th>
2094-
</tr>
2095-
</thead>
2096-
<tbody>
2097-
<tr>
2098-
<td>
2099-
`parallelism=1`
2100-
`completions=1`
2101-
</td>
2102-
<td>
2103-
The runtime will execute 1 synthetics job per minute. After 1 job completes, the `CronJob` configuration will start a new job at the next minute. <DNT>**Throughput will be extremely limited with this configuration.**</DNT>
2104-
</td>
2105-
</tr>
2106-
<tr>
2107-
<td>
2108-
`parallelism=1`
2109-
`completions=6`
2110-
</td>
2111-
<td>
2112-
The runtime will execute 1 synthetics job at a time. After the job completes, a new job will start immediately. After 6 jobs complete, the `CronJob` configuration will start a new Kubernetes Job. <DNT>**Throughput will be limited.**</DNT> A single long-running synthetics job will block the processing of any other synthetics jobs of this type.
2113-
</td>
2114-
</tr>
2115-
<tr>
2116-
<td>
2117-
`parallelism=3`
2118-
`completions=24`
2119-
</td>
2120-
<td>
2121-
The runtime will execute 3 synthetics jobs at once. After any of these jobs complete, a new job will start immediately. After 24 jobs complete, the `CronJob` configuration will start a new Kubernetes Job. <DNT>**Throughput is much better with this or similar configurations.**</DNT>
2122-
</td>
2123-
</tr>
2124-
</tbody>
2093+
<thead>
2094+
<tr>
2095+
<th style={{ width: "300px" }}>
2096+
Example
2097+
</th>
2098+
<th>
2099+
Description
2100+
</th>
2101+
</tr>
2102+
</thead>
2103+
<tbody>
2104+
<tr>
2105+
<td>
2106+
`parallelism=1`
2107+
`completions=1`
2108+
</td>
2109+
<td>
2110+
The runtime will execute 1 synthetics job per minute. After 1 job completes, the `CronJob` configuration will start a new job at the next minute. <DNT>**Throughput will be extremely limited with this configuration.**</DNT>
2111+
</td>
2112+
</tr>
2113+
<tr>
2114+
<td>
2115+
`parallelism=1`
2116+
`completions=6`
2117+
</td>
2118+
<td>
2119+
The runtime will execute 1 synthetics job at a time. After the job completes, a new job will start immediately. After 6 jobs complete, the `CronJob` configuration will start a new Kubernetes Job. <DNT>**Throughput will be limited.**</DNT> A single long-running synthetics job will block the processing of any other synthetics jobs of this type.
2120+
</td>
2121+
</tr>
2122+
<tr>
2123+
<td>
2124+
`parallelism=3`
2125+
`completions=24`
2126+
</td>
2127+
<td>
2128+
The runtime will execute 3 synthetics jobs at once. After any of these jobs complete, a new job will start immediately. After 24 jobs complete, the `CronJob` configuration will start a new Kubernetes Job. <DNT>**Throughput is much better with this or similar configurations.**</DNT>
2129+
</td>
2130+
</tr>
2131+
</tbody>
21252132
</table>
21262133
21272134
If your `parallelism` setting is working well (keeping the queue at zero), setting a higher `completions` value (e.g., 6-10x `parallelism`) can improve efficiency by:
@@ -2131,7 +2138,7 @@ If your `parallelism` setting is working well (keeping the queue at zero), setti
21312138
21322139
It's important to note that the `completions` value should not be too large or the CronJob will experience warning events like the following:
21332140
2134-
```
2141+
```sh
21352142
8m40s Warning TooManyMissedTimes cronjob/synthetics-node-browser-runtime too many missed start times: 101. Set or decrease .spec.startingDeadlineSeconds or check clock skew
21362143
```
21372144
@@ -2166,7 +2173,7 @@ Setting the `fullnameOverride` is highly recommended to create shorter, more man
21662173
21672174
For example, to install two SJMs named `sjm-alpha` and `sjm-beta` into the `newrelic` namespace (both using the same `values.yaml` with your fixed parallelism):
21682175
2169-
```
2176+
```sh
21702177
# Install the first SJM deployment
21712178
helm upgrade --install sjm-alpha newrelic/synthetics-job-manager \
21722179
-n newrelic \
@@ -2175,7 +2182,7 @@ helm upgrade --install sjm-alpha newrelic/synthetics-job-manager \
21752182
--create-namespace
21762183
```
21772184
2178-
```
2185+
```sh
21792186
# Install the second SJM deployment to add capacity
21802187
helm upgrade --install sjm-beta newrelic/synthetics-job-manager \
21812188
-n newrelic \

0 commit comments

Comments
 (0)