Skip to content

[SPIKE option B] Event oneOf + hydrate missing source to device (INTER-2457) - #200

Closed
JuroUhlar wants to merge 3 commits into
mainfrom
spike/INTER-2457-event-oneof
Closed

JuroUhlar wants to merge 3 commits into
mainfrom
spike/INTER-2457-event-oneof

Conversation

@JuroUhlar

@JuroUhlar JuroUhlar commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor
  • Unflattened Event oneOf wrapper (EventDevice | EventEdge).
  • Missing source now deserializes as EventDevice and hydrates source to device.
  • source: edge is unchanged.

Compare with option C: #201

Do not merge.

Discussion point: omit vs flatten

Option B keeps the generated union. Callers must branch on EventDevice / EventEdge. Option C flattens Event so existing event.Identification call sites still compile.

Known issue: CI will fail

Existing API tests still read flat Event fields (EventId, Identification, …) and do not compile. That is the spike.

INTER-2457. Regenerated Event as a oneOf wrapper to show the compile break. Do not merge.
@changeset-bot

changeset-bot Bot commented Aug 31, 2026 •

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 2b9b129

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions

github-actions Bot commented Aug 31, 2026 •

Copy link
Copy Markdown
Contributor

⚠️ Template files and generated files are not in-sync.

Following files do not match corresponding templates:
src/Fingerprint.ServerSdk/Api/FingerprintApi.cs src/Fingerprint.ServerSdk/Model/Event.cs src/Fingerprint.ServerSdk/Sealed.cs

To fix this warning, make sure template files are up-to-date, and generate files by running the following command:

bash ./generate.sh

@JuroUhlar JuroUhlar changed the title [SPIKE] Event oneOf discriminated union (INTER-2457) [SPIKE option B] Event oneOf + hydrate missing source to device (INTER-2457) Sep 6, 2026
@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Wrong commit message format detected

We use Semantic Commit Messages in our project.

Warning
Probably you forgot to activate local git hooks.

Run the next command in the project root to activate local hooks:

sh ./install_hooks.sh

More info you can find in job logs

Commitlint Errors

Commit: 7f58569 `chore: SPIKE Event oneOf discriminated union

INTER-2457. Regenerated Event as a oneOf wrapper to show the compile break. Do not merge.`
Errors:

  • subject must not be sentence-case, start-case, pascal-case, upper-case

@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

⚠️ This PR doesn't contain any changesets. If there are user-facing changes, don't forget to run:

pnpm exec changeset

to create a changeset.

@JuroUhlar
JuroUhlar marked this pull request as draft September 7, 2026 09:05
@JuroUhlar

Copy link
Copy Markdown
Contributor Author

This was a prototype done as part of a spike. Closing now, still usable as a reference during the production implementation.

@JuroUhlar JuroUhlar closed this Sep 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant