Standardize Storage AskProtocol v2 #254
Replies: 11 comments 13 replies
-
Initial FIP draft created at #224 Simple SummaryThe goal of AskProtocol v2 is to help with the discovery between the client and storage providers before making a storage deal proposal. As the first step of the SP discovery, clients can send details of their proposed deal to the storage provider, and the storage provider should be able to respond to the proposal (with accept or reject, price and additional service offer). Note that the ask protocol is not designed to handle back and forth deal negotiations. AbstractAskProtocol v2 aims to improve the existing AskProtocol to help the client understand whether or not a storage provider is likely to accept their deal before they send a signed proposal. The proposed flow is simple. The client sends an ask request with information about the storage deal they would like to make. The ask response by the storage provider indicates whether or not the deal will be accepted with specifics on conditions (for example, how long the offer is valid for, and what the price to store is). More details about the AskProtocol v2 request/response can be found in the specification section. Change MotivationClients need to be able to share details of the storage deal they want to make. Furthermore, they need to know what capabilities and features a Storage Provider supports, so as to understand what Storage Providers they can successfully make a deal with. SpecificationClient Request of AskProtocol v2For the AskProtocol v2 request, the client provides the following information:
where:
Storage Provider Response of AskProtocol v2For the response, the provider will respond with the following information:
where:
Design RationaleTBD Backwards CompatibilityTBD Test CasesTBD Security ConsiderationsTBD Incentive ConsiderationsN/A Product ConsiderationsOne of the main experiences we want to improve is storage dealmaking and overall Filecoin storage reliability. AskProtocol v2 improvements aim to help with the following:
ImplementationTBD CopyrightCopyright and related rights waived via CC0. |
Beta Was this translation helpful? Give feedback.
-
Some discussion points - Ask request
Ask response
|
Beta Was this translation helpful? Give feedback.
-
In venus-market, we have gathered the needs of many miners and miners. access the venus-market address directly during the ask process (market url obtained by accessing a fixed contract/config in the future), and return a series of miners and the miner’s demand, and then let the client choose a miner to issue an order. |
Beta Was this translation helpful? Give feedback.
-
I would like to put @hunjixin 's thought into more general. In Filecoin ecosystem, the storage provider just part of the network infrastructure, above that, there could be higher layer services, e.g. deal broker, gateway or proxy, to help on storing data to Filecoin and retrieval from Filecoin network too. In addition, when we consider retrieval, there could be services particularly for retrieval too, that means, the fast retrieval could be done by other service nodes. And all these services bridging between the clients and storage providers could be possibly provided by smart contracts when FVM is available. In the v2 design, should we make it more flexible to not limit to storage provide nodes and end clients, or we design a delegate or trust protocol for the market in another FIP, while having this protocol support it? |
Beta Was this translation helpful? Give feedback.
-
I would love to evaluate this proposal, but can't do much without much more description of the perceived problems, motivation for specific changes, and design rationale. |
Beta Was this translation helpful? Give feedback.
-
Another thing we should add into a revised ask protocol is an identifier (address) of the market contract for which the ask is intended. The FVM and related protocol changes will eventually support the development of alternative storage markets – contracts that play the same role as, and compete with, the built-in storage market. In the near term those markets may rely on some other out-of-band channel for communicating asks/offers, but to the extend that the Filecoin protocol specifies a standard protocol, we should expand it to support arbitrary alternative market protocols. The very minimum for this would be to add the address of the contract implementing the storage market protocol which the client wishes to use for the deal. Today that would be the address of the built-in storage market actor. There is lots more we could do to better support alternative markets. One possibility would be to add a string field which could contain arbitrary JSON describing market-specific properties of the intended deal (e.g. required collateral, or whether the client intends to pay upfront, ...). We can probably do better than that, but don't have enough experience with alternative markets to know concretely how. Note that we'll need to make a similar change to |
Beta Was this translation helpful? Give feedback.
-
Another thing to think about for the client deal proposal - does the client want their data to be publicly accessible to other network participants (and therefore if it's FIL+ data, anyone can audit the SP's responsiveness to public retrieval requests), or do they want their data to be private (and they're likely encrypting their data / asking SPs to only serve retrievals to a subset of addresses). SPs might offer different prices based on this (whether they're going to pre-pay the cost of retrievals). |
Beta Was this translation helpful? Give feedback.
-
After better understanding the ask and the deal request protocols, I think that either (a) these should become the same thing, or (b) the existing model of advertising a public price might be fine, and the more detailed negotiation is better left to the deal protocol. The proposed Rather than add a duplicative proposal ahead of the deal request, why not just add some better information to the deal proposal response, much like the proposed One objection I can forsee to this proposal is that teams have metrics around improving "deal success rate", and by offloading a rejection to the ask protocol it could be claimed that these are not deal rejections. I don't think clients would care much for this distinction if the upshot is they have to shop their deal around anyway, and now it has two ways to fail. A simpler protocol will be easier for all parties to implement and understand, and we should not let goals for particular metrics wag the dog into a more complex protocol. In light of this I think the ask protocol is intended to provide exactly that information that does not depend on client specifics like the piece CID, and would be suitable for aggregation so that many clients could consult one source for a view of the market. I expect there is a ton of room to improve this protocol by allowing the provider to specify much more detail about timeframes, sizes, collateral bounds, and different prices they might offer for different values thereof. But not in response to a specific client proposal – that's just a deal request and we have a protocol for that. |
Beta Was this translation helpful? Give feedback.
-
@anorth I'm sympathetic to your point that it's better not to have two slightly different ways to get the same information. Having said that your second comment is correct, there is a a cost to the client when making a deal proposal: the client must reserve funds for the deal before making the deal proposal. |
Beta Was this translation helpful? Give feedback.
-
Some notes from discussion with @whyrusleeping and @jacobheun Observations from Estuary and Estuary needs:
|
Beta Was this translation helpful? Give feedback.
-
Recently we are suffered from SP change price after get query, it takes us about 10m ~2h to update the sp's price, so if they change the deal during the timeslot, our deal sending will be failed. We also noticed that if SP use CID Gravity, they might setup different policy for different file size which make they behavior unpredictable. I think we need a way to sync up with this dynamic price change behavior. |
Beta Was this translation helpful? Give feedback.
-
Originally posted by @brendalee, edited by @jennijuju December 13, 2021
Starting this issue to get additional feedback from the community on proposed updates to the storage AsksProtocol v1.1.0. Currently, the ask protocol does not give the client / SP enough information on the likelihood of a storage deal being accepted. Note that there have already been a handful of discussions around storage ask protocol changes with the community (notably in Filecoin Slack #arg channel and other ad-hoc discussions with storage providers).
The goal of AskProtocol v2 is to help with awareness between the client and the storage provider before a deal proposal. Before a client attempts to make a deal, they can send details of their proposed deal, and the storage provider can respond to the proposal (with accept or reject and other details such as price). Note that the ask protocol is not designed to handle back and forth deal negotiations.
Proposed Storage AskProtocol v2 Standard
This proposal is to request change to the current ask protocol and update the version of
AskProtocolID
to/fil/storage/ask/1.1.0
, andStorage AskProtocol v2 Sketch
We need to design a new storage ask protocol. Let's brainstorm what it might look like here.
I think we should keep it very simple still, with a client requesting, and the storage provider responding.
To get started, i'm just going to define a
request
and aresponse
type, and then we can assume thats the protocol.Request
Signature: The request should be signed by the client.
Open question:
Message
field as string as a free-form field set by the client to the storage provider?Response
The response should be a signed object containing the request, for context
Open Questions:
RejectionCode
: Should we keep the code simple and have a predefined list of error codes, or should it to be a string for customized rejection reason in here. Or should it be a structured field? or left open for people to do whatever they like?Beta Was this translation helpful? Give feedback.
All reactions