-
Notifications
You must be signed in to change notification settings - Fork 342
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
Feeds: arbitrary payload instead of arbitrary data structure #1311
Comments
What do you believe are the practical use cases of using BSON type of encoding for feeds instead of the current way of doing things? |
Hey! So I can go on, the goal of this approach is decrease the number of unneccessary requests while utilize anyhow the remaining unused data of the feed chunk. |
I believe this is a good suggestion, but I see it as a nice to have. A higher priority for the dev team is hardening Bee. |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
related PR that aims at JSON serialisation in Feeds and also points out the current error message that prevents to support this behaviour in application layer: fairDataSociety/swarm-feeds#2 |
@nugaon feeds in their current form enforce a strict data structure, because that's part of the definition of |
@acud you are right about its logic can be implemented outside of the Bee. |
Legacy feed swarm implementation had no restriction on the payload. Was there a reason to make it of |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
. |
closed by #4677 |
User story
Story
As I noticed, the payload of Feeds is an arbitrary data structure currently with only the time of the upload and the reference of a Content Addressed Chunk.
I think it is completely a waste of available chunk payload (in case of passing unencrypted reference, it uses 40 bytes from <4096 bytes).
Secondly, what if I want to add to this update more than one reference of swarm content? Or I want to attach metadata as well? This rigid data structure does not let me do that.
Seems neccessary to make a decision on a more flexible data structure first.
My suggestion is to use BSON instead of this current one, which could be ideal for our use-case (bee-js).
Acceptance criteria
On feed update it is possible to pass arbitrary data that is retrievable later.
It could make place for other specific use-cases as well, like dynamic content references in dApp environment (e.g. HTML link references, etc.) and other later.
The interface of this payload thereby has to be in generic type, but you still could protocolize for specific use-cases, like this before mentioned one.
Background
This approach proposal came up on the feed interface PR of bee-js.
The text was updated successfully, but these errors were encountered: