Sample Data (WCSC & WPCA 2026 Series)

1. Overview

The sample-data set provides realistic, true-to-production event-operations data for two real 2026 cycling series. Where the generic faker test data is throwaway scaffolding for unit/UI testing, this set mirrors the actual structure operators work with — enabling number/tag assignment, EP import and result import to be exercised against genuine event graphs.

It is extracted from wpca_prod with real IDs preserved, and loaded only in development, under its own Liquibase context sample-data (changeset prefixes SAMPLE-W for WCSC and SAMPLE-P for WPCA). It layers on top of faker rather than replacing it — faker ids stay below 100, sample-data ids above.

Not fixtured: event_participant and race_result. These are loaded later through the bulk import API so the import pipeline itself is exercised. The fixtures stop at the event-setup graph (series → events → categories → races → result sets) plus the full number/tag inventory.

2. Data Location

Repository Path

event-database (CSVs)

src/main/resources/liquibase/sample-data/{wcsc-2026,wpca-2026}/

event-database (loaders)

src/main/resources/liquibase/changelog/sample-data-{wcsc,wpca}-2026.xml

event-database (wipe)

src/main/resources/liquibase/changelog/delete-sample-data.xml

3. Series Identities

WCSC WPCA

Organisation

9 — Western Cape School Cycling (parent: 2, Cycling SA)

4 — Western Province Cycling Association

Series

9 — "2026 Schools League"

10 — "2026 Road League"

Discipline

Mountain Bike (XCO)

Road

Number type / Tag type

78 / 12

77 / 15

Organisation 9 is shared with faker (the generic faker org-9 row was repurposed: renamed to "Western Cape School Cycling", parent_id 2). loadUpdateData is an idempotent upsert, so the shared row is the single, intentional sample-data → faker coupling.

4. WCSC — 2026 Schools League (Series 9)

Three MTB cross-country (XCO) events, each with a full race graph.

Event ID Name Date

116

Devonbosch

2026-03-14

117

Bethlehem Farm

2026-04-11

118

Rheebokskloof

2026-05-16

Object Count

Series categories (event_category, series-level)

22

Event categories (event_category, event-level)

66

Courses

21

Event race types (XCO, race_type 20)

3

Races

66

Program entries

63

Start groups

66

Result sets

66

Race number inventory (unassigned)

4 206

Tag inventory (unassigned)

4 206

5. WPCA — 2026 Road League (Series 10)

Eleven road events (IDs non-contiguous; 122–126 absent). Mostly bunch road races, plus a team time trial (128), hill climb (133) and individual TT (134).

Event ID Name Date

119

Duynefontein

2026-03-22

120

Redhill

2026-03-29

121

Killarney 1

2026-04-12

127

Simonstown

2026-04-19

128

Team Time Trial

2026-04-26

129

Paardeberg

2026-05-03

130

Philadelphia

2026-05-17

133

Hill Climb

2026-05-24

131

Slent

2026-05-31

134

Individual TT

2026-05-31

132

Killarney 2

2026-06-14

Object Count

Series categories (event_category, series-level)

10

Event categories (event_category, event-level)

101

Courses

8 (4 real + 4 synthesized — see below)

Event race types

9 (4 real + 5 synthesized — see below)

Races

72

Result sets

76

Race number inventory (unassigned)

1 681

Tag inventory (unassigned)

241

WPCA has no program_entry/start_group fixtures — those tables are empty for this series in prod.

5.1. Synthesized rows (fixture-only corrections)

In production, WPCA events 128/129/130/133/134 reused event 121’s event_race_type (177) and course (337) for their road races. Because Race.getEvent() derives the event from event_race_type → event, all those races resolved to event 121, making per-event operations untestable.

To fix this in the fixture (only), the loaders add per-event Road Race rows:

  • event_race_type ids 9001–9005

  • course ids 9102–9105 (event 128 keeps its real course 338)

and repoint the affected 40 races to them. Any event_race_type/course id ≥ 9000 in the WPCA fixture is a deliberate fixture-only correction, not a real wpca_prod id. These rows are not reproduced by the extraction script and must be re-applied after any refresh from prod.

6. Number & Tag Inventory

The full real pool of race numbers and tags is loaded unassigned (person_id and last_used nulled), since persons/EPs are not fixtured and those FKs point at wp_users:

Inventory WCSC WPCA Total

Race numbers

4 206

1 681

5 887

Tags

4 206

241

4 447

This gives operators a realistic pool to assign from when exercising number/tag UI flows.

7. Loading & Coexistence

Wired into wpca-database.xml after the faker block: delete-sample-data.xml runs first (reverse-FK wipe scoped to id > 100 / by type id, so faker rows are untouched), then the two sample loaders in FK order (number/tag types → series → categories → events → courses → event race types → races → program/start groups → result sets → number/tag inventory).

The design is additive coexistence, not retirement of the faker event domain: the generic race/start_group/program_entry rows are loaded by run-once <loadData> in schema-migration changelogs, so editing or deleting them would break Liquibase checksums on existing stage/prod databases. The faker event domain therefore stays intact; sample-data layers on top with disjoint high IDs.

8. Enabling / Disabling

The set is loaded only when the sample-data context is active. In dev it is enabled in admin-service/…​/config/application-dev.yml:

spring:
  liquibase:
    contexts:
      - dev
      - faker
      - sample-data   # remove to skip the realistic WCSC/WPCA 2026 fixtures

Production and tunnel profiles use only dev, so sample-data never loads outside development.