Skip to content

ref(server): Reduce size of item headers struct#5671

Open
Dav1dde wants to merge 1 commit intomasterfrom
dav1d/slimify-items2
Open

ref(server): Reduce size of item headers struct#5671
Dav1dde wants to merge 1 commit intomasterfrom
dav1d/slimify-items2

Conversation

@Dav1dde
Copy link
Member

@Dav1dde Dav1dde commented Feb 27, 2026

Reduces the size of the item headers struct by (de-)serializing on demand.

Some leftover fields are fields which are not serialized, we can either also serialize them or some of them can already be removed in a follow-up.

A nice simplification is that, ContentType and AttachmentType are now Copy. In another follow-up the item type can also be moved into the inner value and Unknown(String) changed to Unknown.

Without any further changes this reduces the ItemHeaders size from 320 bytes to 128.

@Dav1dde Dav1dde self-assigned this Feb 27, 2026
@Dav1dde Dav1dde requested a review from a team as a code owner February 27, 2026 15:35
@Dav1dde Dav1dde force-pushed the dav1d/slimify-items2 branch from eacf74a to 46305f6 Compare February 27, 2026 15:39
@Dav1dde Dav1dde force-pushed the dav1d/slimify-items2 branch from 46305f6 to 6b85afb Compare February 27, 2026 16:00
@Dav1dde Dav1dde force-pushed the dav1d/slimify-items2 branch 2 times, most recently from 44f5a2c to cbfe51f Compare February 27, 2026 16:13
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

@Dav1dde Dav1dde force-pushed the dav1d/slimify-items2 branch from cbfe51f to 3d37592 Compare February 27, 2026 17:08
@Dav1dde Dav1dde force-pushed the dav1d/slimify-items2 branch from 3d37592 to 562b7f5 Compare February 27, 2026 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant