Documentation ¶
Index ¶
- Variables
- func AuthenticatedRecord__Record__resolve(p graphql.ResolveParams) (interface{}, error)
- func AuthenticatedRecord__Signature__resolve(p graphql.ResolveParams) (interface{}, error)
- func Bytes__type__parse(value interface{}) interface{}
- func Bytes__type__parseLiteral(valueAST ast.Value) interface{}
- func Bytes__type__serialize(value interface{}) interface{}
- func CorsMiddleware(next http.HandlerFunc) http.Handler
- func FinishedTask__ClientApparentAddr__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__ClientVersion__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__DealID__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__ErrorMessage__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__Events__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__MinerLatencyMS__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__MinerMultiAddr__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__MinerVersion__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__PayloadCID__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__RetrievalTask__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__Size__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__StartedAt__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__Status__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__StorageTask__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__TimeToFirstByteMS__resolve(p graphql.ResolveParams) (interface{}, error)
- func FinishedTask__TimeToLastByteMS__resolve(p graphql.ResolveParams) (interface{}, error)
- func GetHandler(db state.State, accessToken string) (*http.ServeMux, error)
- func Logs__Log__resolve(p graphql.ResolveParams) (interface{}, error)
- func Logs__UpdatedAt__resolve(p graphql.ResolveParams) (interface{}, error)
- func PopTask__Status__resolve(p graphql.ResolveParams) (interface{}, error)
- func PopTask__Tags__resolve(p graphql.ResolveParams) (interface{}, error)
- func PopTask__WorkedBy__resolve(p graphql.ResolveParams) (interface{}, error)
- func RecordUpdate__Previous__resolve(p graphql.ResolveParams) (interface{}, error)
- func RecordUpdate__Records__resolve(p graphql.ResolveParams) (interface{}, error)
- func RecordUpdate__SigPrev__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__CARExport__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__MaxPriceAttoFIL__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__Miner__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__PayloadCID__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__ScheduleLimit__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__Schedule__resolve(p graphql.ResolveParams) (interface{}, error)
- func RetrievalTask__Tag__resolve(p graphql.ResolveParams) (interface{}, error)
- func StageDetails__Description__resolve(p graphql.ResolveParams) (interface{}, error)
- func StageDetails__ExpectedDuration__resolve(p graphql.ResolveParams) (interface{}, error)
- func StageDetails__Logs__resolve(p graphql.ResolveParams) (interface{}, error)
- func StageDetails__UpdatedAt__resolve(p graphql.ResolveParams) (interface{}, error)
- func Status__type__parse(value interface{}) interface{}
- func Status__type__parseLiteral(valueAST ast.Value) interface{}
- func Status__type__serialize(value interface{}) interface{}
- func StorageTask__FastRetrieval__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__MaxPriceAttoFIL__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__Miner__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__RetrievalScheduleLimit__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__RetrievalSchedule__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__ScheduleLimit__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__Schedule__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__Size__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__StartOffset__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__Tag__resolve(p graphql.ResolveParams) (interface{}, error)
- func StorageTask__Verified__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__CurrentStageDetails__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__ErrorMessage__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__PastStageDetails__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__RetrievalTask__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__RunCount__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__Stage__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__StartedAt__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__Status__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__StorageTask__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__UUID__resolve(p graphql.ResolveParams) (interface{}, error)
- func Task__WorkedBy__resolve(p graphql.ResolveParams) (interface{}, error)
- func Time__type__parse(value interface{}) interface{}
- func Time__type__parseLiteral(valueAST ast.Value) interface{}
- func Time__type__serialize(value interface{}) interface{}
- func UpdateTask__CurrentStageDetails__resolve(p graphql.ResolveParams) (interface{}, error)
- func UpdateTask__ErrorMessage__resolve(p graphql.ResolveParams) (interface{}, error)
- func UpdateTask__RunCount__resolve(p graphql.ResolveParams) (interface{}, error)
- func UpdateTask__Stage__resolve(p graphql.ResolveParams) (interface{}, error)
- func UpdateTask__Status__resolve(p graphql.ResolveParams) (interface{}, error)
- func UpdateTask__WorkedBy__resolve(p graphql.ResolveParams) (interface{}, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var Any__type = graphql.NewUnion(graphql.UnionConfig{ Name: "Any", Types: []*graphql.Object{ union__Any__Bool, union__Any__Int, union__Any__Float, union__Any__String, union__Any__Bytes, union__Any__Map, union__Any__List, union__Any__Link, }, ResolveType: func(p graphql.ResolveTypeParams) *graphql.Object { if node, ok := p.Value.(ipld.Node); ok { switch node.Prototype() { case tasks.Type.Bool: fallthrough case tasks.Type.Bool__Repr: return union__Any__Bool case tasks.Type.Int: fallthrough case tasks.Type.Int__Repr: return union__Any__Int case tasks.Type.Float: fallthrough case tasks.Type.Float__Repr: return union__Any__Float case tasks.Type.String: fallthrough case tasks.Type.String__Repr: return union__Any__String case tasks.Type.Bytes: fallthrough case tasks.Type.Bytes__Repr: return union__Any__Bytes case tasks.Type.Map: fallthrough case tasks.Type.Map__Repr: return union__Any__Map case tasks.Type.List: fallthrough case tasks.Type.List__Repr: return union__Any__List case tasks.Type.Link: fallthrough case tasks.Type.Link__Repr: return union__Any__Link } } fmt.Printf("Actual type %T: %v not in union\n", p.Value, p.Value) return nil }, })
View Source
var AuthenticatedRecord__type = graphql.NewObject(graphql.ObjectConfig{ Name: "AuthenticatedRecord", Fields: graphql.Fields{ "Record": &graphql.Field{ Type: graphql.NewNonNull(FinishedTask__type), Resolve: AuthenticatedRecord__Record__resolve, }, "Signature": &graphql.Field{ Type: graphql.NewNonNull(Bytes__type), Resolve: AuthenticatedRecord__Signature__resolve, }, }, })
View Source
var Bytes__type = graphql.NewScalar(graphql.ScalarConfig{ Name: "Bytes", Description: "Bytes", Serialize: Bytes__type__serialize, ParseValue: Bytes__type__parse, ParseLiteral: Bytes__type__parseLiteral, })
View Source
var FinishedTask__type = graphql.NewObject(graphql.ObjectConfig{ Name: "FinishedTask", Fields: graphql.Fields{ "Status": &graphql.Field{ Type: graphql.NewNonNull(Status__type), Resolve: FinishedTask__Status__resolve, }, "StartedAt": &graphql.Field{ Type: graphql.NewNonNull(Time__type), Resolve: FinishedTask__StartedAt__resolve, }, "ErrorMessage": &graphql.Field{ Type: graphql.String, Resolve: FinishedTask__ErrorMessage__resolve, }, "RetrievalTask": &graphql.Field{ Type: RetrievalTask__type, Resolve: FinishedTask__RetrievalTask__resolve, }, "StorageTask": &graphql.Field{ Type: StorageTask__type, Resolve: FinishedTask__StorageTask__resolve, }, "DealID": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: FinishedTask__DealID__resolve, }, "MinerMultiAddr": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: FinishedTask__MinerMultiAddr__resolve, }, "ClientApparentAddr": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: FinishedTask__ClientApparentAddr__resolve, }, "MinerLatencyMS": &graphql.Field{ Type: graphql.Int, Resolve: FinishedTask__MinerLatencyMS__resolve, }, "TimeToFirstByteMS": &graphql.Field{ Type: graphql.Int, Resolve: FinishedTask__TimeToFirstByteMS__resolve, }, "TimeToLastByteMS": &graphql.Field{ Type: graphql.Int, Resolve: FinishedTask__TimeToLastByteMS__resolve, }, "Events": &graphql.Field{ Type: graphql.NewNonNull(List_StageDetails__type), Resolve: FinishedTask__Events__resolve, }, "MinerVersion": &graphql.Field{ Type: graphql.String, Resolve: FinishedTask__MinerVersion__resolve, }, "ClientVersion": &graphql.Field{ Type: graphql.String, Resolve: FinishedTask__ClientVersion__resolve, }, "Size": &graphql.Field{ Type: graphql.Int, Resolve: FinishedTask__Size__resolve, }, "PayloadCID": &graphql.Field{ Type: graphql.String, Resolve: FinishedTask__PayloadCID__resolve, }, }, })
View Source
var FinishedTasks__type = graphql.NewObject(graphql.ObjectConfig{ Name: "FinishedTasks", Fields: graphql.Fields{ "At": &graphql.Field{ Type: FinishedTask__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.FinishedTasks) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(FinishedTask__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.FinishedTasks) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(FinishedTask__type), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.FinishedTasks) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.FinishedTasks) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var List_AuthenticatedRecord__type = graphql.NewObject(graphql.ObjectConfig{ Name: "List_AuthenticatedRecord", Fields: graphql.Fields{ "At": &graphql.Field{ Type: AuthenticatedRecord__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_AuthenticatedRecord) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(AuthenticatedRecord__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_AuthenticatedRecord) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(AuthenticatedRecord__type), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_AuthenticatedRecord) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_AuthenticatedRecord) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var List_Logs__type = graphql.NewObject(graphql.ObjectConfig{ Name: "List_Logs", Fields: graphql.Fields{ "At": &graphql.Field{ Type: Logs__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_Logs) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(Logs__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_Logs) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(Logs__type), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_Logs) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_Logs) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var List_StageDetails__type = graphql.NewObject(graphql.ObjectConfig{ Name: "List_StageDetails", Fields: graphql.Fields{ "At": &graphql.Field{ Type: StageDetails__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_StageDetails) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(StageDetails__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_StageDetails) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(StageDetails__type), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_StageDetails) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_StageDetails) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var List_String__type = graphql.NewObject(graphql.ObjectConfig{ Name: "List_String", Fields: graphql.Fields{ "At": &graphql.Field{ Type: graphql.String, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_String) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(graphql.String), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_String) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(graphql.String), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_String) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List_String) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var List__type = graphql.NewObject(graphql.ObjectConfig{ Name: "List", Fields: graphql.Fields{ "At": &graphql.Field{ Type: Any__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(Any__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(Any__type), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.List) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var Logs__type = graphql.NewObject(graphql.ObjectConfig{ Name: "Logs", Fields: graphql.Fields{ "Log": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: Logs__Log__resolve, }, "UpdatedAt": &graphql.Field{ Type: graphql.NewNonNull(Time__type), Resolve: Logs__UpdatedAt__resolve, }, }, })
View Source
var Map__type = graphql.NewObject(graphql.ObjectConfig{ Name: "Map", Fields: graphql.Fields{ "At": &graphql.Field{ Type: Any__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.String), }, }, Resolve: resolve_map_at, }, "Keys": &graphql.Field{ Type: graphql.NewList(graphql.String), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(ipld.Node) if !ok { return nil, errNotNode } it := ts.MapIterator() children := make([]ipld.Node, 0) for !it.Done() { node, _, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Values": &graphql.Field{ Type: graphql.NewList(Any__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(ipld.Node) if !ok { return nil, errNotNode } it := ts.MapIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "All": &graphql.Field{ Type: graphql.NewList(Map__type__entry), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(ipld.Node) if !ok { return nil, errNotNode } it := ts.MapIterator() children := make([][]ipld.Node, 0) for !it.Done() { k, v, err := it.Next() if err != nil { return nil, err } children = append(children, []ipld.Node{k, v}) } return children, nil }, }, }, })
View Source
var Map__type__entry = graphql.NewObject(graphql.ObjectConfig{ Name: "Map_Entry", Fields: graphql.Fields{ "Key": &graphql.Field{ Type: graphql.String, Resolve: func(p graphql.ResolveParams) (interface{}, error) { kv, ok := p.Source.([]ipld.Node) if !ok { return nil, errNotNode } return kv[0], nil }, }, "Value": &graphql.Field{ Type: Any__type, Resolve: func(p graphql.ResolveParams) (interface{}, error) { kv, ok := p.Source.([]ipld.Node) if !ok { return nil, errNotNode } return kv[1], nil }, }, }, })
View Source
var PopTask__type = graphql.NewObject(graphql.ObjectConfig{ Name: "PopTask", Fields: graphql.Fields{ "Status": &graphql.Field{ Type: graphql.NewNonNull(Status__type), Resolve: PopTask__Status__resolve, }, "WorkedBy": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: PopTask__WorkedBy__resolve, }, "Tags": &graphql.Field{ Type: List_String__type, Resolve: PopTask__Tags__resolve, }, }, })
View Source
var RecordUpdate__type = graphql.NewObject(graphql.ObjectConfig{ Name: "RecordUpdate", Fields: graphql.Fields{ "Records": &graphql.Field{ Type: graphql.NewNonNull(List_AuthenticatedRecord__type), Resolve: RecordUpdate__Records__resolve, }, "SigPrev": &graphql.Field{ Type: graphql.NewNonNull(Bytes__type), Resolve: RecordUpdate__SigPrev__resolve, }, "Previous": &graphql.Field{ Type: graphql.ID, Resolve: RecordUpdate__Previous__resolve, }, }, })
View Source
var RetrievalTask__type = graphql.NewObject(graphql.ObjectConfig{ Name: "RetrievalTask", Fields: graphql.Fields{ "Miner": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: RetrievalTask__Miner__resolve, }, "PayloadCID": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: RetrievalTask__PayloadCID__resolve, }, "CARExport": &graphql.Field{ Type: graphql.NewNonNull(graphql.Boolean), Resolve: RetrievalTask__CARExport__resolve, }, "Schedule": &graphql.Field{ Type: graphql.String, Resolve: RetrievalTask__Schedule__resolve, }, "ScheduleLimit": &graphql.Field{ Type: graphql.String, Resolve: RetrievalTask__ScheduleLimit__resolve, }, "Tag": &graphql.Field{ Type: graphql.String, Resolve: RetrievalTask__Tag__resolve, }, "MaxPriceAttoFIL": &graphql.Field{ Type: graphql.Int, Resolve: RetrievalTask__MaxPriceAttoFIL__resolve, }, }, })
View Source
var StageDetails__type = graphql.NewObject(graphql.ObjectConfig{ Name: "StageDetails", Fields: graphql.Fields{ "Description": &graphql.Field{ Type: graphql.String, Resolve: StageDetails__Description__resolve, }, "ExpectedDuration": &graphql.Field{ Type: graphql.String, Resolve: StageDetails__ExpectedDuration__resolve, }, "Logs": &graphql.Field{ Type: graphql.NewNonNull(List_Logs__type), Resolve: StageDetails__Logs__resolve, }, "UpdatedAt": &graphql.Field{ Type: Time__type, Resolve: StageDetails__UpdatedAt__resolve, }, }, })
View Source
var Status__type = graphql.NewScalar(graphql.ScalarConfig{ Name: "Status", Description: "Status", Serialize: Status__type__serialize, ParseValue: Status__type__parse, ParseLiteral: Status__type__parseLiteral, })
View Source
var StorageTask__type = graphql.NewObject(graphql.ObjectConfig{ Name: "StorageTask", Fields: graphql.Fields{ "Miner": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: StorageTask__Miner__resolve, }, "MaxPriceAttoFIL": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: StorageTask__MaxPriceAttoFIL__resolve, }, "Size": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: StorageTask__Size__resolve, }, "StartOffset": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: StorageTask__StartOffset__resolve, }, "FastRetrieval": &graphql.Field{ Type: graphql.NewNonNull(graphql.Boolean), Resolve: StorageTask__FastRetrieval__resolve, }, "Verified": &graphql.Field{ Type: graphql.NewNonNull(graphql.Boolean), Resolve: StorageTask__Verified__resolve, }, "Schedule": &graphql.Field{ Type: graphql.String, Resolve: StorageTask__Schedule__resolve, }, "ScheduleLimit": &graphql.Field{ Type: graphql.String, Resolve: StorageTask__ScheduleLimit__resolve, }, "Tag": &graphql.Field{ Type: graphql.String, Resolve: StorageTask__Tag__resolve, }, "RetrievalSchedule": &graphql.Field{ Type: graphql.String, Resolve: StorageTask__RetrievalSchedule__resolve, }, "RetrievalScheduleLimit": &graphql.Field{ Type: graphql.String, Resolve: StorageTask__RetrievalScheduleLimit__resolve, }, }, })
View Source
var Task__type = graphql.NewObject(graphql.ObjectConfig{ Name: "Task", Fields: graphql.Fields{ "UUID": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: Task__UUID__resolve, }, "Status": &graphql.Field{ Type: graphql.NewNonNull(Status__type), Resolve: Task__Status__resolve, }, "WorkedBy": &graphql.Field{ Type: graphql.String, Resolve: Task__WorkedBy__resolve, }, "Stage": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: Task__Stage__resolve, }, "CurrentStageDetails": &graphql.Field{ Type: StageDetails__type, Resolve: Task__CurrentStageDetails__resolve, }, "PastStageDetails": &graphql.Field{ Type: List_StageDetails__type, Resolve: Task__PastStageDetails__resolve, }, "StartedAt": &graphql.Field{ Type: Time__type, Resolve: Task__StartedAt__resolve, }, "RunCount": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: Task__RunCount__resolve, }, "ErrorMessage": &graphql.Field{ Type: graphql.String, Resolve: Task__ErrorMessage__resolve, }, "RetrievalTask": &graphql.Field{ Type: RetrievalTask__type, Resolve: Task__RetrievalTask__resolve, }, "StorageTask": &graphql.Field{ Type: StorageTask__type, Resolve: Task__StorageTask__resolve, }, }, })
View Source
var Tasks__type = graphql.NewObject(graphql.ObjectConfig{ Name: "Tasks", Fields: graphql.Fields{ "At": &graphql.Field{ Type: Task__type, Args: graphql.FieldConfigArgument{ "key": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.Tasks) if !ok { return nil, errNotNode } arg := p.Args["key"] var out ipld.Node var err error switch ta := arg.(type) { case ipld.Node: out, err = ts.LookupByNode(ta) case int64: out, err = ts.LookupByIndex(ta) default: return nil, fmt.Errorf("unknown key type: %T", arg) } return out, err }, }, "All": &graphql.Field{ Type: graphql.NewList(Task__type), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.Tasks) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Range": &graphql.Field{ Type: graphql.NewList(Task__type), Args: graphql.FieldConfigArgument{ "skip": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, "take": &graphql.ArgumentConfig{ Type: graphql.NewNonNull(graphql.Int), }, }, Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.Tasks) if !ok { return nil, errNotNode } it := ts.ListIterator() children := make([]ipld.Node, 0) for !it.Done() { _, node, err := it.Next() if err != nil { return nil, err } children = append(children, node) } return children, nil }, }, "Count": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: func(p graphql.ResolveParams) (interface{}, error) { ts, ok := p.Source.(tasks.Tasks) if !ok { return nil, errNotNode } return ts.Length(), nil }, }, }, })
View Source
var Time__type = graphql.NewScalar(graphql.ScalarConfig{ Name: "Time", Description: "Time", Serialize: Time__type__serialize, ParseValue: Time__type__parse, ParseLiteral: Time__type__parseLiteral, })
View Source
var UpdateTask__type = graphql.NewObject(graphql.ObjectConfig{ Name: "UpdateTask", Fields: graphql.Fields{ "Status": &graphql.Field{ Type: graphql.NewNonNull(Status__type), Resolve: UpdateTask__Status__resolve, }, "ErrorMessage": &graphql.Field{ Type: graphql.String, Resolve: UpdateTask__ErrorMessage__resolve, }, "Stage": &graphql.Field{ Type: graphql.String, Resolve: UpdateTask__Stage__resolve, }, "CurrentStageDetails": &graphql.Field{ Type: StageDetails__type, Resolve: UpdateTask__CurrentStageDetails__resolve, }, "WorkedBy": &graphql.Field{ Type: graphql.NewNonNull(graphql.String), Resolve: UpdateTask__WorkedBy__resolve, }, "RunCount": &graphql.Field{ Type: graphql.NewNonNull(graphql.Int), Resolve: UpdateTask__RunCount__resolve, }, }, })
Functions ¶
func AuthenticatedRecord__Record__resolve ¶
func AuthenticatedRecord__Record__resolve(p graphql.ResolveParams) (interface{}, error)
func AuthenticatedRecord__Signature__resolve ¶
func AuthenticatedRecord__Signature__resolve(p graphql.ResolveParams) (interface{}, error)
func Bytes__type__parse ¶
func Bytes__type__parse(value interface{}) interface{}
func Bytes__type__serialize ¶
func Bytes__type__serialize(value interface{}) interface{}
func CorsMiddleware ¶
func CorsMiddleware(next http.HandlerFunc) http.Handler
func FinishedTask__ClientApparentAddr__resolve ¶
func FinishedTask__ClientApparentAddr__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__ClientVersion__resolve ¶
func FinishedTask__ClientVersion__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__DealID__resolve ¶
func FinishedTask__DealID__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__ErrorMessage__resolve ¶
func FinishedTask__ErrorMessage__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__Events__resolve ¶
func FinishedTask__Events__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__MinerLatencyMS__resolve ¶
func FinishedTask__MinerLatencyMS__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__MinerMultiAddr__resolve ¶
func FinishedTask__MinerMultiAddr__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__MinerVersion__resolve ¶
func FinishedTask__MinerVersion__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__PayloadCID__resolve ¶ added in v0.0.12
func FinishedTask__PayloadCID__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__RetrievalTask__resolve ¶
func FinishedTask__RetrievalTask__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__Size__resolve ¶ added in v0.0.10
func FinishedTask__Size__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__StartedAt__resolve ¶
func FinishedTask__StartedAt__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__Status__resolve ¶
func FinishedTask__Status__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__StorageTask__resolve ¶
func FinishedTask__StorageTask__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__TimeToFirstByteMS__resolve ¶
func FinishedTask__TimeToFirstByteMS__resolve(p graphql.ResolveParams) (interface{}, error)
func FinishedTask__TimeToLastByteMS__resolve ¶
func FinishedTask__TimeToLastByteMS__resolve(p graphql.ResolveParams) (interface{}, error)
func Logs__Log__resolve ¶
func Logs__Log__resolve(p graphql.ResolveParams) (interface{}, error)
func Logs__UpdatedAt__resolve ¶
func Logs__UpdatedAt__resolve(p graphql.ResolveParams) (interface{}, error)
func PopTask__Status__resolve ¶
func PopTask__Status__resolve(p graphql.ResolveParams) (interface{}, error)
func PopTask__Tags__resolve ¶
func PopTask__Tags__resolve(p graphql.ResolveParams) (interface{}, error)
func PopTask__WorkedBy__resolve ¶
func PopTask__WorkedBy__resolve(p graphql.ResolveParams) (interface{}, error)
func RecordUpdate__Previous__resolve ¶
func RecordUpdate__Previous__resolve(p graphql.ResolveParams) (interface{}, error)
func RecordUpdate__Records__resolve ¶
func RecordUpdate__Records__resolve(p graphql.ResolveParams) (interface{}, error)
func RecordUpdate__SigPrev__resolve ¶
func RecordUpdate__SigPrev__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__CARExport__resolve ¶
func RetrievalTask__CARExport__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__MaxPriceAttoFIL__resolve ¶
func RetrievalTask__MaxPriceAttoFIL__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__Miner__resolve ¶
func RetrievalTask__Miner__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__PayloadCID__resolve ¶
func RetrievalTask__PayloadCID__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__ScheduleLimit__resolve ¶
func RetrievalTask__ScheduleLimit__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__Schedule__resolve ¶
func RetrievalTask__Schedule__resolve(p graphql.ResolveParams) (interface{}, error)
func RetrievalTask__Tag__resolve ¶
func RetrievalTask__Tag__resolve(p graphql.ResolveParams) (interface{}, error)
func StageDetails__Description__resolve ¶
func StageDetails__Description__resolve(p graphql.ResolveParams) (interface{}, error)
func StageDetails__ExpectedDuration__resolve ¶
func StageDetails__ExpectedDuration__resolve(p graphql.ResolveParams) (interface{}, error)
func StageDetails__Logs__resolve ¶
func StageDetails__Logs__resolve(p graphql.ResolveParams) (interface{}, error)
func StageDetails__UpdatedAt__resolve ¶
func StageDetails__UpdatedAt__resolve(p graphql.ResolveParams) (interface{}, error)
func Status__type__parse ¶
func Status__type__parse(value interface{}) interface{}
func Status__type__serialize ¶
func Status__type__serialize(value interface{}) interface{}
func StorageTask__FastRetrieval__resolve ¶
func StorageTask__FastRetrieval__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__MaxPriceAttoFIL__resolve ¶
func StorageTask__MaxPriceAttoFIL__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__Miner__resolve ¶
func StorageTask__Miner__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__RetrievalScheduleLimit__resolve ¶ added in v0.0.20
func StorageTask__RetrievalScheduleLimit__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__RetrievalSchedule__resolve ¶ added in v0.0.20
func StorageTask__RetrievalSchedule__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__ScheduleLimit__resolve ¶
func StorageTask__ScheduleLimit__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__Schedule__resolve ¶
func StorageTask__Schedule__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__Size__resolve ¶
func StorageTask__Size__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__StartOffset__resolve ¶
func StorageTask__StartOffset__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__Tag__resolve ¶
func StorageTask__Tag__resolve(p graphql.ResolveParams) (interface{}, error)
func StorageTask__Verified__resolve ¶
func StorageTask__Verified__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__CurrentStageDetails__resolve ¶
func Task__CurrentStageDetails__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__ErrorMessage__resolve ¶
func Task__ErrorMessage__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__PastStageDetails__resolve ¶
func Task__PastStageDetails__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__RetrievalTask__resolve ¶
func Task__RetrievalTask__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__RunCount__resolve ¶
func Task__RunCount__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__Stage__resolve ¶
func Task__Stage__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__StartedAt__resolve ¶
func Task__StartedAt__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__Status__resolve ¶
func Task__Status__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__StorageTask__resolve ¶
func Task__StorageTask__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__UUID__resolve ¶
func Task__UUID__resolve(p graphql.ResolveParams) (interface{}, error)
func Task__WorkedBy__resolve ¶
func Task__WorkedBy__resolve(p graphql.ResolveParams) (interface{}, error)
func Time__type__parse ¶
func Time__type__parse(value interface{}) interface{}
func Time__type__serialize ¶
func Time__type__serialize(value interface{}) interface{}
func UpdateTask__CurrentStageDetails__resolve ¶
func UpdateTask__CurrentStageDetails__resolve(p graphql.ResolveParams) (interface{}, error)
func UpdateTask__ErrorMessage__resolve ¶
func UpdateTask__ErrorMessage__resolve(p graphql.ResolveParams) (interface{}, error)
func UpdateTask__RunCount__resolve ¶
func UpdateTask__RunCount__resolve(p graphql.ResolveParams) (interface{}, error)
func UpdateTask__Stage__resolve ¶
func UpdateTask__Stage__resolve(p graphql.ResolveParams) (interface{}, error)
func UpdateTask__Status__resolve ¶
func UpdateTask__Status__resolve(p graphql.ResolveParams) (interface{}, error)
func UpdateTask__WorkedBy__resolve ¶
func UpdateTask__WorkedBy__resolve(p graphql.ResolveParams) (interface{}, error)
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.