Skip to content

Multiple files sharing support 🖼️+🖼️ - Overview #11411

Description

@Antreesy

Use message.referenceId for group upload identification

Reasoning:

File uploads posted as a separate messages with no connection. There is no way to track, whether they were sent together or not

Current state:

Web is using 30-seconds threshold between uploaded files to count them as 'uploaded together'. Other clients have not implemented yet.

Suggestion:

  • Keep output of refererenceId as before for backward compatibility: SHA256 format (64 chars length, [a-z0-9] characters allowed)
  • Construct in following way:
60 chars (0 .. 59) 1 char - 3 chars (61 .. 63)
unique upload identifier, SHA256 sliced to 60 characters delimiter numeric order of file in upload, e.g. 001
  • On each client:
    • write referenceId in following format when posting from now on
    • backward compatibility - treat all old/new referenceIds as in the old format (64 chars, no logic behind, no decoding) - e.g. keep 10 seconds threshold on Web for grouping
    • feature support - slice each referenceId, validate against 32(string)-3(int)-29(string) format - if passes, treat as new and group files using it

Support state

Write in new format:

  • Web / Desktop
  • iOS
  • Android

Read new format (assume it's not breaking previous uploads):

  • Web / Desktop
  • iOS
  • Android

Usage (read referenceId for combining messages)

Old links

Multiple files sharing support 🖼️+🖼️ - API

Multiple files sharing support 🖼️+🖼️ - Frontend

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions