Repository navigation
stash: switch serialization to JSON - #14298
Merged
Merged
Conversation
Contributor
Author
|
madelynnblue
marked this pull request as ready for review
August 24, 2022 02:32
jkosh44
approved these changes
Aug 24, 2022
jkosh44
left a comment
Contributor
There was a problem hiding this comment.
LGTM, I had a couple of questions and one small comment. I'd also be very interested in a performance comparison of using JSON vs Protobuf.
This removes protobuf for JSON. While JSON is easier to introspect in the backing store, it is also easier to incorrectly migrate. However, we were already using prost derives, which are equally unsafe against migrations as JSON.
A few types were manually serialized to strings or byte arrays. Switch all of those to their existing JSON types, making them completely queryable in their backing data store.
Contributor
Author
|
Didn't run benchmarks. Might later, but not a priority now. |
def-
added a commit
to def-/materialize
that referenced
this pull request
Nov 21, 2026
The byte (de)serialization helpers, the VersionedStorageUsage accessors and From<bool> for SchedulingDecisionV1 have no callers left, and deserialize was the library's only use of anyhow. This deletes 46 lines of uncalled code and one dependency, and cargo check --all-targets of mz-audit-log, mz-catalog, mz-sql and mz-adapter still passes. The helpers lost their last callers in MaterializeInc#14298, MaterializeInc#29127 and MaterializeInc#38101. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Ca97tqbjzmJpgDjc4QXDyG
def-
added a commit
to def-/materialize
that referenced
this pull request
Nov 23, 2026
The byte (de)serialization helpers, the VersionedStorageUsage accessors and From<bool> for SchedulingDecisionV1 have no callers left, and deserialize was the library's only use of anyhow. This deletes 46 lines of uncalled code and one dependency, and cargo check --all-targets of mz-audit-log, mz-catalog, mz-sql and mz-adapter still passes. The helpers lost their last callers in MaterializeInc#14298, MaterializeInc#29127 and MaterializeInc#38101. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This makes introspection in the backing cockroach databases possible with merely a SQL connection. This PR contains no migration code and must not be merged until there is migration code (which would be added as another commit into this PR) or we have another flag day where we start all instances over from scratch (in which case this PR can be merged as is).
Motivation
Checklist
This PR has adequate test coverage / QA involvement has been duly considered.
This PR evolves an existing
$T ⇔ Proto$Tmapping (possibly in a backwards-incompatible way) and therefore is tagged with aT-protobuflabel.This PR includes the following user-facing behavior changes: