meteorgan commented on PR #5562: URL: https://github.com/apache/opendal/pull/5562#issuecomment-2604615134
> Perhaps we should introduce `write_has_content_type` flags to indicate which metadata is available in the meta returned by the write operation. Would `write_returns_content_type` be a better name? > Checking the `meta.content_type()` may pass the test but is meaningless to users; it could also potentially conceal incorrect implementations that developers can simplely return `Metadata::default()` to pass all tests. if a service returns `Metadata::default()`, it indicates that it implements nothing. There's a chance that a developer intended to return some contents but forgot set the fields. Unfortunately, the tests can't catch this. > And it makes it more difficult for us to determine the implementation status of various services. Make sense ! Making it explicit is better. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
