[rust-server] how to cope with loss of `file` type?
Created by: bjgill
Description
Swagger v2 had three types to represent binary data: {type: string, format: binary}
, {type: string, format: byte}
, and {type: file}
. In OpenAPI v3, we lost the last of these.
In rust-server
, binary and byte were treated identically - as swagger::ByteArray
. File was Box<Future<Item=Option<Box<Stream<Item=Vec<u8>, Error=Error> + Send>>, Error=Error> + Send>
.
I'm not sure what the correct approach for OpenAPI v3 is. Should we keep one of binary/byte as swagger::ByteArray
and move the other to use the same type as file used to? Do we keep binary/byte as-is and add in some rust-server
-specific workaround for those wanting to retain the old file behaviour?
openapi-generator version
OpenAPI declaration file content or url
Command line used for generation
Steps to reproduce
Related issues/PRs
Discovered in https://github.com/OpenAPITools/openapi-generator/issues/307