|
|
|
|
|
by cyberax
107 days ago
|
|
Definitely interesting and seems to be a nice improvement over Protobuf. Especially for Python, Protobuf bindings for Python were made probably after taking a lot of hallucinogenic drugs. I like constants, great addition. Things that I'll miss: 1. Oneof fields. There are enums, but it looks like it's not possible to have ad-hoc onefos? 2. Streaming requests/responses. 3. Introspection and annotations. 4. Go bindings. |
|
1. You can create an enum with just "wrapper" fields, that's exactly like a oneof
2. Totally fair, I'm planning to work on this later this year, probably Q3 (priority is adding support to 4 more languages, and then I'll get to it)
3. So there is introspection in the 6 targeted languages, and I think I did it a bit better than protobuf because it generally has better type safety. Example in C++: https://github.com/gepheum/skir-cc-example/blob/main/string_...;
Typescript: https://skir.build/docs/typescript#reflection
I realize I haven't documented it in Python (although it is available and generally the same API as Typescript), will fix that
However, you're right that there is no support yet for annotations. Still trying to gauge whether that's needed
4. Assuming you mean Go language: working on that now, hoping to have C#, Go, Rust and Swift in the next 2-3 months.