Skip to content

docs: schema validation testing scripts#61

Merged
KeranYang merged 4 commits intomainfrom
feat/testing-scripts
Feb 26, 2026
Merged

docs: schema validation testing scripts#61
KeranYang merged 4 commits intomainfrom
feat/testing-scripts

Conversation

@ccm32004
Copy link
Collaborator

uploaded scripts used to test schema validation

Signed-off-by: Cece Ma <mayuqing131@gmail.com>
Signed-off-by: Cece Ma <mayuqing131@gmail.com>
@ccm32004 ccm32004 requested a review from KeranYang February 25, 2026 16:30
@ccm32004 ccm32004 marked this pull request as ready for review February 25, 2026 16:30

if [[ $# -lt 1 ]]; then
echo "Usage: $(basename "$0") <encoder-script> [topic] [num-messages]" >&2
echo " encoder-script Script that writes one message to stdout (e.g. avro_encode_full.py)." >&2
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to ask bash to execute python code so that we don't need to pass a script to it?

# No arguments; message body is hardcoded. Use to send valid Avro that doesn't match full schema.
# Output: Avro binary to stdout. Prefers 'avro' library; falls back to hand-rolled encoding.

import io
Copy link
Contributor

Choose a reason for hiding this comment

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

avro encode name only and avro encode full are specific. Can we have one generic script that works for any schema? we can take a schema file path as input parameter.

Signed-off-by: Cece Ma <mayuqing131@gmail.com>
@ccm32004 ccm32004 requested a review from KeranYang February 26, 2026 16:05
@KeranYang KeranYang merged commit b279b08 into main Feb 26, 2026
2 checks passed
@KeranYang KeranYang deleted the feat/testing-scripts branch February 26, 2026 17:21
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.

2 participants