-
Notifications
You must be signed in to change notification settings - Fork 2
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
Additional attributes per media item #15
Comments
Conflict resolution:
|
How can a client app know when a specific change to one of these files should be indicated as "downloadable" in the album list for the Neebla app? unreadCounts: Each change applies to just a single userId-- i.e., for a single user. And as I’m conceiving the UI currently, other users wouldn’t know about the unreadCount for self. And self doesn’t need to have the UI marked as downloadable in the album-- rather self just needs the unreadCount updated on a specific item. Keywords: Other users should have this update marked as downloadable in the album, but not self. Self already knows about the change. Other users don’t yet know about the change. Badges: Other users should have this update marked as downloadable in the album, but not self. Self already knows about the change. Other users don’t yet know about the change. Note: The typical cases for uploading files (v0 or vN) line up with with the keyword and badges cases. For a v0 upload self knows about the change but others don't yet know. For a vN upload (i.e., so far this has been for a comment), self knows about the change, but others don't yet know. |
My plan is to add a table to the server that tracks when specific changes should be indicated as "downloadable" to the user. These table entries will be returned as part of FileIndex results when a summary is requested (not a FileIndex for a specific sharing group). The entries will expire -- say in a week -- so that we don't accumulate too many of them in the table, and also have to return too many of them in a FileIndex request. Each Upload request will have to supply this information-- what users need to have their album marked as downloadable as a result of a specific change to a file. Those change include both v0 files and vN files. |
With the change to I need a fallback for this condition. Options:
What if I updated a last-synced date for an album when the general sync (not album specific) was done? That way, it wouldn't force the album indicator to be set to true unless the app hadn't been used (i.e., no general sync) for an interval of time. This would also cover the case of just having been invited to an album.
|
There is another tricky issue with these files representing additional media attributes. That is: Who ought to own them, and when do they get created?
I'm not sure if this mode of creating a file as a different user should be something controlled by the requesting user. Or if somehow the need for it should be detected by the server. I think it should always be in the context of an existing "object" in Neebla terms. I.e., an existing file group in server terms. So, the FileIndex table will have one or more rows with the existing fileGroupUUID. A client can know it is adding a file to an existing file group-- it will be some conditional code which is effectively doing a migration. There is however, a race condition. Two users could be trying to view the large image for the same media item in Neebla and trying to add the new media attribute file at the same time. One of them should fail. The new media attribute file will have a new This is an interesting kind of failure, however. It is a "permanent" failure. One which cannot be resolved by retries. Clients don't have a means currently to deal with this kind of failure. To reduce the possibilities of this kind of failure, we could have only owning/creating users create the new additional attribute files. This would make the process of migration really slow, however. |
For I could make some change in Neebla itself, but I'd need to add some tracker objects to track (and buffer) the intended changes if more than some limit of uploads was started. Or, I could make this change to |
I list several pieces of functionality below, because I think they naturally group together.
Cross-device unread counts
Unread counts for specific media items/albums that can be shared with other devices for the specific user. Also so that if you have to re-install the app it preserves unread counts.
Keyword support for media
It would be nice to have keywords per media item. Not sure if it should be a new file or part of the discussion. Definitely need some change to a change resolver. Keywords could be added or removed. But not changed specifically I think. Possibly single word keywords. Or “atomic” phrases that can’t be edited-- but can be removed and then added. Each user could change a keyword (e.g., remove one) that someone else added. These keywords are shared across users.
Marking media items with a limited set of visual icons aka Badges
One per user. E.g., you could mark the media item with “Thumbs up”. Dany’s badge idea: Old vs. new testament.
My plan is to implement this as a single additional file per media item.
Implemented as a JSON structure, this could look like the following for a specific media item:
There are a couple of technical challenges with this change:
How do we do conflict resolution on these files?
How can a client app know when a specific change to one of these files should be indicated as "downloadable" in the album list for the Neebla app?
I address these below.
The text was updated successfully, but these errors were encountered: