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

CORE-8964 Add protobuf support to existing ducktape suite for schema evolution. #24998

Open
wants to merge 8 commits into
base: dev
Choose a base branch
from

Conversation

oleiman
Copy link
Member

@oleiman oleiman commented Feb 1, 2025

Test semantics don't change. Builds on a PR that is still in flight; first interesting commit is 12fbeae

Backports Required

  • none - not a bug fix
  • none - this is a backport
  • none - issue does not exist in previous branches
  • none - papercut/not impactful enough to backport
  • v24.3.x
  • v24.2.x
  • v24.1.x

Release Notes

  • none

Checks whether two structs are precisely equivalent[1] using a simultaneous
depth-first traversal.

The use case is for performing schema lookups on cached table metadata by type
rather than by ID.

[1] - Exclusive of IDs but inclusive of order.

Signed-off-by: Oren Leiman <[email protected]>
Search for a schema that matches the provided type.

Signed-off-by: Oren Leiman <[email protected]>
For catalog_schema_manager, we can use this to perform a type-wise schema
lookup on cached metadata, resulting in table_info bound to an arbitrary
schema rather (possibly) other than the current table schema.

Also update catalog_schema_manager::get_ids_from_table_meta to try a type-wise
lookup before performing the usual compat check. This way we can short-circuit
a schema update if the desired schema is already present in the table.

Also pass source struct to check_schema_compat by value to avoid polluting
cached table metadata with compat annotations.

Signed-off-by: Oren Leiman <[email protected]>
Rather than current schema ID. By this point we should have ensured that the
record schema exists in the table (either historically or currently). This
change lets us look past the current schema to build a writer for historical
data.

Signed-off-by: Oren Leiman <[email protected]>
Specifically move producer and table verification methods onto AvroSchema in
preparation for extending to something more generic (to support both avro &
protobuf schemas)

Signed-off-by: Oren Leiman <[email protected]>
Basically what it says on the tin. Avoid changing the semantics of any test
cases, just add the ability to produce protobuf records of the same structure
as the current avro ones.

Signed-off-by: Oren Leiman <[email protected]>
@oleiman oleiman force-pushed the dlib/core-8964/proto-dt-tests branch from def67d8 to 76ba6c1 Compare February 1, 2025 04:01
@vbotbuildovich
Copy link
Collaborator

CI test results

test results on build#61476
test_id test_kind job_url test_status passed
rptest.tests.compaction_recovery_test.CompactionRecoveryTest.test_index_recovery ducktape https://buildkite.com/redpanda/redpanda/builds/61476#0194bff2-1f22-4a00-bbb9-e00f9a21ef1f FLAKY 1/2
rptest.tests.compaction_recovery_test.CompactionRecoveryTest.test_index_recovery ducktape https://buildkite.com/redpanda/redpanda/builds/61476#0194bff6-7f55-41b8-aff2-61b035739a69 FLAKY 1/3
rptest.tests.compaction_recovery_test.CompactionRecoveryUpgradeTest.test_index_recovery_after_upgrade ducktape https://buildkite.com/redpanda/redpanda/builds/61476#0194bff6-7f53-46bf-bb50-0fe1f01d759b FLAKY 1/2
storage_single_thread_rpunit.storage_single_thread_rpunit unit https://buildkite.com/redpanda/redpanda/builds/61476#0194bfad-ded7-4726-95df-d93da472fae5 FLAKY 1/2

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.

2 participants