-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Unified Provide Interface for Content Routers #10097
Comments
I don't see why this will require an IPIP, IIUC there are no spec things here. This is just agreement on what some Go code should look like so we can use multiple content advertising systems sanely.
We'll need to define the atomicity guarantees and guarantees around duplicates here. I'm not sure how this function is planned to be used, so probably easier to define things here after Start/Stop are well defined. |
I would propose it's idempotent
I would propose the contract is that nothing is promised until the method returns. failing during execution means state is left in an undefined state, and it is the caller's responsibility to re-call the method (see idempotency above) |
I think it's better if it's eventually transactional, if |
I agree with @willscott I can see multiple ways forward:
I have a preference for 3b because the retry logic may be content router specific and the application should make no assumption on the content router. Also 3b keeps the application informed of ongoing statuses, facilitating informed decision-making. This approach strikes a balance between delegation and oversight. |
cc @gammazero |
What does "advertised successfully" mean, at least re. IPNI?
|
In order to reduce noise from advertising short-term content, or advertising content availability on short-lived providers, it has been proposed that the provide system be online of a minimum of time before advertising content. A time of 12h has been suggested.
|
I'd say this is unreasonable to apply across the board (e.g. Amino DHT + IPNI). However, if say IPNI is not equipped to handle certain scenarios then given we're adding new functionality it seems reasonable to roll it out more slowly / carefully. For example, if IPNI is going to heavily punish users if they're not online the X times a day they get pinged and the user isn't running a high availability server it might not be worth allowing pushing data to IPNI at all. For something like the Amino DHT I might do something like:
@guillaumemichel wrote the comment and might disagree, but my 2c is that it means "That the provide system has successfully received (and persisted) the StartProvide request?". The other types of information (e.g.. particularly knowing if the data is ready to be fetched by a third party) seems like a useful API as well. This would hopefully allow easier standardization with DHT + IPNI since both could have local databases to write the Start/Stop Provide requests to as well as ways to track how much of the data they expect to be available (e.g. reprovided to the DHT recently, has been ingested by IPNI and we've passed our uptime checks, etc.). |
Checklist
Description
Problem Statement:
Currently, Kubo is responsible for managing the DHT's provide and reprovide operations. However, with the evolution of Content Routers beyond just the DHT, it's evident that the existing mechanism is not optimal. The reasons are:
Proposed Solution
To better streamline the providing mechanism across different content routers, we propose a unified interface that shifts the responsibility from Kubo to the individual content routers. The proposed interface includes:
StartProvide(CIDs)
: Instructs the content router to begin advertising that the Kubo node is storing the specified CIDs. This advertisement (or republishing) should continue until aStopProvide
is invoked for these CIDs.StopProvide(CIDs)
: Commands the content router to cease the advertisement for the given CIDs.ListProvides
: Returns the list of CIDs currently being advertised by the content router.Benefits
Feedback and Collaboration
The proposed interface is just a draft for now. The goal of this issue is to gather feedback and start a public discussion about specific interface needs for different content routers, especially IPNI and the DHT. This issue will probably be followed up by an IPIP in ipfs/specs, once we have listed the requirements of all (known) Content Routers.
References
cc: @masih @ischasny @aschmahmann @Jorropo @dennis-tra @iand
The text was updated successfully, but these errors were encountered: