Documentation ¶
Index ¶
- type Batch
- type BatchManifest
- type BatchRemoteWallet
- type BatchStatus
- type BatchTag
- type BatchUpdateStorageRequestsParams
- type CreateBatchManifestParams
- type CreateBatchParams
- type CreateBatchRemoteWalletParams
- type CreateBatchTagParams
- type CreateDealParams
- type CreateStorageRequestParams
- type CreateUnpinJobParams
- type DBTX
- type Deal
- type GetExcludedStorageProvidersParams
- type Operation
- type Queries
- func (q *Queries) BatchUpdateStorageRequests(ctx context.Context, arg BatchUpdateStorageRequestsParams) ([]broker.StorageRequestID, error)
- func (q *Queries) Close() error
- func (q *Queries) CreateBatch(ctx context.Context, arg CreateBatchParams) error
- func (q *Queries) CreateBatchManifest(ctx context.Context, arg CreateBatchManifestParams) error
- func (q *Queries) CreateBatchRemoteWallet(ctx context.Context, arg CreateBatchRemoteWalletParams) error
- func (q *Queries) CreateBatchTag(ctx context.Context, arg CreateBatchTagParams) error
- func (q *Queries) CreateDeal(ctx context.Context, arg CreateDealParams) error
- func (q *Queries) CreateOperation(ctx context.Context, id string) error
- func (q *Queries) CreateStorageRequest(ctx context.Context, arg CreateStorageRequestParams) error
- func (q *Queries) CreateUnpinJob(ctx context.Context, arg CreateUnpinJobParams) error
- func (q *Queries) DeleteExecutingUnpinJob(ctx context.Context, id string) error
- func (q *Queries) GetBatch(ctx context.Context, id broker.BatchID) (Batch, error)
- func (q *Queries) GetBatchManifest(ctx context.Context, batchID string) (BatchManifest, error)
- func (q *Queries) GetBatchRemoteWallet(ctx context.Context, batchID broker.BatchID) (BatchRemoteWallet, error)
- func (q *Queries) GetBatchTags(ctx context.Context, batchID broker.BatchID) ([]BatchTag, error)
- func (q *Queries) GetDeals(ctx context.Context, batchID broker.BatchID) ([]Deal, error)
- func (q *Queries) GetExcludedStorageProviders(ctx context.Context, arg GetExcludedStorageProvidersParams) ([]string, error)
- func (q *Queries) GetStorageRequest(ctx context.Context, id broker.StorageRequestID) (StorageRequest, error)
- func (q *Queries) GetStorageRequestIDs(ctx context.Context, batchID sql.NullString) ([]broker.StorageRequestID, error)
- func (q *Queries) GetStorageRequests(ctx context.Context, batchID sql.NullString) ([]StorageRequest, error)
- func (q *Queries) NextUnpinJob(ctx context.Context, stuckSeconds int64) (UnpinJob, error)
- func (q *Queries) RebatchStorageRequests(ctx context.Context, arg RebatchStorageRequestsParams) error
- func (q *Queries) UnpinJobToPending(ctx context.Context, arg UnpinJobToPendingParams) error
- func (q *Queries) UpdateBatch(ctx context.Context, arg UpdateBatchParams) error
- func (q *Queries) UpdateBatchStatus(ctx context.Context, arg UpdateBatchStatusParams) error
- func (q *Queries) UpdateBatchStatusAndError(ctx context.Context, arg UpdateBatchStatusAndErrorParams) error
- func (q *Queries) UpdateDeals(ctx context.Context, arg UpdateDealsParams) (int64, error)
- func (q *Queries) UpdateStorageRequestsStatus(ctx context.Context, arg UpdateStorageRequestsStatusParams) error
- func (q *Queries) WithTx(tx *sql.Tx) *Queries
- type RebatchStorageRequestsParams
- type StorageRequest
- type StorageRequestStatus
- type UnpinJob
- type UnpinJobToPendingParams
- type UpdateBatchParams
- type UpdateBatchStatusAndErrorParams
- type UpdateBatchStatusParams
- type UpdateDealsParams
- type UpdateStorageRequestsStatusParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Batch ¶
type Batch struct { ID broker.BatchID `json:"id"` RepFactor int `json:"repFactor"` DealDuration int `json:"dealDuration"` PayloadCid string `json:"payloadCid"` PieceCid string `json:"pieceCid"` PieceSize uint64 `json:"pieceSize"` CarUrl string `json:"carUrl"` CarIpfsCid string `json:"carIpfsCid"` CarIpfsAddrs string `json:"carIpfsAddrs"` DisallowRebatching bool `json:"disallowRebatching"` FilEpochDeadline uint64 `json:"filEpochDeadline"` Error string `json:"error"` Origin string `json:"origin"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` Providers []string `json:"providers"` Status broker.BatchStatus `json:"status"` PayloadSize sql.NullInt64 `json:"payloadSize"` ProposalStartOffsetSeconds int64 `json:"proposalStartOffsetSeconds"` }
type BatchManifest ¶
type BatchRemoteWallet ¶
type BatchStatus ¶
type BatchStatus string
@enum @enumName StoragePayloadStatus
const ( BatchStatusUnknown BatchStatus = "unknown" BatchStatusPreparing BatchStatus = "preparing" BatchStatusAuctioning BatchStatus = "auctioning" BatchStatusDealMaking BatchStatus = "deal_making" BatchStatusSuccess BatchStatus = "success" BatchStatusError BatchStatus = "error" )
func (*BatchStatus) Scan ¶
func (e *BatchStatus) Scan(src interface{}) error
type BatchUpdateStorageRequestsParams ¶
type BatchUpdateStorageRequestsParams struct { Status broker.StorageRequestStatus `json:"status"` BatchID sql.NullString `json:"batchID"` Ids []string `json:"ids"` }
type CreateBatchParams ¶
type CreateBatchParams struct { ID broker.BatchID `json:"id"` Status broker.BatchStatus `json:"status"` RepFactor int `json:"repFactor"` DealDuration int `json:"dealDuration"` CarUrl string `json:"carUrl"` CarIpfsCid string `json:"carIpfsCid"` CarIpfsAddrs string `json:"carIpfsAddrs"` DisallowRebatching bool `json:"disallowRebatching"` FilEpochDeadline uint64 `json:"filEpochDeadline"` ProposalStartOffsetSeconds int64 `json:"proposalStartOffsetSeconds"` Error string `json:"error"` PayloadCid string `json:"payloadCid"` PayloadSize sql.NullInt64 `json:"payloadSize"` PieceCid string `json:"pieceCid"` PieceSize uint64 `json:"pieceSize"` Origin string `json:"origin"` Providers []string `json:"providers"` }
type CreateBatchTagParams ¶
type CreateDealParams ¶
type CreateDealParams struct { BatchID broker.BatchID `json:"batchID"` AuctionID auction.ID `json:"auctionID"` BidID auction.BidID `json:"bidID"` StorageProviderID string `json:"storageProviderID"` DealID int64 `json:"dealID"` DealExpiration uint64 `json:"dealExpiration"` ErrorCause string `json:"errorCause"` }
type CreateStorageRequestParams ¶
type CreateStorageRequestParams struct { ID broker.StorageRequestID `json:"id"` DataCid string `json:"dataCid"` Status broker.StorageRequestStatus `json:"status"` Origin string `json:"origin"` }
type CreateUnpinJobParams ¶
type Deal ¶
type Deal struct { BatchID broker.BatchID `json:"batchID"` AuctionID auction.ID `json:"auctionID"` BidID auction.BidID `json:"bidID"` StorageProviderID string `json:"storageProviderID"` DealID int64 `json:"dealID"` DealExpiration uint64 `json:"dealExpiration"` ErrorCause string `json:"errorCause"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` }
type Queries ¶
type Queries struct {
// contains filtered or unexported fields
}
func (*Queries) BatchUpdateStorageRequests ¶
func (q *Queries) BatchUpdateStorageRequests(ctx context.Context, arg BatchUpdateStorageRequestsParams) ([]broker.StorageRequestID, error)
func (*Queries) CreateBatch ¶
func (q *Queries) CreateBatch(ctx context.Context, arg CreateBatchParams) error
func (*Queries) CreateBatchManifest ¶
func (q *Queries) CreateBatchManifest(ctx context.Context, arg CreateBatchManifestParams) error
func (*Queries) CreateBatchRemoteWallet ¶
func (q *Queries) CreateBatchRemoteWallet(ctx context.Context, arg CreateBatchRemoteWalletParams) error
func (*Queries) CreateBatchTag ¶
func (q *Queries) CreateBatchTag(ctx context.Context, arg CreateBatchTagParams) error
func (*Queries) CreateDeal ¶
func (q *Queries) CreateDeal(ctx context.Context, arg CreateDealParams) error
func (*Queries) CreateOperation ¶
func (*Queries) CreateStorageRequest ¶
func (q *Queries) CreateStorageRequest(ctx context.Context, arg CreateStorageRequestParams) error
func (*Queries) CreateUnpinJob ¶
func (q *Queries) CreateUnpinJob(ctx context.Context, arg CreateUnpinJobParams) error
func (*Queries) DeleteExecutingUnpinJob ¶
func (*Queries) GetBatchManifest ¶
func (*Queries) GetBatchRemoteWallet ¶
func (*Queries) GetBatchTags ¶
func (*Queries) GetExcludedStorageProviders ¶
func (*Queries) GetStorageRequest ¶
func (q *Queries) GetStorageRequest(ctx context.Context, id broker.StorageRequestID) (StorageRequest, error)
func (*Queries) GetStorageRequestIDs ¶
func (q *Queries) GetStorageRequestIDs(ctx context.Context, batchID sql.NullString) ([]broker.StorageRequestID, error)
func (*Queries) GetStorageRequests ¶
func (q *Queries) GetStorageRequests(ctx context.Context, batchID sql.NullString) ([]StorageRequest, error)
func (*Queries) NextUnpinJob ¶
func (*Queries) RebatchStorageRequests ¶
func (q *Queries) RebatchStorageRequests(ctx context.Context, arg RebatchStorageRequestsParams) error
func (*Queries) UnpinJobToPending ¶
func (q *Queries) UnpinJobToPending(ctx context.Context, arg UnpinJobToPendingParams) error
func (*Queries) UpdateBatch ¶
func (q *Queries) UpdateBatch(ctx context.Context, arg UpdateBatchParams) error
func (*Queries) UpdateBatchStatus ¶
func (q *Queries) UpdateBatchStatus(ctx context.Context, arg UpdateBatchStatusParams) error
func (*Queries) UpdateBatchStatusAndError ¶
func (q *Queries) UpdateBatchStatusAndError(ctx context.Context, arg UpdateBatchStatusAndErrorParams) error
func (*Queries) UpdateDeals ¶
func (*Queries) UpdateStorageRequestsStatus ¶
func (q *Queries) UpdateStorageRequestsStatus(ctx context.Context, arg UpdateStorageRequestsStatusParams) error
type RebatchStorageRequestsParams ¶
type RebatchStorageRequestsParams struct { BatchID sql.NullString `json:"batchID"` ErrorCause string `json:"errorCause"` }
type StorageRequest ¶
type StorageRequest struct { ID broker.StorageRequestID `json:"id"` DataCid string `json:"dataCid"` BatchID sql.NullString `json:"batchID"` Origin string `json:"origin"` RebatchCount int32 `json:"rebatchCount"` ErrorCause string `json:"errorCause"` CreatedAt time.Time `json:"createdAt"` UpdatedAt time.Time `json:"updatedAt"` Status broker.StorageRequestStatus `json:"status"` }
type StorageRequestStatus ¶
type StorageRequestStatus string
const ( StorageRequestStatusUnknown StorageRequestStatus = "unknown" StorageRequestStatusBatching StorageRequestStatus = "batching" StorageRequestStatusPreparing StorageRequestStatus = "preparing" StorageRequestStatusAuctioning StorageRequestStatus = "auctioning" StorageRequestStatusDealMaking StorageRequestStatus = "deal_making" StorageRequestStatusSuccess StorageRequestStatus = "success" StorageRequestStatusError StorageRequestStatus = "error" )
func (*StorageRequestStatus) Scan ¶
func (e *StorageRequestStatus) Scan(src interface{}) error
type UnpinJobToPendingParams ¶
type UpdateBatchParams ¶
type UpdateBatchStatusAndErrorParams ¶
type UpdateBatchStatusAndErrorParams struct { ID broker.BatchID `json:"id"` Status broker.BatchStatus `json:"status"` Error string `json:"error"` }
type UpdateBatchStatusParams ¶
type UpdateBatchStatusParams struct { ID broker.BatchID `json:"id"` Status broker.BatchStatus `json:"status"` }
type UpdateDealsParams ¶
type UpdateStorageRequestsStatusParams ¶
type UpdateStorageRequestsStatusParams struct { BatchID sql.NullString `json:"batchID"` Status broker.StorageRequestStatus `json:"status"` }
Click to show internal directories.
Click to hide internal directories.