Skip to content

Instantly share code, notes, and snippets.

@mjsqu
Created March 6, 2025 08:29
Show Gist options
  • Save mjsqu/d494d8a8276f7d84bea9d99866b60d89 to your computer and use it in GitHub Desktop.
Save mjsqu/d494d8a8276f7d84bea9d99866b60d89 to your computer and use it in GitHub Desktop.
Meltano tap emulator
import json
import sys
size = int(sys.argv[1])
stream_name = "speed_test"
schema_message = {
"type": "SCHEMA",
"stream": stream_name,
"schema": {
"properties": {
"id": {
"type": "integer"
}
}
},
"key_properties": [
"id"
]
}
print(json.dumps(schema_message))
for i in range(size):
print(json.dumps({"type": "RECORD", "stream": stream_name, "record": {"id": i}}))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment