Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traces type consolidation #180

Merged
merged 34 commits into from
Sep 9, 2024
Merged

Traces type consolidation #180

merged 34 commits into from
Sep 9, 2024

Conversation

stephlow
Copy link
Member

@stephlow stephlow commented Aug 22, 2024

The rust and ts apis where quite a bit different in handling traces / spans, which made it hard to make the ingestion engine compatible without a lot of effort.
This PR aims to unify the rust api and the ts api by trimming down the unnesecerry stuff from both sides and consolidate the api's, both with their native impls, as it's currently the case

original slack discussion

ts

  • Moves the Otel related types to the shared package
  • Introduce response specific types
  • Removed raw_payload field
  • Rename parsed_payload to inner
  • Provide a type inferred schema, using drizzle, for the json field inner (prev. parsed_payload)
  • Loads of imports moved to packages/types

rust

  • Removes ts_compat models that were used to bridge the gap, introduced in Implement TypeScript API compatible AttributeMap #199
  • Rename paths to follow the ts api pattern /api/traces -> /v1/traces
  • Serde serializion adjustements to make the AttributeMap compatible with the ts api
  • Updated the TraceSummary to reflect the ts api

@stephlow stephlow changed the title Type consolidation Traces type consolidation Aug 22, 2024
@stephlow stephlow force-pushed the type-consolidation branch from 8651af2 to dd3b454 Compare August 27, 2024 14:41
Copy link

pkg-pr-new bot commented Sep 2, 2024

Open in Stackblitz

pnpm add https://pkg.pr.new/fiberplane/fpx/@fiberplane/studio@180
pnpm add https://pkg.pr.new/fiberplane/fpx/@fiberplane/hono-otel@180

commit: 7943e26

@stephlow stephlow marked this pull request as ready for review September 5, 2024 14:51
@stephlow stephlow requested a review from a team as a code owner September 5, 2024 14:51
@stephlow stephlow merged commit 2b5b114 into main Sep 9, 2024
3 checks passed
@stephlow stephlow deleted the type-consolidation branch September 9, 2024 12:57
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.

3 participants