Documentation ¶
Index ¶
- type AuctionFilters
- type BidParams
- type Config
- type MinMaxFilter
- type Service
- func (s *Service) Close() error
- func (s *Service) GetBid(id auction.BidID) (*bidstore.Bid, error)
- func (s *Service) ListBids(query bidstore.Query) ([]*bidstore.Bid, error)
- func (s *Service) PeerInfo() (*marketpeer.PeerInfo, error)
- func (s *Service) Subscribe(bootstrap bool) error
- func (s *Service) WriteDataURI(payloadCid, uri string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuctionFilters ¶
type AuctionFilters struct { // DealDuration sets the min and max deal duration to bid on. DealDuration MinMaxFilter // DealSize sets the min and max deal size to bid on. DealSize MinMaxFilter }
AuctionFilters specifies filters used when selecting auctions to bid on.
func (*AuctionFilters) Validate ¶
func (f *AuctionFilters) Validate() error
Validate ensures AuctionFilters are valid.
type BidParams ¶
type BidParams struct { // MinerAddr is your Filecoin miner address used to make deals. MinerAddr string // WalletAddrSig is a signature from your owner Lotus wallet address used to authenticate bids. WalletAddrSig []byte // AskPrice in attoFIL per GiB per epoch. AskPrice int64 // VerifiedAskPrice in attoFIL per GiB per epoch. VerifiedAskPrice int64 // FastRetrieval is whether or not you're offering fast retrieval for the deal data. FastRetrieval bool // DealStartWindow is the number of epochs after which won deals must start be on-chain. DealStartWindow uint64 // DealDataDirectory is the directory to which deal data will be written. DealDataDirectory string // DealDataFetchAttempts is the number of times fetching deal data cid will be attempted. DealDataFetchAttempts uint32 // DiscardOrphanDealsAfter is the time after which deals with no progress will be removed. DiscardOrphanDealsAfter time.Duration }
BidParams defines how bids are made.
type Config ¶
type Config struct { Peer marketpeer.Config BidParams BidParams AuctionFilters AuctionFilters BytesLimiter limiter.Limiter }
Config defines params for Service configuration.
type MinMaxFilter ¶
MinMaxFilter is used to specify a range for an auction filter.
func (*MinMaxFilter) Validate ¶
func (f *MinMaxFilter) Validate() error
Validate ensures the filter is a valid min max window.
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service is a miner service that subscribes to brokered deals.
func New ¶
func New( conf Config, store txndswrap.TxnDatastore, lc lotusclient.LotusClient, fc filclient.FilClient, ) (*Service, error)
New returns a new Service.
func (*Service) PeerInfo ¶
func (s *Service) PeerInfo() (*marketpeer.PeerInfo, error)
PeerInfo returns the public information of the market peer.
Click to show internal directories.
Click to hide internal directories.