Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MSC2380: Matrix Media Information API #2380

Open
wants to merge 2 commits into
base: old_master
Choose a base branch
from

Conversation

anoadragon453
Copy link
Member

@anoadragon453 anoadragon453 commented Dec 5, 2019

@anoadragon453 anoadragon453 changed the title Matrix Media Information API MSC2380: Matrix Media Information API Dec 5, 2019
content. Given the content types are optional, clients may not rely on the
information being present anyways.

This would also be yet another HTTP call that clients would have to perform.
Copy link
Member

Choose a reason for hiding this comment

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

It would be great if data model in this MSC be aligned with that used in the related msgtypes (m.file etc.): e.g., the current convention uses w and h instead of width and height. Alternatively, this MSC could be put into relationship to extensible events (making it a much longer story) because the current convention, admittedly, is suboptimal.

the content repository cannot identify the type, it must return
application/octet-stream.

The size is just the size in bytes.
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
The size is just the size in bytes.
The `size` is just the size in bytes.

}
```

The content repository must attempt to identify the content independently of
Copy link
Contributor

Choose a reason for hiding this comment

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

This is probably out-of-scope for this MSC but....why do clients specify the content type at all, then? Wouldn't it be better if the server always determines it and adds it to the event, then? That way people receiving the image events could also be sure that the content type is accurate.

Copy link
Contributor

Choose a reason for hiding this comment

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

like, it might make more sense for the server to replace the "info" blob rather than the client to specify it.

Copy link
Member

Choose a reason for hiding this comment

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

This recommendation is actually a terrible idea because encrypted attachments are blobs.

Copy link
Contributor

Choose a reason for hiding this comment

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

Right, forgot for a moment encryption exists 👍

@turt2live turt2live added the kind:feature MSC for not-core and not-maintenance stuff label Apr 20, 2020
@turt2live turt2live added the needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. label Jun 8, 2021

Authored by Travis Ralston (@turt2live)

Knowing how large a given piece of content actually is before downloading it can
Copy link
Contributor

Choose a reason for hiding this comment

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

I wonder if the same thing could be achieved with a HEAD request in the end. You'd lose support for custom metadata, but if you just want to know the size and type it's a good start that reduces the amount of reinvention we need to do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:feature MSC for not-core and not-maintenance stuff needs-implementation This MSC does not have a qualifying implementation for the SCT to review. The MSC cannot enter FCP. proposal A matrix spec change proposal
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Content repository: No API for finding info on a document (SPEC-448)
5 participants