@checkstack/healthcheck-jenkins-backend 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
1
  # @checkstack/healthcheck-jenkins-backend
2
2
 
3
+ ## 0.2.1
4
+
5
+ ### Patch Changes
6
+
7
+ - f533141: Enforce health result factory function usage via branded types
8
+
9
+ - Added `healthResultSchema()` builder that enforces the use of factory functions at compile-time
10
+ - Added `healthResultArray()` factory for array fields (e.g., DNS resolved values)
11
+ - Added branded `HealthResultField<T>` type to mark schemas created by factory functions
12
+ - Consolidated `ChartType` and `HealthResultMeta` into `@checkstack/common` as single source of truth
13
+ - Updated all 12 health check strategies and 11 collectors to use `healthResultSchema()`
14
+ - Using raw `z.number()` etc. inside `healthResultSchema()` now causes a TypeScript error
15
+
16
+ - Updated dependencies [9faec1f]
17
+ - Updated dependencies [827b286]
18
+ - Updated dependencies [f533141]
19
+ - Updated dependencies [aa4a8ab]
20
+ - @checkstack/backend-api@0.3.0
21
+ - @checkstack/common@0.2.0
22
+ - @checkstack/healthcheck-common@0.3.0
23
+
3
24
  ## 0.2.0
4
25
 
5
26
  ### Minor Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@checkstack/healthcheck-jenkins-backend",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "type": "module",
5
5
  "main": "src/index.ts",
6
6
  "scripts": {
package/src/strategy.ts CHANGED
@@ -10,6 +10,8 @@ import {
10
10
  import {
11
11
  healthResultNumber,
12
12
  healthResultString,
13
+ healthResultBoolean,
14
+ healthResultSchema,
13
15
  } from "@checkstack/healthcheck-common";
14
16
  import type {
15
17
  JenkinsTransportClient,
@@ -46,8 +48,8 @@ export const jenkinsConfigSchema = z.object({
46
48
  export type JenkinsConfig = z.infer<typeof jenkinsConfigSchema>;
47
49
 
48
50
  /** Per-run result metadata */
49
- const jenkinsResultSchema = z.object({
50
- connected: z.boolean().meta({
51
+ const jenkinsResultSchema = healthResultSchema({
52
+ connected: healthResultBoolean({
51
53
  "x-chart-type": "boolean",
52
54
  "x-chart-label": "Connected",
53
55
  }),
@@ -65,7 +67,7 @@ const jenkinsResultSchema = z.object({
65
67
  type JenkinsResult = z.infer<typeof jenkinsResultSchema>;
66
68
 
67
69
  /** Aggregated metadata for buckets */
68
- const jenkinsAggregatedSchema = z.object({
70
+ const jenkinsAggregatedSchema = healthResultSchema({
69
71
  successRate: healthResultNumber({
70
72
  "x-chart-type": "gauge",
71
73
  "x-chart-label": "Success Rate",