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

Remove old telemetry event variants and transformation layer #25179

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

JosephTLyons
Copy link
Collaborator

@JosephTLyons JosephTLyons commented Feb 19, 2025

Now that all events have been migrated to use telemetry::event!, we can remove the old event variants. It looks like the last round of event migration code landed in stable in v0.173 (#24102). I don't plan to land this for a few weeks, to give users more time to migrate >= v0.173.

As a side note, I've renamed AssistantEvent to AssistantEventData, as it no longer represents an event itself, but simply data being bundled and injected into an event.

Once landed, we will need to deploy a new collab.

Release Notes:

  • N/A

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Feb 19, 2025
@JosephTLyons JosephTLyons changed the title Remove old telemetry events and transformation layer Remove old telemetry event variants and transformation layer Feb 19, 2025
),
};

let mut event_properties = serde_json::to_value(&event.event.event_properties).unwrap();
if let serde_json::Value::Object(ref mut map) = event_properties {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm assuming events in the old format will get rejected here?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JosephTLyons the JSON format we send over the wire can't easily change as we have to update server/client in tandem.

It's totally fine to delete the old events if we don't want to process them anymore.

Copy link
Collaborator Author

@JosephTLyons JosephTLyons Feb 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At some point, users will be upgraded to a version where all events are generated via event! and those events no longer interact with the code I deleted in collab, as it was only meant to handle the old historical event format. Do I need to roll back the change that flattens the FlexbileEvent out then? I only removed that as it would be the only variable left in the event enum, but if that changes the json format, I can see why we shouldn't do that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think so (unfortunately) as otherwise there'll be a hard cut-off date. If you could have collab continue parsing either format that would also work.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I rolled back to FlexibleEvent. The idea of having collab parse the wrapped Event and the event data flattened out is appealing, and then we could just remove the wrapped one later down the line, but not sure how to deal with that now. I think this should be good to land after a few more releases. Really just wanted that migration code out of collab.

@JosephTLyons JosephTLyons force-pushed the remove-old-telemetry-events-and-transformation-layer branch from e3d1c0f to c95a78c Compare February 21, 2025 02:34
@JosephTLyons JosephTLyons force-pushed the remove-old-telemetry-events-and-transformation-layer branch from c95a78c to ce9769e Compare February 21, 2025 02:57
@ConradIrwin
Copy link
Member

ConradIrwin commented Feb 21, 2025 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla-signed The user has signed the Contributor License Agreement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants