diff --git a/internal/api/graphql/gqlgen.yml b/internal/api/graphql/gqlgen.yml new file mode 100644 index 00000000..339d9b70 --- /dev/null +++ b/internal/api/graphql/gqlgen.yml @@ -0,0 +1,188 @@ +# Where are all the schema files located? globs are supported eg src/**/*.graphqls +schema: + - graph/schema/*.graphqls + +# Where should the generated server code go? +exec: + filename: graph/generated.go + package: graph + +# Uncomment to enable federation +# federation: +# filename: graph/federation.go +# package: graph + +# Where should any generated models go? +model: + filename: graph/model/models_gen.go + package: model + +# Where should the resolver implementations go? +resolver: + layout: follow-schema + dir: graph/resolver + package: resolver + filename_template: "{name}.go" + # Optional: turn on to not generate template comments above resolvers + # omit_template_comment: false + +# Optional: turn on use ` + "`" + `gqlgen:"fieldName"` + "`" + ` tags in your models +# struct_tag: json + +# Optional: turn on to use []Thing instead of []*Thing +# omit_slice_element_pointers: false + +# Optional: turn on to skip generation of ComplexityRoot struct content and Complexity function +# omit_complexity: false + +# Optional: turn on to not generate any file notice comments in generated files +# omit_gqlgen_file_notice: false + +# Optional: turn on to exclude the gqlgen version in the generated file notice. No effect if `omit_gqlgen_file_notice` is true. +# omit_gqlgen_version_in_file_notice: false + +# Optional: turn off to make struct-type struct fields not use pointers +# e.g. type Thing struct { FieldA OtherThing } instead of { FieldA *OtherThing } +# struct_fields_always_pointers: true + +# Optional: turn off to make resolvers return values instead of pointers for structs +# resolvers_always_return_pointers: true + +# Optional: turn on to return pointers instead of values in unmarshalInput +# return_pointers_in_unmarshalinput: false + +# Optional: wrap nullable input fields with Omittable +# nullable_input_omittable: true + +# Optional: set to speed up generation time by not performing a final validation pass. +# skip_validation: true + +# Optional: set to skip running `go mod tidy` when generating server code +# skip_mod_tidy: true + +# gqlgen will search for any type names in the schema in these go packages +# if they match it will use them, otherwise it will generate them. +autobind: + - "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + +# This section declares type mapping between the GraphQL and go type systems +# +# The first line in each type will be used as defaults for resolver arguments and +# modelgen, the others will be allowed when binding to fields. Configure them to +# your liking +models: + ID: + model: + - github.com/99designs/gqlgen/graphql.ID + - github.com/99designs/gqlgen/graphql.Int + - github.com/99designs/gqlgen/graphql.Int64 + - github.com/99designs/gqlgen/graphql.Int32 + Int: + model: + - github.com/99designs/gqlgen/graphql.Int + - github.com/99designs/gqlgen/graphql.Int64 + - github.com/99designs/gqlgen/graphql.Int32 + Issue: + fields: + issueVariants: + resolver: true + issueMatches: + resolver: true + activities: + resolver: true + componentVersions: + resolver: true + IssueMatch: + fields: + componentInstance: + resolver: true + issue: + resolver: true + evidences: + resolver: true + severity: + resolver: true + effectiveIssueVariants: + resolver: true + issueMatchChanges: + resolver: true + IssueMatchChange: + fields: + issueMatch: + resolver: true + activity: + resolver: true + Component: + fields: + componentVersions: + resolver: true + ComponentInstance: + fields: + componentVersion: + resolver: true + service: + resolver: true + issueMatches: + resolver: true + ComponentVersion: + fields: + component: + resolver: true + issues: + resolver: true + Service: + fields: + owners: + resolver: true + supportGroups: + resolver: true + issues: + resolver: true + activities: + resolver: true + issueRepositories: + resolver: true + componentInstances: + resolver: true + SupportGroup: + fields: + users: + resolver: true + services: + resolver: true + Activity: + fields: + services: + resolver: true + issues: + resolver: true + evidences: + resolver: true + issueMatchChanges: + resolver: true + Evidence: + fields: + activity: + resolver: true + author: + resolver: true + issueMatches: + resolver: true + IssueVariant: + fields: + issue: + resolver: true + issueRepository: + resolver: true + IssueRepository: + fields: + services: + resolver: true + issueVariants: + resolver: true + User: + fields: + supportGroups: + resolver: true + services: + resolver: true \ No newline at end of file diff --git a/internal/api/graphql/graph/baseResolver/activity.go b/internal/api/graphql/graph/baseResolver/activity.go new file mode 100644 index 00000000..4474a83c --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/activity.go @@ -0,0 +1,129 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleActivityBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.Activity, error) { + + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleActivityBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleActivityBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.ActivityFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + activities, err := app.ListActivities(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleActivityBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(activities.Elements) > 1 { + return nil, NewResolverError("SingleActivityBaseResolver", "Internal Error - found multiple activities") + } + + //not found + if len(activities.Elements) < 1 { + return nil, nil + } + + var activityResult = activities.Elements[0] + activity := model.NewActivity(activityResult.Activity) + + return &activity, nil +} + +func ActivityBaseResolver(app app.Heureka, ctx context.Context, filter *model.ActivityFilter, first *int, after *string, parent *model.NodeParent) (*model.ActivityConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called ActivityBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("ActivityBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("ActivityBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var sId []*int64 + var issueId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("ActivityBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("ActivityBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ServiceNodeName: + sId = []*int64{pid} + case model.IssueNodeName: + issueId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.ActivityFilter{} + } + + f := &entity.ActivityFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + ServiceName: filter.ServiceName, + ServiceId: sId, + IssueId: issueId, + } + + opt := GetListOptions(requestedFields) + + activities, err := app.ListActivities(f, opt) + + if err != nil { + return nil, NewResolverError("ActivityBaseResolver", err.Error()) + } + + edges := []*model.ActivityEdge{} + for _, result := range activities.Elements { + a := model.NewActivity(result.Activity) + edge := model.ActivityEdge{ + Node: &a, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if activities.TotalCount != nil { + tc = int(*activities.TotalCount) + } + + connection := model.ActivityConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(activities.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/common.go b/internal/api/graphql/graph/baseResolver/common.go new file mode 100644 index 00000000..9b6fa3ef --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/common.go @@ -0,0 +1,76 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + "fmt" + "github.com/99designs/gqlgen/graphql" + "github.com/samber/lo" + "github.wdf.sap.corp/cc/heureka/internal/entity" + "strconv" +) + +type ResolverError struct { + resolver string + msg string +} + +func (re *ResolverError) Error() string { + return fmt.Sprintf("%s: %s", re.resolver, re.msg) +} + +func NewResolverError(resolver string, msg string) *ResolverError { + return &ResolverError{ + resolver: resolver, + msg: msg, + } +} + +func ParseCursor(cursor *string) (*int64, error) { + + if cursor == nil { + var tmp int64 = 0 + return &tmp, nil + } + + id, err := strconv.ParseInt(*cursor, 10, 64) + if err != nil { + return nil, err + } + + return &id, err +} + +func GetPreloads(ctx context.Context) []string { + return GetNestedPreloads( + graphql.GetOperationContext(ctx), + graphql.CollectFieldsCtx(ctx, nil), + "", + ) +} + +func GetNestedPreloads(ctx *graphql.OperationContext, fields []graphql.CollectedField, prefix string) (preloads []string) { + for _, column := range fields { + prefixColumn := GetPreloadString(prefix, column.Name) + preloads = append(preloads, prefixColumn) + preloads = append(preloads, GetNestedPreloads(ctx, graphql.CollectFields(ctx, column.Selections, nil), prefixColumn)...) + } + return +} + +func GetPreloadString(prefix, name string) string { + if len(prefix) > 0 { + return prefix + "." + name + } + return name +} + +func GetListOptions(requestedFields []string) *entity.ListOptions { + return &entity.ListOptions{ + ShowTotalCount: lo.Contains(requestedFields, "totalCount"), + ShowPageInfo: lo.Contains(requestedFields, "pageInfo"), + IncludeAggregations: lo.Contains(requestedFields, "edges.node.metadata"), + } +} diff --git a/internal/api/graphql/graph/baseResolver/component.go b/internal/api/graphql/graph/baseResolver/component.go new file mode 100644 index 00000000..2fec640c --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/component.go @@ -0,0 +1,108 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleComponentBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.Component, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleComponentBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleComponentBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.ComponentFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + components, err := app.ListComponents(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleComponentBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(components.Elements) > 1 { + return nil, NewResolverError("SingleComponentBaseResolver", "Internal Error - found multiple components") + } + + //not found + if len(components.Elements) < 1 { + return nil, nil + } + + var cr entity.ComponentResult = components.Elements[0] + component := model.NewComponent(cr.Component) + + return &component, nil +} + +func ComponentBaseResolver(app app.Heureka, ctx context.Context, filter *model.ComponentFilter, first *int, after *string, parent *model.NodeParent) (*model.ComponentConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called ComponentBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("ComponentBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("ComponentBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + if filter == nil { + filter = &model.ComponentFilter{} + } + + f := &entity.ComponentFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + Name: filter.ComponentName, + } + + opt := GetListOptions(requestedFields) + + components, err := app.ListComponents(f, opt) + + if err != nil { + return nil, NewResolverError("ComponentBaseResolver", err.Error()) + } + + edges := []*model.ComponentEdge{} + for _, result := range components.Elements { + c := model.NewComponent(result.Component) + edge := model.ComponentEdge{ + Node: &c, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if components.TotalCount != nil { + tc = int(*components.TotalCount) + } + + connection := model.ComponentConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(components.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/component_instance.go b/internal/api/graphql/graph/baseResolver/component_instance.go new file mode 100644 index 00000000..83538971 --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/component_instance.go @@ -0,0 +1,127 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleComponentInstanceBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.ComponentInstance, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleComponentInstanceBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleComponentInstanceBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.ComponentInstanceFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + componentInstances, err := app.ListComponentInstances(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleComponentInstanceBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(componentInstances.Elements) > 1 { + return nil, NewResolverError("SingleComponentInstanceBaseResolver", "Internal Error - found multiple component instances") + } + + //not found + if len(componentInstances.Elements) < 1 { + return nil, nil + } + + var cir entity.ComponentInstanceResult = componentInstances.Elements[0] + componentInstance := model.NewComponentInstance(cir.ComponentInstance) + + return &componentInstance, nil +} + +func ComponentInstanceBaseResolver(app app.Heureka, ctx context.Context, filter *model.ComponentInstanceFilter, first *int, after *string, parent *model.NodeParent) (*model.ComponentInstanceConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called ComponentInstanceBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("ComponentInstanceBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("ComponentInstanceBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var imId []*int64 + var serviceId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("ComponentInstanceBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("ComponentInstanceBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.IssueMatchNodeName: + imId = []*int64{pid} + case model.ServiceNodeName: + serviceId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.ComponentInstanceFilter{} + } + + f := &entity.ComponentInstanceFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + IssueMatchId: imId, + ServiceId: serviceId, + } + + opt := GetListOptions(requestedFields) + + componentInstances, err := app.ListComponentInstances(f, opt) + + //@todo propper error handling + if err != nil { + return nil, NewResolverError("ComponentInstanceBaseResolver", err.Error()) + } + + edges := []*model.ComponentInstanceEdge{} + for _, result := range componentInstances.Elements { + ci := model.NewComponentInstance(result.ComponentInstance) + edge := model.ComponentInstanceEdge{ + Node: &ci, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if componentInstances.TotalCount != nil { + tc = int(*componentInstances.TotalCount) + } + + connection := model.ComponentInstanceConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(componentInstances.PageInfo), + } + + return &connection, nil +} diff --git a/internal/api/graphql/graph/baseResolver/component_version.go b/internal/api/graphql/graph/baseResolver/component_version.go new file mode 100644 index 00000000..12f0dcbd --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/component_version.go @@ -0,0 +1,127 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleComponentVersionBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.ComponentVersion, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleComponentVersionBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleComponentVersionBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.ComponentVersionFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + componentVersions, err := app.ListComponentVersions(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleComponentVersionBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(componentVersions.Elements) > 1 { + return nil, NewResolverError("SingleComponentVersionBaseResolver", "Internal Error - found multiple component versions") + } + + //not found + if len(componentVersions.Elements) < 1 { + return nil, nil + } + + var cvr entity.ComponentVersionResult = componentVersions.Elements[0] + componentVersion := model.NewComponentVersion(cvr.ComponentVersion) + + return &componentVersion, nil +} + +func ComponentVersionBaseResolver(app app.Heureka, ctx context.Context, filter *model.ComponentVersionFilter, first *int, after *string, parent *model.NodeParent) (*model.ComponentVersionConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called ComponentVersionBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("ComponentVersionBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("ComponentVersionBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var issueId []*int64 + var componentId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("ComponentVersionBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("ComponentVersionBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.IssueNodeName: + issueId = []*int64{pid} + case model.ComponentNodeName: + componentId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.ComponentVersionFilter{} + } + + f := &entity.ComponentVersionFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + IssueId: issueId, + ComponentId: componentId, + } + + opt := GetListOptions(requestedFields) + + componentVersions, err := app.ListComponentVersions(f, opt) + + //@todo propper error handling + if err != nil { + return nil, NewResolverError("ComponentVersionBaseResolver", err.Error()) + } + + edges := []*model.ComponentVersionEdge{} + for _, result := range componentVersions.Elements { + cv := model.NewComponentVersion(result.ComponentVersion) + edge := model.ComponentVersionEdge{ + Node: &cv, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if componentVersions.TotalCount != nil { + tc = int(*componentVersions.TotalCount) + } + + connection := model.ComponentVersionConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(componentVersions.PageInfo), + } + + return &connection, nil +} diff --git a/internal/api/graphql/graph/baseResolver/evidence.go b/internal/api/graphql/graph/baseResolver/evidence.go new file mode 100644 index 00000000..ae885c49 --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/evidence.go @@ -0,0 +1,87 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func EvidenceBaseResolver(app app.Heureka, ctx context.Context, filter *model.EvidenceFilter, first *int, after *string, parent *model.NodeParent) (*model.EvidenceConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called EvidenceBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("EvidenceBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("EvidenceBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var activityId []*int64 + var imId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("EvidenceBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("EvidenceBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ActivityNodeName: + activityId = []*int64{pid} + case model.IssueMatchNodeName: + imId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.EvidenceFilter{} + } + + f := &entity.EvidenceFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + ActivityId: activityId, + IssueMatchId: imId, + } + + opt := GetListOptions(requestedFields) + + evidences, err := app.ListEvidences(f, opt) + + if err != nil { + return nil, NewResolverError("EvidenceBaseResolver", err.Error()) + } + + edges := []*model.EvidenceEdge{} + for _, result := range evidences.Elements { + e := model.NewEvidence(result.Evidence) + edge := model.EvidenceEdge{ + Node: &e, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if evidences.TotalCount != nil { + tc = int(*evidences.TotalCount) + } + + connection := model.EvidenceConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(evidences.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/issue.go b/internal/api/graphql/graph/baseResolver/issue.go new file mode 100644 index 00000000..ad08b858 --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/issue.go @@ -0,0 +1,137 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/samber/lo" + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" + "k8s.io/utils/pointer" +) + +func SingleIssueBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.Issue, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleIssueBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleIssueBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.IssueFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + issues, err := app.ListIssues(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleIssueBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(issues.Elements) > 1 { + return nil, NewResolverError("SingleIssueBaseResolver", "Internal Error - found multiple issues") + } + + //not found + if len(issues.Elements) < 1 { + return nil, nil + } + + var ir entity.IssueResult = issues.Elements[0] + issue := model.NewIssue(&ir) + + return &issue, nil +} + +func IssueBaseResolver(app app.Heureka, ctx context.Context, filter *model.IssueFilter, first *int, after *string, parent *model.NodeParent) (*model.IssueConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called IssueBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("IssueBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("IssueBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var activityId []*int64 + var cvId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("IssueBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("IssueBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ActivityNodeName: + activityId = []*int64{pid} + case model.ComponentVersionNodeName: + cvId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.IssueFilter{} + } + + f := &entity.IssueFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + ServiceName: filter.AffectedService, + ActivityId: activityId, + ComponentVersionId: cvId, + PrimaryName: filter.PrimaryName, + Type: lo.Map(filter.IssueType, func(item *model.IssueTypes, _ int) *string { return pointer.String(item.String()) }), + + IssueMatchStatus: nil, //@todo Implement + IssueMatchDiscoveryDate: nil, //@todo Implement + IssueMatchTargetRemediationDate: nil, //@todo Implement + } + + opt := GetListOptions(requestedFields) + + issues, err := app.ListIssues(f, opt) + + //@todo propper error handling + if err != nil { + return nil, NewResolverError("IssueBaseResolver", err.Error()) + } + + edges := []*model.IssueEdge{} + for _, result := range issues.Elements { + iss := model.NewIssue(&result) + edge := model.IssueEdge{ + Node: &iss, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if issues.TotalCount != nil { + tc = int(*issues.TotalCount) + } + + connection := model.IssueConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(issues.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/issue_match.go b/internal/api/graphql/graph/baseResolver/issue_match.go new file mode 100644 index 00000000..68adaa82 --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/issue_match.go @@ -0,0 +1,137 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/samber/lo" + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" + "k8s.io/utils/pointer" +) + +func SingleIssueMatchBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.IssueMatch, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleIssueMatchBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleIssueMatchBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.IssueMatchFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + issueMatches, err := app.ListIssueMatches(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleIssueMatchBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(issueMatches.Elements) > 1 { + return nil, NewResolverError("SingleIssueMatchBaseResolver", "Internal Error - found multiple IssueMatches") + } + + //not found + if len(issueMatches.Elements) < 1 { + return nil, nil + } + + var imr entity.IssueMatchResult = issueMatches.Elements[0] + issueMatch := model.NewIssueMatch(imr.IssueMatch) + + return &issueMatch, nil +} + +func IssueMatchBaseResolver(app app.Heureka, ctx context.Context, filter *model.IssueMatchFilter, first *int, after *string, parent *model.NodeParent) (*model.IssueMatchConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called IssueMatchBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("IssueMatchBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("IssueMatchBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var eId []*int64 + var ciId []*int64 + var issueId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("IssueMatchBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("IssueMatchBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.EvidenceNodeName: + eId = []*int64{pid} + case model.ComponentInstanceNodeName: + ciId = []*int64{pid} + case model.IssueNodeName: + issueId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.IssueMatchFilter{} + } + + f := &entity.IssueMatchFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + AffectedServiceName: filter.AffectedService, + Status: lo.Map(filter.Status, func(item *model.IssueMatchStatusValues, _ int) *string { return pointer.String(item.String()) }), + SeverityValue: lo.Map(filter.Severity, func(item *model.SeverityValues, _ int) *string { return pointer.String(item.String()) }), + SupportGroupName: filter.SupportGroupName, + IssueId: issueId, + EvidenceId: eId, + ComponentInstanceId: ciId, + } + + opt := GetListOptions(requestedFields) + + issueMatches, err := app.ListIssueMatches(f, opt) + + if err != nil { + return nil, NewResolverError("IssueMatchBaseResolver", err.Error()) + } + + edges := []*model.IssueMatchEdge{} + for _, result := range issueMatches.Elements { + im := model.NewIssueMatch(result.IssueMatch) + edge := model.IssueMatchEdge{ + Node: &im, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if issueMatches.TotalCount != nil { + tc = int(*issueMatches.TotalCount) + } + + connection := model.IssueMatchConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(issueMatches.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/issue_match_change.go b/internal/api/graphql/graph/baseResolver/issue_match_change.go new file mode 100644 index 00000000..8c2830cc --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/issue_match_change.go @@ -0,0 +1,90 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/samber/lo" + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" + "k8s.io/utils/pointer" +) + +func IssueMatchChangeBaseResolver(app app.Heureka, ctx context.Context, filter *model.IssueMatchChangeFilter, first *int, after *string, parent *model.NodeParent) (*model.IssueMatchChangeConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called IssueMatchChangeBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("IssueMatchChangeBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("IssueMatchChangeBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var aId []*int64 + var imId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("IssueMatchChangeBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("IssueMatchChangeBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ActivityNodeName: + aId = []*int64{pid} + case model.IssueMatchNodeName: + imId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.IssueMatchChangeFilter{} + } + + f := &entity.IssueMatchChangeFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + Action: lo.Map(filter.Action, func(item *model.IssueMatchChangeActions, _ int) *string { return pointer.String(item.String()) }), + ActivityId: aId, + IssueMatchId: imId, + } + + opt := GetListOptions(requestedFields) + + issueMatchChanges, err := app.ListIssueMatchChanges(f, opt) + + if err != nil { + return nil, NewResolverError("IssueMatchChangeBaseResolver", err.Error()) + } + + edges := []*model.IssueMatchChangeEdge{} + for _, result := range issueMatchChanges.Elements { + imc := model.NewIssueMatchChange(&result) + edge := model.IssueMatchChangeEdge{ + Node: &imc, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if issueMatchChanges.TotalCount != nil { + tc = int(*issueMatchChanges.TotalCount) + } + + connection := model.IssueMatchChangeConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(issueMatchChanges.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/issue_repository.go b/internal/api/graphql/graph/baseResolver/issue_repository.go new file mode 100644 index 00000000..87d731bc --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/issue_repository.go @@ -0,0 +1,133 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/samber/lo" + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleIssueRepositoryBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.IssueRepository, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleIssueRepositoryBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleIssueRepositoryBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.IssueRepositoryFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + issueRepositories, err := app.ListIssueRepositories(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleIssueRepositoryBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(issueRepositories.Elements) > 1 { + return nil, NewResolverError("SingleIssueRepositoryBaseResolver", "Internal Error - found multiple issue repositories") + } + + //not found + if len(issueRepositories.Elements) < 1 { + return nil, nil + } + + var irr entity.IssueRepositoryResult = issueRepositories.Elements[0] + issueRepository := model.NewIssueRepository(irr.IssueRepository) + + return &issueRepository, nil +} + +func IssueRepositoryBaseResolver(app app.Heureka, ctx context.Context, filter *model.IssueRepositoryFilter, first *int, after *string, parent *model.NodeParent) (*model.IssueRepositoryConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called IssueRepositoryBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("IssueRepositoryBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("IssueRepositoryBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var serviceId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("IssueRepositoryBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("IssueRepositoryBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ServiceNodeName: + serviceId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.IssueRepositoryFilter{} + } + + f := &entity.IssueRepositoryFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + ServiceId: serviceId, + Name: filter.Name, + ServiceName: filter.ServiceName, + } + + opt := GetListOptions(requestedFields) + + issueRepositories, err := app.ListIssueRepositories(f, opt) + + if err != nil { + return nil, NewResolverError("IssueRepositoryBaseResolver", err.Error()) + } + + edges := []*model.IssueRepositoryEdge{} + for _, result := range issueRepositories.Elements { + ir := model.NewIssueRepository(result.IssueRepository) + + edge := model.IssueRepositoryEdge{ + Node: &ir, + Cursor: result.Cursor(), + } + + if lo.Contains(requestedFields, "edges.priority") { + p := int(result.IssueRepositoryService.Priority) + edge.Priority = &p + } + + edges = append(edges, &edge) + } + + tc := 0 + if issueRepositories.TotalCount != nil { + tc = int(*issueRepositories.TotalCount) + } + + connection := model.IssueRepositoryConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(issueRepositories.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/issue_variant.go b/internal/api/graphql/graph/baseResolver/issue_variant.go new file mode 100644 index 00000000..2679911b --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/issue_variant.go @@ -0,0 +1,198 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleIssueVariantBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.IssueVariant, error) { + + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleIssueVariantBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleIssueVariantBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.IssueVariantFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + variants, err := app.ListIssueVariants(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleIssueVariantBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(variants.Elements) > 1 { + return nil, NewResolverError("SingleIssueVariantBaseResolver", "Internal Error - found multiple variants") + } + + //not found + if len(variants.Elements) < 1 { + return nil, nil + } + + var ivr entity.IssueVariantResult = variants.Elements[0] + variant := model.NewIssueVariant(ivr.IssueVariant) + + return &variant, nil +} + +func IssueVariantBaseResolver(app app.Heureka, ctx context.Context, filter *model.IssueVariantFilter, first *int, after *string, parent *model.NodeParent) (*model.IssueVariantConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called IssueVariantBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("IssueVariantBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("IssueVariantBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var issueId []*int64 + var irId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("IssueVariantBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("IssueVariantBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.IssueNodeName: + issueId = []*int64{pid} + case model.IssueRepositoryNodeName: + irId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.IssueVariantFilter{} + } + + f := &entity.IssueVariantFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + IssueId: issueId, + IssueRepositoryId: irId, + } + + opt := GetListOptions(requestedFields) + + variants, err := app.ListIssueVariants(f, opt) + + if err != nil { + return nil, NewResolverError("IssueVariantBaseResolver", err.Error()) + } + + edges := []*model.IssueVariantEdge{} + for _, result := range variants.Elements { + iv := model.NewIssueVariant(result.IssueVariant) + edge := model.IssueVariantEdge{ + Node: &iv, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if variants.TotalCount != nil { + tc = int(*variants.TotalCount) + } + + connection := model.IssueVariantConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(variants.PageInfo), + } + + return &connection, nil + +} + +func EffectiveIssueVariantBaseResolver(app app.Heureka, ctx context.Context, filter *model.IssueVariantFilter, first *int, after *string, parent *model.NodeParent) (*model.IssueVariantConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called EffectiveIssueVariantBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("EffectiveIssueVariantBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("EffectiveIssueVariantBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var imId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("EffectiveIssueVariantBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("EffectiveIssueVariantBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.IssueMatchNodeName: + imId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.IssueVariantFilter{} + } + + f := &entity.IssueVariantFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + IssueMatchId: imId, + } + + opt := GetListOptions(requestedFields) + + variants, err := app.ListEffectiveIssueVariants(f, opt) + + if err != nil { + return nil, NewResolverError("EffectiveIssueVariantBaseResolver", err.Error()) + } + + edges := []*model.IssueVariantEdge{} + for _, result := range variants.Elements { + iv := model.NewIssueVariant(result.IssueVariant) + edge := model.IssueVariantEdge{ + Node: &iv, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if variants.TotalCount != nil { + tc = int(*variants.TotalCount) + } + + connection := model.IssueVariantConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(variants.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/service.go b/internal/api/graphql/graph/baseResolver/service.go new file mode 100644 index 00000000..4e090e5d --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/service.go @@ -0,0 +1,145 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/samber/lo" + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleServiceBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.Service, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleServiceBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleServiceBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.ServiceFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + services, err := app.ListServices(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleServiceBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(services.Elements) > 1 { + return nil, NewResolverError("SingleServiceBaseResolver", "Internal Error - found multiple services") + } + + //not found + if len(services.Elements) < 1 { + return nil, nil + } + + var sr entity.ServiceResult = services.Elements[0] + service := model.NewService(sr.Service) + + return &service, nil +} + +func ServiceBaseResolver(app app.Heureka, ctx context.Context, filter *model.ServiceFilter, first *int, after *string, parent *model.NodeParent) (*model.ServiceConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called ServiceBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("ServiceBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("ServiceBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var activityId []*int64 + var irId []*int64 + var sgId []*int64 + var ownerId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("ServiceBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("ServiceBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ActivityNodeName: + activityId = []*int64{pid} + case model.IssueRepositoryNodeName: + irId = []*int64{pid} + case model.SupportGroupNodeName: + sgId = []*int64{pid} + case model.UserNodeName: + ownerId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.ServiceFilter{} + } + + f := &entity.ServiceFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + SupportGroupName: filter.SupportGroupName, + Name: filter.ServiceName, + OwnerName: filter.UserName, + OwnerId: ownerId, + ActivityId: activityId, + IssueRepositoryId: irId, + SupportGroupId: sgId, + } + + opt := GetListOptions(requestedFields) + + services, err := app.ListServices(f, opt) + + if err != nil { + return nil, NewResolverError("ServiceBaseResolver", err.Error()) + } + + edges := []*model.ServiceEdge{} + for _, result := range services.Elements { + s := model.NewService(result.Service) + edge := model.ServiceEdge{ + Node: &s, + Cursor: result.Cursor(), + } + + if lo.Contains(requestedFields, "edges.priority") { + p := int(result.IssueRepositoryService.Priority) + edge.Priority = &p + } + + edges = append(edges, &edge) + } + + tc := 0 + if services.TotalCount != nil { + tc = int(*services.TotalCount) + } + + connection := model.ServiceConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(services.PageInfo), + } + + return &connection, nil + +} diff --git a/internal/api/graphql/graph/baseResolver/support_group.go b/internal/api/graphql/graph/baseResolver/support_group.go new file mode 100644 index 00000000..e05e258a --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/support_group.go @@ -0,0 +1,87 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SupportGroupBaseResolver(app app.Heureka, ctx context.Context, filter *model.SupportGroupFilter, first *int, after *string, parent *model.NodeParent) (*model.SupportGroupConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SupportGroupBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("SupportGroupBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("SupportGroupBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var serviceId []*int64 + var userId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("SupportGroupBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("SupportGroupBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.ServiceNodeName: + serviceId = []*int64{pid} + case model.UserNodeName: + userId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.SupportGroupFilter{} + } + + f := &entity.SupportGroupFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + ServiceId: serviceId, + UserId: userId, + Name: filter.SupportGroupName, + } + + opt := GetListOptions(requestedFields) + + supportGroups, err := app.ListSupportGroups(f, opt) + + if err != nil { + return nil, NewResolverError("SupportGroupBaseResolver", err.Error()) + } + + edges := []*model.SupportGroupEdge{} + for _, result := range supportGroups.Elements { + sg := model.NewSupportGroup(result.SupportGroup) + edge := model.SupportGroupEdge{ + Node: &sg, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if supportGroups.TotalCount != nil { + tc = int(*supportGroups.TotalCount) + } + + connection := model.SupportGroupConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(supportGroups.PageInfo), + } + + return &connection, nil +} diff --git a/internal/api/graphql/graph/baseResolver/user.go b/internal/api/graphql/graph/baseResolver/user.go new file mode 100644 index 00000000..f335ed00 --- /dev/null +++ b/internal/api/graphql/graph/baseResolver/user.go @@ -0,0 +1,127 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package baseResolver + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/app" + "github.wdf.sap.corp/cc/heureka/internal/entity" +) + +func SingleUserBaseResolver(app app.Heureka, ctx context.Context, parent *model.NodeParent) (*model.User, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called SingleUserBaseResolver") + + if parent == nil { + return nil, NewResolverError("SingleUserBaseResolver", "Bad Request - No parent provided") + } + + f := &entity.UserFilter{ + Id: parent.ChildIds, + } + + opt := &entity.ListOptions{} + + users, err := app.ListUsers(f, opt) + + // error while fetching + if err != nil { + return nil, NewResolverError("SingleUserBaseResolver", err.Error()) + } + + // unexpected number of results (should at most be 1) + if len(users.Elements) > 1 { + return nil, NewResolverError("SingleUserBaseResolver", "Internal Error - found multiple users") + } + + //not found + if len(users.Elements) < 1 { + return nil, nil + } + + var ur entity.UserResult = users.Elements[0] + user := model.NewUser(ur.User) + + return &user, nil +} + +func UserBaseResolver(app app.Heureka, ctx context.Context, filter *model.UserFilter, first *int, after *string, parent *model.NodeParent) (*model.UserConnection, error) { + requestedFields := GetPreloads(ctx) + logrus.WithFields(logrus.Fields{ + "requestedFields": requestedFields, + "parent": parent, + }).Debug("Called UserBaseResolver") + + afterId, err := ParseCursor(after) + if err != nil { + logrus.WithField("after", after).Error("UserBaseResolver: Error while parsing parameter 'after'") + return nil, NewResolverError("UserBaseResolver", "Bad Request - unable to parse cursor 'after'") + } + + var supportGroupId []*int64 + var serviceId []*int64 + if parent != nil { + parentId := parent.Parent.GetID() + pid, err := ParseCursor(&parentId) + if err != nil { + logrus.WithField("parent", parent).Error("UserBaseResolver: Error while parsing propagated parent ID'") + return nil, NewResolverError("UserBaseResolver", "Bad Request - Error while parsing propagated ID") + } + + switch parent.ParentName { + case model.SupportGroupNodeName: + supportGroupId = []*int64{pid} + case model.ServiceNodeName: + serviceId = []*int64{pid} + } + } + + if filter == nil { + filter = &model.UserFilter{} + } + + f := &entity.UserFilter{ + Paginated: entity.Paginated{First: first, After: afterId}, + SupportGroupId: supportGroupId, + ServiceId: serviceId, + Name: filter.UserName, + } + + opt := GetListOptions(requestedFields) + + users, err := app.ListUsers(f, opt) + + if err != nil { + return nil, NewResolverError("UserBaseResolver", err.Error()) + } + + edges := []*model.UserEdge{} + for _, result := range users.Elements { + user := model.NewUser(result.User) + edge := model.UserEdge{ + Node: &user, + Cursor: result.Cursor(), + } + edges = append(edges, &edge) + } + + tc := 0 + if users.TotalCount != nil { + tc = int(*users.TotalCount) + } + + connection := model.UserConnection{ + TotalCount: tc, + Edges: edges, + PageInfo: model.NewPageInfo(users.PageInfo), + } + + return &connection, nil +} diff --git a/internal/api/graphql/graph/generated.go b/internal/api/graphql/graph/generated.go new file mode 100644 index 00000000..99869551 --- /dev/null +++ b/internal/api/graphql/graph/generated.go @@ -0,0 +1,28143 @@ +// Code generated by github.com/99designs/gqlgen, DO NOT EDIT. + +package graph + +import ( + "bytes" + "context" + "embed" + "errors" + "fmt" + "strconv" + "sync" + "sync/atomic" + + "github.com/99designs/gqlgen/graphql" + "github.com/99designs/gqlgen/graphql/introspection" + gqlparser "github.com/vektah/gqlparser/v2" + "github.com/vektah/gqlparser/v2/ast" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// region ************************** generated!.gotpl ************************** + +// NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface. +func NewExecutableSchema(cfg Config) graphql.ExecutableSchema { + return &executableSchema{ + schema: cfg.Schema, + resolvers: cfg.Resolvers, + directives: cfg.Directives, + complexity: cfg.Complexity, + } +} + +type Config struct { + Schema *ast.Schema + Resolvers ResolverRoot + Directives DirectiveRoot + Complexity ComplexityRoot +} + +type ResolverRoot interface { + Activity() ActivityResolver + Component() ComponentResolver + ComponentInstance() ComponentInstanceResolver + ComponentVersion() ComponentVersionResolver + Evidence() EvidenceResolver + Issue() IssueResolver + IssueMatch() IssueMatchResolver + IssueMatchChange() IssueMatchChangeResolver + IssueRepository() IssueRepositoryResolver + IssueVariant() IssueVariantResolver + Mutation() MutationResolver + Query() QueryResolver + Service() ServiceResolver + SupportGroup() SupportGroupResolver + User() UserResolver +} + +type DirectiveRoot struct { +} + +type ComplexityRoot struct { + Activity struct { + Evidences func(childComplexity int, filter *model.EvidenceFilter, first *int, after *string) int + ID func(childComplexity int) int + IssueMatchChanges func(childComplexity int, filter *model.IssueMatchChangeFilter, first *int, after *string) int + Issues func(childComplexity int, filter *model.IssueFilter, first *int, after *string) int + Services func(childComplexity int, filter *model.ServiceFilter, first *int, after *string) int + Status func(childComplexity int) int + } + + ActivityConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + ActivityEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + CVSS struct { + Base func(childComplexity int) int + Environmental func(childComplexity int) int + Temporal func(childComplexity int) int + Vector func(childComplexity int) int + } + + CVSSBase struct { + AttackComplexity func(childComplexity int) int + AttackVector func(childComplexity int) int + AvailabilityImpact func(childComplexity int) int + ConfidentialityImpact func(childComplexity int) int + IntegrityImpact func(childComplexity int) int + PrivilegesRequired func(childComplexity int) int + Scope func(childComplexity int) int + Score func(childComplexity int) int + UserInteraction func(childComplexity int) int + } + + CVSSEnvironmental struct { + AvailabilityRequirement func(childComplexity int) int + ConfidentialityRequirement func(childComplexity int) int + IntegrityRequirement func(childComplexity int) int + ModifiedAttackComplexity func(childComplexity int) int + ModifiedAttackVector func(childComplexity int) int + ModifiedAvailabilityImpact func(childComplexity int) int + ModifiedConfidentialityImpact func(childComplexity int) int + ModifiedIntegrityImpact func(childComplexity int) int + ModifiedPrivilegesRequired func(childComplexity int) int + ModifiedScope func(childComplexity int) int + ModifiedUserInteraction func(childComplexity int) int + Score func(childComplexity int) int + } + + CVSSParameter struct { + Name func(childComplexity int) int + Value func(childComplexity int) int + } + + CVSSTemporal struct { + ExploitCodeMaturity func(childComplexity int) int + RemediationLevel func(childComplexity int) int + ReportConfidence func(childComplexity int) int + Score func(childComplexity int) int + } + + Component struct { + ComponentVersions func(childComplexity int, filter *model.ComponentVersionFilter, first *int, after *string) int + ID func(childComplexity int) int + Name func(childComplexity int) int + Type func(childComplexity int) int + } + + ComponentConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + ComponentEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + ComponentInstance struct { + Ccrn func(childComplexity int) int + ComponentVersion func(childComplexity int) int + ComponentVersionID func(childComplexity int) int + Count func(childComplexity int) int + CreatedAt func(childComplexity int) int + ID func(childComplexity int) int + IssueMatches func(childComplexity int, filter *model.IssueMatchFilter, first *int, after *string) int + Service func(childComplexity int) int + ServiceID func(childComplexity int) int + UpdatedAt func(childComplexity int) int + } + + ComponentInstanceConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + ComponentInstanceEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + ComponentVersion struct { + Component func(childComplexity int) int + ComponentID func(childComplexity int) int + ID func(childComplexity int) int + Issues func(childComplexity int, first *int, after *string) int + Version func(childComplexity int) int + } + + ComponentVersionConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + ComponentVersionEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + Evidence struct { + Activity func(childComplexity int) int + ActivityID func(childComplexity int) int + Author func(childComplexity int) int + AuthorID func(childComplexity int) int + Description func(childComplexity int) int + ID func(childComplexity int) int + IssueMatches func(childComplexity int, filter *model.IssueMatchFilter, first *int, after *string) int + RaaEnd func(childComplexity int) int + Type func(childComplexity int) int + Vector func(childComplexity int) int + } + + EvidenceConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + EvidenceEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + Issue struct { + Activities func(childComplexity int, filter *model.ActivityFilter, first *int, after *string) int + ComponentVersions func(childComplexity int, filter *model.ComponentVersionFilter, first *int, after *string) int + ID func(childComplexity int) int + IssueMatches func(childComplexity int, filter *model.IssueMatchFilter, first *int, after *string) int + IssueVariants func(childComplexity int, filter *model.IssueVariantFilter, first *int, after *string) int + LastModified func(childComplexity int) int + Metadata func(childComplexity int) int + PrimaryName func(childComplexity int) int + Type func(childComplexity int) int + } + + IssueConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + IssueEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + IssueMatch struct { + ComponentInstance func(childComplexity int) int + ComponentInstanceID func(childComplexity int) int + DiscoveryDate func(childComplexity int) int + EffectiveIssueVariants func(childComplexity int, filter *model.IssueVariantFilter, first *int, after *string) int + Evidences func(childComplexity int, filter *model.EvidenceFilter, first *int, after *string) int + ID func(childComplexity int) int + Issue func(childComplexity int) int + IssueID func(childComplexity int) int + IssueMatchChanges func(childComplexity int, filter *model.IssueMatchChangeFilter, first *int, after *string) int + RemediationDate func(childComplexity int) int + Severity func(childComplexity int) int + Status func(childComplexity int) int + TargetRemediationDate func(childComplexity int) int + User func(childComplexity int) int + UserID func(childComplexity int) int + } + + IssueMatchChange struct { + Action func(childComplexity int) int + Activity func(childComplexity int) int + ActivityID func(childComplexity int) int + ID func(childComplexity int) int + IssueMatch func(childComplexity int) int + IssueMatchID func(childComplexity int) int + } + + IssueMatchChangeConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + IssueMatchChangeEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + IssueMatchConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + IssueMatchEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + IssueMetadata struct { + ActivityCount func(childComplexity int) int + ComponentInstanceCount func(childComplexity int) int + ComponentVersionCount func(childComplexity int) int + EarliestDiscoveryDate func(childComplexity int) int + EarliestTargetRemediationDate func(childComplexity int) int + IssueMatchCount func(childComplexity int) int + ServiceCount func(childComplexity int) int + } + + IssueRepository struct { + CreatedAt func(childComplexity int) int + ID func(childComplexity int) int + IssueVariants func(childComplexity int, filter *model.IssueVariantFilter, first *int, after *string) int + Name func(childComplexity int) int + Services func(childComplexity int, filter *model.ServiceFilter, first *int, after *string) int + URL func(childComplexity int) int + UpdatedAt func(childComplexity int) int + } + + IssueRepositoryConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + IssueRepositoryEdge struct { + CreatedAt func(childComplexity int) int + Cursor func(childComplexity int) int + Node func(childComplexity int) int + Priority func(childComplexity int) int + UpdatedAt func(childComplexity int) int + } + + IssueVariant struct { + CreatedAt func(childComplexity int) int + Description func(childComplexity int) int + ID func(childComplexity int) int + Issue func(childComplexity int) int + IssueID func(childComplexity int) int + IssueRepository func(childComplexity int) int + IssueRepositoryID func(childComplexity int) int + SecondaryName func(childComplexity int) int + Severity func(childComplexity int) int + UpdatedAt func(childComplexity int) int + } + + IssueVariantConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + IssueVariantEdge struct { + CreatedAt func(childComplexity int) int + Cursor func(childComplexity int) int + Node func(childComplexity int) int + UpdatedAt func(childComplexity int) int + } + + Mutation struct { + CreateActivity func(childComplexity int, input model.ActivityInput) int + CreateComponent func(childComplexity int, input model.ComponentInput) int + CreateComponentInstance func(childComplexity int, input model.ComponentInstanceInput) int + CreateComponentVersion func(childComplexity int, input model.ComponentVersionInput) int + CreateEvidence func(childComplexity int, input model.EvidenceInput) int + CreateIssueMatch func(childComplexity int, input model.IssueMatchInput) int + CreateIssueRepository func(childComplexity int, input model.IssueRepositoryInput) int + CreateIssueVariant func(childComplexity int, input model.IssueVariantInput) int + CreateService func(childComplexity int, input model.ServiceInput) int + CreateSupportGroup func(childComplexity int, input model.SupportGroupInput) int + CreateUser func(childComplexity int, input model.UserInput) int + DeleteActivity func(childComplexity int, id string) int + DeleteComponent func(childComplexity int, id string) int + DeleteComponentInstance func(childComplexity int, id string) int + DeleteComponentVersion func(childComplexity int, id string) int + DeleteEvidence func(childComplexity int, id string) int + DeleteIssueMatch func(childComplexity int, id string) int + DeleteIssueRepository func(childComplexity int, id string) int + DeleteIssueVariant func(childComplexity int, id string) int + DeleteService func(childComplexity int, id string) int + DeleteSupportGroup func(childComplexity int, id string) int + DeleteUser func(childComplexity int, id string) int + UpdateActivity func(childComplexity int, id string, input model.ActivityInput) int + UpdateComponent func(childComplexity int, id string, input model.ComponentInput) int + UpdateComponentInstance func(childComplexity int, id string, input model.ComponentInstanceInput) int + UpdateComponentVersion func(childComplexity int, id string, input model.ComponentVersionInput) int + UpdateEvidence func(childComplexity int, id string, input model.EvidenceInput) int + UpdateIssueMatch func(childComplexity int, id string, input model.IssueMatchInput) int + UpdateIssueRepository func(childComplexity int, id string, input model.IssueRepositoryInput) int + UpdateIssueVariant func(childComplexity int, id string, input model.IssueVariantInput) int + UpdateService func(childComplexity int, id string, input model.ServiceInput) int + UpdateSupportGroup func(childComplexity int, id string, input model.SupportGroupInput) int + UpdateUser func(childComplexity int, id string, input model.UserInput) int + } + + Page struct { + After func(childComplexity int) int + IsCurrent func(childComplexity int) int + PageCount func(childComplexity int) int + PageNumber func(childComplexity int) int + } + + PageInfo struct { + HasNextPage func(childComplexity int) int + HasPreviousPage func(childComplexity int) int + IsValidPage func(childComplexity int) int + NextPageAfter func(childComplexity int) int + PageNumber func(childComplexity int) int + Pages func(childComplexity int) int + } + + Query struct { + Activities func(childComplexity int, filter *model.ActivityFilter, first *int, after *string) int + ComponentInstances func(childComplexity int, filter *model.ComponentInstanceFilter, first *int, after *string) int + ComponentVersions func(childComplexity int, filter *model.ComponentVersionFilter, first *int, after *string) int + Components func(childComplexity int, filter *model.ComponentFilter, first *int, after *string) int + Evidences func(childComplexity int, filter *model.EvidenceFilter, first *int, after *string) int + IssueMatchChanges func(childComplexity int, filter *model.IssueMatchChangeFilter, first *int, after *string) int + IssueMatches func(childComplexity int, filter *model.IssueMatchFilter, first *int, after *string) int + IssueRepositories func(childComplexity int, filter *model.IssueRepositoryFilter, first *int, after *string) int + IssueVariants func(childComplexity int, filter *model.IssueVariantFilter, first *int, after *string) int + Issues func(childComplexity int, filter *model.IssueFilter, first *int, after *string) int + Services func(childComplexity int, filter *model.ServiceFilter, first *int, after *string) int + SupportGroups func(childComplexity int, filter *model.SupportGroupFilter, first *int, after *string) int + Users func(childComplexity int, filter *model.UserFilter, first *int, after *string) int + } + + Service struct { + Activities func(childComplexity int, filter *model.ActivityFilter, first *int, after *string) int + ComponentInstances func(childComplexity int, filter *model.ComponentInstanceFilter, first *int, after *string) int + ID func(childComplexity int) int + IssueRepositories func(childComplexity int, filter *model.IssueRepositoryFilter, first *int, after *string) int + Name func(childComplexity int) int + Owners func(childComplexity int, filter *model.UserFilter, first *int, after *string) int + SupportGroups func(childComplexity int, filter *model.SupportGroupFilter, first *int, after *string) int + } + + ServiceConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + ServiceEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + Priority func(childComplexity int) int + } + + Severity struct { + Cvss func(childComplexity int) int + Score func(childComplexity int) int + Value func(childComplexity int) int + } + + SupportGroup struct { + ID func(childComplexity int) int + Name func(childComplexity int) int + Services func(childComplexity int, filter *model.ServiceFilter, first *int, after *string) int + Users func(childComplexity int, filter *model.UserFilter, first *int, after *string) int + } + + SupportGroupConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + SupportGroupEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } + + User struct { + ID func(childComplexity int) int + Name func(childComplexity int) int + SapID func(childComplexity int) int + Services func(childComplexity int, filter *model.ServiceFilter, first *int, after *string) int + SupportGroups func(childComplexity int, filter *model.SupportGroupFilter, first *int, after *string) int + } + + UserConnection struct { + Edges func(childComplexity int) int + PageInfo func(childComplexity int) int + TotalCount func(childComplexity int) int + } + + UserEdge struct { + Cursor func(childComplexity int) int + Node func(childComplexity int) int + } +} + +type ActivityResolver interface { + Services(ctx context.Context, obj *model.Activity, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) + Issues(ctx context.Context, obj *model.Activity, filter *model.IssueFilter, first *int, after *string) (*model.IssueConnection, error) + Evidences(ctx context.Context, obj *model.Activity, filter *model.EvidenceFilter, first *int, after *string) (*model.EvidenceConnection, error) + IssueMatchChanges(ctx context.Context, obj *model.Activity, filter *model.IssueMatchChangeFilter, first *int, after *string) (*model.IssueMatchChangeConnection, error) +} +type ComponentResolver interface { + ComponentVersions(ctx context.Context, obj *model.Component, filter *model.ComponentVersionFilter, first *int, after *string) (*model.ComponentVersionConnection, error) +} +type ComponentInstanceResolver interface { + ComponentVersion(ctx context.Context, obj *model.ComponentInstance) (*model.ComponentVersion, error) + IssueMatches(ctx context.Context, obj *model.ComponentInstance, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) + + Service(ctx context.Context, obj *model.ComponentInstance) (*model.Service, error) +} +type ComponentVersionResolver interface { + Component(ctx context.Context, obj *model.ComponentVersion) (*model.Component, error) + Issues(ctx context.Context, obj *model.ComponentVersion, first *int, after *string) (*model.IssueConnection, error) +} +type EvidenceResolver interface { + Author(ctx context.Context, obj *model.Evidence) (*model.User, error) + + Activity(ctx context.Context, obj *model.Evidence) (*model.Activity, error) + IssueMatches(ctx context.Context, obj *model.Evidence, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) +} +type IssueResolver interface { + IssueVariants(ctx context.Context, obj *model.Issue, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) + Activities(ctx context.Context, obj *model.Issue, filter *model.ActivityFilter, first *int, after *string) (*model.ActivityConnection, error) + IssueMatches(ctx context.Context, obj *model.Issue, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) + ComponentVersions(ctx context.Context, obj *model.Issue, filter *model.ComponentVersionFilter, first *int, after *string) (*model.ComponentVersionConnection, error) +} +type IssueMatchResolver interface { + Severity(ctx context.Context, obj *model.IssueMatch) (*model.Severity, error) + EffectiveIssueVariants(ctx context.Context, obj *model.IssueMatch, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) + Evidences(ctx context.Context, obj *model.IssueMatch, filter *model.EvidenceFilter, first *int, after *string) (*model.EvidenceConnection, error) + + Issue(ctx context.Context, obj *model.IssueMatch) (*model.Issue, error) + + ComponentInstance(ctx context.Context, obj *model.IssueMatch) (*model.ComponentInstance, error) + IssueMatchChanges(ctx context.Context, obj *model.IssueMatch, filter *model.IssueMatchChangeFilter, first *int, after *string) (*model.IssueMatchChangeConnection, error) +} +type IssueMatchChangeResolver interface { + IssueMatch(ctx context.Context, obj *model.IssueMatchChange) (*model.IssueMatch, error) + + Activity(ctx context.Context, obj *model.IssueMatchChange) (*model.Activity, error) +} +type IssueRepositoryResolver interface { + IssueVariants(ctx context.Context, obj *model.IssueRepository, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) + Services(ctx context.Context, obj *model.IssueRepository, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) +} +type IssueVariantResolver interface { + IssueRepository(ctx context.Context, obj *model.IssueVariant) (*model.IssueRepository, error) + + Issue(ctx context.Context, obj *model.IssueVariant) (*model.Issue, error) +} +type MutationResolver interface { + CreateUser(ctx context.Context, input model.UserInput) (*model.User, error) + UpdateUser(ctx context.Context, id string, input model.UserInput) (*model.User, error) + DeleteUser(ctx context.Context, id string) (string, error) + CreateSupportGroup(ctx context.Context, input model.SupportGroupInput) (*model.SupportGroup, error) + UpdateSupportGroup(ctx context.Context, id string, input model.SupportGroupInput) (*model.SupportGroup, error) + DeleteSupportGroup(ctx context.Context, id string) (string, error) + CreateComponent(ctx context.Context, input model.ComponentInput) (*model.Component, error) + UpdateComponent(ctx context.Context, id string, input model.ComponentInput) (*model.Component, error) + DeleteComponent(ctx context.Context, id string) (string, error) + CreateComponentInstance(ctx context.Context, input model.ComponentInstanceInput) (*model.ComponentInstance, error) + UpdateComponentInstance(ctx context.Context, id string, input model.ComponentInstanceInput) (*model.ComponentInstance, error) + DeleteComponentInstance(ctx context.Context, id string) (string, error) + CreateComponentVersion(ctx context.Context, input model.ComponentVersionInput) (*model.ComponentVersion, error) + UpdateComponentVersion(ctx context.Context, id string, input model.ComponentVersionInput) (*model.ComponentVersion, error) + DeleteComponentVersion(ctx context.Context, id string) (string, error) + CreateService(ctx context.Context, input model.ServiceInput) (*model.Service, error) + UpdateService(ctx context.Context, id string, input model.ServiceInput) (*model.Service, error) + DeleteService(ctx context.Context, id string) (string, error) + CreateIssueRepository(ctx context.Context, input model.IssueRepositoryInput) (*model.IssueRepository, error) + UpdateIssueRepository(ctx context.Context, id string, input model.IssueRepositoryInput) (*model.IssueRepository, error) + DeleteIssueRepository(ctx context.Context, id string) (string, error) + CreateIssueVariant(ctx context.Context, input model.IssueVariantInput) (*model.IssueVariant, error) + UpdateIssueVariant(ctx context.Context, id string, input model.IssueVariantInput) (*model.IssueVariant, error) + DeleteIssueVariant(ctx context.Context, id string) (string, error) + CreateEvidence(ctx context.Context, input model.EvidenceInput) (*model.Evidence, error) + UpdateEvidence(ctx context.Context, id string, input model.EvidenceInput) (*model.Evidence, error) + DeleteEvidence(ctx context.Context, id string) (string, error) + CreateIssueMatch(ctx context.Context, input model.IssueMatchInput) (*model.IssueMatch, error) + UpdateIssueMatch(ctx context.Context, id string, input model.IssueMatchInput) (*model.IssueMatch, error) + DeleteIssueMatch(ctx context.Context, id string) (string, error) + CreateActivity(ctx context.Context, input model.ActivityInput) (*model.Activity, error) + UpdateActivity(ctx context.Context, id string, input model.ActivityInput) (*model.Activity, error) + DeleteActivity(ctx context.Context, id string) (string, error) +} +type QueryResolver interface { + Issues(ctx context.Context, filter *model.IssueFilter, first *int, after *string) (*model.IssueConnection, error) + IssueMatches(ctx context.Context, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) + IssueMatchChanges(ctx context.Context, filter *model.IssueMatchChangeFilter, first *int, after *string) (*model.IssueMatchChangeConnection, error) + Services(ctx context.Context, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) + Components(ctx context.Context, filter *model.ComponentFilter, first *int, after *string) (*model.ComponentConnection, error) + ComponentVersions(ctx context.Context, filter *model.ComponentVersionFilter, first *int, after *string) (*model.ComponentVersionConnection, error) + ComponentInstances(ctx context.Context, filter *model.ComponentInstanceFilter, first *int, after *string) (*model.ComponentInstanceConnection, error) + Activities(ctx context.Context, filter *model.ActivityFilter, first *int, after *string) (*model.ActivityConnection, error) + IssueVariants(ctx context.Context, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) + IssueRepositories(ctx context.Context, filter *model.IssueRepositoryFilter, first *int, after *string) (*model.IssueRepositoryConnection, error) + Evidences(ctx context.Context, filter *model.EvidenceFilter, first *int, after *string) (*model.EvidenceConnection, error) + SupportGroups(ctx context.Context, filter *model.SupportGroupFilter, first *int, after *string) (*model.SupportGroupConnection, error) + Users(ctx context.Context, filter *model.UserFilter, first *int, after *string) (*model.UserConnection, error) +} +type ServiceResolver interface { + Owners(ctx context.Context, obj *model.Service, filter *model.UserFilter, first *int, after *string) (*model.UserConnection, error) + SupportGroups(ctx context.Context, obj *model.Service, filter *model.SupportGroupFilter, first *int, after *string) (*model.SupportGroupConnection, error) + Activities(ctx context.Context, obj *model.Service, filter *model.ActivityFilter, first *int, after *string) (*model.ActivityConnection, error) + IssueRepositories(ctx context.Context, obj *model.Service, filter *model.IssueRepositoryFilter, first *int, after *string) (*model.IssueRepositoryConnection, error) + ComponentInstances(ctx context.Context, obj *model.Service, filter *model.ComponentInstanceFilter, first *int, after *string) (*model.ComponentInstanceConnection, error) +} +type SupportGroupResolver interface { + Users(ctx context.Context, obj *model.SupportGroup, filter *model.UserFilter, first *int, after *string) (*model.UserConnection, error) + Services(ctx context.Context, obj *model.SupportGroup, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) +} +type UserResolver interface { + SupportGroups(ctx context.Context, obj *model.User, filter *model.SupportGroupFilter, first *int, after *string) (*model.SupportGroupConnection, error) + Services(ctx context.Context, obj *model.User, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) +} + +type executableSchema struct { + schema *ast.Schema + resolvers ResolverRoot + directives DirectiveRoot + complexity ComplexityRoot +} + +func (e *executableSchema) Schema() *ast.Schema { + if e.schema != nil { + return e.schema + } + return parsedSchema +} + +func (e *executableSchema) Complexity(typeName, field string, childComplexity int, rawArgs map[string]interface{}) (int, bool) { + ec := executionContext{nil, e, 0, 0, nil} + _ = ec + switch typeName + "." + field { + + case "Activity.evidences": + if e.complexity.Activity.Evidences == nil { + break + } + + args, err := ec.field_Activity_evidences_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Activity.Evidences(childComplexity, args["filter"].(*model.EvidenceFilter), args["first"].(*int), args["after"].(*string)), true + + case "Activity.id": + if e.complexity.Activity.ID == nil { + break + } + + return e.complexity.Activity.ID(childComplexity), true + + case "Activity.issueMatchChanges": + if e.complexity.Activity.IssueMatchChanges == nil { + break + } + + args, err := ec.field_Activity_issueMatchChanges_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Activity.IssueMatchChanges(childComplexity, args["filter"].(*model.IssueMatchChangeFilter), args["first"].(*int), args["after"].(*string)), true + + case "Activity.issues": + if e.complexity.Activity.Issues == nil { + break + } + + args, err := ec.field_Activity_issues_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Activity.Issues(childComplexity, args["filter"].(*model.IssueFilter), args["first"].(*int), args["after"].(*string)), true + + case "Activity.services": + if e.complexity.Activity.Services == nil { + break + } + + args, err := ec.field_Activity_services_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Activity.Services(childComplexity, args["filter"].(*model.ServiceFilter), args["first"].(*int), args["after"].(*string)), true + + case "Activity.status": + if e.complexity.Activity.Status == nil { + break + } + + return e.complexity.Activity.Status(childComplexity), true + + case "ActivityConnection.edges": + if e.complexity.ActivityConnection.Edges == nil { + break + } + + return e.complexity.ActivityConnection.Edges(childComplexity), true + + case "ActivityConnection.pageInfo": + if e.complexity.ActivityConnection.PageInfo == nil { + break + } + + return e.complexity.ActivityConnection.PageInfo(childComplexity), true + + case "ActivityConnection.totalCount": + if e.complexity.ActivityConnection.TotalCount == nil { + break + } + + return e.complexity.ActivityConnection.TotalCount(childComplexity), true + + case "ActivityEdge.cursor": + if e.complexity.ActivityEdge.Cursor == nil { + break + } + + return e.complexity.ActivityEdge.Cursor(childComplexity), true + + case "ActivityEdge.node": + if e.complexity.ActivityEdge.Node == nil { + break + } + + return e.complexity.ActivityEdge.Node(childComplexity), true + + case "CVSS.base": + if e.complexity.CVSS.Base == nil { + break + } + + return e.complexity.CVSS.Base(childComplexity), true + + case "CVSS.environmental": + if e.complexity.CVSS.Environmental == nil { + break + } + + return e.complexity.CVSS.Environmental(childComplexity), true + + case "CVSS.temporal": + if e.complexity.CVSS.Temporal == nil { + break + } + + return e.complexity.CVSS.Temporal(childComplexity), true + + case "CVSS.vector": + if e.complexity.CVSS.Vector == nil { + break + } + + return e.complexity.CVSS.Vector(childComplexity), true + + case "CVSSBase.attackComplexity": + if e.complexity.CVSSBase.AttackComplexity == nil { + break + } + + return e.complexity.CVSSBase.AttackComplexity(childComplexity), true + + case "CVSSBase.attackVector": + if e.complexity.CVSSBase.AttackVector == nil { + break + } + + return e.complexity.CVSSBase.AttackVector(childComplexity), true + + case "CVSSBase.availabilityImpact": + if e.complexity.CVSSBase.AvailabilityImpact == nil { + break + } + + return e.complexity.CVSSBase.AvailabilityImpact(childComplexity), true + + case "CVSSBase.confidentialityImpact": + if e.complexity.CVSSBase.ConfidentialityImpact == nil { + break + } + + return e.complexity.CVSSBase.ConfidentialityImpact(childComplexity), true + + case "CVSSBase.integrityImpact": + if e.complexity.CVSSBase.IntegrityImpact == nil { + break + } + + return e.complexity.CVSSBase.IntegrityImpact(childComplexity), true + + case "CVSSBase.privilegesRequired": + if e.complexity.CVSSBase.PrivilegesRequired == nil { + break + } + + return e.complexity.CVSSBase.PrivilegesRequired(childComplexity), true + + case "CVSSBase.scope": + if e.complexity.CVSSBase.Scope == nil { + break + } + + return e.complexity.CVSSBase.Scope(childComplexity), true + + case "CVSSBase.score": + if e.complexity.CVSSBase.Score == nil { + break + } + + return e.complexity.CVSSBase.Score(childComplexity), true + + case "CVSSBase.userInteraction": + if e.complexity.CVSSBase.UserInteraction == nil { + break + } + + return e.complexity.CVSSBase.UserInteraction(childComplexity), true + + case "CVSSEnvironmental.availabilityRequirement": + if e.complexity.CVSSEnvironmental.AvailabilityRequirement == nil { + break + } + + return e.complexity.CVSSEnvironmental.AvailabilityRequirement(childComplexity), true + + case "CVSSEnvironmental.confidentialityRequirement": + if e.complexity.CVSSEnvironmental.ConfidentialityRequirement == nil { + break + } + + return e.complexity.CVSSEnvironmental.ConfidentialityRequirement(childComplexity), true + + case "CVSSEnvironmental.integrityRequirement": + if e.complexity.CVSSEnvironmental.IntegrityRequirement == nil { + break + } + + return e.complexity.CVSSEnvironmental.IntegrityRequirement(childComplexity), true + + case "CVSSEnvironmental.modifiedAttackComplexity": + if e.complexity.CVSSEnvironmental.ModifiedAttackComplexity == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedAttackComplexity(childComplexity), true + + case "CVSSEnvironmental.modifiedAttackVector": + if e.complexity.CVSSEnvironmental.ModifiedAttackVector == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedAttackVector(childComplexity), true + + case "CVSSEnvironmental.modifiedAvailabilityImpact": + if e.complexity.CVSSEnvironmental.ModifiedAvailabilityImpact == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedAvailabilityImpact(childComplexity), true + + case "CVSSEnvironmental.modifiedConfidentialityImpact": + if e.complexity.CVSSEnvironmental.ModifiedConfidentialityImpact == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedConfidentialityImpact(childComplexity), true + + case "CVSSEnvironmental.modifiedIntegrityImpact": + if e.complexity.CVSSEnvironmental.ModifiedIntegrityImpact == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedIntegrityImpact(childComplexity), true + + case "CVSSEnvironmental.modifiedPrivilegesRequired": + if e.complexity.CVSSEnvironmental.ModifiedPrivilegesRequired == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedPrivilegesRequired(childComplexity), true + + case "CVSSEnvironmental.modifiedScope": + if e.complexity.CVSSEnvironmental.ModifiedScope == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedScope(childComplexity), true + + case "CVSSEnvironmental.modifiedUserInteraction": + if e.complexity.CVSSEnvironmental.ModifiedUserInteraction == nil { + break + } + + return e.complexity.CVSSEnvironmental.ModifiedUserInteraction(childComplexity), true + + case "CVSSEnvironmental.score": + if e.complexity.CVSSEnvironmental.Score == nil { + break + } + + return e.complexity.CVSSEnvironmental.Score(childComplexity), true + + case "CVSSParameter.name": + if e.complexity.CVSSParameter.Name == nil { + break + } + + return e.complexity.CVSSParameter.Name(childComplexity), true + + case "CVSSParameter.value": + if e.complexity.CVSSParameter.Value == nil { + break + } + + return e.complexity.CVSSParameter.Value(childComplexity), true + + case "CVSSTemporal.exploitCodeMaturity": + if e.complexity.CVSSTemporal.ExploitCodeMaturity == nil { + break + } + + return e.complexity.CVSSTemporal.ExploitCodeMaturity(childComplexity), true + + case "CVSSTemporal.remediationLevel": + if e.complexity.CVSSTemporal.RemediationLevel == nil { + break + } + + return e.complexity.CVSSTemporal.RemediationLevel(childComplexity), true + + case "CVSSTemporal.reportConfidence": + if e.complexity.CVSSTemporal.ReportConfidence == nil { + break + } + + return e.complexity.CVSSTemporal.ReportConfidence(childComplexity), true + + case "CVSSTemporal.score": + if e.complexity.CVSSTemporal.Score == nil { + break + } + + return e.complexity.CVSSTemporal.Score(childComplexity), true + + case "Component.componentVersions": + if e.complexity.Component.ComponentVersions == nil { + break + } + + args, err := ec.field_Component_componentVersions_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Component.ComponentVersions(childComplexity, args["filter"].(*model.ComponentVersionFilter), args["first"].(*int), args["after"].(*string)), true + + case "Component.id": + if e.complexity.Component.ID == nil { + break + } + + return e.complexity.Component.ID(childComplexity), true + + case "Component.name": + if e.complexity.Component.Name == nil { + break + } + + return e.complexity.Component.Name(childComplexity), true + + case "Component.type": + if e.complexity.Component.Type == nil { + break + } + + return e.complexity.Component.Type(childComplexity), true + + case "ComponentConnection.edges": + if e.complexity.ComponentConnection.Edges == nil { + break + } + + return e.complexity.ComponentConnection.Edges(childComplexity), true + + case "ComponentConnection.pageInfo": + if e.complexity.ComponentConnection.PageInfo == nil { + break + } + + return e.complexity.ComponentConnection.PageInfo(childComplexity), true + + case "ComponentConnection.totalCount": + if e.complexity.ComponentConnection.TotalCount == nil { + break + } + + return e.complexity.ComponentConnection.TotalCount(childComplexity), true + + case "ComponentEdge.cursor": + if e.complexity.ComponentEdge.Cursor == nil { + break + } + + return e.complexity.ComponentEdge.Cursor(childComplexity), true + + case "ComponentEdge.node": + if e.complexity.ComponentEdge.Node == nil { + break + } + + return e.complexity.ComponentEdge.Node(childComplexity), true + + case "ComponentInstance.ccrn": + if e.complexity.ComponentInstance.Ccrn == nil { + break + } + + return e.complexity.ComponentInstance.Ccrn(childComplexity), true + + case "ComponentInstance.componentVersion": + if e.complexity.ComponentInstance.ComponentVersion == nil { + break + } + + return e.complexity.ComponentInstance.ComponentVersion(childComplexity), true + + case "ComponentInstance.componentVersionId": + if e.complexity.ComponentInstance.ComponentVersionID == nil { + break + } + + return e.complexity.ComponentInstance.ComponentVersionID(childComplexity), true + + case "ComponentInstance.count": + if e.complexity.ComponentInstance.Count == nil { + break + } + + return e.complexity.ComponentInstance.Count(childComplexity), true + + case "ComponentInstance.createdAt": + if e.complexity.ComponentInstance.CreatedAt == nil { + break + } + + return e.complexity.ComponentInstance.CreatedAt(childComplexity), true + + case "ComponentInstance.id": + if e.complexity.ComponentInstance.ID == nil { + break + } + + return e.complexity.ComponentInstance.ID(childComplexity), true + + case "ComponentInstance.issueMatches": + if e.complexity.ComponentInstance.IssueMatches == nil { + break + } + + args, err := ec.field_ComponentInstance_issueMatches_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.ComponentInstance.IssueMatches(childComplexity, args["filter"].(*model.IssueMatchFilter), args["first"].(*int), args["after"].(*string)), true + + case "ComponentInstance.service": + if e.complexity.ComponentInstance.Service == nil { + break + } + + return e.complexity.ComponentInstance.Service(childComplexity), true + + case "ComponentInstance.serviceId": + if e.complexity.ComponentInstance.ServiceID == nil { + break + } + + return e.complexity.ComponentInstance.ServiceID(childComplexity), true + + case "ComponentInstance.updatedAt": + if e.complexity.ComponentInstance.UpdatedAt == nil { + break + } + + return e.complexity.ComponentInstance.UpdatedAt(childComplexity), true + + case "ComponentInstanceConnection.edges": + if e.complexity.ComponentInstanceConnection.Edges == nil { + break + } + + return e.complexity.ComponentInstanceConnection.Edges(childComplexity), true + + case "ComponentInstanceConnection.pageInfo": + if e.complexity.ComponentInstanceConnection.PageInfo == nil { + break + } + + return e.complexity.ComponentInstanceConnection.PageInfo(childComplexity), true + + case "ComponentInstanceConnection.totalCount": + if e.complexity.ComponentInstanceConnection.TotalCount == nil { + break + } + + return e.complexity.ComponentInstanceConnection.TotalCount(childComplexity), true + + case "ComponentInstanceEdge.cursor": + if e.complexity.ComponentInstanceEdge.Cursor == nil { + break + } + + return e.complexity.ComponentInstanceEdge.Cursor(childComplexity), true + + case "ComponentInstanceEdge.node": + if e.complexity.ComponentInstanceEdge.Node == nil { + break + } + + return e.complexity.ComponentInstanceEdge.Node(childComplexity), true + + case "ComponentVersion.component": + if e.complexity.ComponentVersion.Component == nil { + break + } + + return e.complexity.ComponentVersion.Component(childComplexity), true + + case "ComponentVersion.componentId": + if e.complexity.ComponentVersion.ComponentID == nil { + break + } + + return e.complexity.ComponentVersion.ComponentID(childComplexity), true + + case "ComponentVersion.id": + if e.complexity.ComponentVersion.ID == nil { + break + } + + return e.complexity.ComponentVersion.ID(childComplexity), true + + case "ComponentVersion.issues": + if e.complexity.ComponentVersion.Issues == nil { + break + } + + args, err := ec.field_ComponentVersion_issues_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.ComponentVersion.Issues(childComplexity, args["first"].(*int), args["after"].(*string)), true + + case "ComponentVersion.version": + if e.complexity.ComponentVersion.Version == nil { + break + } + + return e.complexity.ComponentVersion.Version(childComplexity), true + + case "ComponentVersionConnection.edges": + if e.complexity.ComponentVersionConnection.Edges == nil { + break + } + + return e.complexity.ComponentVersionConnection.Edges(childComplexity), true + + case "ComponentVersionConnection.pageInfo": + if e.complexity.ComponentVersionConnection.PageInfo == nil { + break + } + + return e.complexity.ComponentVersionConnection.PageInfo(childComplexity), true + + case "ComponentVersionConnection.totalCount": + if e.complexity.ComponentVersionConnection.TotalCount == nil { + break + } + + return e.complexity.ComponentVersionConnection.TotalCount(childComplexity), true + + case "ComponentVersionEdge.cursor": + if e.complexity.ComponentVersionEdge.Cursor == nil { + break + } + + return e.complexity.ComponentVersionEdge.Cursor(childComplexity), true + + case "ComponentVersionEdge.node": + if e.complexity.ComponentVersionEdge.Node == nil { + break + } + + return e.complexity.ComponentVersionEdge.Node(childComplexity), true + + case "Evidence.activity": + if e.complexity.Evidence.Activity == nil { + break + } + + return e.complexity.Evidence.Activity(childComplexity), true + + case "Evidence.activityId": + if e.complexity.Evidence.ActivityID == nil { + break + } + + return e.complexity.Evidence.ActivityID(childComplexity), true + + case "Evidence.author": + if e.complexity.Evidence.Author == nil { + break + } + + return e.complexity.Evidence.Author(childComplexity), true + + case "Evidence.authorId": + if e.complexity.Evidence.AuthorID == nil { + break + } + + return e.complexity.Evidence.AuthorID(childComplexity), true + + case "Evidence.description": + if e.complexity.Evidence.Description == nil { + break + } + + return e.complexity.Evidence.Description(childComplexity), true + + case "Evidence.id": + if e.complexity.Evidence.ID == nil { + break + } + + return e.complexity.Evidence.ID(childComplexity), true + + case "Evidence.issueMatches": + if e.complexity.Evidence.IssueMatches == nil { + break + } + + args, err := ec.field_Evidence_issueMatches_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Evidence.IssueMatches(childComplexity, args["filter"].(*model.IssueMatchFilter), args["first"].(*int), args["after"].(*string)), true + + case "Evidence.raaEnd": + if e.complexity.Evidence.RaaEnd == nil { + break + } + + return e.complexity.Evidence.RaaEnd(childComplexity), true + + case "Evidence.type": + if e.complexity.Evidence.Type == nil { + break + } + + return e.complexity.Evidence.Type(childComplexity), true + + case "Evidence.vector": + if e.complexity.Evidence.Vector == nil { + break + } + + return e.complexity.Evidence.Vector(childComplexity), true + + case "EvidenceConnection.edges": + if e.complexity.EvidenceConnection.Edges == nil { + break + } + + return e.complexity.EvidenceConnection.Edges(childComplexity), true + + case "EvidenceConnection.pageInfo": + if e.complexity.EvidenceConnection.PageInfo == nil { + break + } + + return e.complexity.EvidenceConnection.PageInfo(childComplexity), true + + case "EvidenceConnection.totalCount": + if e.complexity.EvidenceConnection.TotalCount == nil { + break + } + + return e.complexity.EvidenceConnection.TotalCount(childComplexity), true + + case "EvidenceEdge.cursor": + if e.complexity.EvidenceEdge.Cursor == nil { + break + } + + return e.complexity.EvidenceEdge.Cursor(childComplexity), true + + case "EvidenceEdge.node": + if e.complexity.EvidenceEdge.Node == nil { + break + } + + return e.complexity.EvidenceEdge.Node(childComplexity), true + + case "Issue.activities": + if e.complexity.Issue.Activities == nil { + break + } + + args, err := ec.field_Issue_activities_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Issue.Activities(childComplexity, args["filter"].(*model.ActivityFilter), args["first"].(*int), args["after"].(*string)), true + + case "Issue.componentVersions": + if e.complexity.Issue.ComponentVersions == nil { + break + } + + args, err := ec.field_Issue_componentVersions_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Issue.ComponentVersions(childComplexity, args["filter"].(*model.ComponentVersionFilter), args["first"].(*int), args["after"].(*string)), true + + case "Issue.id": + if e.complexity.Issue.ID == nil { + break + } + + return e.complexity.Issue.ID(childComplexity), true + + case "Issue.issueMatches": + if e.complexity.Issue.IssueMatches == nil { + break + } + + args, err := ec.field_Issue_issueMatches_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Issue.IssueMatches(childComplexity, args["filter"].(*model.IssueMatchFilter), args["first"].(*int), args["after"].(*string)), true + + case "Issue.issueVariants": + if e.complexity.Issue.IssueVariants == nil { + break + } + + args, err := ec.field_Issue_issueVariants_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Issue.IssueVariants(childComplexity, args["filter"].(*model.IssueVariantFilter), args["first"].(*int), args["after"].(*string)), true + + case "Issue.lastModified": + if e.complexity.Issue.LastModified == nil { + break + } + + return e.complexity.Issue.LastModified(childComplexity), true + + case "Issue.metadata": + if e.complexity.Issue.Metadata == nil { + break + } + + return e.complexity.Issue.Metadata(childComplexity), true + + case "Issue.primaryName": + if e.complexity.Issue.PrimaryName == nil { + break + } + + return e.complexity.Issue.PrimaryName(childComplexity), true + + case "Issue.type": + if e.complexity.Issue.Type == nil { + break + } + + return e.complexity.Issue.Type(childComplexity), true + + case "IssueConnection.edges": + if e.complexity.IssueConnection.Edges == nil { + break + } + + return e.complexity.IssueConnection.Edges(childComplexity), true + + case "IssueConnection.pageInfo": + if e.complexity.IssueConnection.PageInfo == nil { + break + } + + return e.complexity.IssueConnection.PageInfo(childComplexity), true + + case "IssueConnection.totalCount": + if e.complexity.IssueConnection.TotalCount == nil { + break + } + + return e.complexity.IssueConnection.TotalCount(childComplexity), true + + case "IssueEdge.cursor": + if e.complexity.IssueEdge.Cursor == nil { + break + } + + return e.complexity.IssueEdge.Cursor(childComplexity), true + + case "IssueEdge.node": + if e.complexity.IssueEdge.Node == nil { + break + } + + return e.complexity.IssueEdge.Node(childComplexity), true + + case "IssueMatch.componentInstance": + if e.complexity.IssueMatch.ComponentInstance == nil { + break + } + + return e.complexity.IssueMatch.ComponentInstance(childComplexity), true + + case "IssueMatch.componentInstanceId": + if e.complexity.IssueMatch.ComponentInstanceID == nil { + break + } + + return e.complexity.IssueMatch.ComponentInstanceID(childComplexity), true + + case "IssueMatch.discoveryDate": + if e.complexity.IssueMatch.DiscoveryDate == nil { + break + } + + return e.complexity.IssueMatch.DiscoveryDate(childComplexity), true + + case "IssueMatch.effectiveIssueVariants": + if e.complexity.IssueMatch.EffectiveIssueVariants == nil { + break + } + + args, err := ec.field_IssueMatch_effectiveIssueVariants_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.IssueMatch.EffectiveIssueVariants(childComplexity, args["filter"].(*model.IssueVariantFilter), args["first"].(*int), args["after"].(*string)), true + + case "IssueMatch.evidences": + if e.complexity.IssueMatch.Evidences == nil { + break + } + + args, err := ec.field_IssueMatch_evidences_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.IssueMatch.Evidences(childComplexity, args["filter"].(*model.EvidenceFilter), args["first"].(*int), args["after"].(*string)), true + + case "IssueMatch.id": + if e.complexity.IssueMatch.ID == nil { + break + } + + return e.complexity.IssueMatch.ID(childComplexity), true + + case "IssueMatch.issue": + if e.complexity.IssueMatch.Issue == nil { + break + } + + return e.complexity.IssueMatch.Issue(childComplexity), true + + case "IssueMatch.issueId": + if e.complexity.IssueMatch.IssueID == nil { + break + } + + return e.complexity.IssueMatch.IssueID(childComplexity), true + + case "IssueMatch.issueMatchChanges": + if e.complexity.IssueMatch.IssueMatchChanges == nil { + break + } + + args, err := ec.field_IssueMatch_issueMatchChanges_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.IssueMatch.IssueMatchChanges(childComplexity, args["filter"].(*model.IssueMatchChangeFilter), args["first"].(*int), args["after"].(*string)), true + + case "IssueMatch.remediationDate": + if e.complexity.IssueMatch.RemediationDate == nil { + break + } + + return e.complexity.IssueMatch.RemediationDate(childComplexity), true + + case "IssueMatch.severity": + if e.complexity.IssueMatch.Severity == nil { + break + } + + return e.complexity.IssueMatch.Severity(childComplexity), true + + case "IssueMatch.status": + if e.complexity.IssueMatch.Status == nil { + break + } + + return e.complexity.IssueMatch.Status(childComplexity), true + + case "IssueMatch.targetRemediationDate": + if e.complexity.IssueMatch.TargetRemediationDate == nil { + break + } + + return e.complexity.IssueMatch.TargetRemediationDate(childComplexity), true + + case "IssueMatch.user": + if e.complexity.IssueMatch.User == nil { + break + } + + return e.complexity.IssueMatch.User(childComplexity), true + + case "IssueMatch.userId": + if e.complexity.IssueMatch.UserID == nil { + break + } + + return e.complexity.IssueMatch.UserID(childComplexity), true + + case "IssueMatchChange.action": + if e.complexity.IssueMatchChange.Action == nil { + break + } + + return e.complexity.IssueMatchChange.Action(childComplexity), true + + case "IssueMatchChange.activity": + if e.complexity.IssueMatchChange.Activity == nil { + break + } + + return e.complexity.IssueMatchChange.Activity(childComplexity), true + + case "IssueMatchChange.activityId": + if e.complexity.IssueMatchChange.ActivityID == nil { + break + } + + return e.complexity.IssueMatchChange.ActivityID(childComplexity), true + + case "IssueMatchChange.id": + if e.complexity.IssueMatchChange.ID == nil { + break + } + + return e.complexity.IssueMatchChange.ID(childComplexity), true + + case "IssueMatchChange.issueMatch": + if e.complexity.IssueMatchChange.IssueMatch == nil { + break + } + + return e.complexity.IssueMatchChange.IssueMatch(childComplexity), true + + case "IssueMatchChange.issueMatchId": + if e.complexity.IssueMatchChange.IssueMatchID == nil { + break + } + + return e.complexity.IssueMatchChange.IssueMatchID(childComplexity), true + + case "IssueMatchChangeConnection.edges": + if e.complexity.IssueMatchChangeConnection.Edges == nil { + break + } + + return e.complexity.IssueMatchChangeConnection.Edges(childComplexity), true + + case "IssueMatchChangeConnection.pageInfo": + if e.complexity.IssueMatchChangeConnection.PageInfo == nil { + break + } + + return e.complexity.IssueMatchChangeConnection.PageInfo(childComplexity), true + + case "IssueMatchChangeConnection.totalCount": + if e.complexity.IssueMatchChangeConnection.TotalCount == nil { + break + } + + return e.complexity.IssueMatchChangeConnection.TotalCount(childComplexity), true + + case "IssueMatchChangeEdge.cursor": + if e.complexity.IssueMatchChangeEdge.Cursor == nil { + break + } + + return e.complexity.IssueMatchChangeEdge.Cursor(childComplexity), true + + case "IssueMatchChangeEdge.node": + if e.complexity.IssueMatchChangeEdge.Node == nil { + break + } + + return e.complexity.IssueMatchChangeEdge.Node(childComplexity), true + + case "IssueMatchConnection.edges": + if e.complexity.IssueMatchConnection.Edges == nil { + break + } + + return e.complexity.IssueMatchConnection.Edges(childComplexity), true + + case "IssueMatchConnection.pageInfo": + if e.complexity.IssueMatchConnection.PageInfo == nil { + break + } + + return e.complexity.IssueMatchConnection.PageInfo(childComplexity), true + + case "IssueMatchConnection.totalCount": + if e.complexity.IssueMatchConnection.TotalCount == nil { + break + } + + return e.complexity.IssueMatchConnection.TotalCount(childComplexity), true + + case "IssueMatchEdge.cursor": + if e.complexity.IssueMatchEdge.Cursor == nil { + break + } + + return e.complexity.IssueMatchEdge.Cursor(childComplexity), true + + case "IssueMatchEdge.node": + if e.complexity.IssueMatchEdge.Node == nil { + break + } + + return e.complexity.IssueMatchEdge.Node(childComplexity), true + + case "IssueMetadata.activityCount": + if e.complexity.IssueMetadata.ActivityCount == nil { + break + } + + return e.complexity.IssueMetadata.ActivityCount(childComplexity), true + + case "IssueMetadata.componentInstanceCount": + if e.complexity.IssueMetadata.ComponentInstanceCount == nil { + break + } + + return e.complexity.IssueMetadata.ComponentInstanceCount(childComplexity), true + + case "IssueMetadata.componentVersionCount": + if e.complexity.IssueMetadata.ComponentVersionCount == nil { + break + } + + return e.complexity.IssueMetadata.ComponentVersionCount(childComplexity), true + + case "IssueMetadata.earliestDiscoveryDate": + if e.complexity.IssueMetadata.EarliestDiscoveryDate == nil { + break + } + + return e.complexity.IssueMetadata.EarliestDiscoveryDate(childComplexity), true + + case "IssueMetadata.earliestTargetRemediationDate": + if e.complexity.IssueMetadata.EarliestTargetRemediationDate == nil { + break + } + + return e.complexity.IssueMetadata.EarliestTargetRemediationDate(childComplexity), true + + case "IssueMetadata.issueMatchCount": + if e.complexity.IssueMetadata.IssueMatchCount == nil { + break + } + + return e.complexity.IssueMetadata.IssueMatchCount(childComplexity), true + + case "IssueMetadata.serviceCount": + if e.complexity.IssueMetadata.ServiceCount == nil { + break + } + + return e.complexity.IssueMetadata.ServiceCount(childComplexity), true + + case "IssueRepository.created_at": + if e.complexity.IssueRepository.CreatedAt == nil { + break + } + + return e.complexity.IssueRepository.CreatedAt(childComplexity), true + + case "IssueRepository.id": + if e.complexity.IssueRepository.ID == nil { + break + } + + return e.complexity.IssueRepository.ID(childComplexity), true + + case "IssueRepository.issueVariants": + if e.complexity.IssueRepository.IssueVariants == nil { + break + } + + args, err := ec.field_IssueRepository_issueVariants_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.IssueRepository.IssueVariants(childComplexity, args["filter"].(*model.IssueVariantFilter), args["first"].(*int), args["after"].(*string)), true + + case "IssueRepository.name": + if e.complexity.IssueRepository.Name == nil { + break + } + + return e.complexity.IssueRepository.Name(childComplexity), true + + case "IssueRepository.services": + if e.complexity.IssueRepository.Services == nil { + break + } + + args, err := ec.field_IssueRepository_services_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.IssueRepository.Services(childComplexity, args["filter"].(*model.ServiceFilter), args["first"].(*int), args["after"].(*string)), true + + case "IssueRepository.url": + if e.complexity.IssueRepository.URL == nil { + break + } + + return e.complexity.IssueRepository.URL(childComplexity), true + + case "IssueRepository.updated_at": + if e.complexity.IssueRepository.UpdatedAt == nil { + break + } + + return e.complexity.IssueRepository.UpdatedAt(childComplexity), true + + case "IssueRepositoryConnection.edges": + if e.complexity.IssueRepositoryConnection.Edges == nil { + break + } + + return e.complexity.IssueRepositoryConnection.Edges(childComplexity), true + + case "IssueRepositoryConnection.pageInfo": + if e.complexity.IssueRepositoryConnection.PageInfo == nil { + break + } + + return e.complexity.IssueRepositoryConnection.PageInfo(childComplexity), true + + case "IssueRepositoryConnection.totalCount": + if e.complexity.IssueRepositoryConnection.TotalCount == nil { + break + } + + return e.complexity.IssueRepositoryConnection.TotalCount(childComplexity), true + + case "IssueRepositoryEdge.created_at": + if e.complexity.IssueRepositoryEdge.CreatedAt == nil { + break + } + + return e.complexity.IssueRepositoryEdge.CreatedAt(childComplexity), true + + case "IssueRepositoryEdge.cursor": + if e.complexity.IssueRepositoryEdge.Cursor == nil { + break + } + + return e.complexity.IssueRepositoryEdge.Cursor(childComplexity), true + + case "IssueRepositoryEdge.node": + if e.complexity.IssueRepositoryEdge.Node == nil { + break + } + + return e.complexity.IssueRepositoryEdge.Node(childComplexity), true + + case "IssueRepositoryEdge.priority": + if e.complexity.IssueRepositoryEdge.Priority == nil { + break + } + + return e.complexity.IssueRepositoryEdge.Priority(childComplexity), true + + case "IssueRepositoryEdge.updated_at": + if e.complexity.IssueRepositoryEdge.UpdatedAt == nil { + break + } + + return e.complexity.IssueRepositoryEdge.UpdatedAt(childComplexity), true + + case "IssueVariant.created_at": + if e.complexity.IssueVariant.CreatedAt == nil { + break + } + + return e.complexity.IssueVariant.CreatedAt(childComplexity), true + + case "IssueVariant.description": + if e.complexity.IssueVariant.Description == nil { + break + } + + return e.complexity.IssueVariant.Description(childComplexity), true + + case "IssueVariant.id": + if e.complexity.IssueVariant.ID == nil { + break + } + + return e.complexity.IssueVariant.ID(childComplexity), true + + case "IssueVariant.issue": + if e.complexity.IssueVariant.Issue == nil { + break + } + + return e.complexity.IssueVariant.Issue(childComplexity), true + + case "IssueVariant.issueId": + if e.complexity.IssueVariant.IssueID == nil { + break + } + + return e.complexity.IssueVariant.IssueID(childComplexity), true + + case "IssueVariant.issueRepository": + if e.complexity.IssueVariant.IssueRepository == nil { + break + } + + return e.complexity.IssueVariant.IssueRepository(childComplexity), true + + case "IssueVariant.issueRepositoryId": + if e.complexity.IssueVariant.IssueRepositoryID == nil { + break + } + + return e.complexity.IssueVariant.IssueRepositoryID(childComplexity), true + + case "IssueVariant.secondaryName": + if e.complexity.IssueVariant.SecondaryName == nil { + break + } + + return e.complexity.IssueVariant.SecondaryName(childComplexity), true + + case "IssueVariant.severity": + if e.complexity.IssueVariant.Severity == nil { + break + } + + return e.complexity.IssueVariant.Severity(childComplexity), true + + case "IssueVariant.updated_at": + if e.complexity.IssueVariant.UpdatedAt == nil { + break + } + + return e.complexity.IssueVariant.UpdatedAt(childComplexity), true + + case "IssueVariantConnection.edges": + if e.complexity.IssueVariantConnection.Edges == nil { + break + } + + return e.complexity.IssueVariantConnection.Edges(childComplexity), true + + case "IssueVariantConnection.pageInfo": + if e.complexity.IssueVariantConnection.PageInfo == nil { + break + } + + return e.complexity.IssueVariantConnection.PageInfo(childComplexity), true + + case "IssueVariantConnection.totalCount": + if e.complexity.IssueVariantConnection.TotalCount == nil { + break + } + + return e.complexity.IssueVariantConnection.TotalCount(childComplexity), true + + case "IssueVariantEdge.created_at": + if e.complexity.IssueVariantEdge.CreatedAt == nil { + break + } + + return e.complexity.IssueVariantEdge.CreatedAt(childComplexity), true + + case "IssueVariantEdge.cursor": + if e.complexity.IssueVariantEdge.Cursor == nil { + break + } + + return e.complexity.IssueVariantEdge.Cursor(childComplexity), true + + case "IssueVariantEdge.node": + if e.complexity.IssueVariantEdge.Node == nil { + break + } + + return e.complexity.IssueVariantEdge.Node(childComplexity), true + + case "IssueVariantEdge.updated_at": + if e.complexity.IssueVariantEdge.UpdatedAt == nil { + break + } + + return e.complexity.IssueVariantEdge.UpdatedAt(childComplexity), true + + case "Mutation.createActivity": + if e.complexity.Mutation.CreateActivity == nil { + break + } + + args, err := ec.field_Mutation_createActivity_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateActivity(childComplexity, args["input"].(model.ActivityInput)), true + + case "Mutation.createComponent": + if e.complexity.Mutation.CreateComponent == nil { + break + } + + args, err := ec.field_Mutation_createComponent_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateComponent(childComplexity, args["input"].(model.ComponentInput)), true + + case "Mutation.createComponentInstance": + if e.complexity.Mutation.CreateComponentInstance == nil { + break + } + + args, err := ec.field_Mutation_createComponentInstance_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateComponentInstance(childComplexity, args["input"].(model.ComponentInstanceInput)), true + + case "Mutation.createComponentVersion": + if e.complexity.Mutation.CreateComponentVersion == nil { + break + } + + args, err := ec.field_Mutation_createComponentVersion_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateComponentVersion(childComplexity, args["input"].(model.ComponentVersionInput)), true + + case "Mutation.createEvidence": + if e.complexity.Mutation.CreateEvidence == nil { + break + } + + args, err := ec.field_Mutation_createEvidence_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateEvidence(childComplexity, args["input"].(model.EvidenceInput)), true + + case "Mutation.createIssueMatch": + if e.complexity.Mutation.CreateIssueMatch == nil { + break + } + + args, err := ec.field_Mutation_createIssueMatch_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateIssueMatch(childComplexity, args["input"].(model.IssueMatchInput)), true + + case "Mutation.createIssueRepository": + if e.complexity.Mutation.CreateIssueRepository == nil { + break + } + + args, err := ec.field_Mutation_createIssueRepository_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateIssueRepository(childComplexity, args["input"].(model.IssueRepositoryInput)), true + + case "Mutation.createIssueVariant": + if e.complexity.Mutation.CreateIssueVariant == nil { + break + } + + args, err := ec.field_Mutation_createIssueVariant_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateIssueVariant(childComplexity, args["input"].(model.IssueVariantInput)), true + + case "Mutation.createService": + if e.complexity.Mutation.CreateService == nil { + break + } + + args, err := ec.field_Mutation_createService_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateService(childComplexity, args["input"].(model.ServiceInput)), true + + case "Mutation.createSupportGroup": + if e.complexity.Mutation.CreateSupportGroup == nil { + break + } + + args, err := ec.field_Mutation_createSupportGroup_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateSupportGroup(childComplexity, args["input"].(model.SupportGroupInput)), true + + case "Mutation.createUser": + if e.complexity.Mutation.CreateUser == nil { + break + } + + args, err := ec.field_Mutation_createUser_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.CreateUser(childComplexity, args["input"].(model.UserInput)), true + + case "Mutation.deleteActivity": + if e.complexity.Mutation.DeleteActivity == nil { + break + } + + args, err := ec.field_Mutation_deleteActivity_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteActivity(childComplexity, args["id"].(string)), true + + case "Mutation.deleteComponent": + if e.complexity.Mutation.DeleteComponent == nil { + break + } + + args, err := ec.field_Mutation_deleteComponent_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteComponent(childComplexity, args["id"].(string)), true + + case "Mutation.deleteComponentInstance": + if e.complexity.Mutation.DeleteComponentInstance == nil { + break + } + + args, err := ec.field_Mutation_deleteComponentInstance_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteComponentInstance(childComplexity, args["id"].(string)), true + + case "Mutation.deleteComponentVersion": + if e.complexity.Mutation.DeleteComponentVersion == nil { + break + } + + args, err := ec.field_Mutation_deleteComponentVersion_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteComponentVersion(childComplexity, args["id"].(string)), true + + case "Mutation.deleteEvidence": + if e.complexity.Mutation.DeleteEvidence == nil { + break + } + + args, err := ec.field_Mutation_deleteEvidence_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteEvidence(childComplexity, args["id"].(string)), true + + case "Mutation.deleteIssueMatch": + if e.complexity.Mutation.DeleteIssueMatch == nil { + break + } + + args, err := ec.field_Mutation_deleteIssueMatch_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteIssueMatch(childComplexity, args["id"].(string)), true + + case "Mutation.deleteIssueRepository": + if e.complexity.Mutation.DeleteIssueRepository == nil { + break + } + + args, err := ec.field_Mutation_deleteIssueRepository_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteIssueRepository(childComplexity, args["id"].(string)), true + + case "Mutation.deleteIssueVariant": + if e.complexity.Mutation.DeleteIssueVariant == nil { + break + } + + args, err := ec.field_Mutation_deleteIssueVariant_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteIssueVariant(childComplexity, args["id"].(string)), true + + case "Mutation.deleteService": + if e.complexity.Mutation.DeleteService == nil { + break + } + + args, err := ec.field_Mutation_deleteService_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteService(childComplexity, args["id"].(string)), true + + case "Mutation.deleteSupportGroup": + if e.complexity.Mutation.DeleteSupportGroup == nil { + break + } + + args, err := ec.field_Mutation_deleteSupportGroup_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteSupportGroup(childComplexity, args["id"].(string)), true + + case "Mutation.deleteUser": + if e.complexity.Mutation.DeleteUser == nil { + break + } + + args, err := ec.field_Mutation_deleteUser_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.DeleteUser(childComplexity, args["id"].(string)), true + + case "Mutation.updateActivity": + if e.complexity.Mutation.UpdateActivity == nil { + break + } + + args, err := ec.field_Mutation_updateActivity_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateActivity(childComplexity, args["id"].(string), args["input"].(model.ActivityInput)), true + + case "Mutation.updateComponent": + if e.complexity.Mutation.UpdateComponent == nil { + break + } + + args, err := ec.field_Mutation_updateComponent_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateComponent(childComplexity, args["id"].(string), args["input"].(model.ComponentInput)), true + + case "Mutation.updateComponentInstance": + if e.complexity.Mutation.UpdateComponentInstance == nil { + break + } + + args, err := ec.field_Mutation_updateComponentInstance_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateComponentInstance(childComplexity, args["id"].(string), args["input"].(model.ComponentInstanceInput)), true + + case "Mutation.updateComponentVersion": + if e.complexity.Mutation.UpdateComponentVersion == nil { + break + } + + args, err := ec.field_Mutation_updateComponentVersion_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateComponentVersion(childComplexity, args["id"].(string), args["input"].(model.ComponentVersionInput)), true + + case "Mutation.updateEvidence": + if e.complexity.Mutation.UpdateEvidence == nil { + break + } + + args, err := ec.field_Mutation_updateEvidence_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateEvidence(childComplexity, args["id"].(string), args["input"].(model.EvidenceInput)), true + + case "Mutation.updateIssueMatch": + if e.complexity.Mutation.UpdateIssueMatch == nil { + break + } + + args, err := ec.field_Mutation_updateIssueMatch_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateIssueMatch(childComplexity, args["id"].(string), args["input"].(model.IssueMatchInput)), true + + case "Mutation.updateIssueRepository": + if e.complexity.Mutation.UpdateIssueRepository == nil { + break + } + + args, err := ec.field_Mutation_updateIssueRepository_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateIssueRepository(childComplexity, args["id"].(string), args["input"].(model.IssueRepositoryInput)), true + + case "Mutation.updateIssueVariant": + if e.complexity.Mutation.UpdateIssueVariant == nil { + break + } + + args, err := ec.field_Mutation_updateIssueVariant_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateIssueVariant(childComplexity, args["id"].(string), args["input"].(model.IssueVariantInput)), true + + case "Mutation.updateService": + if e.complexity.Mutation.UpdateService == nil { + break + } + + args, err := ec.field_Mutation_updateService_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateService(childComplexity, args["id"].(string), args["input"].(model.ServiceInput)), true + + case "Mutation.updateSupportGroup": + if e.complexity.Mutation.UpdateSupportGroup == nil { + break + } + + args, err := ec.field_Mutation_updateSupportGroup_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateSupportGroup(childComplexity, args["id"].(string), args["input"].(model.SupportGroupInput)), true + + case "Mutation.updateUser": + if e.complexity.Mutation.UpdateUser == nil { + break + } + + args, err := ec.field_Mutation_updateUser_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.UpdateUser(childComplexity, args["id"].(string), args["input"].(model.UserInput)), true + + case "Page.after": + if e.complexity.Page.After == nil { + break + } + + return e.complexity.Page.After(childComplexity), true + + case "Page.isCurrent": + if e.complexity.Page.IsCurrent == nil { + break + } + + return e.complexity.Page.IsCurrent(childComplexity), true + + case "Page.pageCount": + if e.complexity.Page.PageCount == nil { + break + } + + return e.complexity.Page.PageCount(childComplexity), true + + case "Page.pageNumber": + if e.complexity.Page.PageNumber == nil { + break + } + + return e.complexity.Page.PageNumber(childComplexity), true + + case "PageInfo.hasNextPage": + if e.complexity.PageInfo.HasNextPage == nil { + break + } + + return e.complexity.PageInfo.HasNextPage(childComplexity), true + + case "PageInfo.hasPreviousPage": + if e.complexity.PageInfo.HasPreviousPage == nil { + break + } + + return e.complexity.PageInfo.HasPreviousPage(childComplexity), true + + case "PageInfo.isValidPage": + if e.complexity.PageInfo.IsValidPage == nil { + break + } + + return e.complexity.PageInfo.IsValidPage(childComplexity), true + + case "PageInfo.nextPageAfter": + if e.complexity.PageInfo.NextPageAfter == nil { + break + } + + return e.complexity.PageInfo.NextPageAfter(childComplexity), true + + case "PageInfo.pageNumber": + if e.complexity.PageInfo.PageNumber == nil { + break + } + + return e.complexity.PageInfo.PageNumber(childComplexity), true + + case "PageInfo.pages": + if e.complexity.PageInfo.Pages == nil { + break + } + + return e.complexity.PageInfo.Pages(childComplexity), true + + case "Query.Activities": + if e.complexity.Query.Activities == nil { + break + } + + args, err := ec.field_Query_Activities_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.Activities(childComplexity, args["filter"].(*model.ActivityFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.ComponentInstances": + if e.complexity.Query.ComponentInstances == nil { + break + } + + args, err := ec.field_Query_ComponentInstances_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.ComponentInstances(childComplexity, args["filter"].(*model.ComponentInstanceFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.ComponentVersions": + if e.complexity.Query.ComponentVersions == nil { + break + } + + args, err := ec.field_Query_ComponentVersions_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.ComponentVersions(childComplexity, args["filter"].(*model.ComponentVersionFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.Components": + if e.complexity.Query.Components == nil { + break + } + + args, err := ec.field_Query_Components_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.Components(childComplexity, args["filter"].(*model.ComponentFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.Evidences": + if e.complexity.Query.Evidences == nil { + break + } + + args, err := ec.field_Query_Evidences_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.Evidences(childComplexity, args["filter"].(*model.EvidenceFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.IssueMatchChanges": + if e.complexity.Query.IssueMatchChanges == nil { + break + } + + args, err := ec.field_Query_IssueMatchChanges_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.IssueMatchChanges(childComplexity, args["filter"].(*model.IssueMatchChangeFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.IssueMatches": + if e.complexity.Query.IssueMatches == nil { + break + } + + args, err := ec.field_Query_IssueMatches_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.IssueMatches(childComplexity, args["filter"].(*model.IssueMatchFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.IssueRepositories": + if e.complexity.Query.IssueRepositories == nil { + break + } + + args, err := ec.field_Query_IssueRepositories_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.IssueRepositories(childComplexity, args["filter"].(*model.IssueRepositoryFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.IssueVariants": + if e.complexity.Query.IssueVariants == nil { + break + } + + args, err := ec.field_Query_IssueVariants_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.IssueVariants(childComplexity, args["filter"].(*model.IssueVariantFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.Issues": + if e.complexity.Query.Issues == nil { + break + } + + args, err := ec.field_Query_Issues_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.Issues(childComplexity, args["filter"].(*model.IssueFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.Services": + if e.complexity.Query.Services == nil { + break + } + + args, err := ec.field_Query_Services_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.Services(childComplexity, args["filter"].(*model.ServiceFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.SupportGroups": + if e.complexity.Query.SupportGroups == nil { + break + } + + args, err := ec.field_Query_SupportGroups_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.SupportGroups(childComplexity, args["filter"].(*model.SupportGroupFilter), args["first"].(*int), args["after"].(*string)), true + + case "Query.Users": + if e.complexity.Query.Users == nil { + break + } + + args, err := ec.field_Query_Users_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Query.Users(childComplexity, args["filter"].(*model.UserFilter), args["first"].(*int), args["after"].(*string)), true + + case "Service.activities": + if e.complexity.Service.Activities == nil { + break + } + + args, err := ec.field_Service_activities_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Service.Activities(childComplexity, args["filter"].(*model.ActivityFilter), args["first"].(*int), args["after"].(*string)), true + + case "Service.componentInstances": + if e.complexity.Service.ComponentInstances == nil { + break + } + + args, err := ec.field_Service_componentInstances_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Service.ComponentInstances(childComplexity, args["filter"].(*model.ComponentInstanceFilter), args["first"].(*int), args["after"].(*string)), true + + case "Service.id": + if e.complexity.Service.ID == nil { + break + } + + return e.complexity.Service.ID(childComplexity), true + + case "Service.issueRepositories": + if e.complexity.Service.IssueRepositories == nil { + break + } + + args, err := ec.field_Service_issueRepositories_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Service.IssueRepositories(childComplexity, args["filter"].(*model.IssueRepositoryFilter), args["first"].(*int), args["after"].(*string)), true + + case "Service.name": + if e.complexity.Service.Name == nil { + break + } + + return e.complexity.Service.Name(childComplexity), true + + case "Service.owners": + if e.complexity.Service.Owners == nil { + break + } + + args, err := ec.field_Service_owners_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Service.Owners(childComplexity, args["filter"].(*model.UserFilter), args["first"].(*int), args["after"].(*string)), true + + case "Service.supportGroups": + if e.complexity.Service.SupportGroups == nil { + break + } + + args, err := ec.field_Service_supportGroups_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Service.SupportGroups(childComplexity, args["filter"].(*model.SupportGroupFilter), args["first"].(*int), args["after"].(*string)), true + + case "ServiceConnection.edges": + if e.complexity.ServiceConnection.Edges == nil { + break + } + + return e.complexity.ServiceConnection.Edges(childComplexity), true + + case "ServiceConnection.pageInfo": + if e.complexity.ServiceConnection.PageInfo == nil { + break + } + + return e.complexity.ServiceConnection.PageInfo(childComplexity), true + + case "ServiceConnection.totalCount": + if e.complexity.ServiceConnection.TotalCount == nil { + break + } + + return e.complexity.ServiceConnection.TotalCount(childComplexity), true + + case "ServiceEdge.cursor": + if e.complexity.ServiceEdge.Cursor == nil { + break + } + + return e.complexity.ServiceEdge.Cursor(childComplexity), true + + case "ServiceEdge.node": + if e.complexity.ServiceEdge.Node == nil { + break + } + + return e.complexity.ServiceEdge.Node(childComplexity), true + + case "ServiceEdge.priority": + if e.complexity.ServiceEdge.Priority == nil { + break + } + + return e.complexity.ServiceEdge.Priority(childComplexity), true + + case "Severity.cvss": + if e.complexity.Severity.Cvss == nil { + break + } + + return e.complexity.Severity.Cvss(childComplexity), true + + case "Severity.score": + if e.complexity.Severity.Score == nil { + break + } + + return e.complexity.Severity.Score(childComplexity), true + + case "Severity.value": + if e.complexity.Severity.Value == nil { + break + } + + return e.complexity.Severity.Value(childComplexity), true + + case "SupportGroup.id": + if e.complexity.SupportGroup.ID == nil { + break + } + + return e.complexity.SupportGroup.ID(childComplexity), true + + case "SupportGroup.name": + if e.complexity.SupportGroup.Name == nil { + break + } + + return e.complexity.SupportGroup.Name(childComplexity), true + + case "SupportGroup.services": + if e.complexity.SupportGroup.Services == nil { + break + } + + args, err := ec.field_SupportGroup_services_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.SupportGroup.Services(childComplexity, args["filter"].(*model.ServiceFilter), args["first"].(*int), args["after"].(*string)), true + + case "SupportGroup.users": + if e.complexity.SupportGroup.Users == nil { + break + } + + args, err := ec.field_SupportGroup_users_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.SupportGroup.Users(childComplexity, args["filter"].(*model.UserFilter), args["first"].(*int), args["after"].(*string)), true + + case "SupportGroupConnection.edges": + if e.complexity.SupportGroupConnection.Edges == nil { + break + } + + return e.complexity.SupportGroupConnection.Edges(childComplexity), true + + case "SupportGroupConnection.pageInfo": + if e.complexity.SupportGroupConnection.PageInfo == nil { + break + } + + return e.complexity.SupportGroupConnection.PageInfo(childComplexity), true + + case "SupportGroupConnection.totalCount": + if e.complexity.SupportGroupConnection.TotalCount == nil { + break + } + + return e.complexity.SupportGroupConnection.TotalCount(childComplexity), true + + case "SupportGroupEdge.cursor": + if e.complexity.SupportGroupEdge.Cursor == nil { + break + } + + return e.complexity.SupportGroupEdge.Cursor(childComplexity), true + + case "SupportGroupEdge.node": + if e.complexity.SupportGroupEdge.Node == nil { + break + } + + return e.complexity.SupportGroupEdge.Node(childComplexity), true + + case "User.id": + if e.complexity.User.ID == nil { + break + } + + return e.complexity.User.ID(childComplexity), true + + case "User.name": + if e.complexity.User.Name == nil { + break + } + + return e.complexity.User.Name(childComplexity), true + + case "User.sapID": + if e.complexity.User.SapID == nil { + break + } + + return e.complexity.User.SapID(childComplexity), true + + case "User.services": + if e.complexity.User.Services == nil { + break + } + + args, err := ec.field_User_services_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.User.Services(childComplexity, args["filter"].(*model.ServiceFilter), args["first"].(*int), args["after"].(*string)), true + + case "User.supportGroups": + if e.complexity.User.SupportGroups == nil { + break + } + + args, err := ec.field_User_supportGroups_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.User.SupportGroups(childComplexity, args["filter"].(*model.SupportGroupFilter), args["first"].(*int), args["after"].(*string)), true + + case "UserConnection.edges": + if e.complexity.UserConnection.Edges == nil { + break + } + + return e.complexity.UserConnection.Edges(childComplexity), true + + case "UserConnection.pageInfo": + if e.complexity.UserConnection.PageInfo == nil { + break + } + + return e.complexity.UserConnection.PageInfo(childComplexity), true + + case "UserConnection.totalCount": + if e.complexity.UserConnection.TotalCount == nil { + break + } + + return e.complexity.UserConnection.TotalCount(childComplexity), true + + case "UserEdge.cursor": + if e.complexity.UserEdge.Cursor == nil { + break + } + + return e.complexity.UserEdge.Cursor(childComplexity), true + + case "UserEdge.node": + if e.complexity.UserEdge.Node == nil { + break + } + + return e.complexity.UserEdge.Node(childComplexity), true + + } + return 0, false +} + +func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { + rc := graphql.GetOperationContext(ctx) + ec := executionContext{rc, e, 0, 0, make(chan graphql.DeferredResult)} + inputUnmarshalMap := graphql.BuildUnmarshalerMap( + ec.unmarshalInputActivityFilter, + ec.unmarshalInputActivityInput, + ec.unmarshalInputComponentFilter, + ec.unmarshalInputComponentInput, + ec.unmarshalInputComponentInstanceFilter, + ec.unmarshalInputComponentInstanceInput, + ec.unmarshalInputComponentVersionFilter, + ec.unmarshalInputComponentVersionInput, + ec.unmarshalInputDateTimeFilter, + ec.unmarshalInputEvidenceFilter, + ec.unmarshalInputEvidenceInput, + ec.unmarshalInputIssueFilter, + ec.unmarshalInputIssueMatchChangeFilter, + ec.unmarshalInputIssueMatchFilter, + ec.unmarshalInputIssueMatchInput, + ec.unmarshalInputIssueRepositoryFilter, + ec.unmarshalInputIssueRepositoryInput, + ec.unmarshalInputIssueVariantFilter, + ec.unmarshalInputIssueVariantInput, + ec.unmarshalInputServiceFilter, + ec.unmarshalInputServiceInput, + ec.unmarshalInputSeverityInput, + ec.unmarshalInputSupportGroupFilter, + ec.unmarshalInputSupportGroupInput, + ec.unmarshalInputUserFilter, + ec.unmarshalInputUserInput, + ) + first := true + + switch rc.Operation.Operation { + case ast.Query: + return func(ctx context.Context) *graphql.Response { + var response graphql.Response + var data graphql.Marshaler + if first { + first = false + ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap) + data = ec._Query(ctx, rc.Operation.SelectionSet) + } else { + if atomic.LoadInt32(&ec.pendingDeferred) > 0 { + result := <-ec.deferredResults + atomic.AddInt32(&ec.pendingDeferred, -1) + data = result.Result + response.Path = result.Path + response.Label = result.Label + response.Errors = result.Errors + } else { + return nil + } + } + var buf bytes.Buffer + data.MarshalGQL(&buf) + response.Data = buf.Bytes() + if atomic.LoadInt32(&ec.deferred) > 0 { + hasNext := atomic.LoadInt32(&ec.pendingDeferred) > 0 + response.HasNext = &hasNext + } + + return &response + } + case ast.Mutation: + return func(ctx context.Context) *graphql.Response { + if !first { + return nil + } + first = false + ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap) + data := ec._Mutation(ctx, rc.Operation.SelectionSet) + var buf bytes.Buffer + data.MarshalGQL(&buf) + + return &graphql.Response{ + Data: buf.Bytes(), + } + } + + default: + return graphql.OneShot(graphql.ErrorResponse(ctx, "unsupported GraphQL operation")) + } +} + +type executionContext struct { + *graphql.OperationContext + *executableSchema + deferred int32 + pendingDeferred int32 + deferredResults chan graphql.DeferredResult +} + +func (ec *executionContext) processDeferredGroup(dg graphql.DeferredGroup) { + atomic.AddInt32(&ec.pendingDeferred, 1) + go func() { + ctx := graphql.WithFreshResponseContext(dg.Context) + dg.FieldSet.Dispatch(ctx) + ds := graphql.DeferredResult{ + Path: dg.Path, + Label: dg.Label, + Result: dg.FieldSet, + Errors: graphql.GetErrors(ctx), + } + // null fields should bubble up + if dg.FieldSet.Invalids > 0 { + ds.Result = graphql.Null + } + ec.deferredResults <- ds + }() +} + +func (ec *executionContext) introspectSchema() (*introspection.Schema, error) { + if ec.DisableIntrospection { + return nil, errors.New("introspection disabled") + } + return introspection.WrapSchema(ec.Schema()), nil +} + +func (ec *executionContext) introspectType(name string) (*introspection.Type, error) { + if ec.DisableIntrospection { + return nil, errors.New("introspection disabled") + } + return introspection.WrapTypeFromDef(ec.Schema(), ec.Schema().Types[name]), nil +} + +//go:embed "schema/activity.graphqls" "schema/common.graphqls" "schema/component.graphqls" "schema/component_instance.graphqls" "schema/component_version.graphqls" "schema/evidence.graphqls" "schema/issue.graphqls" "schema/issue_match.graphqls" "schema/issue_match_change.graphqls" "schema/issue_repository.graphqls" "schema/issue_variant.graphqls" "schema/mutation.graphqls" "schema/query.graphqls" "schema/service.graphqls" "schema/support_group.graphqls" "schema/user.graphqls" +var sourcesFS embed.FS + +func sourceData(filename string) string { + data, err := sourcesFS.ReadFile(filename) + if err != nil { + panic(fmt.Sprintf("codegen problem: %s not available", filename)) + } + return string(data) +} + +var sources = []*ast.Source{ + {Name: "schema/activity.graphqls", Input: sourceData("schema/activity.graphqls"), BuiltIn: false}, + {Name: "schema/common.graphqls", Input: sourceData("schema/common.graphqls"), BuiltIn: false}, + {Name: "schema/component.graphqls", Input: sourceData("schema/component.graphqls"), BuiltIn: false}, + {Name: "schema/component_instance.graphqls", Input: sourceData("schema/component_instance.graphqls"), BuiltIn: false}, + {Name: "schema/component_version.graphqls", Input: sourceData("schema/component_version.graphqls"), BuiltIn: false}, + {Name: "schema/evidence.graphqls", Input: sourceData("schema/evidence.graphqls"), BuiltIn: false}, + {Name: "schema/issue.graphqls", Input: sourceData("schema/issue.graphqls"), BuiltIn: false}, + {Name: "schema/issue_match.graphqls", Input: sourceData("schema/issue_match.graphqls"), BuiltIn: false}, + {Name: "schema/issue_match_change.graphqls", Input: sourceData("schema/issue_match_change.graphqls"), BuiltIn: false}, + {Name: "schema/issue_repository.graphqls", Input: sourceData("schema/issue_repository.graphqls"), BuiltIn: false}, + {Name: "schema/issue_variant.graphqls", Input: sourceData("schema/issue_variant.graphqls"), BuiltIn: false}, + {Name: "schema/mutation.graphqls", Input: sourceData("schema/mutation.graphqls"), BuiltIn: false}, + {Name: "schema/query.graphqls", Input: sourceData("schema/query.graphqls"), BuiltIn: false}, + {Name: "schema/service.graphqls", Input: sourceData("schema/service.graphqls"), BuiltIn: false}, + {Name: "schema/support_group.graphqls", Input: sourceData("schema/support_group.graphqls"), BuiltIn: false}, + {Name: "schema/user.graphqls", Input: sourceData("schema/user.graphqls"), BuiltIn: false}, +} +var parsedSchema = gqlparser.MustLoadSchema(sources...) + +// endregion ************************** generated!.gotpl ************************** + +// region ***************************** args.gotpl ***************************** + +func (ec *executionContext) field_Activity_evidences_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.EvidenceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOEvidenceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Activity_issueMatchChanges_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchChangeFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchChangeFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Activity_issues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Activity_services_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ServiceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOServiceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_ComponentInstance_issueMatches_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_ComponentVersion_issues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg0, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg0 + var arg1 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg1, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Component_componentVersions_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ComponentVersionFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOComponentVersionFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Evidence_issueMatches_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_IssueMatch_effectiveIssueVariants_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueVariantFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueVariantFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_IssueMatch_evidences_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.EvidenceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOEvidenceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_IssueMatch_issueMatchChanges_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchChangeFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchChangeFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_IssueRepository_issueVariants_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueVariantFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueVariantFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_IssueRepository_services_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ServiceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOServiceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Issue_activities_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ActivityFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOActivityFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Issue_componentVersions_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ComponentVersionFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOComponentVersionFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Issue_issueMatches_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Issue_issueVariants_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueVariantFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueVariantFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Mutation_createActivity_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.ActivityInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNActivityInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createComponentInstance_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.ComponentInstanceInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNComponentInstanceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createComponentVersion_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.ComponentVersionInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNComponentVersionInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createComponent_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.ComponentInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNComponentInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createEvidence_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.EvidenceInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNEvidenceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createIssueMatch_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.IssueMatchInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNIssueMatchInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createIssueRepository_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.IssueRepositoryInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNIssueRepositoryInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createIssueVariant_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.IssueVariantInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNIssueVariantInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createService_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.ServiceInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNServiceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createSupportGroup_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.SupportGroupInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNSupportGroupInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_createUser_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 model.UserInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNUserInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteActivity_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteComponentInstance_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteComponentVersion_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteComponent_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteEvidence_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteIssueMatch_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteIssueRepository_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteIssueVariant_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteService_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteSupportGroup_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_deleteUser_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateActivity_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.ActivityInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNActivityInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateComponentInstance_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.ComponentInstanceInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNComponentInstanceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateComponentVersion_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.ComponentVersionInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNComponentVersionInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateComponent_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.ComponentInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNComponentInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateEvidence_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.EvidenceInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNEvidenceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateIssueMatch_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.IssueMatchInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNIssueMatchInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateIssueRepository_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.IssueRepositoryInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNIssueRepositoryInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateIssueVariant_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.IssueVariantInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNIssueVariantInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateService_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.ServiceInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNServiceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateSupportGroup_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.SupportGroupInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNSupportGroupInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Mutation_updateUser_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["id"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + arg0, err = ec.unmarshalNID2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["id"] = arg0 + var arg1 model.UserInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg1, err = ec.unmarshalNUserInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg1 + return args, nil +} + +func (ec *executionContext) field_Query_Activities_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ActivityFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOActivityFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_ComponentInstances_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ComponentInstanceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOComponentInstanceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_ComponentVersions_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ComponentVersionFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOComponentVersionFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_Components_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ComponentFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOComponentFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_Evidences_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.EvidenceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOEvidenceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_IssueMatchChanges_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchChangeFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchChangeFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_IssueMatches_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueMatchFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueMatchFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_IssueRepositories_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueRepositoryFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueRepositoryFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_IssueVariants_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueVariantFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueVariantFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_Issues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_Services_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ServiceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOServiceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_SupportGroups_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.SupportGroupFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOSupportGroupFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query_Users_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.UserFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOUserFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Query___type_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 string + if tmp, ok := rawArgs["name"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + arg0, err = ec.unmarshalNString2string(ctx, tmp) + if err != nil { + return nil, err + } + } + args["name"] = arg0 + return args, nil +} + +func (ec *executionContext) field_Service_activities_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ActivityFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOActivityFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Service_componentInstances_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ComponentInstanceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOComponentInstanceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Service_issueRepositories_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.IssueRepositoryFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOIssueRepositoryFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Service_owners_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.UserFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOUserFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_Service_supportGroups_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.SupportGroupFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOSupportGroupFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_SupportGroup_services_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ServiceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOServiceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_SupportGroup_users_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.UserFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOUserFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_User_services_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.ServiceFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOServiceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field_User_supportGroups_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 *model.SupportGroupFilter + if tmp, ok := rawArgs["filter"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("filter")) + arg0, err = ec.unmarshalOSupportGroupFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupFilter(ctx, tmp) + if err != nil { + return nil, err + } + } + args["filter"] = arg0 + var arg1 *int + if tmp, ok := rawArgs["first"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("first")) + arg1, err = ec.unmarshalOInt2ᚖint(ctx, tmp) + if err != nil { + return nil, err + } + } + args["first"] = arg1 + var arg2 *string + if tmp, ok := rawArgs["after"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + arg2, err = ec.unmarshalOString2ᚖstring(ctx, tmp) + if err != nil { + return nil, err + } + } + args["after"] = arg2 + return args, nil +} + +func (ec *executionContext) field___Type_enumValues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 bool + if tmp, ok := rawArgs["includeDeprecated"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("includeDeprecated")) + arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp) + if err != nil { + return nil, err + } + } + args["includeDeprecated"] = arg0 + return args, nil +} + +func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 bool + if tmp, ok := rawArgs["includeDeprecated"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("includeDeprecated")) + arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp) + if err != nil { + return nil, err + } + } + args["includeDeprecated"] = arg0 + return args, nil +} + +// endregion ***************************** args.gotpl ***************************** + +// region ************************** directives.gotpl ************************** + +// endregion ************************** directives.gotpl ************************** + +// region **************************** field.gotpl ***************************** + +func (ec *executionContext) _Activity_id(ctx context.Context, field graphql.CollectedField, obj *model.Activity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Activity_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Activity_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Activity", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Activity_status(ctx context.Context, field graphql.CollectedField, obj *model.Activity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Activity_status(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Status, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ActivityStatusValues) + fc.Result = res + return ec.marshalOActivityStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Activity_status(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Activity", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ActivityStatusValues does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Activity_services(ctx context.Context, field graphql.CollectedField, obj *model.Activity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Activity_services(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Activity().Services(rctx, obj, fc.Args["filter"].(*model.ServiceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ServiceConnection) + fc.Result = res + return ec.marshalOServiceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Activity_services(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Activity", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ServiceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ServiceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ServiceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ServiceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Activity_services_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Activity_issues(ctx context.Context, field graphql.CollectedField, obj *model.Activity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Activity_issues(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Activity().Issues(rctx, obj, fc.Args["filter"].(*model.IssueFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueConnection) + fc.Result = res + return ec.marshalOIssueConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Activity_issues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Activity", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Activity_issues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Activity_evidences(ctx context.Context, field graphql.CollectedField, obj *model.Activity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Activity_evidences(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Activity().Evidences(rctx, obj, fc.Args["filter"].(*model.EvidenceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.EvidenceConnection) + fc.Result = res + return ec.marshalOEvidenceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Activity_evidences(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Activity", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_EvidenceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_EvidenceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_EvidenceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EvidenceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Activity_evidences_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Activity_issueMatchChanges(ctx context.Context, field graphql.CollectedField, obj *model.Activity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Activity_issueMatchChanges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Activity().IssueMatchChanges(rctx, obj, fc.Args["filter"].(*model.IssueMatchChangeFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchChangeConnection) + fc.Result = res + return ec.marshalOIssueMatchChangeConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Activity_issueMatchChanges(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Activity", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchChangeConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchChangeConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchChangeConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchChangeConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Activity_issueMatchChanges_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _ActivityConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.ActivityConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ActivityConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ActivityConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ActivityConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ActivityConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.ActivityConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ActivityConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.ActivityEdge) + fc.Result = res + return ec.marshalOActivityEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ActivityConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ActivityConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_ActivityEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_ActivityEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ActivityEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ActivityConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.ActivityConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ActivityConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ActivityConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ActivityConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ActivityEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.ActivityEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ActivityEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Activity) + fc.Result = res + return ec.marshalNActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ActivityEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ActivityEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Activity_id(ctx, field) + case "status": + return ec.fieldContext_Activity_status(ctx, field) + case "services": + return ec.fieldContext_Activity_services(ctx, field) + case "issues": + return ec.fieldContext_Activity_issues(ctx, field) + case "evidences": + return ec.fieldContext_Activity_evidences(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_Activity_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Activity", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ActivityEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.ActivityEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ActivityEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ActivityEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ActivityEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSS_vector(ctx context.Context, field graphql.CollectedField, obj *model.Cvss) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSS_vector(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Vector, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSS_vector(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSS", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSS_base(ctx context.Context, field graphql.CollectedField, obj *model.Cvss) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSS_base(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Base, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.CVSSBase) + fc.Result = res + return ec.marshalOCVSSBase2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCVSSBase(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSS_base(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSS", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "score": + return ec.fieldContext_CVSSBase_score(ctx, field) + case "attackVector": + return ec.fieldContext_CVSSBase_attackVector(ctx, field) + case "attackComplexity": + return ec.fieldContext_CVSSBase_attackComplexity(ctx, field) + case "privilegesRequired": + return ec.fieldContext_CVSSBase_privilegesRequired(ctx, field) + case "userInteraction": + return ec.fieldContext_CVSSBase_userInteraction(ctx, field) + case "scope": + return ec.fieldContext_CVSSBase_scope(ctx, field) + case "confidentialityImpact": + return ec.fieldContext_CVSSBase_confidentialityImpact(ctx, field) + case "integrityImpact": + return ec.fieldContext_CVSSBase_integrityImpact(ctx, field) + case "availabilityImpact": + return ec.fieldContext_CVSSBase_availabilityImpact(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type CVSSBase", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSS_temporal(ctx context.Context, field graphql.CollectedField, obj *model.Cvss) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSS_temporal(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Temporal, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.CVSSTemporal) + fc.Result = res + return ec.marshalOCVSSTemporal2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCVSSTemporal(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSS_temporal(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSS", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "score": + return ec.fieldContext_CVSSTemporal_score(ctx, field) + case "exploitCodeMaturity": + return ec.fieldContext_CVSSTemporal_exploitCodeMaturity(ctx, field) + case "remediationLevel": + return ec.fieldContext_CVSSTemporal_remediationLevel(ctx, field) + case "reportConfidence": + return ec.fieldContext_CVSSTemporal_reportConfidence(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type CVSSTemporal", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSS_environmental(ctx context.Context, field graphql.CollectedField, obj *model.Cvss) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSS_environmental(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Environmental, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.CVSSEnvironmental) + fc.Result = res + return ec.marshalOCVSSEnvironmental2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCVSSEnvironmental(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSS_environmental(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSS", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "score": + return ec.fieldContext_CVSSEnvironmental_score(ctx, field) + case "modifiedAttackVector": + return ec.fieldContext_CVSSEnvironmental_modifiedAttackVector(ctx, field) + case "modifiedAttackComplexity": + return ec.fieldContext_CVSSEnvironmental_modifiedAttackComplexity(ctx, field) + case "modifiedPrivilegesRequired": + return ec.fieldContext_CVSSEnvironmental_modifiedPrivilegesRequired(ctx, field) + case "modifiedUserInteraction": + return ec.fieldContext_CVSSEnvironmental_modifiedUserInteraction(ctx, field) + case "modifiedScope": + return ec.fieldContext_CVSSEnvironmental_modifiedScope(ctx, field) + case "modifiedConfidentialityImpact": + return ec.fieldContext_CVSSEnvironmental_modifiedConfidentialityImpact(ctx, field) + case "modifiedIntegrityImpact": + return ec.fieldContext_CVSSEnvironmental_modifiedIntegrityImpact(ctx, field) + case "modifiedAvailabilityImpact": + return ec.fieldContext_CVSSEnvironmental_modifiedAvailabilityImpact(ctx, field) + case "confidentialityRequirement": + return ec.fieldContext_CVSSEnvironmental_confidentialityRequirement(ctx, field) + case "availabilityRequirement": + return ec.fieldContext_CVSSEnvironmental_availabilityRequirement(ctx, field) + case "integrityRequirement": + return ec.fieldContext_CVSSEnvironmental_integrityRequirement(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type CVSSEnvironmental", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_score(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_score(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Score, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*float64) + fc.Result = res + return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_score(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_attackVector(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_attackVector(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.AttackVector, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_attackVector(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_attackComplexity(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_attackComplexity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.AttackComplexity, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_attackComplexity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_privilegesRequired(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_privilegesRequired(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PrivilegesRequired, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_privilegesRequired(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_userInteraction(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_userInteraction(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UserInteraction, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_userInteraction(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_scope(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_scope(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Scope, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_scope(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_confidentialityImpact(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_confidentialityImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ConfidentialityImpact, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_confidentialityImpact(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_integrityImpact(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_integrityImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IntegrityImpact, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_integrityImpact(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSBase_availabilityImpact(ctx context.Context, field graphql.CollectedField, obj *model.CVSSBase) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSBase_availabilityImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.AvailabilityImpact, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSBase_availabilityImpact(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSBase", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_score(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_score(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Score, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*float64) + fc.Result = res + return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_score(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedAttackVector(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedAttackVector(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedAttackVector, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedAttackVector(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedAttackComplexity(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedAttackComplexity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedAttackComplexity, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedAttackComplexity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedPrivilegesRequired(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedPrivilegesRequired(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedPrivilegesRequired, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedPrivilegesRequired(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedUserInteraction(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedUserInteraction(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedUserInteraction, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedUserInteraction(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedScope(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedScope(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedScope, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedScope(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedConfidentialityImpact(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedConfidentialityImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedConfidentialityImpact, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedConfidentialityImpact(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedIntegrityImpact(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedIntegrityImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedIntegrityImpact, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedIntegrityImpact(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_modifiedAvailabilityImpact(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_modifiedAvailabilityImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ModifiedAvailabilityImpact, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_modifiedAvailabilityImpact(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_confidentialityRequirement(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_confidentialityRequirement(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ConfidentialityRequirement, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_confidentialityRequirement(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_availabilityRequirement(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_availabilityRequirement(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.AvailabilityRequirement, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_availabilityRequirement(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSEnvironmental_integrityRequirement(ctx context.Context, field graphql.CollectedField, obj *model.CVSSEnvironmental) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSEnvironmental_integrityRequirement(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IntegrityRequirement, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSEnvironmental_integrityRequirement(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSEnvironmental", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSParameter_name(ctx context.Context, field graphql.CollectedField, obj *model.CVSSParameter) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSParameter_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSParameter_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSParameter", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSParameter_value(ctx context.Context, field graphql.CollectedField, obj *model.CVSSParameter) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSParameter_value(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Value, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSParameter_value(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSParameter", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSTemporal_score(ctx context.Context, field graphql.CollectedField, obj *model.CVSSTemporal) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSTemporal_score(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Score, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*float64) + fc.Result = res + return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSTemporal_score(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSTemporal", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSTemporal_exploitCodeMaturity(ctx context.Context, field graphql.CollectedField, obj *model.CVSSTemporal) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSTemporal_exploitCodeMaturity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ExploitCodeMaturity, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSTemporal_exploitCodeMaturity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSTemporal", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSTemporal_remediationLevel(ctx context.Context, field graphql.CollectedField, obj *model.CVSSTemporal) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSTemporal_remediationLevel(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.RemediationLevel, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSTemporal_remediationLevel(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSTemporal", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _CVSSTemporal_reportConfidence(ctx context.Context, field graphql.CollectedField, obj *model.CVSSTemporal) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CVSSTemporal_reportConfidence(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ReportConfidence, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_CVSSTemporal_reportConfidence(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CVSSTemporal", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Component_id(ctx context.Context, field graphql.CollectedField, obj *model.Component) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Component_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Component_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Component", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Component_name(ctx context.Context, field graphql.CollectedField, obj *model.Component) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Component_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Component_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Component", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Component_type(ctx context.Context, field graphql.CollectedField, obj *model.Component) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Component_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentTypeValues) + fc.Result = res + return ec.marshalOComponentTypeValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentTypeValues(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Component_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Component", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ComponentTypeValues does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Component_componentVersions(ctx context.Context, field graphql.CollectedField, obj *model.Component) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Component_componentVersions(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Component().ComponentVersions(rctx, obj, fc.Args["filter"].(*model.ComponentVersionFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentVersionConnection) + fc.Result = res + return ec.marshalOComponentVersionConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Component_componentVersions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Component", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ComponentVersionConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ComponentVersionConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ComponentVersionConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersionConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Component_componentVersions_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _ComponentConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.ComponentConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.ComponentConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.ComponentEdge) + fc.Result = res + return ec.marshalOComponentEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_ComponentEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_ComponentEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.ComponentConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.ComponentEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Component) + fc.Result = res + return ec.marshalNComponent2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Component_id(ctx, field) + case "name": + return ec.fieldContext_Component_name(ctx, field) + case "type": + return ec.fieldContext_Component_type(ctx, field) + case "componentVersions": + return ec.fieldContext_Component_componentVersions(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Component", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.ComponentEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_id(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_ccrn(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_ccrn(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Ccrn, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_ccrn(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_count(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_count(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Count, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*int) + fc.Result = res + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_count(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_componentVersionId(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_componentVersionId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ComponentVersionID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_componentVersionId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_componentVersion(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_componentVersion(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.ComponentInstance().ComponentVersion(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentVersion) + fc.Result = res + return ec.marshalOComponentVersion2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_componentVersion(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentVersion_id(ctx, field) + case "version": + return ec.fieldContext_ComponentVersion_version(ctx, field) + case "componentId": + return ec.fieldContext_ComponentVersion_componentId(ctx, field) + case "component": + return ec.fieldContext_ComponentVersion_component(ctx, field) + case "issues": + return ec.fieldContext_ComponentVersion_issues(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersion", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_issueMatches(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_issueMatches(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.ComponentInstance().IssueMatches(rctx, obj, fc.Args["filter"].(*model.IssueMatchFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchConnection) + fc.Result = res + return ec.marshalOIssueMatchConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_issueMatches(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_ComponentInstance_issueMatches_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_serviceId(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_serviceId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ServiceID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_serviceId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_service(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_service(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.ComponentInstance().Service(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Service) + fc.Result = res + return ec.marshalOService2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_service(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Service_id(ctx, field) + case "name": + return ec.fieldContext_Service_name(ctx, field) + case "owners": + return ec.fieldContext_Service_owners(ctx, field) + case "supportGroups": + return ec.fieldContext_Service_supportGroups(ctx, field) + case "activities": + return ec.fieldContext_Service_activities(ctx, field) + case "issueRepositories": + return ec.fieldContext_Service_issueRepositories(ctx, field) + case "componentInstances": + return ec.fieldContext_Service_componentInstances(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Service", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_createdAt(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_createdAt(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.CreatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_createdAt(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstance_updatedAt(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstance) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstance_updatedAt(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UpdatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstance_updatedAt(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstance", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstanceConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstanceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstanceConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstanceConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstanceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstanceConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstanceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstanceConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]*model.ComponentInstanceEdge) + fc.Result = res + return ec.marshalNComponentInstanceEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstanceConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstanceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_ComponentInstanceEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_ComponentInstanceEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstanceEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstanceConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstanceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstanceConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstanceConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstanceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstanceEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstanceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstanceEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentInstance) + fc.Result = res + return ec.marshalNComponentInstance2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstance(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstanceEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstanceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentInstance_id(ctx, field) + case "ccrn": + return ec.fieldContext_ComponentInstance_ccrn(ctx, field) + case "count": + return ec.fieldContext_ComponentInstance_count(ctx, field) + case "componentVersionId": + return ec.fieldContext_ComponentInstance_componentVersionId(ctx, field) + case "componentVersion": + return ec.fieldContext_ComponentInstance_componentVersion(ctx, field) + case "issueMatches": + return ec.fieldContext_ComponentInstance_issueMatches(ctx, field) + case "serviceId": + return ec.fieldContext_ComponentInstance_serviceId(ctx, field) + case "service": + return ec.fieldContext_ComponentInstance_service(ctx, field) + case "createdAt": + return ec.fieldContext_ComponentInstance_createdAt(ctx, field) + case "updatedAt": + return ec.fieldContext_ComponentInstance_updatedAt(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstance", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentInstanceEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.ComponentInstanceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentInstanceEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentInstanceEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentInstanceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersion_id(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersion_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersion_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersion", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersion_version(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersion_version(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Version, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersion_version(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersion", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersion_componentId(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersion_componentId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ComponentID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersion_componentId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersion", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersion_component(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersion_component(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.ComponentVersion().Component(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Component) + fc.Result = res + return ec.marshalOComponent2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersion_component(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersion", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Component_id(ctx, field) + case "name": + return ec.fieldContext_Component_name(ctx, field) + case "type": + return ec.fieldContext_Component_type(ctx, field) + case "componentVersions": + return ec.fieldContext_Component_componentVersions(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Component", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersion_issues(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersion_issues(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.ComponentVersion().Issues(rctx, obj, fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueConnection) + fc.Result = res + return ec.marshalOIssueConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersion_issues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersion", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_ComponentVersion_issues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersionConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersionConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersionConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersionConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersionConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersionConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersionConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersionConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]*model.ComponentVersionEdge) + fc.Result = res + return ec.marshalNComponentVersionEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersionConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersionConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_ComponentVersionEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_ComponentVersionEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersionEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersionConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersionConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersionConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersionConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersionConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersionEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersionEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersionEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentVersion) + fc.Result = res + return ec.marshalNComponentVersion2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersionEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersionEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentVersion_id(ctx, field) + case "version": + return ec.fieldContext_ComponentVersion_version(ctx, field) + case "componentId": + return ec.fieldContext_ComponentVersion_componentId(ctx, field) + case "component": + return ec.fieldContext_ComponentVersion_component(ctx, field) + case "issues": + return ec.fieldContext_ComponentVersion_issues(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersion", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ComponentVersionEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.ComponentVersionEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ComponentVersionEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ComponentVersionEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ComponentVersionEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_id(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_description(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_type(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_vector(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_vector(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Vector, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_vector(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_raaEnd(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_raaEnd(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.RaaEnd, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_raaEnd(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_authorId(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_authorId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.AuthorID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_authorId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_author(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_author(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Evidence().Author(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.User) + fc.Result = res + return ec.marshalOUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_author(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "sapID": + return ec.fieldContext_User_sapID(ctx, field) + case "name": + return ec.fieldContext_User_name(ctx, field) + case "supportGroups": + return ec.fieldContext_User_supportGroups(ctx, field) + case "services": + return ec.fieldContext_User_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_activityId(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_activityId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ActivityID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_activityId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_activity(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_activity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Evidence().Activity(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Activity) + fc.Result = res + return ec.marshalOActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_activity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Activity_id(ctx, field) + case "status": + return ec.fieldContext_Activity_status(ctx, field) + case "services": + return ec.fieldContext_Activity_services(ctx, field) + case "issues": + return ec.fieldContext_Activity_issues(ctx, field) + case "evidences": + return ec.fieldContext_Activity_evidences(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_Activity_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Activity", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _Evidence_issueMatches(ctx context.Context, field graphql.CollectedField, obj *model.Evidence) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evidence_issueMatches(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Evidence().IssueMatches(rctx, obj, fc.Args["filter"].(*model.IssueMatchFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchConnection) + fc.Result = res + return ec.marshalOIssueMatchConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Evidence_issueMatches(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evidence", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Evidence_issueMatches_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _EvidenceConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.EvidenceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EvidenceConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_EvidenceConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EvidenceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _EvidenceConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.EvidenceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EvidenceConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.EvidenceEdge) + fc.Result = res + return ec.marshalOEvidenceEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_EvidenceConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EvidenceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_EvidenceEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_EvidenceEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EvidenceEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _EvidenceConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.EvidenceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EvidenceConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_EvidenceConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EvidenceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _EvidenceEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.EvidenceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EvidenceEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Evidence) + fc.Result = res + return ec.marshalNEvidence2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidence(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_EvidenceEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EvidenceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Evidence_id(ctx, field) + case "description": + return ec.fieldContext_Evidence_description(ctx, field) + case "type": + return ec.fieldContext_Evidence_type(ctx, field) + case "vector": + return ec.fieldContext_Evidence_vector(ctx, field) + case "raaEnd": + return ec.fieldContext_Evidence_raaEnd(ctx, field) + case "authorId": + return ec.fieldContext_Evidence_authorId(ctx, field) + case "author": + return ec.fieldContext_Evidence_author(ctx, field) + case "activityId": + return ec.fieldContext_Evidence_activityId(ctx, field) + case "activity": + return ec.fieldContext_Evidence_activity(ctx, field) + case "issueMatches": + return ec.fieldContext_Evidence_issueMatches(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Evidence", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _EvidenceEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.EvidenceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EvidenceEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_EvidenceEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EvidenceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Issue_id(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Issue_type(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueTypes) + fc.Result = res + return ec.marshalOIssueTypes2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type IssueTypes does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Issue_primaryName(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_primaryName(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PrimaryName, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_primaryName(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Issue_lastModified(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_lastModified(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.LastModified, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_lastModified(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Issue_issueVariants(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_issueVariants(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Issue().IssueVariants(rctx, obj, fc.Args["filter"].(*model.IssueVariantFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueVariantConnection) + fc.Result = res + return ec.marshalOIssueVariantConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_issueVariants(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueVariantConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueVariantConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueVariantConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariantConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Issue_issueVariants_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Issue_activities(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_activities(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Issue().Activities(rctx, obj, fc.Args["filter"].(*model.ActivityFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ActivityConnection) + fc.Result = res + return ec.marshalOActivityConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_activities(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ActivityConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ActivityConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ActivityConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ActivityConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Issue_activities_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Issue_issueMatches(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_issueMatches(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Issue().IssueMatches(rctx, obj, fc.Args["filter"].(*model.IssueMatchFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchConnection) + fc.Result = res + return ec.marshalOIssueMatchConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_issueMatches(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Issue_issueMatches_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Issue_componentVersions(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_componentVersions(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Issue().ComponentVersions(rctx, obj, fc.Args["filter"].(*model.ComponentVersionFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentVersionConnection) + fc.Result = res + return ec.marshalOComponentVersionConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_componentVersions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ComponentVersionConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ComponentVersionConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ComponentVersionConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersionConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Issue_componentVersions_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Issue_metadata(ctx context.Context, field graphql.CollectedField, obj *model.Issue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Issue_metadata(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Metadata, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMetadata) + fc.Result = res + return ec.marshalOIssueMetadata2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMetadata(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Issue_metadata(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Issue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "serviceCount": + return ec.fieldContext_IssueMetadata_serviceCount(ctx, field) + case "activityCount": + return ec.fieldContext_IssueMetadata_activityCount(ctx, field) + case "issueMatchCount": + return ec.fieldContext_IssueMetadata_issueMatchCount(ctx, field) + case "componentInstanceCount": + return ec.fieldContext_IssueMetadata_componentInstanceCount(ctx, field) + case "componentVersionCount": + return ec.fieldContext_IssueMetadata_componentVersionCount(ctx, field) + case "earliestDiscoveryDate": + return ec.fieldContext_IssueMetadata_earliestDiscoveryDate(ctx, field) + case "earliestTargetRemediationDate": + return ec.fieldContext_IssueMetadata_earliestTargetRemediationDate(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMetadata", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.IssueConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]*model.IssueEdge) + fc.Result = res + return ec.marshalNIssueEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_IssueEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_IssueEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.IssueConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.IssueEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Issue) + fc.Result = res + return ec.marshalNIssue2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssue(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Issue_id(ctx, field) + case "type": + return ec.fieldContext_Issue_type(ctx, field) + case "primaryName": + return ec.fieldContext_Issue_primaryName(ctx, field) + case "lastModified": + return ec.fieldContext_Issue_lastModified(ctx, field) + case "issueVariants": + return ec.fieldContext_Issue_issueVariants(ctx, field) + case "activities": + return ec.fieldContext_Issue_activities(ctx, field) + case "issueMatches": + return ec.fieldContext_Issue_issueMatches(ctx, field) + case "componentVersions": + return ec.fieldContext_Issue_componentVersions(ctx, field) + case "metadata": + return ec.fieldContext_Issue_metadata(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Issue", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.IssueEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_id(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_status(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_status(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Status, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchStatusValues) + fc.Result = res + return ec.marshalOIssueMatchStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_status(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type IssueMatchStatusValues does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_remediationDate(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_remediationDate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.RemediationDate, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_remediationDate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_discoveryDate(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_discoveryDate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.DiscoveryDate, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_discoveryDate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_targetRemediationDate(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_targetRemediationDate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TargetRemediationDate, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_targetRemediationDate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_severity(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_severity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatch().Severity(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Severity) + fc.Result = res + return ec.marshalOSeverity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_severity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "value": + return ec.fieldContext_Severity_value(ctx, field) + case "score": + return ec.fieldContext_Severity_score(ctx, field) + case "cvss": + return ec.fieldContext_Severity_cvss(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Severity", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_effectiveIssueVariants(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_effectiveIssueVariants(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatch().EffectiveIssueVariants(rctx, obj, fc.Args["filter"].(*model.IssueVariantFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueVariantConnection) + fc.Result = res + return ec.marshalOIssueVariantConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_effectiveIssueVariants(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueVariantConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueVariantConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueVariantConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariantConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_IssueMatch_effectiveIssueVariants_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_evidences(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_evidences(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatch().Evidences(rctx, obj, fc.Args["filter"].(*model.EvidenceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.EvidenceConnection) + fc.Result = res + return ec.marshalOEvidenceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_evidences(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_EvidenceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_EvidenceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_EvidenceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EvidenceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_IssueMatch_evidences_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_issueId(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_issueId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IssueID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_issueId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_issue(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_issue(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatch().Issue(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Issue) + fc.Result = res + return ec.marshalNIssue2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssue(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_issue(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Issue_id(ctx, field) + case "type": + return ec.fieldContext_Issue_type(ctx, field) + case "primaryName": + return ec.fieldContext_Issue_primaryName(ctx, field) + case "lastModified": + return ec.fieldContext_Issue_lastModified(ctx, field) + case "issueVariants": + return ec.fieldContext_Issue_issueVariants(ctx, field) + case "activities": + return ec.fieldContext_Issue_activities(ctx, field) + case "issueMatches": + return ec.fieldContext_Issue_issueMatches(ctx, field) + case "componentVersions": + return ec.fieldContext_Issue_componentVersions(ctx, field) + case "metadata": + return ec.fieldContext_Issue_metadata(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Issue", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_userId(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_userId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UserID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_userId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_user(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_user(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.User, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.User) + fc.Result = res + return ec.marshalOUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_user(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "sapID": + return ec.fieldContext_User_sapID(ctx, field) + case "name": + return ec.fieldContext_User_name(ctx, field) + case "supportGroups": + return ec.fieldContext_User_supportGroups(ctx, field) + case "services": + return ec.fieldContext_User_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_componentInstanceId(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_componentInstanceId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ComponentInstanceID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_componentInstanceId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_componentInstance(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_componentInstance(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatch().ComponentInstance(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentInstance) + fc.Result = res + return ec.marshalNComponentInstance2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstance(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_componentInstance(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentInstance_id(ctx, field) + case "ccrn": + return ec.fieldContext_ComponentInstance_ccrn(ctx, field) + case "count": + return ec.fieldContext_ComponentInstance_count(ctx, field) + case "componentVersionId": + return ec.fieldContext_ComponentInstance_componentVersionId(ctx, field) + case "componentVersion": + return ec.fieldContext_ComponentInstance_componentVersion(ctx, field) + case "issueMatches": + return ec.fieldContext_ComponentInstance_issueMatches(ctx, field) + case "serviceId": + return ec.fieldContext_ComponentInstance_serviceId(ctx, field) + case "service": + return ec.fieldContext_ComponentInstance_service(ctx, field) + case "createdAt": + return ec.fieldContext_ComponentInstance_createdAt(ctx, field) + case "updatedAt": + return ec.fieldContext_ComponentInstance_updatedAt(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstance", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatch_issueMatchChanges(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatch) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatch_issueMatchChanges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatch().IssueMatchChanges(rctx, obj, fc.Args["filter"].(*model.IssueMatchChangeFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchChangeConnection) + fc.Result = res + return ec.marshalOIssueMatchChangeConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatch_issueMatchChanges(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatch", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchChangeConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchChangeConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchChangeConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchChangeConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_IssueMatch_issueMatchChanges_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChange_id(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChange) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChange_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChange_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChange", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChange_action(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChange) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChange_action(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Action, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchChangeActions) + fc.Result = res + return ec.marshalOIssueMatchChangeActions2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChange_action(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChange", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type IssueMatchChangeActions does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChange_issueMatchId(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChange) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChange_issueMatchId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IssueMatchID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChange_issueMatchId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChange", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChange_issueMatch(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChange) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChange_issueMatch(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatchChange().IssueMatch(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueMatch) + fc.Result = res + return ec.marshalNIssueMatch2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatch(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChange_issueMatch(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChange", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueMatch_id(ctx, field) + case "status": + return ec.fieldContext_IssueMatch_status(ctx, field) + case "remediationDate": + return ec.fieldContext_IssueMatch_remediationDate(ctx, field) + case "discoveryDate": + return ec.fieldContext_IssueMatch_discoveryDate(ctx, field) + case "targetRemediationDate": + return ec.fieldContext_IssueMatch_targetRemediationDate(ctx, field) + case "severity": + return ec.fieldContext_IssueMatch_severity(ctx, field) + case "effectiveIssueVariants": + return ec.fieldContext_IssueMatch_effectiveIssueVariants(ctx, field) + case "evidences": + return ec.fieldContext_IssueMatch_evidences(ctx, field) + case "issueId": + return ec.fieldContext_IssueMatch_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueMatch_issue(ctx, field) + case "userId": + return ec.fieldContext_IssueMatch_userId(ctx, field) + case "user": + return ec.fieldContext_IssueMatch_user(ctx, field) + case "componentInstanceId": + return ec.fieldContext_IssueMatch_componentInstanceId(ctx, field) + case "componentInstance": + return ec.fieldContext_IssueMatch_componentInstance(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_IssueMatch_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatch", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChange_activityId(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChange) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChange_activityId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ActivityID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChange_activityId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChange", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChange_activity(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChange) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChange_activity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueMatchChange().Activity(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Activity) + fc.Result = res + return ec.marshalNActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChange_activity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChange", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Activity_id(ctx, field) + case "status": + return ec.fieldContext_Activity_status(ctx, field) + case "services": + return ec.fieldContext_Activity_services(ctx, field) + case "issues": + return ec.fieldContext_Activity_issues(ctx, field) + case "evidences": + return ec.fieldContext_Activity_evidences(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_Activity_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Activity", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChangeConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChangeConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChangeConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChangeConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChangeConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChangeConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChangeConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChangeConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.IssueMatchChangeEdge) + fc.Result = res + return ec.marshalOIssueMatchChangeEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChangeConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChangeConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_IssueMatchChangeEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_IssueMatchChangeEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchChangeEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChangeConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChangeConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChangeConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChangeConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChangeConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChangeEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChangeEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChangeEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueMatchChange) + fc.Result = res + return ec.marshalNIssueMatchChange2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChange(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChangeEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChangeEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueMatchChange_id(ctx, field) + case "action": + return ec.fieldContext_IssueMatchChange_action(ctx, field) + case "issueMatchId": + return ec.fieldContext_IssueMatchChange_issueMatchId(ctx, field) + case "issueMatch": + return ec.fieldContext_IssueMatchChange_issueMatch(ctx, field) + case "activityId": + return ec.fieldContext_IssueMatchChange_activityId(ctx, field) + case "activity": + return ec.fieldContext_IssueMatchChange_activity(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchChange", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchChangeEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchChangeEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchChangeEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchChangeEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchChangeEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.IssueMatchEdge) + fc.Result = res + return ec.marshalOIssueMatchEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_IssueMatchEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_IssueMatchEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueMatch) + fc.Result = res + return ec.marshalNIssueMatch2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatch(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueMatch_id(ctx, field) + case "status": + return ec.fieldContext_IssueMatch_status(ctx, field) + case "remediationDate": + return ec.fieldContext_IssueMatch_remediationDate(ctx, field) + case "discoveryDate": + return ec.fieldContext_IssueMatch_discoveryDate(ctx, field) + case "targetRemediationDate": + return ec.fieldContext_IssueMatch_targetRemediationDate(ctx, field) + case "severity": + return ec.fieldContext_IssueMatch_severity(ctx, field) + case "effectiveIssueVariants": + return ec.fieldContext_IssueMatch_effectiveIssueVariants(ctx, field) + case "evidences": + return ec.fieldContext_IssueMatch_evidences(ctx, field) + case "issueId": + return ec.fieldContext_IssueMatch_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueMatch_issue(ctx, field) + case "userId": + return ec.fieldContext_IssueMatch_userId(ctx, field) + case "user": + return ec.fieldContext_IssueMatch_user(ctx, field) + case "componentInstanceId": + return ec.fieldContext_IssueMatch_componentInstanceId(ctx, field) + case "componentInstance": + return ec.fieldContext_IssueMatch_componentInstance(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_IssueMatch_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatch", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMatchEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.IssueMatchEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMatchEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMatchEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMatchEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_serviceCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_serviceCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ServiceCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_serviceCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_activityCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_activityCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ActivityCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_activityCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_issueMatchCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_issueMatchCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IssueMatchCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_issueMatchCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_componentInstanceCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_componentInstanceCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ComponentInstanceCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_componentInstanceCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_componentVersionCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_componentVersionCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ComponentVersionCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_componentVersionCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_earliestDiscoveryDate(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_earliestDiscoveryDate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.EarliestDiscoveryDate, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNDateTime2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_earliestDiscoveryDate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueMetadata_earliestTargetRemediationDate(ctx context.Context, field graphql.CollectedField, obj *model.IssueMetadata) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueMetadata_earliestTargetRemediationDate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.EarliestTargetRemediationDate, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNDateTime2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueMetadata_earliestTargetRemediationDate(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueMetadata", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_id(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_name(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_url(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_url(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.URL, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_url(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_issueVariants(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_issueVariants(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueRepository().IssueVariants(rctx, obj, fc.Args["filter"].(*model.IssueVariantFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueVariantConnection) + fc.Result = res + return ec.marshalOIssueVariantConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_issueVariants(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueVariantConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueVariantConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueVariantConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariantConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_IssueRepository_issueVariants_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_services(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_services(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueRepository().Services(rctx, obj, fc.Args["filter"].(*model.ServiceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ServiceConnection) + fc.Result = res + return ec.marshalOServiceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_services(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ServiceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ServiceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ServiceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ServiceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_IssueRepository_services_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_created_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_created_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.CreatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_created_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepository_updated_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepository) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepository_updated_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UpdatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepository_updated_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepository", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.IssueRepositoryEdge) + fc.Result = res + return ec.marshalOIssueRepositoryEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_IssueRepositoryEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_IssueRepositoryEdge_cursor(ctx, field) + case "priority": + return ec.fieldContext_IssueRepositoryEdge_priority(ctx, field) + case "created_at": + return ec.fieldContext_IssueRepositoryEdge_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueRepositoryEdge_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepositoryEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueRepository) + fc.Result = res + return ec.marshalNIssueRepository2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueRepository_id(ctx, field) + case "name": + return ec.fieldContext_IssueRepository_name(ctx, field) + case "url": + return ec.fieldContext_IssueRepository_url(ctx, field) + case "issueVariants": + return ec.fieldContext_IssueRepository_issueVariants(ctx, field) + case "services": + return ec.fieldContext_IssueRepository_services(ctx, field) + case "created_at": + return ec.fieldContext_IssueRepository_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueRepository_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepository", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryEdge_priority(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryEdge_priority(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Priority, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*int) + fc.Result = res + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryEdge_priority(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryEdge_created_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryEdge_created_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.CreatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryEdge_created_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueRepositoryEdge_updated_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueRepositoryEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueRepositoryEdge_updated_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UpdatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueRepositoryEdge_updated_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueRepositoryEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_id(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_secondaryName(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_secondaryName(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.SecondaryName, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_secondaryName(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_description(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_severity(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_severity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Severity, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Severity) + fc.Result = res + return ec.marshalOSeverity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_severity(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "value": + return ec.fieldContext_Severity_value(ctx, field) + case "score": + return ec.fieldContext_Severity_score(ctx, field) + case "cvss": + return ec.fieldContext_Severity_cvss(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Severity", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_issueRepositoryId(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_issueRepositoryId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IssueRepositoryID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_issueRepositoryId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_issueRepository(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_issueRepository(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueVariant().IssueRepository(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueRepository) + fc.Result = res + return ec.marshalOIssueRepository2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_issueRepository(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueRepository_id(ctx, field) + case "name": + return ec.fieldContext_IssueRepository_name(ctx, field) + case "url": + return ec.fieldContext_IssueRepository_url(ctx, field) + case "issueVariants": + return ec.fieldContext_IssueRepository_issueVariants(ctx, field) + case "services": + return ec.fieldContext_IssueRepository_services(ctx, field) + case "created_at": + return ec.fieldContext_IssueRepository_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueRepository_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepository", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_issueId(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_issueId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IssueID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_issueId(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_issue(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_issue(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.IssueVariant().Issue(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Issue) + fc.Result = res + return ec.marshalOIssue2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssue(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_issue(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Issue_id(ctx, field) + case "type": + return ec.fieldContext_Issue_type(ctx, field) + case "primaryName": + return ec.fieldContext_Issue_primaryName(ctx, field) + case "lastModified": + return ec.fieldContext_Issue_lastModified(ctx, field) + case "issueVariants": + return ec.fieldContext_Issue_issueVariants(ctx, field) + case "activities": + return ec.fieldContext_Issue_activities(ctx, field) + case "issueMatches": + return ec.fieldContext_Issue_issueMatches(ctx, field) + case "componentVersions": + return ec.fieldContext_Issue_componentVersions(ctx, field) + case "metadata": + return ec.fieldContext_Issue_metadata(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Issue", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_created_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_created_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.CreatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_created_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariant_updated_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariant) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariant_updated_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UpdatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariant_updated_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariant", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.IssueVariantEdge) + fc.Result = res + return ec.marshalOIssueVariantEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_IssueVariantEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_IssueVariantEdge_cursor(ctx, field) + case "created_at": + return ec.fieldContext_IssueVariantEdge_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueVariantEdge_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariantEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueVariant) + fc.Result = res + return ec.marshalNIssueVariant2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariant(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueVariant_id(ctx, field) + case "secondaryName": + return ec.fieldContext_IssueVariant_secondaryName(ctx, field) + case "description": + return ec.fieldContext_IssueVariant_description(ctx, field) + case "severity": + return ec.fieldContext_IssueVariant_severity(ctx, field) + case "issueRepositoryId": + return ec.fieldContext_IssueVariant_issueRepositoryId(ctx, field) + case "issueRepository": + return ec.fieldContext_IssueVariant_issueRepository(ctx, field) + case "issueId": + return ec.fieldContext_IssueVariant_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueVariant_issue(ctx, field) + case "created_at": + return ec.fieldContext_IssueVariant_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueVariant_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariant", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantEdge_created_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantEdge_created_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.CreatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantEdge_created_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _IssueVariantEdge_updated_at(ctx context.Context, field graphql.CollectedField, obj *model.IssueVariantEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_IssueVariantEdge_updated_at(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.UpdatedAt, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalODateTime2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_IssueVariantEdge_updated_at(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "IssueVariantEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type DateTime does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createUser(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateUser(rctx, fc.Args["input"].(model.UserInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.User) + fc.Result = res + return ec.marshalNUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "sapID": + return ec.fieldContext_User_sapID(ctx, field) + case "name": + return ec.fieldContext_User_name(ctx, field) + case "supportGroups": + return ec.fieldContext_User_supportGroups(ctx, field) + case "services": + return ec.fieldContext_User_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateUser(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateUser(rctx, fc.Args["id"].(string), fc.Args["input"].(model.UserInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.User) + fc.Result = res + return ec.marshalNUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "sapID": + return ec.fieldContext_User_sapID(ctx, field) + case "name": + return ec.fieldContext_User_name(ctx, field) + case "supportGroups": + return ec.fieldContext_User_supportGroups(ctx, field) + case "services": + return ec.fieldContext_User_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteUser(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteUser(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createSupportGroup(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createSupportGroup(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateSupportGroup(rctx, fc.Args["input"].(model.SupportGroupInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.SupportGroup) + fc.Result = res + return ec.marshalNSupportGroup2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroup(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createSupportGroup(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_SupportGroup_id(ctx, field) + case "name": + return ec.fieldContext_SupportGroup_name(ctx, field) + case "users": + return ec.fieldContext_SupportGroup_users(ctx, field) + case "services": + return ec.fieldContext_SupportGroup_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroup", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createSupportGroup_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateSupportGroup(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateSupportGroup(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateSupportGroup(rctx, fc.Args["id"].(string), fc.Args["input"].(model.SupportGroupInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.SupportGroup) + fc.Result = res + return ec.marshalNSupportGroup2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroup(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateSupportGroup(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_SupportGroup_id(ctx, field) + case "name": + return ec.fieldContext_SupportGroup_name(ctx, field) + case "users": + return ec.fieldContext_SupportGroup_users(ctx, field) + case "services": + return ec.fieldContext_SupportGroup_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroup", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateSupportGroup_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteSupportGroup(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteSupportGroup(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteSupportGroup(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteSupportGroup(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteSupportGroup_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createComponent(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createComponent(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateComponent(rctx, fc.Args["input"].(model.ComponentInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Component) + fc.Result = res + return ec.marshalNComponent2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createComponent(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Component_id(ctx, field) + case "name": + return ec.fieldContext_Component_name(ctx, field) + case "type": + return ec.fieldContext_Component_type(ctx, field) + case "componentVersions": + return ec.fieldContext_Component_componentVersions(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Component", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createComponent_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateComponent(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateComponent(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateComponent(rctx, fc.Args["id"].(string), fc.Args["input"].(model.ComponentInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Component) + fc.Result = res + return ec.marshalNComponent2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateComponent(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Component_id(ctx, field) + case "name": + return ec.fieldContext_Component_name(ctx, field) + case "type": + return ec.fieldContext_Component_type(ctx, field) + case "componentVersions": + return ec.fieldContext_Component_componentVersions(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Component", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateComponent_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteComponent(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteComponent(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteComponent(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteComponent(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteComponent_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createComponentInstance(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createComponentInstance(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateComponentInstance(rctx, fc.Args["input"].(model.ComponentInstanceInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentInstance) + fc.Result = res + return ec.marshalNComponentInstance2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstance(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createComponentInstance(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentInstance_id(ctx, field) + case "ccrn": + return ec.fieldContext_ComponentInstance_ccrn(ctx, field) + case "count": + return ec.fieldContext_ComponentInstance_count(ctx, field) + case "componentVersionId": + return ec.fieldContext_ComponentInstance_componentVersionId(ctx, field) + case "componentVersion": + return ec.fieldContext_ComponentInstance_componentVersion(ctx, field) + case "issueMatches": + return ec.fieldContext_ComponentInstance_issueMatches(ctx, field) + case "serviceId": + return ec.fieldContext_ComponentInstance_serviceId(ctx, field) + case "service": + return ec.fieldContext_ComponentInstance_service(ctx, field) + case "createdAt": + return ec.fieldContext_ComponentInstance_createdAt(ctx, field) + case "updatedAt": + return ec.fieldContext_ComponentInstance_updatedAt(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstance", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createComponentInstance_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateComponentInstance(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateComponentInstance(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateComponentInstance(rctx, fc.Args["id"].(string), fc.Args["input"].(model.ComponentInstanceInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentInstance) + fc.Result = res + return ec.marshalNComponentInstance2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstance(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateComponentInstance(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentInstance_id(ctx, field) + case "ccrn": + return ec.fieldContext_ComponentInstance_ccrn(ctx, field) + case "count": + return ec.fieldContext_ComponentInstance_count(ctx, field) + case "componentVersionId": + return ec.fieldContext_ComponentInstance_componentVersionId(ctx, field) + case "componentVersion": + return ec.fieldContext_ComponentInstance_componentVersion(ctx, field) + case "issueMatches": + return ec.fieldContext_ComponentInstance_issueMatches(ctx, field) + case "serviceId": + return ec.fieldContext_ComponentInstance_serviceId(ctx, field) + case "service": + return ec.fieldContext_ComponentInstance_service(ctx, field) + case "createdAt": + return ec.fieldContext_ComponentInstance_createdAt(ctx, field) + case "updatedAt": + return ec.fieldContext_ComponentInstance_updatedAt(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstance", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateComponentInstance_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteComponentInstance(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteComponentInstance(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteComponentInstance(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteComponentInstance(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteComponentInstance_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createComponentVersion(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createComponentVersion(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateComponentVersion(rctx, fc.Args["input"].(model.ComponentVersionInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentVersion) + fc.Result = res + return ec.marshalNComponentVersion2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createComponentVersion(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentVersion_id(ctx, field) + case "version": + return ec.fieldContext_ComponentVersion_version(ctx, field) + case "componentId": + return ec.fieldContext_ComponentVersion_componentId(ctx, field) + case "component": + return ec.fieldContext_ComponentVersion_component(ctx, field) + case "issues": + return ec.fieldContext_ComponentVersion_issues(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersion", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createComponentVersion_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateComponentVersion(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateComponentVersion(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateComponentVersion(rctx, fc.Args["id"].(string), fc.Args["input"].(model.ComponentVersionInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.ComponentVersion) + fc.Result = res + return ec.marshalNComponentVersion2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateComponentVersion(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ComponentVersion_id(ctx, field) + case "version": + return ec.fieldContext_ComponentVersion_version(ctx, field) + case "componentId": + return ec.fieldContext_ComponentVersion_componentId(ctx, field) + case "component": + return ec.fieldContext_ComponentVersion_component(ctx, field) + case "issues": + return ec.fieldContext_ComponentVersion_issues(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersion", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateComponentVersion_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteComponentVersion(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteComponentVersion(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteComponentVersion(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteComponentVersion(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteComponentVersion_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createService(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createService(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateService(rctx, fc.Args["input"].(model.ServiceInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Service) + fc.Result = res + return ec.marshalNService2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createService(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Service_id(ctx, field) + case "name": + return ec.fieldContext_Service_name(ctx, field) + case "owners": + return ec.fieldContext_Service_owners(ctx, field) + case "supportGroups": + return ec.fieldContext_Service_supportGroups(ctx, field) + case "activities": + return ec.fieldContext_Service_activities(ctx, field) + case "issueRepositories": + return ec.fieldContext_Service_issueRepositories(ctx, field) + case "componentInstances": + return ec.fieldContext_Service_componentInstances(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Service", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createService_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateService(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateService(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateService(rctx, fc.Args["id"].(string), fc.Args["input"].(model.ServiceInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Service) + fc.Result = res + return ec.marshalNService2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateService(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Service_id(ctx, field) + case "name": + return ec.fieldContext_Service_name(ctx, field) + case "owners": + return ec.fieldContext_Service_owners(ctx, field) + case "supportGroups": + return ec.fieldContext_Service_supportGroups(ctx, field) + case "activities": + return ec.fieldContext_Service_activities(ctx, field) + case "issueRepositories": + return ec.fieldContext_Service_issueRepositories(ctx, field) + case "componentInstances": + return ec.fieldContext_Service_componentInstances(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Service", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateService_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteService(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteService(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteService(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteService(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteService_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createIssueRepository(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createIssueRepository(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateIssueRepository(rctx, fc.Args["input"].(model.IssueRepositoryInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueRepository) + fc.Result = res + return ec.marshalNIssueRepository2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createIssueRepository(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueRepository_id(ctx, field) + case "name": + return ec.fieldContext_IssueRepository_name(ctx, field) + case "url": + return ec.fieldContext_IssueRepository_url(ctx, field) + case "issueVariants": + return ec.fieldContext_IssueRepository_issueVariants(ctx, field) + case "services": + return ec.fieldContext_IssueRepository_services(ctx, field) + case "created_at": + return ec.fieldContext_IssueRepository_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueRepository_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepository", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createIssueRepository_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateIssueRepository(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateIssueRepository(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateIssueRepository(rctx, fc.Args["id"].(string), fc.Args["input"].(model.IssueRepositoryInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueRepository) + fc.Result = res + return ec.marshalNIssueRepository2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateIssueRepository(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueRepository_id(ctx, field) + case "name": + return ec.fieldContext_IssueRepository_name(ctx, field) + case "url": + return ec.fieldContext_IssueRepository_url(ctx, field) + case "issueVariants": + return ec.fieldContext_IssueRepository_issueVariants(ctx, field) + case "services": + return ec.fieldContext_IssueRepository_services(ctx, field) + case "created_at": + return ec.fieldContext_IssueRepository_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueRepository_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepository", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateIssueRepository_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteIssueRepository(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteIssueRepository(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteIssueRepository(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteIssueRepository(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteIssueRepository_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createIssueVariant(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createIssueVariant(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateIssueVariant(rctx, fc.Args["input"].(model.IssueVariantInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueVariant) + fc.Result = res + return ec.marshalNIssueVariant2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariant(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createIssueVariant(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueVariant_id(ctx, field) + case "secondaryName": + return ec.fieldContext_IssueVariant_secondaryName(ctx, field) + case "description": + return ec.fieldContext_IssueVariant_description(ctx, field) + case "severity": + return ec.fieldContext_IssueVariant_severity(ctx, field) + case "issueRepositoryId": + return ec.fieldContext_IssueVariant_issueRepositoryId(ctx, field) + case "issueRepository": + return ec.fieldContext_IssueVariant_issueRepository(ctx, field) + case "issueId": + return ec.fieldContext_IssueVariant_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueVariant_issue(ctx, field) + case "created_at": + return ec.fieldContext_IssueVariant_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueVariant_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariant", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createIssueVariant_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateIssueVariant(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateIssueVariant(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateIssueVariant(rctx, fc.Args["id"].(string), fc.Args["input"].(model.IssueVariantInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueVariant) + fc.Result = res + return ec.marshalNIssueVariant2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariant(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateIssueVariant(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueVariant_id(ctx, field) + case "secondaryName": + return ec.fieldContext_IssueVariant_secondaryName(ctx, field) + case "description": + return ec.fieldContext_IssueVariant_description(ctx, field) + case "severity": + return ec.fieldContext_IssueVariant_severity(ctx, field) + case "issueRepositoryId": + return ec.fieldContext_IssueVariant_issueRepositoryId(ctx, field) + case "issueRepository": + return ec.fieldContext_IssueVariant_issueRepository(ctx, field) + case "issueId": + return ec.fieldContext_IssueVariant_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueVariant_issue(ctx, field) + case "created_at": + return ec.fieldContext_IssueVariant_created_at(ctx, field) + case "updated_at": + return ec.fieldContext_IssueVariant_updated_at(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariant", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateIssueVariant_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteIssueVariant(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteIssueVariant(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteIssueVariant(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteIssueVariant(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteIssueVariant_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createEvidence(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createEvidence(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateEvidence(rctx, fc.Args["input"].(model.EvidenceInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Evidence) + fc.Result = res + return ec.marshalNEvidence2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidence(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createEvidence(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Evidence_id(ctx, field) + case "description": + return ec.fieldContext_Evidence_description(ctx, field) + case "type": + return ec.fieldContext_Evidence_type(ctx, field) + case "vector": + return ec.fieldContext_Evidence_vector(ctx, field) + case "raaEnd": + return ec.fieldContext_Evidence_raaEnd(ctx, field) + case "authorId": + return ec.fieldContext_Evidence_authorId(ctx, field) + case "author": + return ec.fieldContext_Evidence_author(ctx, field) + case "activityId": + return ec.fieldContext_Evidence_activityId(ctx, field) + case "activity": + return ec.fieldContext_Evidence_activity(ctx, field) + case "issueMatches": + return ec.fieldContext_Evidence_issueMatches(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Evidence", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createEvidence_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateEvidence(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateEvidence(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateEvidence(rctx, fc.Args["id"].(string), fc.Args["input"].(model.EvidenceInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Evidence) + fc.Result = res + return ec.marshalNEvidence2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidence(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateEvidence(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Evidence_id(ctx, field) + case "description": + return ec.fieldContext_Evidence_description(ctx, field) + case "type": + return ec.fieldContext_Evidence_type(ctx, field) + case "vector": + return ec.fieldContext_Evidence_vector(ctx, field) + case "raaEnd": + return ec.fieldContext_Evidence_raaEnd(ctx, field) + case "authorId": + return ec.fieldContext_Evidence_authorId(ctx, field) + case "author": + return ec.fieldContext_Evidence_author(ctx, field) + case "activityId": + return ec.fieldContext_Evidence_activityId(ctx, field) + case "activity": + return ec.fieldContext_Evidence_activity(ctx, field) + case "issueMatches": + return ec.fieldContext_Evidence_issueMatches(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Evidence", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateEvidence_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteEvidence(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteEvidence(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteEvidence(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteEvidence(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteEvidence_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createIssueMatch(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createIssueMatch(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateIssueMatch(rctx, fc.Args["input"].(model.IssueMatchInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueMatch) + fc.Result = res + return ec.marshalNIssueMatch2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatch(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createIssueMatch(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueMatch_id(ctx, field) + case "status": + return ec.fieldContext_IssueMatch_status(ctx, field) + case "remediationDate": + return ec.fieldContext_IssueMatch_remediationDate(ctx, field) + case "discoveryDate": + return ec.fieldContext_IssueMatch_discoveryDate(ctx, field) + case "targetRemediationDate": + return ec.fieldContext_IssueMatch_targetRemediationDate(ctx, field) + case "severity": + return ec.fieldContext_IssueMatch_severity(ctx, field) + case "effectiveIssueVariants": + return ec.fieldContext_IssueMatch_effectiveIssueVariants(ctx, field) + case "evidences": + return ec.fieldContext_IssueMatch_evidences(ctx, field) + case "issueId": + return ec.fieldContext_IssueMatch_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueMatch_issue(ctx, field) + case "userId": + return ec.fieldContext_IssueMatch_userId(ctx, field) + case "user": + return ec.fieldContext_IssueMatch_user(ctx, field) + case "componentInstanceId": + return ec.fieldContext_IssueMatch_componentInstanceId(ctx, field) + case "componentInstance": + return ec.fieldContext_IssueMatch_componentInstance(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_IssueMatch_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatch", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createIssueMatch_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateIssueMatch(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateIssueMatch(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateIssueMatch(rctx, fc.Args["id"].(string), fc.Args["input"].(model.IssueMatchInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.IssueMatch) + fc.Result = res + return ec.marshalNIssueMatch2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatch(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateIssueMatch(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_IssueMatch_id(ctx, field) + case "status": + return ec.fieldContext_IssueMatch_status(ctx, field) + case "remediationDate": + return ec.fieldContext_IssueMatch_remediationDate(ctx, field) + case "discoveryDate": + return ec.fieldContext_IssueMatch_discoveryDate(ctx, field) + case "targetRemediationDate": + return ec.fieldContext_IssueMatch_targetRemediationDate(ctx, field) + case "severity": + return ec.fieldContext_IssueMatch_severity(ctx, field) + case "effectiveIssueVariants": + return ec.fieldContext_IssueMatch_effectiveIssueVariants(ctx, field) + case "evidences": + return ec.fieldContext_IssueMatch_evidences(ctx, field) + case "issueId": + return ec.fieldContext_IssueMatch_issueId(ctx, field) + case "issue": + return ec.fieldContext_IssueMatch_issue(ctx, field) + case "userId": + return ec.fieldContext_IssueMatch_userId(ctx, field) + case "user": + return ec.fieldContext_IssueMatch_user(ctx, field) + case "componentInstanceId": + return ec.fieldContext_IssueMatch_componentInstanceId(ctx, field) + case "componentInstance": + return ec.fieldContext_IssueMatch_componentInstance(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_IssueMatch_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatch", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateIssueMatch_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteIssueMatch(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteIssueMatch(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteIssueMatch(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteIssueMatch(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteIssueMatch_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createActivity(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createActivity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateActivity(rctx, fc.Args["input"].(model.ActivityInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Activity) + fc.Result = res + return ec.marshalNActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_createActivity(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Activity_id(ctx, field) + case "status": + return ec.fieldContext_Activity_status(ctx, field) + case "services": + return ec.fieldContext_Activity_services(ctx, field) + case "issues": + return ec.fieldContext_Activity_issues(ctx, field) + case "evidences": + return ec.fieldContext_Activity_evidences(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_Activity_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Activity", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createActivity_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateActivity(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateActivity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().UpdateActivity(rctx, fc.Args["id"].(string), fc.Args["input"].(model.ActivityInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Activity) + fc.Result = res + return ec.marshalNActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_updateActivity(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Activity_id(ctx, field) + case "status": + return ec.fieldContext_Activity_status(ctx, field) + case "services": + return ec.fieldContext_Activity_services(ctx, field) + case "issues": + return ec.fieldContext_Activity_issues(ctx, field) + case "evidences": + return ec.fieldContext_Activity_evidences(ctx, field) + case "issueMatchChanges": + return ec.fieldContext_Activity_issueMatchChanges(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Activity", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateActivity_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Mutation_deleteActivity(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_deleteActivity(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().DeleteActivity(rctx, fc.Args["id"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_deleteActivity(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_deleteActivity_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Page_after(ctx context.Context, field graphql.CollectedField, obj *model.Page) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Page_after(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.After, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Page_after(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Page", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Page_isCurrent(ctx context.Context, field graphql.CollectedField, obj *model.Page) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Page_isCurrent(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IsCurrent, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*bool) + fc.Result = res + return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Page_isCurrent(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Page", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Page_pageNumber(ctx context.Context, field graphql.CollectedField, obj *model.Page) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Page_pageNumber(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageNumber, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*int) + fc.Result = res + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Page_pageNumber(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Page", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Page_pageCount(ctx context.Context, field graphql.CollectedField, obj *model.Page) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Page_pageCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*int) + fc.Result = res + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Page_pageCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Page", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _PageInfo_hasNextPage(ctx context.Context, field graphql.CollectedField, obj *model.PageInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PageInfo_hasNextPage(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.HasNextPage, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*bool) + fc.Result = res + return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_PageInfo_hasNextPage(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PageInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _PageInfo_hasPreviousPage(ctx context.Context, field graphql.CollectedField, obj *model.PageInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.HasPreviousPage, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*bool) + fc.Result = res + return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_PageInfo_hasPreviousPage(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PageInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _PageInfo_isValidPage(ctx context.Context, field graphql.CollectedField, obj *model.PageInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PageInfo_isValidPage(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IsValidPage, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*bool) + fc.Result = res + return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_PageInfo_isValidPage(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PageInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _PageInfo_pageNumber(ctx context.Context, field graphql.CollectedField, obj *model.PageInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PageInfo_pageNumber(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageNumber, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*int) + fc.Result = res + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_PageInfo_pageNumber(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PageInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _PageInfo_nextPageAfter(ctx context.Context, field graphql.CollectedField, obj *model.PageInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.NextPageAfter, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_PageInfo_nextPageAfter(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PageInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _PageInfo_pages(ctx context.Context, field graphql.CollectedField, obj *model.PageInfo) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PageInfo_pages(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Pages, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.Page) + fc.Result = res + return ec.marshalOPage2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPage(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_PageInfo_pages(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PageInfo", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "after": + return ec.fieldContext_Page_after(ctx, field) + case "isCurrent": + return ec.fieldContext_Page_isCurrent(ctx, field) + case "pageNumber": + return ec.fieldContext_Page_pageNumber(ctx, field) + case "pageCount": + return ec.fieldContext_Page_pageCount(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Page", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _Query_Issues(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_Issues(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().Issues(rctx, fc.Args["filter"].(*model.IssueFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueConnection) + fc.Result = res + return ec.marshalOIssueConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_Issues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_Issues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_IssueMatches(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_IssueMatches(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().IssueMatches(rctx, fc.Args["filter"].(*model.IssueMatchFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchConnection) + fc.Result = res + return ec.marshalOIssueMatchConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_IssueMatches(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_IssueMatches_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_IssueMatchChanges(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_IssueMatchChanges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().IssueMatchChanges(rctx, fc.Args["filter"].(*model.IssueMatchChangeFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueMatchChangeConnection) + fc.Result = res + return ec.marshalOIssueMatchChangeConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_IssueMatchChanges(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueMatchChangeConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueMatchChangeConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueMatchChangeConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueMatchChangeConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_IssueMatchChanges_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_Services(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_Services(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().Services(rctx, fc.Args["filter"].(*model.ServiceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ServiceConnection) + fc.Result = res + return ec.marshalOServiceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_Services(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ServiceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ServiceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ServiceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ServiceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_Services_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_Components(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_Components(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().Components(rctx, fc.Args["filter"].(*model.ComponentFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentConnection) + fc.Result = res + return ec.marshalOComponentConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_Components(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ComponentConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ComponentConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ComponentConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_Components_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_ComponentVersions(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_ComponentVersions(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().ComponentVersions(rctx, fc.Args["filter"].(*model.ComponentVersionFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentVersionConnection) + fc.Result = res + return ec.marshalOComponentVersionConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_ComponentVersions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ComponentVersionConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ComponentVersionConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ComponentVersionConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentVersionConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_ComponentVersions_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_ComponentInstances(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_ComponentInstances(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().ComponentInstances(rctx, fc.Args["filter"].(*model.ComponentInstanceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentInstanceConnection) + fc.Result = res + return ec.marshalOComponentInstanceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_ComponentInstances(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ComponentInstanceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ComponentInstanceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ComponentInstanceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstanceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_ComponentInstances_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_Activities(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_Activities(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().Activities(rctx, fc.Args["filter"].(*model.ActivityFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ActivityConnection) + fc.Result = res + return ec.marshalOActivityConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_Activities(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ActivityConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ActivityConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ActivityConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ActivityConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_Activities_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_IssueVariants(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_IssueVariants(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().IssueVariants(rctx, fc.Args["filter"].(*model.IssueVariantFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueVariantConnection) + fc.Result = res + return ec.marshalOIssueVariantConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_IssueVariants(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueVariantConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueVariantConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueVariantConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueVariantConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_IssueVariants_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_IssueRepositories(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_IssueRepositories(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().IssueRepositories(rctx, fc.Args["filter"].(*model.IssueRepositoryFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueRepositoryConnection) + fc.Result = res + return ec.marshalOIssueRepositoryConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_IssueRepositories(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueRepositoryConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueRepositoryConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueRepositoryConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepositoryConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_IssueRepositories_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_Evidences(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_Evidences(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().Evidences(rctx, fc.Args["filter"].(*model.EvidenceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.EvidenceConnection) + fc.Result = res + return ec.marshalOEvidenceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_Evidences(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_EvidenceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_EvidenceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_EvidenceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EvidenceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_Evidences_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_SupportGroups(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_SupportGroups(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().SupportGroups(rctx, fc.Args["filter"].(*model.SupportGroupFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.SupportGroupConnection) + fc.Result = res + return ec.marshalOSupportGroupConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_SupportGroups(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_SupportGroupConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_SupportGroupConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_SupportGroupConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroupConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_SupportGroups_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query_Users(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_Users(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Query().Users(rctx, fc.Args["filter"].(*model.UserFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.UserConnection) + fc.Result = res + return ec.marshalOUserConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query_Users(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_UserConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_UserConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_UserConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type UserConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_Users_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query___type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.introspectType(fc.Args["name"].(string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query___type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query___type_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query___schema(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.introspectSchema() + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*introspection.Schema) + fc.Result = res + return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Query___schema(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "description": + return ec.fieldContext___Schema_description(ctx, field) + case "types": + return ec.fieldContext___Schema_types(ctx, field) + case "queryType": + return ec.fieldContext___Schema_queryType(ctx, field) + case "mutationType": + return ec.fieldContext___Schema_mutationType(ctx, field) + case "subscriptionType": + return ec.fieldContext___Schema_subscriptionType(ctx, field) + case "directives": + return ec.fieldContext___Schema_directives(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Schema", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _Service_id(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Service_name(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Service_owners(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_owners(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Service().Owners(rctx, obj, fc.Args["filter"].(*model.UserFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.UserConnection) + fc.Result = res + return ec.marshalOUserConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_owners(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_UserConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_UserConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_UserConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type UserConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Service_owners_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Service_supportGroups(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_supportGroups(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Service().SupportGroups(rctx, obj, fc.Args["filter"].(*model.SupportGroupFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.SupportGroupConnection) + fc.Result = res + return ec.marshalOSupportGroupConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_supportGroups(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_SupportGroupConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_SupportGroupConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_SupportGroupConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroupConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Service_supportGroups_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Service_activities(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_activities(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Service().Activities(rctx, obj, fc.Args["filter"].(*model.ActivityFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ActivityConnection) + fc.Result = res + return ec.marshalOActivityConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_activities(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ActivityConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ActivityConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ActivityConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ActivityConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Service_activities_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Service_issueRepositories(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_issueRepositories(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Service().IssueRepositories(rctx, obj, fc.Args["filter"].(*model.IssueRepositoryFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.IssueRepositoryConnection) + fc.Result = res + return ec.marshalOIssueRepositoryConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_issueRepositories(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_IssueRepositoryConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_IssueRepositoryConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_IssueRepositoryConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type IssueRepositoryConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Service_issueRepositories_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _Service_componentInstances(ctx context.Context, field graphql.CollectedField, obj *model.Service) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Service_componentInstances(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Service().ComponentInstances(rctx, obj, fc.Args["filter"].(*model.ComponentInstanceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ComponentInstanceConnection) + fc.Result = res + return ec.marshalOComponentInstanceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Service_componentInstances(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Service", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ComponentInstanceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ComponentInstanceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ComponentInstanceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ComponentInstanceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Service_componentInstances_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _ServiceConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.ServiceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ServiceConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ServiceConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ServiceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ServiceConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.ServiceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ServiceConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.ServiceEdge) + fc.Result = res + return ec.marshalOServiceEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ServiceConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ServiceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_ServiceEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_ServiceEdge_cursor(ctx, field) + case "priority": + return ec.fieldContext_ServiceEdge_priority(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ServiceEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ServiceConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.ServiceConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ServiceConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ServiceConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ServiceConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ServiceEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.ServiceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ServiceEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.Service) + fc.Result = res + return ec.marshalNService2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ServiceEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ServiceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Service_id(ctx, field) + case "name": + return ec.fieldContext_Service_name(ctx, field) + case "owners": + return ec.fieldContext_Service_owners(ctx, field) + case "supportGroups": + return ec.fieldContext_Service_supportGroups(ctx, field) + case "activities": + return ec.fieldContext_Service_activities(ctx, field) + case "issueRepositories": + return ec.fieldContext_Service_issueRepositories(ctx, field) + case "componentInstances": + return ec.fieldContext_Service_componentInstances(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Service", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _ServiceEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.ServiceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ServiceEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ServiceEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ServiceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ServiceEdge_priority(ctx context.Context, field graphql.CollectedField, obj *model.ServiceEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ServiceEdge_priority(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Priority, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*int) + fc.Result = res + return ec.marshalOInt2ᚖint(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_ServiceEdge_priority(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ServiceEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Severity_value(ctx context.Context, field graphql.CollectedField, obj *model.Severity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Severity_value(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Value, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.SeverityValues) + fc.Result = res + return ec.marshalOSeverityValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Severity_value(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Severity", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type SeverityValues does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Severity_score(ctx context.Context, field graphql.CollectedField, obj *model.Severity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Severity_score(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Score, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*float64) + fc.Result = res + return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Severity_score(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Severity", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _Severity_cvss(ctx context.Context, field graphql.CollectedField, obj *model.Severity) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Severity_cvss(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cvss, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.Cvss) + fc.Result = res + return ec.marshalOCVSS2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCvss(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Severity_cvss(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Severity", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "vector": + return ec.fieldContext_CVSS_vector(ctx, field) + case "base": + return ec.fieldContext_CVSS_base(ctx, field) + case "temporal": + return ec.fieldContext_CVSS_temporal(ctx, field) + case "environmental": + return ec.fieldContext_CVSS_environmental(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type CVSS", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroup_id(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroup) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroup_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroup_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroup", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroup_name(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroup) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroup_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroup_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroup", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroup_users(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroup) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroup_users(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.SupportGroup().Users(rctx, obj, fc.Args["filter"].(*model.UserFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.UserConnection) + fc.Result = res + return ec.marshalOUserConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroup_users(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroup", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_UserConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_UserConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_UserConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type UserConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_SupportGroup_users_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _SupportGroup_services(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroup) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroup_services(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.SupportGroup().Services(rctx, obj, fc.Args["filter"].(*model.ServiceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ServiceConnection) + fc.Result = res + return ec.marshalOServiceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroup_services(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroup", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ServiceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ServiceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ServiceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ServiceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_SupportGroup_services_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _SupportGroupConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroupConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroupConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroupConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroupConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroupConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroupConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroupConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.SupportGroupEdge) + fc.Result = res + return ec.marshalOSupportGroupEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroupConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroupConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_SupportGroupEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_SupportGroupEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroupEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroupConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroupConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroupConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroupConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroupConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroupEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroupEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroupEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.SupportGroup) + fc.Result = res + return ec.marshalNSupportGroup2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroup(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroupEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroupEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_SupportGroup_id(ctx, field) + case "name": + return ec.fieldContext_SupportGroup_name(ctx, field) + case "users": + return ec.fieldContext_SupportGroup_users(ctx, field) + case "services": + return ec.fieldContext_SupportGroup_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroup", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _SupportGroupEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.SupportGroupEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SupportGroupEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SupportGroupEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SupportGroupEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _User_id(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.ID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNID2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_User_id(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _User_sapID(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_sapID(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.SapID, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_User_sapID(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _User_name(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_User_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _User_supportGroups(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_supportGroups(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.User().SupportGroups(rctx, obj, fc.Args["filter"].(*model.SupportGroupFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.SupportGroupConnection) + fc.Result = res + return ec.marshalOSupportGroupConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_User_supportGroups(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_SupportGroupConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_SupportGroupConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_SupportGroupConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SupportGroupConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_User_supportGroups_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _User_services(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_services(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.User().Services(rctx, obj, fc.Args["filter"].(*model.ServiceFilter), fc.Args["first"].(*int), fc.Args["after"].(*string)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.ServiceConnection) + fc.Result = res + return ec.marshalOServiceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceConnection(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_User_services(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "totalCount": + return ec.fieldContext_ServiceConnection_totalCount(ctx, field) + case "edges": + return ec.fieldContext_ServiceConnection_edges(ctx, field) + case "pageInfo": + return ec.fieldContext_ServiceConnection_pageInfo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ServiceConnection", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_User_services_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) _UserConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *model.UserConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_UserConnection_totalCount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.TotalCount, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(int) + fc.Result = res + return ec.marshalNInt2int(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_UserConnection_totalCount(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "UserConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _UserConnection_edges(ctx context.Context, field graphql.CollectedField, obj *model.UserConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_UserConnection_edges(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Edges, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]*model.UserEdge) + fc.Result = res + return ec.marshalOUserEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserEdge(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_UserConnection_edges(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "UserConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "node": + return ec.fieldContext_UserEdge_node(ctx, field) + case "cursor": + return ec.fieldContext_UserEdge_cursor(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type UserEdge", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _UserConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *model.UserConnection) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_UserConnection_pageInfo(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PageInfo, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*model.PageInfo) + fc.Result = res + return ec.marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_UserConnection_pageInfo(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "UserConnection", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "hasNextPage": + return ec.fieldContext_PageInfo_hasNextPage(ctx, field) + case "hasPreviousPage": + return ec.fieldContext_PageInfo_hasPreviousPage(ctx, field) + case "isValidPage": + return ec.fieldContext_PageInfo_isValidPage(ctx, field) + case "pageNumber": + return ec.fieldContext_PageInfo_pageNumber(ctx, field) + case "nextPageAfter": + return ec.fieldContext_PageInfo_nextPageAfter(ctx, field) + case "pages": + return ec.fieldContext_PageInfo_pages(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PageInfo", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _UserEdge_node(ctx context.Context, field graphql.CollectedField, obj *model.UserEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_UserEdge_node(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Node, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*model.User) + fc.Result = res + return ec.marshalNUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_UserEdge_node(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "UserEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "sapID": + return ec.fieldContext_User_sapID(ctx, field) + case "name": + return ec.fieldContext_User_name(ctx, field) + case "supportGroups": + return ec.fieldContext_User_supportGroups(ctx, field) + case "services": + return ec.fieldContext_User_services(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) _UserEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *model.UserEdge) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_UserEdge_cursor(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Cursor, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_UserEdge_cursor(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "UserEdge", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Directive_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Directive_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_locations(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Locations, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]string) + fc.Result = res + return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Directive_locations(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type __DirectiveLocation does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_args(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Args, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]introspection.InputValue) + fc.Result = res + return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Directive_args(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___InputValue_name(ctx, field) + case "description": + return ec.fieldContext___InputValue_description(ctx, field) + case "type": + return ec.fieldContext___InputValue_type(ctx, field) + case "defaultValue": + return ec.fieldContext___InputValue_defaultValue(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_isRepeatable(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IsRepeatable, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(bool) + fc.Result = res + return ec.marshalNBoolean2bool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Directive_isRepeatable(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___EnumValue_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__EnumValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___EnumValue_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__EnumValue", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_isDeprecated(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IsDeprecated(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(bool) + fc.Result = res + return ec.marshalNBoolean2bool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___EnumValue_isDeprecated(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__EnumValue", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_deprecationReason(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.DeprecationReason(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___EnumValue_deprecationReason(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__EnumValue", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Field_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Field_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_args(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Args, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]introspection.InputValue) + fc.Result = res + return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Field_args(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___InputValue_name(ctx, field) + case "description": + return ec.fieldContext___InputValue_description(ctx, field) + case "type": + return ec.fieldContext___InputValue_type(ctx, field) + case "defaultValue": + return ec.fieldContext___InputValue_defaultValue(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Field_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_isDeprecated(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.IsDeprecated(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(bool) + fc.Result = res + return ec.marshalNBoolean2bool(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Field_isDeprecated(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_deprecationReason(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.DeprecationReason(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Field_deprecationReason(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___InputValue_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___InputValue_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Type, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___InputValue_type(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_defaultValue(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.DefaultValue, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___InputValue_defaultValue(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Schema_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_types(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Types(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]introspection.Type) + fc.Result = res + return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_types(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_queryType(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.QueryType(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_queryType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_mutationType(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.MutationType(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_mutationType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_subscriptionType(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.SubscriptionType(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_subscriptionType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_directives(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Directives(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.([]introspection.Directive) + fc.Result = res + return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_directives(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___Directive_name(ctx, field) + case "description": + return ec.fieldContext___Directive_description(ctx, field) + case "locations": + return ec.fieldContext___Directive_locations(ctx, field) + case "args": + return ec.fieldContext___Directive_args(ctx, field) + case "isRepeatable": + return ec.fieldContext___Directive_isRepeatable(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Directive", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_kind(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Kind(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(string) + fc.Result = res + return ec.marshalN__TypeKind2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_kind(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type __TypeKind does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Name(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_name(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Description(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_description(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_fields(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Fields(fc.Args["includeDeprecated"].(bool)), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]introspection.Field) + fc.Result = res + return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_fields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___Field_name(ctx, field) + case "description": + return ec.fieldContext___Field_description(ctx, field) + case "args": + return ec.fieldContext___Field_args(ctx, field) + case "type": + return ec.fieldContext___Field_type(ctx, field) + case "isDeprecated": + return ec.fieldContext___Field_isDeprecated(ctx, field) + case "deprecationReason": + return ec.fieldContext___Field_deprecationReason(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Field", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field___Type_fields_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_interfaces(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.Interfaces(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_interfaces(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_possibleTypes(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.PossibleTypes(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_possibleTypes(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_enumValues(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.EnumValues(fc.Args["includeDeprecated"].(bool)), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]introspection.EnumValue) + fc.Result = res + return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_enumValues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___EnumValue_name(ctx, field) + case "description": + return ec.fieldContext___EnumValue_description(ctx, field) + case "isDeprecated": + return ec.fieldContext___EnumValue_isDeprecated(ctx, field) + case "deprecationReason": + return ec.fieldContext___EnumValue_deprecationReason(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __EnumValue", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field___Type_enumValues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return fc, err + } + return fc, nil +} + +func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_inputFields(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.InputFields(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.([]introspection.InputValue) + fc.Result = res + return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_inputFields(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___InputValue_name(ctx, field) + case "description": + return ec.fieldContext___InputValue_description(ctx, field) + case "type": + return ec.fieldContext___InputValue_type(ctx, field) + case "defaultValue": + return ec.fieldContext___InputValue_defaultValue(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_ofType(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.OfType(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_ofType(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + +func (ec *executionContext) ___Type_specifiedByURL(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_specifiedByURL(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.SpecifiedByURL(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_specifiedByURL(_ context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +// endregion **************************** field.gotpl ***************************** + +// region **************************** input.gotpl ***************************** + +func (ec *executionContext) unmarshalInputActivityFilter(ctx context.Context, obj interface{}) (model.ActivityFilter, error) { + var it model.ActivityFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"serviceName", "status"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "serviceName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("serviceName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ServiceName = data + case "status": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("status")) + data, err := ec.unmarshalOActivityStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx, v) + if err != nil { + return it, err + } + it.Status = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputActivityInput(ctx context.Context, obj interface{}) (model.ActivityInput, error) { + var it model.ActivityInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"status"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "status": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("status")) + data, err := ec.unmarshalOActivityStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx, v) + if err != nil { + return it, err + } + it.Status = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputComponentFilter(ctx context.Context, obj interface{}) (model.ComponentFilter, error) { + var it model.ComponentFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"componentName"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "componentName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("componentName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ComponentName = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputComponentInput(ctx context.Context, obj interface{}) (model.ComponentInput, error) { + var it model.ComponentInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"name", "type"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "name": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Name = data + case "type": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("type")) + data, err := ec.unmarshalOComponentTypeValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentTypeValues(ctx, v) + if err != nil { + return it, err + } + it.Type = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputComponentInstanceFilter(ctx context.Context, obj interface{}) (model.ComponentInstanceFilter, error) { + var it model.ComponentInstanceFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"issueMatchId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "issueMatchId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueMatchId")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.IssueMatchID = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputComponentInstanceInput(ctx context.Context, obj interface{}) (model.ComponentInstanceInput, error) { + var it model.ComponentInstanceInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"ccrn", "count", "componentVersionId", "serviceId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "ccrn": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ccrn")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Ccrn = data + case "count": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("count")) + data, err := ec.unmarshalOInt2ᚖint(ctx, v) + if err != nil { + return it, err + } + it.Count = data + case "componentVersionId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("componentVersionId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ComponentVersionID = data + case "serviceId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("serviceId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ServiceID = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputComponentVersionFilter(ctx context.Context, obj interface{}) (model.ComponentVersionFilter, error) { + var it model.ComponentVersionFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"issueId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "issueId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueId")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.IssueID = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputComponentVersionInput(ctx context.Context, obj interface{}) (model.ComponentVersionInput, error) { + var it model.ComponentVersionInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"version", "componentId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "version": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("version")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Version = data + case "componentId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("componentId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ComponentID = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputDateTimeFilter(ctx context.Context, obj interface{}) (model.DateTimeFilter, error) { + var it model.DateTimeFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"after", "before"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "after": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("after")) + data, err := ec.unmarshalODateTime2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.After = data + case "before": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("before")) + data, err := ec.unmarshalODateTime2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Before = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputEvidenceFilter(ctx context.Context, obj interface{}) (model.EvidenceFilter, error) { + var it model.EvidenceFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"placeholder"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "placeholder": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("placeholder")) + data, err := ec.unmarshalOBoolean2ᚕᚖbool(ctx, v) + if err != nil { + return it, err + } + it.Placeholder = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputEvidenceInput(ctx context.Context, obj interface{}) (model.EvidenceInput, error) { + var it model.EvidenceInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"description", "type", "raaEnd", "authorId", "activityId", "severity"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "description": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Description = data + case "type": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("type")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Type = data + case "raaEnd": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("raaEnd")) + data, err := ec.unmarshalODateTime2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.RaaEnd = data + case "authorId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("authorId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.AuthorID = data + case "activityId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("activityId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ActivityID = data + case "severity": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("severity")) + data, err := ec.unmarshalOSeverityInput2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityInput(ctx, v) + if err != nil { + return it, err + } + it.Severity = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueFilter(ctx context.Context, obj interface{}) (model.IssueFilter, error) { + var it model.IssueFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"affectedService", "primaryName", "issueMatchStatus", "issueType", "componentVersionId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "affectedService": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("affectedService")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.AffectedService = data + case "primaryName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("primaryName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.PrimaryName = data + case "issueMatchStatus": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueMatchStatus")) + data, err := ec.unmarshalOIssueMatchStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx, v) + if err != nil { + return it, err + } + it.IssueMatchStatus = data + case "issueType": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueType")) + data, err := ec.unmarshalOIssueTypes2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx, v) + if err != nil { + return it, err + } + it.IssueType = data + case "componentVersionId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("componentVersionId")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ComponentVersionID = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueMatchChangeFilter(ctx context.Context, obj interface{}) (model.IssueMatchChangeFilter, error) { + var it model.IssueMatchChangeFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"action"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "action": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("action")) + data, err := ec.unmarshalOIssueMatchChangeActions2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx, v) + if err != nil { + return it, err + } + it.Action = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueMatchFilter(ctx context.Context, obj interface{}) (model.IssueMatchFilter, error) { + var it model.IssueMatchFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"status", "severity", "affectedService", "SupportGroupName"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "status": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("status")) + data, err := ec.unmarshalOIssueMatchStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx, v) + if err != nil { + return it, err + } + it.Status = data + case "severity": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("severity")) + data, err := ec.unmarshalOSeverityValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx, v) + if err != nil { + return it, err + } + it.Severity = data + case "affectedService": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("affectedService")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.AffectedService = data + case "SupportGroupName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("SupportGroupName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SupportGroupName = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueMatchInput(ctx context.Context, obj interface{}) (model.IssueMatchInput, error) { + var it model.IssueMatchInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"status", "remediationDate", "discoveryDate", "targetRemediationDate", "issueId", "componentInstanceId", "userId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "status": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("status")) + data, err := ec.unmarshalOIssueMatchStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx, v) + if err != nil { + return it, err + } + it.Status = data + case "remediationDate": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("remediationDate")) + data, err := ec.unmarshalODateTime2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.RemediationDate = data + case "discoveryDate": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("discoveryDate")) + data, err := ec.unmarshalODateTime2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.DiscoveryDate = data + case "targetRemediationDate": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("targetRemediationDate")) + data, err := ec.unmarshalODateTime2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.TargetRemediationDate = data + case "issueId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.IssueID = data + case "componentInstanceId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("componentInstanceId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ComponentInstanceID = data + case "userId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("userId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.UserID = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueRepositoryFilter(ctx context.Context, obj interface{}) (model.IssueRepositoryFilter, error) { + var it model.IssueRepositoryFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"serviceName", "serviceId", "name"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "serviceName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("serviceName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ServiceName = data + case "serviceId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("serviceId")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ServiceID = data + case "name": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Name = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueRepositoryInput(ctx context.Context, obj interface{}) (model.IssueRepositoryInput, error) { + var it model.IssueRepositoryInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"name", "url"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "name": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Name = data + case "url": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("url")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.URL = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueVariantFilter(ctx context.Context, obj interface{}) (model.IssueVariantFilter, error) { + var it model.IssueVariantFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"secondaryName"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "secondaryName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("secondaryName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SecondaryName = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputIssueVariantInput(ctx context.Context, obj interface{}) (model.IssueVariantInput, error) { + var it model.IssueVariantInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"secondaryName", "description", "issueRepositoryId", "issueId", "severity"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "secondaryName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("secondaryName")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SecondaryName = data + case "description": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("description")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Description = data + case "issueRepositoryId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueRepositoryId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.IssueRepositoryID = data + case "issueId": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("issueId")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.IssueID = data + case "severity": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("severity")) + data, err := ec.unmarshalOSeverityInput2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityInput(ctx, v) + if err != nil { + return it, err + } + it.Severity = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputServiceFilter(ctx context.Context, obj interface{}) (model.ServiceFilter, error) { + var it model.ServiceFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"serviceName", "userSapID", "userName", "supportGroupName"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "serviceName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("serviceName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.ServiceName = data + case "userSapID": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("userSapID")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.UserSapID = data + case "userName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("userName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.UserName = data + case "supportGroupName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("supportGroupName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SupportGroupName = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputServiceInput(ctx context.Context, obj interface{}) (model.ServiceInput, error) { + var it model.ServiceInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"name"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "name": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Name = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputSeverityInput(ctx context.Context, obj interface{}) (model.SeverityInput, error) { + var it model.SeverityInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"vector"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "vector": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("vector")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Vector = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputSupportGroupFilter(ctx context.Context, obj interface{}) (model.SupportGroupFilter, error) { + var it model.SupportGroupFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"supportGroupName", "userIds"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "supportGroupName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("supportGroupName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SupportGroupName = data + case "userIds": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("userIds")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.UserIds = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputSupportGroupInput(ctx context.Context, obj interface{}) (model.SupportGroupInput, error) { + var it model.SupportGroupInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"name"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "name": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Name = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputUserFilter(ctx context.Context, obj interface{}) (model.UserFilter, error) { + var it model.UserFilter + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"userName", "supportGroupIds"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "userName": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("userName")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.UserName = data + case "supportGroupIds": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("supportGroupIds")) + data, err := ec.unmarshalOString2ᚕᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SupportGroupIds = data + } + } + + return it, nil +} + +func (ec *executionContext) unmarshalInputUserInput(ctx context.Context, obj interface{}) (model.UserInput, error) { + var it model.UserInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"sapID", "name"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "sapID": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("sapID")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.SapID = data + case "name": + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name")) + data, err := ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + it.Name = data + } + } + + return it, nil +} + +// endregion **************************** input.gotpl ***************************** + +// region ************************** interface.gotpl *************************** + +func (ec *executionContext) _Connection(ctx context.Context, sel ast.SelectionSet, obj model.Connection) graphql.Marshaler { + switch obj := (obj).(type) { + case nil: + return graphql.Null + case model.ActivityConnection: + return ec._ActivityConnection(ctx, sel, &obj) + case *model.ActivityConnection: + if obj == nil { + return graphql.Null + } + return ec._ActivityConnection(ctx, sel, obj) + case model.ComponentConnection: + return ec._ComponentConnection(ctx, sel, &obj) + case *model.ComponentConnection: + if obj == nil { + return graphql.Null + } + return ec._ComponentConnection(ctx, sel, obj) + case model.ComponentInstanceConnection: + return ec._ComponentInstanceConnection(ctx, sel, &obj) + case *model.ComponentInstanceConnection: + if obj == nil { + return graphql.Null + } + return ec._ComponentInstanceConnection(ctx, sel, obj) + case model.ComponentVersionConnection: + return ec._ComponentVersionConnection(ctx, sel, &obj) + case *model.ComponentVersionConnection: + if obj == nil { + return graphql.Null + } + return ec._ComponentVersionConnection(ctx, sel, obj) + case model.EvidenceConnection: + return ec._EvidenceConnection(ctx, sel, &obj) + case *model.EvidenceConnection: + if obj == nil { + return graphql.Null + } + return ec._EvidenceConnection(ctx, sel, obj) + case model.IssueConnection: + return ec._IssueConnection(ctx, sel, &obj) + case *model.IssueConnection: + if obj == nil { + return graphql.Null + } + return ec._IssueConnection(ctx, sel, obj) + case model.IssueMatchConnection: + return ec._IssueMatchConnection(ctx, sel, &obj) + case *model.IssueMatchConnection: + if obj == nil { + return graphql.Null + } + return ec._IssueMatchConnection(ctx, sel, obj) + case model.IssueMatchChangeConnection: + return ec._IssueMatchChangeConnection(ctx, sel, &obj) + case *model.IssueMatchChangeConnection: + if obj == nil { + return graphql.Null + } + return ec._IssueMatchChangeConnection(ctx, sel, obj) + case model.IssueRepositoryConnection: + return ec._IssueRepositoryConnection(ctx, sel, &obj) + case *model.IssueRepositoryConnection: + if obj == nil { + return graphql.Null + } + return ec._IssueRepositoryConnection(ctx, sel, obj) + case model.IssueVariantConnection: + return ec._IssueVariantConnection(ctx, sel, &obj) + case *model.IssueVariantConnection: + if obj == nil { + return graphql.Null + } + return ec._IssueVariantConnection(ctx, sel, obj) + case model.ServiceConnection: + return ec._ServiceConnection(ctx, sel, &obj) + case *model.ServiceConnection: + if obj == nil { + return graphql.Null + } + return ec._ServiceConnection(ctx, sel, obj) + case model.SupportGroupConnection: + return ec._SupportGroupConnection(ctx, sel, &obj) + case *model.SupportGroupConnection: + if obj == nil { + return graphql.Null + } + return ec._SupportGroupConnection(ctx, sel, obj) + case model.UserConnection: + return ec._UserConnection(ctx, sel, &obj) + case *model.UserConnection: + if obj == nil { + return graphql.Null + } + return ec._UserConnection(ctx, sel, obj) + default: + panic(fmt.Errorf("unexpected type %T", obj)) + } +} + +func (ec *executionContext) _Edge(ctx context.Context, sel ast.SelectionSet, obj model.Edge) graphql.Marshaler { + switch obj := (obj).(type) { + case nil: + return graphql.Null + case model.ActivityEdge: + return ec._ActivityEdge(ctx, sel, &obj) + case *model.ActivityEdge: + if obj == nil { + return graphql.Null + } + return ec._ActivityEdge(ctx, sel, obj) + case model.ComponentEdge: + return ec._ComponentEdge(ctx, sel, &obj) + case *model.ComponentEdge: + if obj == nil { + return graphql.Null + } + return ec._ComponentEdge(ctx, sel, obj) + case model.ComponentInstanceEdge: + return ec._ComponentInstanceEdge(ctx, sel, &obj) + case *model.ComponentInstanceEdge: + if obj == nil { + return graphql.Null + } + return ec._ComponentInstanceEdge(ctx, sel, obj) + case model.ComponentVersionEdge: + return ec._ComponentVersionEdge(ctx, sel, &obj) + case *model.ComponentVersionEdge: + if obj == nil { + return graphql.Null + } + return ec._ComponentVersionEdge(ctx, sel, obj) + case model.EvidenceEdge: + return ec._EvidenceEdge(ctx, sel, &obj) + case *model.EvidenceEdge: + if obj == nil { + return graphql.Null + } + return ec._EvidenceEdge(ctx, sel, obj) + case model.IssueEdge: + return ec._IssueEdge(ctx, sel, &obj) + case *model.IssueEdge: + if obj == nil { + return graphql.Null + } + return ec._IssueEdge(ctx, sel, obj) + case model.IssueMatchEdge: + return ec._IssueMatchEdge(ctx, sel, &obj) + case *model.IssueMatchEdge: + if obj == nil { + return graphql.Null + } + return ec._IssueMatchEdge(ctx, sel, obj) + case model.IssueMatchChangeEdge: + return ec._IssueMatchChangeEdge(ctx, sel, &obj) + case *model.IssueMatchChangeEdge: + if obj == nil { + return graphql.Null + } + return ec._IssueMatchChangeEdge(ctx, sel, obj) + case model.IssueRepositoryEdge: + return ec._IssueRepositoryEdge(ctx, sel, &obj) + case *model.IssueRepositoryEdge: + if obj == nil { + return graphql.Null + } + return ec._IssueRepositoryEdge(ctx, sel, obj) + case model.IssueVariantEdge: + return ec._IssueVariantEdge(ctx, sel, &obj) + case *model.IssueVariantEdge: + if obj == nil { + return graphql.Null + } + return ec._IssueVariantEdge(ctx, sel, obj) + case model.ServiceEdge: + return ec._ServiceEdge(ctx, sel, &obj) + case *model.ServiceEdge: + if obj == nil { + return graphql.Null + } + return ec._ServiceEdge(ctx, sel, obj) + case model.SupportGroupEdge: + return ec._SupportGroupEdge(ctx, sel, &obj) + case *model.SupportGroupEdge: + if obj == nil { + return graphql.Null + } + return ec._SupportGroupEdge(ctx, sel, obj) + case model.UserEdge: + return ec._UserEdge(ctx, sel, &obj) + case *model.UserEdge: + if obj == nil { + return graphql.Null + } + return ec._UserEdge(ctx, sel, obj) + default: + panic(fmt.Errorf("unexpected type %T", obj)) + } +} + +func (ec *executionContext) _Node(ctx context.Context, sel ast.SelectionSet, obj model.Node) graphql.Marshaler { + switch obj := (obj).(type) { + case nil: + return graphql.Null + case model.Activity: + return ec._Activity(ctx, sel, &obj) + case *model.Activity: + if obj == nil { + return graphql.Null + } + return ec._Activity(ctx, sel, obj) + case model.Component: + return ec._Component(ctx, sel, &obj) + case *model.Component: + if obj == nil { + return graphql.Null + } + return ec._Component(ctx, sel, obj) + case model.ComponentInstance: + return ec._ComponentInstance(ctx, sel, &obj) + case *model.ComponentInstance: + if obj == nil { + return graphql.Null + } + return ec._ComponentInstance(ctx, sel, obj) + case model.ComponentVersion: + return ec._ComponentVersion(ctx, sel, &obj) + case *model.ComponentVersion: + if obj == nil { + return graphql.Null + } + return ec._ComponentVersion(ctx, sel, obj) + case model.Evidence: + return ec._Evidence(ctx, sel, &obj) + case *model.Evidence: + if obj == nil { + return graphql.Null + } + return ec._Evidence(ctx, sel, obj) + case model.Issue: + return ec._Issue(ctx, sel, &obj) + case *model.Issue: + if obj == nil { + return graphql.Null + } + return ec._Issue(ctx, sel, obj) + case model.IssueMatch: + return ec._IssueMatch(ctx, sel, &obj) + case *model.IssueMatch: + if obj == nil { + return graphql.Null + } + return ec._IssueMatch(ctx, sel, obj) + case model.IssueMatchChange: + return ec._IssueMatchChange(ctx, sel, &obj) + case *model.IssueMatchChange: + if obj == nil { + return graphql.Null + } + return ec._IssueMatchChange(ctx, sel, obj) + case model.IssueRepository: + return ec._IssueRepository(ctx, sel, &obj) + case *model.IssueRepository: + if obj == nil { + return graphql.Null + } + return ec._IssueRepository(ctx, sel, obj) + case model.IssueVariant: + return ec._IssueVariant(ctx, sel, &obj) + case *model.IssueVariant: + if obj == nil { + return graphql.Null + } + return ec._IssueVariant(ctx, sel, obj) + case model.Service: + return ec._Service(ctx, sel, &obj) + case *model.Service: + if obj == nil { + return graphql.Null + } + return ec._Service(ctx, sel, obj) + case model.SupportGroup: + return ec._SupportGroup(ctx, sel, &obj) + case *model.SupportGroup: + if obj == nil { + return graphql.Null + } + return ec._SupportGroup(ctx, sel, obj) + case model.User: + return ec._User(ctx, sel, &obj) + case *model.User: + if obj == nil { + return graphql.Null + } + return ec._User(ctx, sel, obj) + default: + panic(fmt.Errorf("unexpected type %T", obj)) + } +} + +// endregion ************************** interface.gotpl *************************** + +// region **************************** object.gotpl **************************** + +var activityImplementors = []string{"Activity", "Node"} + +func (ec *executionContext) _Activity(ctx context.Context, sel ast.SelectionSet, obj *model.Activity) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, activityImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Activity") + case "id": + out.Values[i] = ec._Activity_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "status": + out.Values[i] = ec._Activity_status(ctx, field, obj) + case "services": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Activity_services(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issues": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Activity_issues(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "evidences": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Activity_evidences(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueMatchChanges": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Activity_issueMatchChanges(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var activityConnectionImplementors = []string{"ActivityConnection", "Connection"} + +func (ec *executionContext) _ActivityConnection(ctx context.Context, sel ast.SelectionSet, obj *model.ActivityConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, activityConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ActivityConnection") + case "totalCount": + out.Values[i] = ec._ActivityConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._ActivityConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._ActivityConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var activityEdgeImplementors = []string{"ActivityEdge", "Edge"} + +func (ec *executionContext) _ActivityEdge(ctx context.Context, sel ast.SelectionSet, obj *model.ActivityEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, activityEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ActivityEdge") + case "node": + out.Values[i] = ec._ActivityEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._ActivityEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var cVSSImplementors = []string{"CVSS"} + +func (ec *executionContext) _CVSS(ctx context.Context, sel ast.SelectionSet, obj *model.Cvss) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, cVSSImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("CVSS") + case "vector": + out.Values[i] = ec._CVSS_vector(ctx, field, obj) + case "base": + out.Values[i] = ec._CVSS_base(ctx, field, obj) + case "temporal": + out.Values[i] = ec._CVSS_temporal(ctx, field, obj) + case "environmental": + out.Values[i] = ec._CVSS_environmental(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var cVSSBaseImplementors = []string{"CVSSBase"} + +func (ec *executionContext) _CVSSBase(ctx context.Context, sel ast.SelectionSet, obj *model.CVSSBase) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, cVSSBaseImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("CVSSBase") + case "score": + out.Values[i] = ec._CVSSBase_score(ctx, field, obj) + case "attackVector": + out.Values[i] = ec._CVSSBase_attackVector(ctx, field, obj) + case "attackComplexity": + out.Values[i] = ec._CVSSBase_attackComplexity(ctx, field, obj) + case "privilegesRequired": + out.Values[i] = ec._CVSSBase_privilegesRequired(ctx, field, obj) + case "userInteraction": + out.Values[i] = ec._CVSSBase_userInteraction(ctx, field, obj) + case "scope": + out.Values[i] = ec._CVSSBase_scope(ctx, field, obj) + case "confidentialityImpact": + out.Values[i] = ec._CVSSBase_confidentialityImpact(ctx, field, obj) + case "integrityImpact": + out.Values[i] = ec._CVSSBase_integrityImpact(ctx, field, obj) + case "availabilityImpact": + out.Values[i] = ec._CVSSBase_availabilityImpact(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var cVSSEnvironmentalImplementors = []string{"CVSSEnvironmental"} + +func (ec *executionContext) _CVSSEnvironmental(ctx context.Context, sel ast.SelectionSet, obj *model.CVSSEnvironmental) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, cVSSEnvironmentalImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("CVSSEnvironmental") + case "score": + out.Values[i] = ec._CVSSEnvironmental_score(ctx, field, obj) + case "modifiedAttackVector": + out.Values[i] = ec._CVSSEnvironmental_modifiedAttackVector(ctx, field, obj) + case "modifiedAttackComplexity": + out.Values[i] = ec._CVSSEnvironmental_modifiedAttackComplexity(ctx, field, obj) + case "modifiedPrivilegesRequired": + out.Values[i] = ec._CVSSEnvironmental_modifiedPrivilegesRequired(ctx, field, obj) + case "modifiedUserInteraction": + out.Values[i] = ec._CVSSEnvironmental_modifiedUserInteraction(ctx, field, obj) + case "modifiedScope": + out.Values[i] = ec._CVSSEnvironmental_modifiedScope(ctx, field, obj) + case "modifiedConfidentialityImpact": + out.Values[i] = ec._CVSSEnvironmental_modifiedConfidentialityImpact(ctx, field, obj) + case "modifiedIntegrityImpact": + out.Values[i] = ec._CVSSEnvironmental_modifiedIntegrityImpact(ctx, field, obj) + case "modifiedAvailabilityImpact": + out.Values[i] = ec._CVSSEnvironmental_modifiedAvailabilityImpact(ctx, field, obj) + case "confidentialityRequirement": + out.Values[i] = ec._CVSSEnvironmental_confidentialityRequirement(ctx, field, obj) + case "availabilityRequirement": + out.Values[i] = ec._CVSSEnvironmental_availabilityRequirement(ctx, field, obj) + case "integrityRequirement": + out.Values[i] = ec._CVSSEnvironmental_integrityRequirement(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var cVSSParameterImplementors = []string{"CVSSParameter"} + +func (ec *executionContext) _CVSSParameter(ctx context.Context, sel ast.SelectionSet, obj *model.CVSSParameter) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, cVSSParameterImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("CVSSParameter") + case "name": + out.Values[i] = ec._CVSSParameter_name(ctx, field, obj) + case "value": + out.Values[i] = ec._CVSSParameter_value(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var cVSSTemporalImplementors = []string{"CVSSTemporal"} + +func (ec *executionContext) _CVSSTemporal(ctx context.Context, sel ast.SelectionSet, obj *model.CVSSTemporal) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, cVSSTemporalImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("CVSSTemporal") + case "score": + out.Values[i] = ec._CVSSTemporal_score(ctx, field, obj) + case "exploitCodeMaturity": + out.Values[i] = ec._CVSSTemporal_exploitCodeMaturity(ctx, field, obj) + case "remediationLevel": + out.Values[i] = ec._CVSSTemporal_remediationLevel(ctx, field, obj) + case "reportConfidence": + out.Values[i] = ec._CVSSTemporal_reportConfidence(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentImplementors = []string{"Component", "Node"} + +func (ec *executionContext) _Component(ctx context.Context, sel ast.SelectionSet, obj *model.Component) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Component") + case "id": + out.Values[i] = ec._Component_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "name": + out.Values[i] = ec._Component_name(ctx, field, obj) + case "type": + out.Values[i] = ec._Component_type(ctx, field, obj) + case "componentVersions": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Component_componentVersions(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentConnectionImplementors = []string{"ComponentConnection", "Connection"} + +func (ec *executionContext) _ComponentConnection(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentConnection") + case "totalCount": + out.Values[i] = ec._ComponentConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._ComponentConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._ComponentConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentEdgeImplementors = []string{"ComponentEdge", "Edge"} + +func (ec *executionContext) _ComponentEdge(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentEdge") + case "node": + out.Values[i] = ec._ComponentEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._ComponentEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentInstanceImplementors = []string{"ComponentInstance", "Node"} + +func (ec *executionContext) _ComponentInstance(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentInstance) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentInstanceImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentInstance") + case "id": + out.Values[i] = ec._ComponentInstance_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "ccrn": + out.Values[i] = ec._ComponentInstance_ccrn(ctx, field, obj) + case "count": + out.Values[i] = ec._ComponentInstance_count(ctx, field, obj) + case "componentVersionId": + out.Values[i] = ec._ComponentInstance_componentVersionId(ctx, field, obj) + case "componentVersion": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._ComponentInstance_componentVersion(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueMatches": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._ComponentInstance_issueMatches(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "serviceId": + out.Values[i] = ec._ComponentInstance_serviceId(ctx, field, obj) + case "service": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._ComponentInstance_service(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "createdAt": + out.Values[i] = ec._ComponentInstance_createdAt(ctx, field, obj) + case "updatedAt": + out.Values[i] = ec._ComponentInstance_updatedAt(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentInstanceConnectionImplementors = []string{"ComponentInstanceConnection", "Connection"} + +func (ec *executionContext) _ComponentInstanceConnection(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentInstanceConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentInstanceConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentInstanceConnection") + case "totalCount": + out.Values[i] = ec._ComponentInstanceConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._ComponentInstanceConnection_edges(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "pageInfo": + out.Values[i] = ec._ComponentInstanceConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentInstanceEdgeImplementors = []string{"ComponentInstanceEdge", "Edge"} + +func (ec *executionContext) _ComponentInstanceEdge(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentInstanceEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentInstanceEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentInstanceEdge") + case "node": + out.Values[i] = ec._ComponentInstanceEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._ComponentInstanceEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentVersionImplementors = []string{"ComponentVersion", "Node"} + +func (ec *executionContext) _ComponentVersion(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentVersion) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentVersionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentVersion") + case "id": + out.Values[i] = ec._ComponentVersion_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "version": + out.Values[i] = ec._ComponentVersion_version(ctx, field, obj) + case "componentId": + out.Values[i] = ec._ComponentVersion_componentId(ctx, field, obj) + case "component": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._ComponentVersion_component(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issues": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._ComponentVersion_issues(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentVersionConnectionImplementors = []string{"ComponentVersionConnection", "Connection"} + +func (ec *executionContext) _ComponentVersionConnection(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentVersionConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentVersionConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentVersionConnection") + case "totalCount": + out.Values[i] = ec._ComponentVersionConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._ComponentVersionConnection_edges(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "pageInfo": + out.Values[i] = ec._ComponentVersionConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var componentVersionEdgeImplementors = []string{"ComponentVersionEdge", "Edge"} + +func (ec *executionContext) _ComponentVersionEdge(ctx context.Context, sel ast.SelectionSet, obj *model.ComponentVersionEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, componentVersionEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ComponentVersionEdge") + case "node": + out.Values[i] = ec._ComponentVersionEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._ComponentVersionEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var evidenceImplementors = []string{"Evidence", "Node"} + +func (ec *executionContext) _Evidence(ctx context.Context, sel ast.SelectionSet, obj *model.Evidence) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, evidenceImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Evidence") + case "id": + out.Values[i] = ec._Evidence_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "description": + out.Values[i] = ec._Evidence_description(ctx, field, obj) + case "type": + out.Values[i] = ec._Evidence_type(ctx, field, obj) + case "vector": + out.Values[i] = ec._Evidence_vector(ctx, field, obj) + case "raaEnd": + out.Values[i] = ec._Evidence_raaEnd(ctx, field, obj) + case "authorId": + out.Values[i] = ec._Evidence_authorId(ctx, field, obj) + case "author": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Evidence_author(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "activityId": + out.Values[i] = ec._Evidence_activityId(ctx, field, obj) + case "activity": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Evidence_activity(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueMatches": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Evidence_issueMatches(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var evidenceConnectionImplementors = []string{"EvidenceConnection", "Connection"} + +func (ec *executionContext) _EvidenceConnection(ctx context.Context, sel ast.SelectionSet, obj *model.EvidenceConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, evidenceConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("EvidenceConnection") + case "totalCount": + out.Values[i] = ec._EvidenceConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._EvidenceConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._EvidenceConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var evidenceEdgeImplementors = []string{"EvidenceEdge", "Edge"} + +func (ec *executionContext) _EvidenceEdge(ctx context.Context, sel ast.SelectionSet, obj *model.EvidenceEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, evidenceEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("EvidenceEdge") + case "node": + out.Values[i] = ec._EvidenceEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._EvidenceEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueImplementors = []string{"Issue", "Node"} + +func (ec *executionContext) _Issue(ctx context.Context, sel ast.SelectionSet, obj *model.Issue) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Issue") + case "id": + out.Values[i] = ec._Issue_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "type": + out.Values[i] = ec._Issue_type(ctx, field, obj) + case "primaryName": + out.Values[i] = ec._Issue_primaryName(ctx, field, obj) + case "lastModified": + out.Values[i] = ec._Issue_lastModified(ctx, field, obj) + case "issueVariants": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Issue_issueVariants(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "activities": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Issue_activities(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueMatches": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Issue_issueMatches(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "componentVersions": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Issue_componentVersions(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "metadata": + out.Values[i] = ec._Issue_metadata(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueConnectionImplementors = []string{"IssueConnection", "Connection"} + +func (ec *executionContext) _IssueConnection(ctx context.Context, sel ast.SelectionSet, obj *model.IssueConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueConnection") + case "totalCount": + out.Values[i] = ec._IssueConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._IssueConnection_edges(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "pageInfo": + out.Values[i] = ec._IssueConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueEdgeImplementors = []string{"IssueEdge", "Edge"} + +func (ec *executionContext) _IssueEdge(ctx context.Context, sel ast.SelectionSet, obj *model.IssueEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueEdge") + case "node": + out.Values[i] = ec._IssueEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._IssueEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMatchImplementors = []string{"IssueMatch", "Node"} + +func (ec *executionContext) _IssueMatch(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMatch) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMatchImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMatch") + case "id": + out.Values[i] = ec._IssueMatch_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "status": + out.Values[i] = ec._IssueMatch_status(ctx, field, obj) + case "remediationDate": + out.Values[i] = ec._IssueMatch_remediationDate(ctx, field, obj) + case "discoveryDate": + out.Values[i] = ec._IssueMatch_discoveryDate(ctx, field, obj) + case "targetRemediationDate": + out.Values[i] = ec._IssueMatch_targetRemediationDate(ctx, field, obj) + case "severity": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatch_severity(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "effectiveIssueVariants": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatch_effectiveIssueVariants(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "evidences": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatch_evidences(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueId": + out.Values[i] = ec._IssueMatch_issueId(ctx, field, obj) + case "issue": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatch_issue(ctx, field, obj) + if res == graphql.Null { + atomic.AddUint32(&fs.Invalids, 1) + } + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "userId": + out.Values[i] = ec._IssueMatch_userId(ctx, field, obj) + case "user": + out.Values[i] = ec._IssueMatch_user(ctx, field, obj) + case "componentInstanceId": + out.Values[i] = ec._IssueMatch_componentInstanceId(ctx, field, obj) + case "componentInstance": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatch_componentInstance(ctx, field, obj) + if res == graphql.Null { + atomic.AddUint32(&fs.Invalids, 1) + } + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueMatchChanges": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatch_issueMatchChanges(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMatchChangeImplementors = []string{"IssueMatchChange", "Node"} + +func (ec *executionContext) _IssueMatchChange(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMatchChange) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMatchChangeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMatchChange") + case "id": + out.Values[i] = ec._IssueMatchChange_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "action": + out.Values[i] = ec._IssueMatchChange_action(ctx, field, obj) + case "issueMatchId": + out.Values[i] = ec._IssueMatchChange_issueMatchId(ctx, field, obj) + case "issueMatch": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatchChange_issueMatch(ctx, field, obj) + if res == graphql.Null { + atomic.AddUint32(&fs.Invalids, 1) + } + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "activityId": + out.Values[i] = ec._IssueMatchChange_activityId(ctx, field, obj) + case "activity": + field := field + + innerFunc := func(ctx context.Context, fs *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueMatchChange_activity(ctx, field, obj) + if res == graphql.Null { + atomic.AddUint32(&fs.Invalids, 1) + } + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMatchChangeConnectionImplementors = []string{"IssueMatchChangeConnection", "Connection"} + +func (ec *executionContext) _IssueMatchChangeConnection(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMatchChangeConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMatchChangeConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMatchChangeConnection") + case "totalCount": + out.Values[i] = ec._IssueMatchChangeConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._IssueMatchChangeConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._IssueMatchChangeConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMatchChangeEdgeImplementors = []string{"IssueMatchChangeEdge", "Edge"} + +func (ec *executionContext) _IssueMatchChangeEdge(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMatchChangeEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMatchChangeEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMatchChangeEdge") + case "node": + out.Values[i] = ec._IssueMatchChangeEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._IssueMatchChangeEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMatchConnectionImplementors = []string{"IssueMatchConnection", "Connection"} + +func (ec *executionContext) _IssueMatchConnection(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMatchConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMatchConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMatchConnection") + case "totalCount": + out.Values[i] = ec._IssueMatchConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._IssueMatchConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._IssueMatchConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMatchEdgeImplementors = []string{"IssueMatchEdge", "Edge"} + +func (ec *executionContext) _IssueMatchEdge(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMatchEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMatchEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMatchEdge") + case "node": + out.Values[i] = ec._IssueMatchEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._IssueMatchEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueMetadataImplementors = []string{"IssueMetadata"} + +func (ec *executionContext) _IssueMetadata(ctx context.Context, sel ast.SelectionSet, obj *model.IssueMetadata) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueMetadataImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueMetadata") + case "serviceCount": + out.Values[i] = ec._IssueMetadata_serviceCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "activityCount": + out.Values[i] = ec._IssueMetadata_activityCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "issueMatchCount": + out.Values[i] = ec._IssueMetadata_issueMatchCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "componentInstanceCount": + out.Values[i] = ec._IssueMetadata_componentInstanceCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "componentVersionCount": + out.Values[i] = ec._IssueMetadata_componentVersionCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "earliestDiscoveryDate": + out.Values[i] = ec._IssueMetadata_earliestDiscoveryDate(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "earliestTargetRemediationDate": + out.Values[i] = ec._IssueMetadata_earliestTargetRemediationDate(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueRepositoryImplementors = []string{"IssueRepository", "Node"} + +func (ec *executionContext) _IssueRepository(ctx context.Context, sel ast.SelectionSet, obj *model.IssueRepository) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueRepositoryImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueRepository") + case "id": + out.Values[i] = ec._IssueRepository_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "name": + out.Values[i] = ec._IssueRepository_name(ctx, field, obj) + case "url": + out.Values[i] = ec._IssueRepository_url(ctx, field, obj) + case "issueVariants": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueRepository_issueVariants(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "services": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueRepository_services(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "created_at": + out.Values[i] = ec._IssueRepository_created_at(ctx, field, obj) + case "updated_at": + out.Values[i] = ec._IssueRepository_updated_at(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueRepositoryConnectionImplementors = []string{"IssueRepositoryConnection", "Connection"} + +func (ec *executionContext) _IssueRepositoryConnection(ctx context.Context, sel ast.SelectionSet, obj *model.IssueRepositoryConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueRepositoryConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueRepositoryConnection") + case "totalCount": + out.Values[i] = ec._IssueRepositoryConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._IssueRepositoryConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._IssueRepositoryConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueRepositoryEdgeImplementors = []string{"IssueRepositoryEdge", "Edge"} + +func (ec *executionContext) _IssueRepositoryEdge(ctx context.Context, sel ast.SelectionSet, obj *model.IssueRepositoryEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueRepositoryEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueRepositoryEdge") + case "node": + out.Values[i] = ec._IssueRepositoryEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._IssueRepositoryEdge_cursor(ctx, field, obj) + case "priority": + out.Values[i] = ec._IssueRepositoryEdge_priority(ctx, field, obj) + case "created_at": + out.Values[i] = ec._IssueRepositoryEdge_created_at(ctx, field, obj) + case "updated_at": + out.Values[i] = ec._IssueRepositoryEdge_updated_at(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueVariantImplementors = []string{"IssueVariant", "Node"} + +func (ec *executionContext) _IssueVariant(ctx context.Context, sel ast.SelectionSet, obj *model.IssueVariant) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueVariantImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueVariant") + case "id": + out.Values[i] = ec._IssueVariant_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "secondaryName": + out.Values[i] = ec._IssueVariant_secondaryName(ctx, field, obj) + case "description": + out.Values[i] = ec._IssueVariant_description(ctx, field, obj) + case "severity": + out.Values[i] = ec._IssueVariant_severity(ctx, field, obj) + case "issueRepositoryId": + out.Values[i] = ec._IssueVariant_issueRepositoryId(ctx, field, obj) + case "issueRepository": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueVariant_issueRepository(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueId": + out.Values[i] = ec._IssueVariant_issueId(ctx, field, obj) + case "issue": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._IssueVariant_issue(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "created_at": + out.Values[i] = ec._IssueVariant_created_at(ctx, field, obj) + case "updated_at": + out.Values[i] = ec._IssueVariant_updated_at(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueVariantConnectionImplementors = []string{"IssueVariantConnection", "Connection"} + +func (ec *executionContext) _IssueVariantConnection(ctx context.Context, sel ast.SelectionSet, obj *model.IssueVariantConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueVariantConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueVariantConnection") + case "totalCount": + out.Values[i] = ec._IssueVariantConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._IssueVariantConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._IssueVariantConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var issueVariantEdgeImplementors = []string{"IssueVariantEdge", "Edge"} + +func (ec *executionContext) _IssueVariantEdge(ctx context.Context, sel ast.SelectionSet, obj *model.IssueVariantEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, issueVariantEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("IssueVariantEdge") + case "node": + out.Values[i] = ec._IssueVariantEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._IssueVariantEdge_cursor(ctx, field, obj) + case "created_at": + out.Values[i] = ec._IssueVariantEdge_created_at(ctx, field, obj) + case "updated_at": + out.Values[i] = ec._IssueVariantEdge_updated_at(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var mutationImplementors = []string{"Mutation"} + +func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors) + ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ + Object: "Mutation", + }) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{ + Object: field.Name, + Field: field, + }) + + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Mutation") + case "createUser": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createUser(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateUser": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateUser(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteUser": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteUser(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createSupportGroup": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createSupportGroup(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateSupportGroup": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateSupportGroup(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteSupportGroup": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteSupportGroup(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createComponent": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createComponent(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateComponent": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateComponent(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteComponent": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteComponent(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createComponentInstance": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createComponentInstance(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateComponentInstance": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateComponentInstance(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteComponentInstance": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteComponentInstance(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createComponentVersion": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createComponentVersion(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateComponentVersion": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateComponentVersion(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteComponentVersion": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteComponentVersion(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createService": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createService(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateService": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateService(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteService": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteService(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createIssueRepository": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createIssueRepository(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateIssueRepository": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateIssueRepository(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteIssueRepository": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteIssueRepository(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createIssueVariant": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createIssueVariant(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateIssueVariant": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateIssueVariant(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteIssueVariant": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteIssueVariant(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createEvidence": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createEvidence(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateEvidence": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateEvidence(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteEvidence": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteEvidence(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createIssueMatch": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createIssueMatch(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateIssueMatch": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateIssueMatch(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteIssueMatch": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteIssueMatch(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "createActivity": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createActivity(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "updateActivity": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateActivity(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deleteActivity": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_deleteActivity(ctx, field) + }) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var pageImplementors = []string{"Page"} + +func (ec *executionContext) _Page(ctx context.Context, sel ast.SelectionSet, obj *model.Page) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, pageImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Page") + case "after": + out.Values[i] = ec._Page_after(ctx, field, obj) + case "isCurrent": + out.Values[i] = ec._Page_isCurrent(ctx, field, obj) + case "pageNumber": + out.Values[i] = ec._Page_pageNumber(ctx, field, obj) + case "pageCount": + out.Values[i] = ec._Page_pageCount(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var pageInfoImplementors = []string{"PageInfo"} + +func (ec *executionContext) _PageInfo(ctx context.Context, sel ast.SelectionSet, obj *model.PageInfo) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, pageInfoImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("PageInfo") + case "hasNextPage": + out.Values[i] = ec._PageInfo_hasNextPage(ctx, field, obj) + case "hasPreviousPage": + out.Values[i] = ec._PageInfo_hasPreviousPage(ctx, field, obj) + case "isValidPage": + out.Values[i] = ec._PageInfo_isValidPage(ctx, field, obj) + case "pageNumber": + out.Values[i] = ec._PageInfo_pageNumber(ctx, field, obj) + case "nextPageAfter": + out.Values[i] = ec._PageInfo_nextPageAfter(ctx, field, obj) + case "pages": + out.Values[i] = ec._PageInfo_pages(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var queryImplementors = []string{"Query"} + +func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors) + ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ + Object: "Query", + }) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{ + Object: field.Name, + Field: field, + }) + + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Query") + case "Issues": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_Issues(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "IssueMatches": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_IssueMatches(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "IssueMatchChanges": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_IssueMatchChanges(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "Services": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_Services(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "Components": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_Components(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "ComponentVersions": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_ComponentVersions(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "ComponentInstances": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_ComponentInstances(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "Activities": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_Activities(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "IssueVariants": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_IssueVariants(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "IssueRepositories": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_IssueRepositories(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "Evidences": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_Evidences(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "SupportGroups": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_SupportGroups(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "Users": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Query_Users(ctx, field) + return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, + func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return rrm(innerCtx) }) + case "__type": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Query___type(ctx, field) + }) + case "__schema": + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Query___schema(ctx, field) + }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var serviceImplementors = []string{"Service", "Node"} + +func (ec *executionContext) _Service(ctx context.Context, sel ast.SelectionSet, obj *model.Service) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, serviceImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Service") + case "id": + out.Values[i] = ec._Service_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "name": + out.Values[i] = ec._Service_name(ctx, field, obj) + case "owners": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Service_owners(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "supportGroups": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Service_supportGroups(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "activities": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Service_activities(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "issueRepositories": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Service_issueRepositories(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "componentInstances": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._Service_componentInstances(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var serviceConnectionImplementors = []string{"ServiceConnection", "Connection"} + +func (ec *executionContext) _ServiceConnection(ctx context.Context, sel ast.SelectionSet, obj *model.ServiceConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, serviceConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ServiceConnection") + case "totalCount": + out.Values[i] = ec._ServiceConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._ServiceConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._ServiceConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var serviceEdgeImplementors = []string{"ServiceEdge", "Edge"} + +func (ec *executionContext) _ServiceEdge(ctx context.Context, sel ast.SelectionSet, obj *model.ServiceEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, serviceEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("ServiceEdge") + case "node": + out.Values[i] = ec._ServiceEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._ServiceEdge_cursor(ctx, field, obj) + case "priority": + out.Values[i] = ec._ServiceEdge_priority(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var severityImplementors = []string{"Severity"} + +func (ec *executionContext) _Severity(ctx context.Context, sel ast.SelectionSet, obj *model.Severity) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, severityImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("Severity") + case "value": + out.Values[i] = ec._Severity_value(ctx, field, obj) + case "score": + out.Values[i] = ec._Severity_score(ctx, field, obj) + case "cvss": + out.Values[i] = ec._Severity_cvss(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var supportGroupImplementors = []string{"SupportGroup", "Node"} + +func (ec *executionContext) _SupportGroup(ctx context.Context, sel ast.SelectionSet, obj *model.SupportGroup) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, supportGroupImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("SupportGroup") + case "id": + out.Values[i] = ec._SupportGroup_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "name": + out.Values[i] = ec._SupportGroup_name(ctx, field, obj) + case "users": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._SupportGroup_users(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "services": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._SupportGroup_services(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var supportGroupConnectionImplementors = []string{"SupportGroupConnection", "Connection"} + +func (ec *executionContext) _SupportGroupConnection(ctx context.Context, sel ast.SelectionSet, obj *model.SupportGroupConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, supportGroupConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("SupportGroupConnection") + case "totalCount": + out.Values[i] = ec._SupportGroupConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._SupportGroupConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._SupportGroupConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var supportGroupEdgeImplementors = []string{"SupportGroupEdge", "Edge"} + +func (ec *executionContext) _SupportGroupEdge(ctx context.Context, sel ast.SelectionSet, obj *model.SupportGroupEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, supportGroupEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("SupportGroupEdge") + case "node": + out.Values[i] = ec._SupportGroupEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._SupportGroupEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var userImplementors = []string{"User", "Node"} + +func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj *model.User) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, userImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("User") + case "id": + out.Values[i] = ec._User_id(ctx, field, obj) + if out.Values[i] == graphql.Null { + atomic.AddUint32(&out.Invalids, 1) + } + case "sapID": + out.Values[i] = ec._User_sapID(ctx, field, obj) + case "name": + out.Values[i] = ec._User_name(ctx, field, obj) + case "supportGroups": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._User_supportGroups(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + case "services": + field := field + + innerFunc := func(ctx context.Context, _ *graphql.FieldSet) (res graphql.Marshaler) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + } + }() + res = ec._User_services(ctx, field, obj) + return res + } + + if field.Deferrable != nil { + dfs, ok := deferred[field.Deferrable.Label] + di := 0 + if ok { + dfs.AddField(field) + di = len(dfs.Values) - 1 + } else { + dfs = graphql.NewFieldSet([]graphql.CollectedField{field}) + deferred[field.Deferrable.Label] = dfs + } + dfs.Concurrently(di, func(ctx context.Context) graphql.Marshaler { + return innerFunc(ctx, dfs) + }) + + // don't run the out.Concurrently() call below + out.Values[i] = graphql.Null + continue + } + + out.Concurrently(i, func(ctx context.Context) graphql.Marshaler { return innerFunc(ctx, out) }) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var userConnectionImplementors = []string{"UserConnection", "Connection"} + +func (ec *executionContext) _UserConnection(ctx context.Context, sel ast.SelectionSet, obj *model.UserConnection) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, userConnectionImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("UserConnection") + case "totalCount": + out.Values[i] = ec._UserConnection_totalCount(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "edges": + out.Values[i] = ec._UserConnection_edges(ctx, field, obj) + case "pageInfo": + out.Values[i] = ec._UserConnection_pageInfo(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var userEdgeImplementors = []string{"UserEdge", "Edge"} + +func (ec *executionContext) _UserEdge(ctx context.Context, sel ast.SelectionSet, obj *model.UserEdge) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, userEdgeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("UserEdge") + case "node": + out.Values[i] = ec._UserEdge_node(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "cursor": + out.Values[i] = ec._UserEdge_cursor(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var __DirectiveImplementors = []string{"__Directive"} + +func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("__Directive") + case "name": + out.Values[i] = ec.___Directive_name(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "description": + out.Values[i] = ec.___Directive_description(ctx, field, obj) + case "locations": + out.Values[i] = ec.___Directive_locations(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "args": + out.Values[i] = ec.___Directive_args(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "isRepeatable": + out.Values[i] = ec.___Directive_isRepeatable(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var __EnumValueImplementors = []string{"__EnumValue"} + +func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("__EnumValue") + case "name": + out.Values[i] = ec.___EnumValue_name(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "description": + out.Values[i] = ec.___EnumValue_description(ctx, field, obj) + case "isDeprecated": + out.Values[i] = ec.___EnumValue_isDeprecated(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deprecationReason": + out.Values[i] = ec.___EnumValue_deprecationReason(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var __FieldImplementors = []string{"__Field"} + +func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("__Field") + case "name": + out.Values[i] = ec.___Field_name(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "description": + out.Values[i] = ec.___Field_description(ctx, field, obj) + case "args": + out.Values[i] = ec.___Field_args(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "type": + out.Values[i] = ec.___Field_type(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "isDeprecated": + out.Values[i] = ec.___Field_isDeprecated(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "deprecationReason": + out.Values[i] = ec.___Field_deprecationReason(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var __InputValueImplementors = []string{"__InputValue"} + +func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("__InputValue") + case "name": + out.Values[i] = ec.___InputValue_name(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "description": + out.Values[i] = ec.___InputValue_description(ctx, field, obj) + case "type": + out.Values[i] = ec.___InputValue_type(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "defaultValue": + out.Values[i] = ec.___InputValue_defaultValue(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var __SchemaImplementors = []string{"__Schema"} + +func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("__Schema") + case "description": + out.Values[i] = ec.___Schema_description(ctx, field, obj) + case "types": + out.Values[i] = ec.___Schema_types(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "queryType": + out.Values[i] = ec.___Schema_queryType(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "mutationType": + out.Values[i] = ec.___Schema_mutationType(ctx, field, obj) + case "subscriptionType": + out.Values[i] = ec.___Schema_subscriptionType(ctx, field, obj) + case "directives": + out.Values[i] = ec.___Schema_directives(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +var __TypeImplementors = []string{"__Type"} + +func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler { + fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors) + + out := graphql.NewFieldSet(fields) + deferred := make(map[string]*graphql.FieldSet) + for i, field := range fields { + switch field.Name { + case "__typename": + out.Values[i] = graphql.MarshalString("__Type") + case "kind": + out.Values[i] = ec.___Type_kind(ctx, field, obj) + if out.Values[i] == graphql.Null { + out.Invalids++ + } + case "name": + out.Values[i] = ec.___Type_name(ctx, field, obj) + case "description": + out.Values[i] = ec.___Type_description(ctx, field, obj) + case "fields": + out.Values[i] = ec.___Type_fields(ctx, field, obj) + case "interfaces": + out.Values[i] = ec.___Type_interfaces(ctx, field, obj) + case "possibleTypes": + out.Values[i] = ec.___Type_possibleTypes(ctx, field, obj) + case "enumValues": + out.Values[i] = ec.___Type_enumValues(ctx, field, obj) + case "inputFields": + out.Values[i] = ec.___Type_inputFields(ctx, field, obj) + case "ofType": + out.Values[i] = ec.___Type_ofType(ctx, field, obj) + case "specifiedByURL": + out.Values[i] = ec.___Type_specifiedByURL(ctx, field, obj) + default: + panic("unknown field " + strconv.Quote(field.Name)) + } + } + out.Dispatch(ctx) + if out.Invalids > 0 { + return graphql.Null + } + + atomic.AddInt32(&ec.deferred, int32(len(deferred))) + + for label, dfs := range deferred { + ec.processDeferredGroup(graphql.DeferredGroup{ + Label: label, + Path: graphql.GetPath(ctx), + FieldSet: dfs, + Context: ctx, + }) + } + + return out +} + +// endregion **************************** object.gotpl **************************** + +// region ***************************** type.gotpl ***************************** + +func (ec *executionContext) marshalNActivity2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx context.Context, sel ast.SelectionSet, v model.Activity) graphql.Marshaler { + return ec._Activity(ctx, sel, &v) +} + +func (ec *executionContext) marshalNActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx context.Context, sel ast.SelectionSet, v *model.Activity) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._Activity(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNActivityInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityInput(ctx context.Context, v interface{}) (model.ActivityInput, error) { + res, err := ec.unmarshalInputActivityInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalNBoolean2bool(ctx context.Context, v interface{}) (bool, error) { + res, err := graphql.UnmarshalBoolean(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { + res := graphql.MarshalBoolean(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) marshalNComponent2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx context.Context, sel ast.SelectionSet, v model.Component) graphql.Marshaler { + return ec._Component(ctx, sel, &v) +} + +func (ec *executionContext) marshalNComponent2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx context.Context, sel ast.SelectionSet, v *model.Component) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._Component(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNComponentInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInput(ctx context.Context, v interface{}) (model.ComponentInput, error) { + res, err := ec.unmarshalInputComponentInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNComponentInstance2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstance(ctx context.Context, sel ast.SelectionSet, v model.ComponentInstance) graphql.Marshaler { + return ec._ComponentInstance(ctx, sel, &v) +} + +func (ec *executionContext) marshalNComponentInstance2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstance(ctx context.Context, sel ast.SelectionSet, v *model.ComponentInstance) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._ComponentInstance(ctx, sel, v) +} + +func (ec *executionContext) marshalNComponentInstanceEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceEdge(ctx context.Context, sel ast.SelectionSet, v []*model.ComponentInstanceEdge) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOComponentInstanceEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalNComponentInstanceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceInput(ctx context.Context, v interface{}) (model.ComponentInstanceInput, error) { + res, err := ec.unmarshalInputComponentInstanceInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNComponentVersion2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx context.Context, sel ast.SelectionSet, v model.ComponentVersion) graphql.Marshaler { + return ec._ComponentVersion(ctx, sel, &v) +} + +func (ec *executionContext) marshalNComponentVersion2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx context.Context, sel ast.SelectionSet, v *model.ComponentVersion) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._ComponentVersion(ctx, sel, v) +} + +func (ec *executionContext) marshalNComponentVersionEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionEdge(ctx context.Context, sel ast.SelectionSet, v []*model.ComponentVersionEdge) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOComponentVersionEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalNComponentVersionInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionInput(ctx context.Context, v interface{}) (model.ComponentVersionInput, error) { + res, err := ec.unmarshalInputComponentVersionInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalNDateTime2string(ctx context.Context, v interface{}) (string, error) { + res, err := graphql.UnmarshalString(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNDateTime2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { + res := graphql.MarshalString(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) marshalNEvidence2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidence(ctx context.Context, sel ast.SelectionSet, v model.Evidence) graphql.Marshaler { + return ec._Evidence(ctx, sel, &v) +} + +func (ec *executionContext) marshalNEvidence2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidence(ctx context.Context, sel ast.SelectionSet, v *model.Evidence) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._Evidence(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNEvidenceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceInput(ctx context.Context, v interface{}) (model.EvidenceInput, error) { + res, err := ec.unmarshalInputEvidenceInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalNID2string(ctx context.Context, v interface{}) (string, error) { + res, err := graphql.UnmarshalID(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNID2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { + res := graphql.MarshalID(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) unmarshalNInt2int(ctx context.Context, v interface{}) (int, error) { + res, err := graphql.UnmarshalInt(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNInt2int(ctx context.Context, sel ast.SelectionSet, v int) graphql.Marshaler { + res := graphql.MarshalInt(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) marshalNIssue2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssue(ctx context.Context, sel ast.SelectionSet, v model.Issue) graphql.Marshaler { + return ec._Issue(ctx, sel, &v) +} + +func (ec *executionContext) marshalNIssue2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssue(ctx context.Context, sel ast.SelectionSet, v *model.Issue) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._Issue(ctx, sel, v) +} + +func (ec *executionContext) marshalNIssueEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueEdge(ctx context.Context, sel ast.SelectionSet, v []*model.IssueEdge) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalNIssueMatch2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatch(ctx context.Context, sel ast.SelectionSet, v model.IssueMatch) graphql.Marshaler { + return ec._IssueMatch(ctx, sel, &v) +} + +func (ec *executionContext) marshalNIssueMatch2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatch(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatch) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._IssueMatch(ctx, sel, v) +} + +func (ec *executionContext) marshalNIssueMatchChange2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChange(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchChange) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._IssueMatchChange(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNIssueMatchInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchInput(ctx context.Context, v interface{}) (model.IssueMatchInput, error) { + res, err := ec.unmarshalInputIssueMatchInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNIssueRepository2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx context.Context, sel ast.SelectionSet, v model.IssueRepository) graphql.Marshaler { + return ec._IssueRepository(ctx, sel, &v) +} + +func (ec *executionContext) marshalNIssueRepository2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx context.Context, sel ast.SelectionSet, v *model.IssueRepository) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._IssueRepository(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNIssueRepositoryInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryInput(ctx context.Context, v interface{}) (model.IssueRepositoryInput, error) { + res, err := ec.unmarshalInputIssueRepositoryInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNIssueVariant2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariant(ctx context.Context, sel ast.SelectionSet, v model.IssueVariant) graphql.Marshaler { + return ec._IssueVariant(ctx, sel, &v) +} + +func (ec *executionContext) marshalNIssueVariant2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariant(ctx context.Context, sel ast.SelectionSet, v *model.IssueVariant) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._IssueVariant(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNIssueVariantInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantInput(ctx context.Context, v interface{}) (model.IssueVariantInput, error) { + res, err := ec.unmarshalInputIssueVariantInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNService2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx context.Context, sel ast.SelectionSet, v model.Service) graphql.Marshaler { + return ec._Service(ctx, sel, &v) +} + +func (ec *executionContext) marshalNService2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx context.Context, sel ast.SelectionSet, v *model.Service) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._Service(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNServiceInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceInput(ctx context.Context, v interface{}) (model.ServiceInput, error) { + res, err := ec.unmarshalInputServiceInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalNString2string(ctx context.Context, v interface{}) (string, error) { + res, err := graphql.UnmarshalString(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { + res := graphql.MarshalString(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) marshalNSupportGroup2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroup(ctx context.Context, sel ast.SelectionSet, v model.SupportGroup) graphql.Marshaler { + return ec._SupportGroup(ctx, sel, &v) +} + +func (ec *executionContext) marshalNSupportGroup2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroup(ctx context.Context, sel ast.SelectionSet, v *model.SupportGroup) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._SupportGroup(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNSupportGroupInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupInput(ctx context.Context, v interface{}) (model.SupportGroupInput, error) { + res, err := ec.unmarshalInputSupportGroupInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalNUser2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v model.User) graphql.Marshaler { + return ec._User(ctx, sel, &v) +} + +func (ec *executionContext) marshalNUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v *model.User) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec._User(ctx, sel, v) +} + +func (ec *executionContext) unmarshalNUserInput2githubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserInput(ctx context.Context, v interface{}) (model.UserInput, error) { + res, err := ec.unmarshalInputUserInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler { + return ec.___Directive(ctx, sel, &v) +} + +func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) unmarshalN__DirectiveLocation2string(ctx context.Context, v interface{}) (string, error) { + res, err := graphql.UnmarshalString(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { + res := graphql.MarshalString(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) { + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]string, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalN__DirectiveLocation2string(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__DirectiveLocation2string(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler { + return ec.___EnumValue(ctx, sel, &v) +} + +func (ec *executionContext) marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler { + return ec.___Field(ctx, sel, &v) +} + +func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler { + return ec.___InputValue(ctx, sel, &v) +} + +func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler { + return ec.___Type(ctx, sel, &v) +} + +func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler { + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { + if v == nil { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + return graphql.Null + } + return ec.___Type(ctx, sel, v) +} + +func (ec *executionContext) unmarshalN__TypeKind2string(ctx context.Context, v interface{}) (string, error) { + res, err := graphql.UnmarshalString(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { + res := graphql.MarshalString(v) + if res == graphql.Null { + if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { + ec.Errorf(ctx, "the requested element is null which the schema does not allow") + } + } + return res +} + +func (ec *executionContext) marshalOActivity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivity(ctx context.Context, sel ast.SelectionSet, v *model.Activity) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._Activity(ctx, sel, v) +} + +func (ec *executionContext) marshalOActivityConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityConnection(ctx context.Context, sel ast.SelectionSet, v *model.ActivityConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ActivityConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOActivityEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityEdge(ctx context.Context, sel ast.SelectionSet, v []*model.ActivityEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOActivityEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOActivityEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityEdge(ctx context.Context, sel ast.SelectionSet, v *model.ActivityEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ActivityEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOActivityFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityFilter(ctx context.Context, v interface{}) (*model.ActivityFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputActivityFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOActivityStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx context.Context, v interface{}) ([]*model.ActivityStatusValues, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*model.ActivityStatusValues, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOActivityStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOActivityStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx context.Context, sel ast.SelectionSet, v []*model.ActivityStatusValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOActivityStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalOActivityStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx context.Context, v interface{}) (*model.ActivityStatusValues, error) { + if v == nil { + return nil, nil + } + var res = new(model.ActivityStatusValues) + err := res.UnmarshalGQL(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOActivityStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐActivityStatusValues(ctx context.Context, sel ast.SelectionSet, v *model.ActivityStatusValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return v +} + +func (ec *executionContext) unmarshalOBoolean2bool(ctx context.Context, v interface{}) (bool, error) { + res, err := graphql.UnmarshalBoolean(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { + res := graphql.MarshalBoolean(v) + return res +} + +func (ec *executionContext) unmarshalOBoolean2ᚕᚖbool(ctx context.Context, v interface{}) ([]*bool, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*bool, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOBoolean2ᚖbool(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOBoolean2ᚕᚖbool(ctx context.Context, sel ast.SelectionSet, v []*bool) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + for i := range v { + ret[i] = ec.marshalOBoolean2ᚖbool(ctx, sel, v[i]) + } + + return ret +} + +func (ec *executionContext) unmarshalOBoolean2ᚖbool(ctx context.Context, v interface{}) (*bool, error) { + if v == nil { + return nil, nil + } + res, err := graphql.UnmarshalBoolean(v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast.SelectionSet, v *bool) graphql.Marshaler { + if v == nil { + return graphql.Null + } + res := graphql.MarshalBoolean(*v) + return res +} + +func (ec *executionContext) marshalOCVSS2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCvss(ctx context.Context, sel ast.SelectionSet, v *model.Cvss) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._CVSS(ctx, sel, v) +} + +func (ec *executionContext) marshalOCVSSBase2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCVSSBase(ctx context.Context, sel ast.SelectionSet, v *model.CVSSBase) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._CVSSBase(ctx, sel, v) +} + +func (ec *executionContext) marshalOCVSSEnvironmental2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCVSSEnvironmental(ctx context.Context, sel ast.SelectionSet, v *model.CVSSEnvironmental) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._CVSSEnvironmental(ctx, sel, v) +} + +func (ec *executionContext) marshalOCVSSTemporal2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐCVSSTemporal(ctx context.Context, sel ast.SelectionSet, v *model.CVSSTemporal) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._CVSSTemporal(ctx, sel, v) +} + +func (ec *executionContext) marshalOComponent2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponent(ctx context.Context, sel ast.SelectionSet, v *model.Component) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._Component(ctx, sel, v) +} + +func (ec *executionContext) marshalOComponentConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentConnection(ctx context.Context, sel ast.SelectionSet, v *model.ComponentConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOComponentEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentEdge(ctx context.Context, sel ast.SelectionSet, v []*model.ComponentEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOComponentEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOComponentEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentEdge(ctx context.Context, sel ast.SelectionSet, v *model.ComponentEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOComponentFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentFilter(ctx context.Context, v interface{}) (*model.ComponentFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputComponentFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOComponentInstanceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceConnection(ctx context.Context, sel ast.SelectionSet, v *model.ComponentInstanceConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentInstanceConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOComponentInstanceEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceEdge(ctx context.Context, sel ast.SelectionSet, v *model.ComponentInstanceEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentInstanceEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOComponentInstanceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentInstanceFilter(ctx context.Context, v interface{}) (*model.ComponentInstanceFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputComponentInstanceFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOComponentTypeValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentTypeValues(ctx context.Context, v interface{}) (*model.ComponentTypeValues, error) { + if v == nil { + return nil, nil + } + var res = new(model.ComponentTypeValues) + err := res.UnmarshalGQL(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOComponentTypeValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentTypeValues(ctx context.Context, sel ast.SelectionSet, v *model.ComponentTypeValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return v +} + +func (ec *executionContext) marshalOComponentVersion2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersion(ctx context.Context, sel ast.SelectionSet, v *model.ComponentVersion) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentVersion(ctx, sel, v) +} + +func (ec *executionContext) marshalOComponentVersionConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionConnection(ctx context.Context, sel ast.SelectionSet, v *model.ComponentVersionConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentVersionConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOComponentVersionEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionEdge(ctx context.Context, sel ast.SelectionSet, v *model.ComponentVersionEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ComponentVersionEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOComponentVersionFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐComponentVersionFilter(ctx context.Context, v interface{}) (*model.ComponentVersionFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputComponentVersionFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalODateTime2ᚖstring(ctx context.Context, v interface{}) (*string, error) { + if v == nil { + return nil, nil + } + res, err := graphql.UnmarshalString(v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalODateTime2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler { + if v == nil { + return graphql.Null + } + res := graphql.MarshalString(*v) + return res +} + +func (ec *executionContext) marshalOEvidenceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceConnection(ctx context.Context, sel ast.SelectionSet, v *model.EvidenceConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._EvidenceConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOEvidenceEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceEdge(ctx context.Context, sel ast.SelectionSet, v []*model.EvidenceEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOEvidenceEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOEvidenceEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceEdge(ctx context.Context, sel ast.SelectionSet, v *model.EvidenceEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._EvidenceEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOEvidenceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐEvidenceFilter(ctx context.Context, v interface{}) (*model.EvidenceFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputEvidenceFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOFloat2ᚖfloat64(ctx context.Context, v interface{}) (*float64, error) { + if v == nil { + return nil, nil + } + res, err := graphql.UnmarshalFloatContext(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOFloat2ᚖfloat64(ctx context.Context, sel ast.SelectionSet, v *float64) graphql.Marshaler { + if v == nil { + return graphql.Null + } + res := graphql.MarshalFloatContext(*v) + return graphql.WrapContextMarshaler(ctx, res) +} + +func (ec *executionContext) unmarshalOInt2ᚖint(ctx context.Context, v interface{}) (*int, error) { + if v == nil { + return nil, nil + } + res, err := graphql.UnmarshalInt(v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOInt2ᚖint(ctx context.Context, sel ast.SelectionSet, v *int) graphql.Marshaler { + if v == nil { + return graphql.Null + } + res := graphql.MarshalInt(*v) + return res +} + +func (ec *executionContext) marshalOIssue2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssue(ctx context.Context, sel ast.SelectionSet, v *model.Issue) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._Issue(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueConnection(ctx context.Context, sel ast.SelectionSet, v *model.IssueConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueEdge(ctx context.Context, sel ast.SelectionSet, v *model.IssueEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOIssueFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueFilter(ctx context.Context, v interface{}) (*model.IssueFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputIssueFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOIssueMatchChangeActions2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx context.Context, v interface{}) ([]*model.IssueMatchChangeActions, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*model.IssueMatchChangeActions, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOIssueMatchChangeActions2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOIssueMatchChangeActions2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx context.Context, sel ast.SelectionSet, v []*model.IssueMatchChangeActions) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueMatchChangeActions2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalOIssueMatchChangeActions2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx context.Context, v interface{}) (*model.IssueMatchChangeActions, error) { + if v == nil { + return nil, nil + } + var res = new(model.IssueMatchChangeActions) + err := res.UnmarshalGQL(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOIssueMatchChangeActions2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeActions(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchChangeActions) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return v +} + +func (ec *executionContext) marshalOIssueMatchChangeConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeConnection(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchChangeConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueMatchChangeConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueMatchChangeEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeEdge(ctx context.Context, sel ast.SelectionSet, v []*model.IssueMatchChangeEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueMatchChangeEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOIssueMatchChangeEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeEdge(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchChangeEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueMatchChangeEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOIssueMatchChangeFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchChangeFilter(ctx context.Context, v interface{}) (*model.IssueMatchChangeFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputIssueMatchChangeFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOIssueMatchConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchConnection(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueMatchConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueMatchEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchEdge(ctx context.Context, sel ast.SelectionSet, v []*model.IssueMatchEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueMatchEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOIssueMatchEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchEdge(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueMatchEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOIssueMatchFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchFilter(ctx context.Context, v interface{}) (*model.IssueMatchFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputIssueMatchFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOIssueMatchStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx context.Context, v interface{}) ([]*model.IssueMatchStatusValues, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*model.IssueMatchStatusValues, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOIssueMatchStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOIssueMatchStatusValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx context.Context, sel ast.SelectionSet, v []*model.IssueMatchStatusValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueMatchStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalOIssueMatchStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx context.Context, v interface{}) (*model.IssueMatchStatusValues, error) { + if v == nil { + return nil, nil + } + var res = new(model.IssueMatchStatusValues) + err := res.UnmarshalGQL(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOIssueMatchStatusValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMatchStatusValues(ctx context.Context, sel ast.SelectionSet, v *model.IssueMatchStatusValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return v +} + +func (ec *executionContext) marshalOIssueMetadata2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueMetadata(ctx context.Context, sel ast.SelectionSet, v *model.IssueMetadata) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueMetadata(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueRepository2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepository(ctx context.Context, sel ast.SelectionSet, v *model.IssueRepository) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueRepository(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueRepositoryConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryConnection(ctx context.Context, sel ast.SelectionSet, v *model.IssueRepositoryConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueRepositoryConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueRepositoryEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryEdge(ctx context.Context, sel ast.SelectionSet, v []*model.IssueRepositoryEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueRepositoryEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOIssueRepositoryEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryEdge(ctx context.Context, sel ast.SelectionSet, v *model.IssueRepositoryEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueRepositoryEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOIssueRepositoryFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueRepositoryFilter(ctx context.Context, v interface{}) (*model.IssueRepositoryFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputIssueRepositoryFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOIssueTypes2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx context.Context, v interface{}) ([]*model.IssueTypes, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*model.IssueTypes, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOIssueTypes2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOIssueTypes2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx context.Context, sel ast.SelectionSet, v []*model.IssueTypes) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueTypes2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalOIssueTypes2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx context.Context, v interface{}) (*model.IssueTypes, error) { + if v == nil { + return nil, nil + } + var res = new(model.IssueTypes) + err := res.UnmarshalGQL(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOIssueTypes2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueTypes(ctx context.Context, sel ast.SelectionSet, v *model.IssueTypes) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return v +} + +func (ec *executionContext) marshalOIssueVariantConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantConnection(ctx context.Context, sel ast.SelectionSet, v *model.IssueVariantConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueVariantConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOIssueVariantEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantEdge(ctx context.Context, sel ast.SelectionSet, v []*model.IssueVariantEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOIssueVariantEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOIssueVariantEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantEdge(ctx context.Context, sel ast.SelectionSet, v *model.IssueVariantEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._IssueVariantEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOIssueVariantFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐIssueVariantFilter(ctx context.Context, v interface{}) (*model.IssueVariantFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputIssueVariantFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOPage2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPage(ctx context.Context, sel ast.SelectionSet, v []*model.Page) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOPage2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPage(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOPage2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPage(ctx context.Context, sel ast.SelectionSet, v *model.Page) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._Page(ctx, sel, v) +} + +func (ec *executionContext) marshalOPageInfo2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐPageInfo(ctx context.Context, sel ast.SelectionSet, v *model.PageInfo) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._PageInfo(ctx, sel, v) +} + +func (ec *executionContext) marshalOService2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐService(ctx context.Context, sel ast.SelectionSet, v *model.Service) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._Service(ctx, sel, v) +} + +func (ec *executionContext) marshalOServiceConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceConnection(ctx context.Context, sel ast.SelectionSet, v *model.ServiceConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ServiceConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOServiceEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceEdge(ctx context.Context, sel ast.SelectionSet, v []*model.ServiceEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOServiceEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOServiceEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceEdge(ctx context.Context, sel ast.SelectionSet, v *model.ServiceEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._ServiceEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOServiceFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐServiceFilter(ctx context.Context, v interface{}) (*model.ServiceFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputServiceFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOSeverity2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverity(ctx context.Context, sel ast.SelectionSet, v *model.Severity) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._Severity(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOSeverityInput2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityInput(ctx context.Context, v interface{}) (*model.SeverityInput, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputSeverityInput(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) unmarshalOSeverityValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx context.Context, v interface{}) ([]*model.SeverityValues, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*model.SeverityValues, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOSeverityValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOSeverityValues2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx context.Context, sel ast.SelectionSet, v []*model.SeverityValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOSeverityValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) unmarshalOSeverityValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx context.Context, v interface{}) (*model.SeverityValues, error) { + if v == nil { + return nil, nil + } + var res = new(model.SeverityValues) + err := res.UnmarshalGQL(v) + return res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOSeverityValues2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSeverityValues(ctx context.Context, sel ast.SelectionSet, v *model.SeverityValues) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return v +} + +func (ec *executionContext) unmarshalOString2ᚕᚖstring(ctx context.Context, v interface{}) ([]*string, error) { + if v == nil { + return nil, nil + } + var vSlice []interface{} + if v != nil { + vSlice = graphql.CoerceList(v) + } + var err error + res := make([]*string, len(vSlice)) + for i := range vSlice { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i)) + res[i], err = ec.unmarshalOString2ᚖstring(ctx, vSlice[i]) + if err != nil { + return nil, err + } + } + return res, nil +} + +func (ec *executionContext) marshalOString2ᚕᚖstring(ctx context.Context, sel ast.SelectionSet, v []*string) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + for i := range v { + ret[i] = ec.marshalOString2ᚖstring(ctx, sel, v[i]) + } + + return ret +} + +func (ec *executionContext) unmarshalOString2ᚖstring(ctx context.Context, v interface{}) (*string, error) { + if v == nil { + return nil, nil + } + res, err := graphql.UnmarshalString(v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler { + if v == nil { + return graphql.Null + } + res := graphql.MarshalString(*v) + return res +} + +func (ec *executionContext) marshalOSupportGroupConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupConnection(ctx context.Context, sel ast.SelectionSet, v *model.SupportGroupConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._SupportGroupConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOSupportGroupEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupEdge(ctx context.Context, sel ast.SelectionSet, v []*model.SupportGroupEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOSupportGroupEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOSupportGroupEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupEdge(ctx context.Context, sel ast.SelectionSet, v *model.SupportGroupEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._SupportGroupEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOSupportGroupFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐSupportGroupFilter(ctx context.Context, v interface{}) (*model.SupportGroupFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputSupportGroupFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalOUser2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v *model.User) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._User(ctx, sel, v) +} + +func (ec *executionContext) marshalOUserConnection2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserConnection(ctx context.Context, sel ast.SelectionSet, v *model.UserConnection) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._UserConnection(ctx, sel, v) +} + +func (ec *executionContext) marshalOUserEdge2ᚕᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserEdge(ctx context.Context, sel ast.SelectionSet, v []*model.UserEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalOUserEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserEdge(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + return ret +} + +func (ec *executionContext) marshalOUserEdge2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserEdge(ctx context.Context, sel ast.SelectionSet, v *model.UserEdge) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec._UserEdge(ctx, sel, v) +} + +func (ec *executionContext) unmarshalOUserFilter2ᚖgithubᚗwdfᚗsapᚗcorpᚋccᚋheurekaᚋinternalᚋapiᚋgraphqlᚋgraphᚋmodelᚐUserFilter(ctx context.Context, v interface{}) (*model.UserFilter, error) { + if v == nil { + return nil, nil + } + res, err := ec.unmarshalInputUserFilter(ctx, v) + return &res, graphql.ErrorOnPath(ctx, err) +} + +func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec.___Schema(ctx, sel, v) +} + +func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler { + if v == nil { + return graphql.Null + } + ret := make(graphql.Array, len(v)) + var wg sync.WaitGroup + isLen1 := len(v) == 1 + if !isLen1 { + wg.Add(len(v)) + } + for i := range v { + i := i + fc := &graphql.FieldContext{ + Index: &i, + Result: &v[i], + } + ctx := graphql.WithFieldContext(ctx, fc) + f := func(i int) { + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = nil + } + }() + if !isLen1 { + defer wg.Done() + } + ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i]) + } + if isLen1 { + f(i) + } else { + go f(i) + } + + } + wg.Wait() + + for _, e := range ret { + if e == graphql.Null { + return graphql.Null + } + } + + return ret +} + +func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { + if v == nil { + return graphql.Null + } + return ec.___Type(ctx, sel, v) +} + +// endregion ***************************** type.gotpl ***************************** diff --git a/internal/api/graphql/graph/model/common.go b/internal/api/graphql/graph/model/common.go new file mode 100644 index 00000000..7ff93a61 --- /dev/null +++ b/internal/api/graphql/graph/model/common.go @@ -0,0 +1,84 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package model + +import "fmt" + +type NodeName string + +func (e NodeName) String() string { + return string(e) +} + +const ( + ActivityNodeName NodeName = "Activity" + IssueVariantNodeName NodeName = "IssueVariant" + IssueRepositoryNodeName NodeName = "IssueRepository" + ComponentNodeName NodeName = "Component" + ComponentInstanceNodeName NodeName = "ComponentInstance" + ComponentVersionNodeName NodeName = "ComponentVersion" + EvidenceNodeName NodeName = "Evidence" + ServiceNodeName NodeName = "Service" + SupportGroupNodeName NodeName = "SupportGroup" + UserNodeName NodeName = "User" + IssueNodeName NodeName = "Issue" + IssueMatchNodeName NodeName = "IssueMatch" + IssueMatchChangeNodeName NodeName = "IssueMatchChange" +) + +type NodeParent struct { + Parent Node + ParentName NodeName + ChildIds []*int64 +} + +func IssueMatchChangeAction(s string) IssueMatchChangeActions { + switch s { + case IssueMatchChangeActionsAdd.String(): + return IssueMatchChangeActionsAdd + case IssueMatchChangeActionsRemove.String(): + return IssueMatchChangeActionsRemove + } + return IssueMatchChangeActionsAdd +} + +func IssueMatchStatusValue(s string) IssueMatchStatusValues { + switch s { + case IssueMatchStatusValuesFalsePositive.String(): + return IssueMatchStatusValuesFalsePositive + case IssueMatchStatusValuesRiskAccepted.String(): + return IssueMatchStatusValuesRiskAccepted + case IssueMatchStatusValuesMitigated.String(): + return IssueMatchStatusValuesMitigated + } + return IssueMatchStatusValuesNew +} + +func SeverityValue(s string) (SeverityValues, error) { + switch s { + case SeverityValuesNone.String(): + return SeverityValuesNone, nil + case SeverityValuesLow.String(): + return SeverityValuesLow, nil + case SeverityValuesMedium.String(): + return SeverityValuesMedium, nil + case SeverityValuesHigh.String(): + return SeverityValuesHigh, nil + case SeverityValuesCritical.String(): + return SeverityValuesCritical, nil + } + return "unknown", fmt.Errorf("Invalid SeverityValues provided: %s", s) +} + +func ComponentTypeValue(s string) (ComponentTypeValues, error) { + switch s { + case ComponentTypeValuesContainerImage.String(): + return ComponentTypeValuesContainerImage, nil + case ComponentTypeValuesRepository.String(): + return ComponentTypeValuesRepository, nil + case ComponentTypeValuesVirtualMachineImage.String(): + return ComponentTypeValuesVirtualMachineImage, nil + } + return "unknown", fmt.Errorf("Invalid ComponentTypeValues provided: %s", s) +} diff --git a/internal/api/graphql/graph/model/models.go b/internal/api/graphql/graph/model/models.go new file mode 100644 index 00000000..55a3481a --- /dev/null +++ b/internal/api/graphql/graph/model/models.go @@ -0,0 +1,435 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package model + +import ( + "fmt" + "strconv" + "time" + + "github.com/samber/lo" + + "github.wdf.sap.corp/cc/heureka/internal/entity" + "github.wdf.sap.corp/cc/heureka/pkg/util" +) + +// add custom models here + +func NewPageInfo(p *entity.PageInfo) *PageInfo { + if p == nil { + return nil + } + return &PageInfo{ + HasNextPage: p.HasNextPage, + HasPreviousPage: p.HasPreviousPage, + IsValidPage: p.IsValidPage, + PageNumber: p.PageNumber, + NextPageAfter: p.NextPageAfter, + Pages: lo.Map(p.Pages, func(page entity.Page, _ int) *Page { + return NewPage(&page) + }), + } +} + +func NewPage(p *entity.Page) *Page { + if p == nil { + return nil + } + return &Page{ + After: p.After, + IsCurrent: util.Ptr(p.IsCurrent), + PageNumber: p.PageNumber, + PageCount: p.PageCount, + } +} + +func NewSeverity(sev entity.Severity) *Severity { + severity, _ := SeverityValue(sev.Value) + + if severity == "unknown" { + return &Severity{ + Value: &severity, + Score: &sev.Score, + Cvss: nil, + } + } + + baseScore := sev.Cvss.Base.Score() + av := sev.Cvss.Base.AV.String() + attackComplexity := sev.Cvss.Base.AC.String() + privilegesRequired := sev.Cvss.Base.PR.String() + userInteraction := sev.Cvss.Base.UI.String() + scope := sev.Cvss.Base.S.String() + confidentialityImpact := sev.Cvss.Base.C.String() + integrityImpact := sev.Cvss.Base.I.String() + availabilityImpact := sev.Cvss.Base.A.String() + + temporalScore := sev.Cvss.Temporal.Score() + exploitCodeMaturity := sev.Cvss.Temporal.E.String() + remediationLevel := sev.Cvss.Temporal.RL.String() + reportConfidence := sev.Cvss.Temporal.RC.String() + + environmentalScore := sev.Cvss.Environmental.Score() + modifiedAttackVector := sev.Cvss.Environmental.MAV.String() + modifiedAttackComplexity := sev.Cvss.Environmental.MAC.String() + modifiedPrivilegesRequired := sev.Cvss.Environmental.MPR.String() + modifiedUserInteraction := sev.Cvss.Environmental.MUI.String() + modifiedScope := sev.Cvss.Environmental.MS.String() + modifiedConfidentialityImpact := sev.Cvss.Environmental.MC.String() + modifiedIntegrityImpact := sev.Cvss.Environmental.MI.String() + modifiedAvailabilityImpact := sev.Cvss.Environmental.MA.String() + availabilityRequirement := sev.Cvss.Environmental.AR.String() + integrityRequirement := sev.Cvss.Environmental.IR.String() + confidentialityRequirement := sev.Cvss.Environmental.CR.String() + s := &Severity{ + Value: &severity, + Score: &sev.Score, + Cvss: &Cvss{ + Vector: &sev.Cvss.Vector, + Base: &CVSSBase{ + Score: &baseScore, + AttackVector: &av, + AttackComplexity: &attackComplexity, + PrivilegesRequired: &privilegesRequired, + UserInteraction: &userInteraction, + Scope: &scope, + ConfidentialityImpact: &confidentialityImpact, + IntegrityImpact: &integrityImpact, + AvailabilityImpact: &availabilityImpact, + }, + Temporal: &CVSSTemporal{ + Score: &temporalScore, + ExploitCodeMaturity: &exploitCodeMaturity, + RemediationLevel: &remediationLevel, + ReportConfidence: &reportConfidence, + }, + Environmental: &CVSSEnvironmental{ + Score: &environmentalScore, + ModifiedAttackVector: &modifiedAttackVector, + ModifiedAttackComplexity: &modifiedAttackComplexity, + ModifiedPrivilegesRequired: &modifiedPrivilegesRequired, + ModifiedUserInteraction: &modifiedUserInteraction, + ModifiedScope: &modifiedScope, + ModifiedConfidentialityImpact: &modifiedConfidentialityImpact, + ModifiedIntegrityImpact: &modifiedIntegrityImpact, + ModifiedAvailabilityImpact: &modifiedAvailabilityImpact, + ConfidentialityRequirement: &confidentialityRequirement, + AvailabilityRequirement: &availabilityRequirement, + IntegrityRequirement: &integrityRequirement, + }, + }, + } + return s +} + +func NewSeverityEntity(severity *SeverityInput) entity.Severity { + if severity == nil || severity.Vector == nil { + return entity.Severity{} + } + return entity.NewSeverity(*severity.Vector) +} + +func NewIssue(issue *entity.IssueResult) Issue { + lastModified := issue.Issue.UpdatedAt.String() + issueType := IssueTypes(issue.Type.String()) + + var metadata IssueMetadata + + if issue.IssueAggregations != nil { + metadata = IssueMetadata{ + ServiceCount: int(issue.IssueAggregations.AffectedServices), + ActivityCount: int(issue.IssueAggregations.Activites), + IssueMatchCount: int(issue.IssueAggregations.IssueMatches), + ComponentInstanceCount: int(issue.IssueAggregations.AffectedComponentInstances), + ComponentVersionCount: int(issue.IssueAggregations.ComponentVersions), + EarliestDiscoveryDate: issue.IssueAggregations.EarliestDiscoveryDate.String(), + EarliestTargetRemediationDate: issue.IssueAggregations.EarliestTargetRemediationDate.String(), + } + } + + return Issue{ + ID: fmt.Sprintf("%d", issue.Issue.Id), + PrimaryName: &issue.Issue.PrimaryName, + Type: &issueType, + LastModified: &lastModified, + Metadata: &metadata, + } +} + +func NewIssueMatch(im *entity.IssueMatch) IssueMatch { + status := IssueMatchStatusValue(im.Status.String()) + targetRemediationDate := im.TargetRemediationDate.Format(time.RFC3339) + discoveryDate := im.CreatedAt.Format(time.RFC3339) + remediationDate := im.RemediationDate.Format(time.RFC3339) + severity := NewSeverity(im.Severity) + return IssueMatch{ + ID: fmt.Sprintf("%d", im.Id), + Status: &status, + RemediationDate: &remediationDate, + DiscoveryDate: &discoveryDate, + TargetRemediationDate: &targetRemediationDate, + Severity: severity, + IssueID: util.Ptr(fmt.Sprintf("%d", im.IssueId)), + ComponentInstanceID: util.Ptr(fmt.Sprintf("%d", im.ComponentInstanceId)), + UserID: util.Ptr(fmt.Sprintf("%d", im.UserId)), + } +} + +func NewIssueMatchEntity(im *IssueMatchInput) entity.IssueMatch { + issueId, _ := strconv.ParseInt(lo.FromPtr(im.IssueID), 10, 64) + ciId, _ := strconv.ParseInt(lo.FromPtr(im.ComponentInstanceID), 10, 64) + userId, _ := strconv.ParseInt(lo.FromPtr(im.UserID), 10, 64) + targetRemediationDate, _ := time.Parse(time.RFC3339, lo.FromPtr(im.TargetRemediationDate)) + remediationDate, _ := time.Parse(time.RFC3339, lo.FromPtr(im.RemediationDate)) + createdAt, _ := time.Parse(time.RFC3339, lo.FromPtr(im.DiscoveryDate)) + status := entity.IssueMatchStatusValuesNone + if im.Status != nil { + status = entity.NewIssueMatchStatusValue(im.Status.String()) + } + return entity.IssueMatch{ + Status: status, + TargetRemediationDate: targetRemediationDate, + RemediationDate: remediationDate, + Severity: entity.Severity{}, + IssueId: issueId, + ComponentInstanceId: ciId, + UserId: userId, + CreatedAt: createdAt, + } +} + +func NewIssueMatchChange(imc *entity.IssueMatchChangeResult) IssueMatchChange { + action := IssueMatchChangeAction(imc.Action) + return IssueMatchChange{ + ID: fmt.Sprintf("%d", imc.Id), + Action: &action, + IssueMatchID: util.Ptr(fmt.Sprintf("%d", imc.IssueMatchId)), + IssueMatch: nil, + ActivityID: util.Ptr(fmt.Sprintf("%d", imc.ActivityId)), + Activity: nil, + } +} + +func NewIssueRepository(repo *entity.IssueRepository) IssueRepository { + createdAt := repo.BaseIssueRepository.CreatedAt.String() + updatedAt := repo.BaseIssueRepository.UpdatedAt.String() + return IssueRepository{ + ID: fmt.Sprintf("%d", repo.Id), + Name: &repo.Name, + URL: &repo.Url, + Services: nil, + IssueVariants: nil, + CreatedAt: &createdAt, + UpdatedAt: &updatedAt, + } +} + +func NewIssueRepositoryEntity(repo *IssueRepositoryInput) entity.IssueRepository { + return entity.IssueRepository{ + BaseIssueRepository: entity.BaseIssueRepository{ + Name: lo.FromPtr(repo.Name), + Url: lo.FromPtr(repo.URL), + }, + } +} + +func NewIssueVariant(issueVariant *entity.IssueVariant) IssueVariant { + var repo IssueRepository + if issueVariant.IssueRepository != nil { + repo = NewIssueRepository(issueVariant.IssueRepository) + } + createdAt := issueVariant.CreatedAt.String() + updatedAt := issueVariant.UpdatedAt.String() + return IssueVariant{ + ID: fmt.Sprintf("%d", issueVariant.Id), + SecondaryName: &issueVariant.SecondaryName, + Description: &issueVariant.Description, + Severity: NewSeverity(issueVariant.Severity), + IssueID: util.Ptr(fmt.Sprintf("%d", issueVariant.IssueId)), + IssueRepositoryID: util.Ptr(fmt.Sprintf("%d", issueVariant.IssueRepositoryId)), + IssueRepository: &repo, + CreatedAt: &createdAt, + UpdatedAt: &updatedAt, + } +} + +func NewIssueVariantEdge(issueVariant *entity.IssueVariant) IssueVariantEdge { + iv := NewIssueVariant(issueVariant) + edgeCreationDate := issueVariant.CreatedAt.String() + edgeUpdateDate := issueVariant.UpdatedAt.String() + issueVariantEdge := IssueVariantEdge{ + Node: &iv, + Cursor: &iv.ID, + CreatedAt: &edgeCreationDate, + UpdatedAt: &edgeUpdateDate, + } + return issueVariantEdge +} + +func NewIssueVariantEntity(issueVariant *IssueVariantInput) entity.IssueVariant { + issueId, _ := strconv.ParseInt(lo.FromPtr(issueVariant.IssueID), 10, 64) + irId, _ := strconv.ParseInt(lo.FromPtr(issueVariant.IssueRepositoryID), 10, 64) + return entity.IssueVariant{ + SecondaryName: lo.FromPtr(issueVariant.SecondaryName), + Description: lo.FromPtr(issueVariant.Description), + Severity: NewSeverityEntity(issueVariant.Severity), + IssueId: issueId, + IssueRepositoryId: irId, + } +} + +func NewUser(user *entity.User) User { + return User{ + ID: fmt.Sprintf("%d", user.Id), + SapID: &user.SapID, + Name: &user.Name, + } +} + +func NewUserEntity(user *UserInput) entity.User { + return entity.User{ + Name: lo.FromPtr(user.Name), + SapID: lo.FromPtr(user.SapID), + } +} + +func NewService(s *entity.Service) Service { + return Service{ + ID: fmt.Sprintf("%d", s.Id), + Name: &s.Name, + } +} + +func NewServiceEntity(service *ServiceInput) entity.Service { + return entity.Service{ + BaseService: entity.BaseService{ + Name: lo.FromPtr(service.Name), + }, + } +} + +func NewSupportGroup(supportGroup *entity.SupportGroup) SupportGroup { + return SupportGroup{ + ID: fmt.Sprintf("%d", supportGroup.Id), + Name: &supportGroup.Name, + } +} + +func NewSupportGroupEntity(supportGroup *SupportGroupInput) entity.SupportGroup { + return entity.SupportGroup{ + Name: lo.FromPtr(supportGroup.Name), + } +} + +func NewActivity(activity *entity.Activity) Activity { + status := ActivityStatusValues(activity.Status.String()) + return Activity{ + ID: fmt.Sprintf("%d", activity.Id), + Status: &status, + } +} + +func NewActivityEntity(activity *ActivityInput) entity.Activity { + status := entity.ActivityStatusValuesOpen + if activity.Status != nil { + status = entity.NewActivityStatusValue(activity.Status.String()) + } + return entity.Activity{ + Status: status, + } +} + +func NewEvidence(evidence *entity.Evidence) Evidence { + authorId := fmt.Sprintf("%d", evidence.UserId) + activityId := fmt.Sprintf("%d", evidence.ActivityId) + severity := NewSeverity(evidence.Severity) + t := evidence.Type.String() + raaEnd := evidence.RaaEnd.Format(time.RFC3339) + return Evidence{ + ID: fmt.Sprintf("%d", evidence.Id), + Description: &evidence.Description, + AuthorID: &authorId, + ActivityID: &activityId, + Vector: severity.Cvss.Vector, + Type: &t, + RaaEnd: &raaEnd, + } +} + +func NewEvidenceEntity(evidence *EvidenceInput) entity.Evidence { + authorId, _ := strconv.ParseInt(lo.FromPtr(evidence.AuthorID), 10, 64) + activityId, _ := strconv.ParseInt(lo.FromPtr(evidence.ActivityID), 10, 64) + t := entity.NewEvidenceTypeValue(lo.FromPtr(evidence.Type)) + raaEnd, _ := time.Parse(time.RFC3339, lo.FromPtr(evidence.RaaEnd)) + // raaEnd, _ := time.Parse("2006-01-02 15:04:05.999999999 -0700 MST", lo.FromPtr(evidence.RaaEnd)) + return entity.Evidence{ + Description: lo.FromPtr(evidence.Description), + UserId: authorId, + ActivityId: activityId, + Severity: NewSeverityEntity(evidence.Severity), + Type: t, + RaaEnd: raaEnd, + } +} + +func NewComponent(component *entity.Component) Component { + componentType, _ := ComponentTypeValue(component.Type) + return Component{ + ID: fmt.Sprintf("%d", component.Id), + Name: &component.Name, + Type: &componentType, + } +} + +func NewComponentEntity(component *ComponentInput) entity.Component { + componentType := "" + if component.Type != nil && component.Type.IsValid() { + componentType = component.Type.String() + } + return entity.Component{ + Name: lo.FromPtr(component.Name), + Type: componentType, + } +} + +func NewComponentVersion(componentVersion *entity.ComponentVersion) ComponentVersion { + return ComponentVersion{ + ID: fmt.Sprintf("%d", componentVersion.Id), + Version: &componentVersion.Version, + ComponentID: util.Ptr(fmt.Sprintf("%d", componentVersion.ComponentId)), + } +} + +func NewComponentVersionEntity(componentVersion *ComponentVersionInput) entity.ComponentVersion { + componentId, err := strconv.ParseInt(lo.FromPtr(componentVersion.ComponentID), 10, 64) + if err != nil { + componentId = 0 + } + return entity.ComponentVersion{ + Version: lo.FromPtr(componentVersion.Version), + ComponentId: componentId, + } +} + +func NewComponentInstance(componentInstance *entity.ComponentInstance) ComponentInstance { + count := int(componentInstance.Count) + return ComponentInstance{ + ID: fmt.Sprintf("%d", componentInstance.Id), + Ccrn: &componentInstance.CCRN, + Count: &count, + ComponentVersionID: util.Ptr(fmt.Sprintf("%d", componentInstance.ComponentVersionId)), + ServiceID: util.Ptr(fmt.Sprintf("%d", componentInstance.ServiceId)), + } +} + +func NewComponentInstanceEntity(componentInstance *ComponentInstanceInput) entity.ComponentInstance { + componentVersionId, _ := strconv.ParseInt(lo.FromPtr(componentInstance.ComponentVersionID), 10, 64) + serviceId, _ := strconv.ParseInt(lo.FromPtr(componentInstance.ServiceID), 10, 64) + return entity.ComponentInstance{ + CCRN: lo.FromPtr(componentInstance.Ccrn), + Count: int16(lo.FromPtr(componentInstance.Count)), + ComponentVersionId: componentVersionId, + ServiceId: serviceId, + } +} diff --git a/internal/api/graphql/graph/model/models_gen.go b/internal/api/graphql/graph/model/models_gen.go new file mode 100644 index 00000000..dc9364ff --- /dev/null +++ b/internal/api/graphql/graph/model/models_gen.go @@ -0,0 +1,991 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +// Code generated by github.com/99designs/gqlgen, DO NOT EDIT. + +package model + +import ( + "fmt" + "io" + "strconv" +) + +type Connection interface { + IsConnection() + GetTotalCount() int + GetPageInfo() *PageInfo +} + +type Edge interface { + IsEdge() + GetNode() Node + GetCursor() *string +} + +type Node interface { + IsNode() + GetID() string +} + +type Activity struct { + ID string `json:"id"` + Status *ActivityStatusValues `json:"status,omitempty"` + Services *ServiceConnection `json:"services,omitempty"` + Issues *IssueConnection `json:"issues,omitempty"` + Evidences *EvidenceConnection `json:"evidences,omitempty"` + IssueMatchChanges *IssueMatchChangeConnection `json:"issueMatchChanges,omitempty"` +} + +func (Activity) IsNode() {} +func (this Activity) GetID() string { return this.ID } + +type ActivityConnection struct { + TotalCount int `json:"totalCount"` + Edges []*ActivityEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (ActivityConnection) IsConnection() {} +func (this ActivityConnection) GetTotalCount() int { return this.TotalCount } +func (this ActivityConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type ActivityEdge struct { + Node *Activity `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (ActivityEdge) IsEdge() {} +func (this ActivityEdge) GetNode() Node { return *this.Node } +func (this ActivityEdge) GetCursor() *string { return this.Cursor } + +type ActivityFilter struct { + ServiceName []*string `json:"serviceName,omitempty"` + Status []*ActivityStatusValues `json:"status,omitempty"` +} + +type ActivityInput struct { + Status *ActivityStatusValues `json:"status,omitempty"` +} + +type Cvss struct { + Vector *string `json:"vector,omitempty"` + Base *CVSSBase `json:"base,omitempty"` + Temporal *CVSSTemporal `json:"temporal,omitempty"` + Environmental *CVSSEnvironmental `json:"environmental,omitempty"` +} + +type CVSSBase struct { + Score *float64 `json:"score,omitempty"` + AttackVector *string `json:"attackVector,omitempty"` + AttackComplexity *string `json:"attackComplexity,omitempty"` + PrivilegesRequired *string `json:"privilegesRequired,omitempty"` + UserInteraction *string `json:"userInteraction,omitempty"` + Scope *string `json:"scope,omitempty"` + ConfidentialityImpact *string `json:"confidentialityImpact,omitempty"` + IntegrityImpact *string `json:"integrityImpact,omitempty"` + AvailabilityImpact *string `json:"availabilityImpact,omitempty"` +} + +type CVSSEnvironmental struct { + Score *float64 `json:"score,omitempty"` + ModifiedAttackVector *string `json:"modifiedAttackVector,omitempty"` + ModifiedAttackComplexity *string `json:"modifiedAttackComplexity,omitempty"` + ModifiedPrivilegesRequired *string `json:"modifiedPrivilegesRequired,omitempty"` + ModifiedUserInteraction *string `json:"modifiedUserInteraction,omitempty"` + ModifiedScope *string `json:"modifiedScope,omitempty"` + ModifiedConfidentialityImpact *string `json:"modifiedConfidentialityImpact,omitempty"` + ModifiedIntegrityImpact *string `json:"modifiedIntegrityImpact,omitempty"` + ModifiedAvailabilityImpact *string `json:"modifiedAvailabilityImpact,omitempty"` + ConfidentialityRequirement *string `json:"confidentialityRequirement,omitempty"` + AvailabilityRequirement *string `json:"availabilityRequirement,omitempty"` + IntegrityRequirement *string `json:"integrityRequirement,omitempty"` +} + +type CVSSParameter struct { + Name *string `json:"name,omitempty"` + Value *string `json:"value,omitempty"` +} + +type CVSSTemporal struct { + Score *float64 `json:"score,omitempty"` + ExploitCodeMaturity *string `json:"exploitCodeMaturity,omitempty"` + RemediationLevel *string `json:"remediationLevel,omitempty"` + ReportConfidence *string `json:"reportConfidence,omitempty"` +} + +type Component struct { + ID string `json:"id"` + Name *string `json:"name,omitempty"` + Type *ComponentTypeValues `json:"type,omitempty"` + ComponentVersions *ComponentVersionConnection `json:"componentVersions,omitempty"` +} + +func (Component) IsNode() {} +func (this Component) GetID() string { return this.ID } + +type ComponentConnection struct { + TotalCount int `json:"totalCount"` + Edges []*ComponentEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (ComponentConnection) IsConnection() {} +func (this ComponentConnection) GetTotalCount() int { return this.TotalCount } +func (this ComponentConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type ComponentEdge struct { + Node *Component `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (ComponentEdge) IsEdge() {} +func (this ComponentEdge) GetNode() Node { return *this.Node } +func (this ComponentEdge) GetCursor() *string { return this.Cursor } + +type ComponentFilter struct { + ComponentName []*string `json:"componentName,omitempty"` +} + +type ComponentInput struct { + Name *string `json:"name,omitempty"` + Type *ComponentTypeValues `json:"type,omitempty"` +} + +type ComponentInstance struct { + ID string `json:"id"` + Ccrn *string `json:"ccrn,omitempty"` + Count *int `json:"count,omitempty"` + ComponentVersionID *string `json:"componentVersionId,omitempty"` + ComponentVersion *ComponentVersion `json:"componentVersion,omitempty"` + IssueMatches *IssueMatchConnection `json:"issueMatches,omitempty"` + ServiceID *string `json:"serviceId,omitempty"` + Service *Service `json:"service,omitempty"` + CreatedAt *string `json:"createdAt,omitempty"` + UpdatedAt *string `json:"updatedAt,omitempty"` +} + +func (ComponentInstance) IsNode() {} +func (this ComponentInstance) GetID() string { return this.ID } + +type ComponentInstanceConnection struct { + TotalCount int `json:"totalCount"` + Edges []*ComponentInstanceEdge `json:"edges"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (ComponentInstanceConnection) IsConnection() {} +func (this ComponentInstanceConnection) GetTotalCount() int { return this.TotalCount } +func (this ComponentInstanceConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type ComponentInstanceEdge struct { + Node *ComponentInstance `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (ComponentInstanceEdge) IsEdge() {} +func (this ComponentInstanceEdge) GetNode() Node { return *this.Node } +func (this ComponentInstanceEdge) GetCursor() *string { return this.Cursor } + +type ComponentInstanceFilter struct { + IssueMatchID []*string `json:"issueMatchId,omitempty"` +} + +type ComponentInstanceInput struct { + Ccrn *string `json:"ccrn,omitempty"` + Count *int `json:"count,omitempty"` + ComponentVersionID *string `json:"componentVersionId,omitempty"` + ServiceID *string `json:"serviceId,omitempty"` +} + +type ComponentVersion struct { + ID string `json:"id"` + Version *string `json:"version,omitempty"` + ComponentID *string `json:"componentId,omitempty"` + Component *Component `json:"component,omitempty"` + Issues *IssueConnection `json:"issues,omitempty"` +} + +func (ComponentVersion) IsNode() {} +func (this ComponentVersion) GetID() string { return this.ID } + +type ComponentVersionConnection struct { + TotalCount int `json:"totalCount"` + Edges []*ComponentVersionEdge `json:"edges"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (ComponentVersionConnection) IsConnection() {} +func (this ComponentVersionConnection) GetTotalCount() int { return this.TotalCount } +func (this ComponentVersionConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type ComponentVersionEdge struct { + Node *ComponentVersion `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (ComponentVersionEdge) IsEdge() {} +func (this ComponentVersionEdge) GetNode() Node { return *this.Node } +func (this ComponentVersionEdge) GetCursor() *string { return this.Cursor } + +type ComponentVersionFilter struct { + IssueID []*string `json:"issueId,omitempty"` +} + +type ComponentVersionInput struct { + Version *string `json:"version,omitempty"` + ComponentID *string `json:"componentId,omitempty"` +} + +type DateTimeFilter struct { + After *string `json:"after,omitempty"` + Before *string `json:"before,omitempty"` +} + +type Evidence struct { + ID string `json:"id"` + Description *string `json:"description,omitempty"` + Type *string `json:"type,omitempty"` + Vector *string `json:"vector,omitempty"` + RaaEnd *string `json:"raaEnd,omitempty"` + AuthorID *string `json:"authorId,omitempty"` + Author *User `json:"author,omitempty"` + ActivityID *string `json:"activityId,omitempty"` + Activity *Activity `json:"activity,omitempty"` + IssueMatches *IssueMatchConnection `json:"issueMatches,omitempty"` +} + +func (Evidence) IsNode() {} +func (this Evidence) GetID() string { return this.ID } + +type EvidenceConnection struct { + TotalCount int `json:"totalCount"` + Edges []*EvidenceEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (EvidenceConnection) IsConnection() {} +func (this EvidenceConnection) GetTotalCount() int { return this.TotalCount } +func (this EvidenceConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type EvidenceEdge struct { + Node *Evidence `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (EvidenceEdge) IsEdge() {} +func (this EvidenceEdge) GetNode() Node { return *this.Node } +func (this EvidenceEdge) GetCursor() *string { return this.Cursor } + +type EvidenceFilter struct { + Placeholder []*bool `json:"placeholder,omitempty"` +} + +type EvidenceInput struct { + Description *string `json:"description,omitempty"` + Type *string `json:"type,omitempty"` + RaaEnd *string `json:"raaEnd,omitempty"` + AuthorID *string `json:"authorId,omitempty"` + ActivityID *string `json:"activityId,omitempty"` + Severity *SeverityInput `json:"severity,omitempty"` +} + +type Issue struct { + ID string `json:"id"` + Type *IssueTypes `json:"type,omitempty"` + PrimaryName *string `json:"primaryName,omitempty"` + LastModified *string `json:"lastModified,omitempty"` + IssueVariants *IssueVariantConnection `json:"issueVariants,omitempty"` + Activities *ActivityConnection `json:"activities,omitempty"` + IssueMatches *IssueMatchConnection `json:"issueMatches,omitempty"` + ComponentVersions *ComponentVersionConnection `json:"componentVersions,omitempty"` + Metadata *IssueMetadata `json:"metadata,omitempty"` +} + +func (Issue) IsNode() {} +func (this Issue) GetID() string { return this.ID } + +type IssueConnection struct { + TotalCount int `json:"totalCount"` + Edges []*IssueEdge `json:"edges"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (IssueConnection) IsConnection() {} +func (this IssueConnection) GetTotalCount() int { return this.TotalCount } +func (this IssueConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type IssueEdge struct { + Node *Issue `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (IssueEdge) IsEdge() {} +func (this IssueEdge) GetNode() Node { return *this.Node } +func (this IssueEdge) GetCursor() *string { return this.Cursor } + +type IssueFilter struct { + AffectedService []*string `json:"affectedService,omitempty"` + PrimaryName []*string `json:"primaryName,omitempty"` + IssueMatchStatus []*IssueMatchStatusValues `json:"issueMatchStatus,omitempty"` + IssueType []*IssueTypes `json:"issueType,omitempty"` + ComponentVersionID []*string `json:"componentVersionId,omitempty"` +} + +type IssueMatch struct { + ID string `json:"id"` + Status *IssueMatchStatusValues `json:"status,omitempty"` + RemediationDate *string `json:"remediationDate,omitempty"` + DiscoveryDate *string `json:"discoveryDate,omitempty"` + TargetRemediationDate *string `json:"targetRemediationDate,omitempty"` + Severity *Severity `json:"severity,omitempty"` + EffectiveIssueVariants *IssueVariantConnection `json:"effectiveIssueVariants,omitempty"` + Evidences *EvidenceConnection `json:"evidences,omitempty"` + IssueID *string `json:"issueId,omitempty"` + Issue *Issue `json:"issue"` + UserID *string `json:"userId,omitempty"` + User *User `json:"user,omitempty"` + ComponentInstanceID *string `json:"componentInstanceId,omitempty"` + ComponentInstance *ComponentInstance `json:"componentInstance"` + IssueMatchChanges *IssueMatchChangeConnection `json:"issueMatchChanges,omitempty"` +} + +func (IssueMatch) IsNode() {} +func (this IssueMatch) GetID() string { return this.ID } + +type IssueMatchChange struct { + ID string `json:"id"` + Action *IssueMatchChangeActions `json:"action,omitempty"` + IssueMatchID *string `json:"issueMatchId,omitempty"` + IssueMatch *IssueMatch `json:"issueMatch"` + ActivityID *string `json:"activityId,omitempty"` + Activity *Activity `json:"activity"` +} + +func (IssueMatchChange) IsNode() {} +func (this IssueMatchChange) GetID() string { return this.ID } + +type IssueMatchChangeConnection struct { + TotalCount int `json:"totalCount"` + Edges []*IssueMatchChangeEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (IssueMatchChangeConnection) IsConnection() {} +func (this IssueMatchChangeConnection) GetTotalCount() int { return this.TotalCount } +func (this IssueMatchChangeConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type IssueMatchChangeEdge struct { + Node *IssueMatchChange `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (IssueMatchChangeEdge) IsEdge() {} +func (this IssueMatchChangeEdge) GetNode() Node { return *this.Node } +func (this IssueMatchChangeEdge) GetCursor() *string { return this.Cursor } + +type IssueMatchChangeFilter struct { + Action []*IssueMatchChangeActions `json:"action,omitempty"` +} + +type IssueMatchConnection struct { + TotalCount int `json:"totalCount"` + Edges []*IssueMatchEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (IssueMatchConnection) IsConnection() {} +func (this IssueMatchConnection) GetTotalCount() int { return this.TotalCount } +func (this IssueMatchConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type IssueMatchEdge struct { + Node *IssueMatch `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (IssueMatchEdge) IsEdge() {} +func (this IssueMatchEdge) GetNode() Node { return *this.Node } +func (this IssueMatchEdge) GetCursor() *string { return this.Cursor } + +type IssueMatchFilter struct { + Status []*IssueMatchStatusValues `json:"status,omitempty"` + Severity []*SeverityValues `json:"severity,omitempty"` + AffectedService []*string `json:"affectedService,omitempty"` + SupportGroupName []*string `json:"SupportGroupName,omitempty"` +} + +type IssueMatchInput struct { + Status *IssueMatchStatusValues `json:"status,omitempty"` + RemediationDate *string `json:"remediationDate,omitempty"` + DiscoveryDate *string `json:"discoveryDate,omitempty"` + TargetRemediationDate *string `json:"targetRemediationDate,omitempty"` + IssueID *string `json:"issueId,omitempty"` + ComponentInstanceID *string `json:"componentInstanceId,omitempty"` + UserID *string `json:"userId,omitempty"` +} + +type IssueMetadata struct { + ServiceCount int `json:"serviceCount"` + ActivityCount int `json:"activityCount"` + IssueMatchCount int `json:"issueMatchCount"` + ComponentInstanceCount int `json:"componentInstanceCount"` + ComponentVersionCount int `json:"componentVersionCount"` + EarliestDiscoveryDate string `json:"earliestDiscoveryDate"` + EarliestTargetRemediationDate string `json:"earliestTargetRemediationDate"` +} + +type IssueRepository struct { + ID string `json:"id"` + Name *string `json:"name,omitempty"` + URL *string `json:"url,omitempty"` + IssueVariants *IssueVariantConnection `json:"issueVariants,omitempty"` + Services *ServiceConnection `json:"services,omitempty"` + CreatedAt *string `json:"created_at,omitempty"` + UpdatedAt *string `json:"updated_at,omitempty"` +} + +func (IssueRepository) IsNode() {} +func (this IssueRepository) GetID() string { return this.ID } + +type IssueRepositoryConnection struct { + TotalCount int `json:"totalCount"` + Edges []*IssueRepositoryEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (IssueRepositoryConnection) IsConnection() {} +func (this IssueRepositoryConnection) GetTotalCount() int { return this.TotalCount } +func (this IssueRepositoryConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type IssueRepositoryEdge struct { + Node *IssueRepository `json:"node"` + Cursor *string `json:"cursor,omitempty"` + Priority *int `json:"priority,omitempty"` + CreatedAt *string `json:"created_at,omitempty"` + UpdatedAt *string `json:"updated_at,omitempty"` +} + +func (IssueRepositoryEdge) IsEdge() {} +func (this IssueRepositoryEdge) GetNode() Node { return *this.Node } +func (this IssueRepositoryEdge) GetCursor() *string { return this.Cursor } + +type IssueRepositoryFilter struct { + ServiceName []*string `json:"serviceName,omitempty"` + ServiceID []*string `json:"serviceId,omitempty"` + Name []*string `json:"name,omitempty"` +} + +type IssueRepositoryInput struct { + Name *string `json:"name,omitempty"` + URL *string `json:"url,omitempty"` +} + +type IssueVariant struct { + ID string `json:"id"` + SecondaryName *string `json:"secondaryName,omitempty"` + Description *string `json:"description,omitempty"` + Severity *Severity `json:"severity,omitempty"` + IssueRepositoryID *string `json:"issueRepositoryId,omitempty"` + IssueRepository *IssueRepository `json:"issueRepository,omitempty"` + IssueID *string `json:"issueId,omitempty"` + Issue *Issue `json:"issue,omitempty"` + CreatedAt *string `json:"created_at,omitempty"` + UpdatedAt *string `json:"updated_at,omitempty"` +} + +func (IssueVariant) IsNode() {} +func (this IssueVariant) GetID() string { return this.ID } + +type IssueVariantConnection struct { + TotalCount int `json:"totalCount"` + Edges []*IssueVariantEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (IssueVariantConnection) IsConnection() {} +func (this IssueVariantConnection) GetTotalCount() int { return this.TotalCount } +func (this IssueVariantConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type IssueVariantEdge struct { + Node *IssueVariant `json:"node"` + Cursor *string `json:"cursor,omitempty"` + CreatedAt *string `json:"created_at,omitempty"` + UpdatedAt *string `json:"updated_at,omitempty"` +} + +func (IssueVariantEdge) IsEdge() {} +func (this IssueVariantEdge) GetNode() Node { return *this.Node } +func (this IssueVariantEdge) GetCursor() *string { return this.Cursor } + +type IssueVariantFilter struct { + SecondaryName []*string `json:"secondaryName,omitempty"` +} + +type IssueVariantInput struct { + SecondaryName *string `json:"secondaryName,omitempty"` + Description *string `json:"description,omitempty"` + IssueRepositoryID *string `json:"issueRepositoryId,omitempty"` + IssueID *string `json:"issueId,omitempty"` + Severity *SeverityInput `json:"severity,omitempty"` +} + +type Mutation struct { +} + +type Page struct { + After *string `json:"after,omitempty"` + IsCurrent *bool `json:"isCurrent,omitempty"` + PageNumber *int `json:"pageNumber,omitempty"` + PageCount *int `json:"pageCount,omitempty"` +} + +type PageInfo struct { + HasNextPage *bool `json:"hasNextPage,omitempty"` + HasPreviousPage *bool `json:"hasPreviousPage,omitempty"` + IsValidPage *bool `json:"isValidPage,omitempty"` + PageNumber *int `json:"pageNumber,omitempty"` + NextPageAfter *string `json:"nextPageAfter,omitempty"` + Pages []*Page `json:"pages,omitempty"` +} + +type Query struct { +} + +type Service struct { + ID string `json:"id"` + Name *string `json:"name,omitempty"` + Owners *UserConnection `json:"owners,omitempty"` + SupportGroups *SupportGroupConnection `json:"supportGroups,omitempty"` + Activities *ActivityConnection `json:"activities,omitempty"` + IssueRepositories *IssueRepositoryConnection `json:"issueRepositories,omitempty"` + ComponentInstances *ComponentInstanceConnection `json:"componentInstances,omitempty"` +} + +func (Service) IsNode() {} +func (this Service) GetID() string { return this.ID } + +type ServiceConnection struct { + TotalCount int `json:"totalCount"` + Edges []*ServiceEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (ServiceConnection) IsConnection() {} +func (this ServiceConnection) GetTotalCount() int { return this.TotalCount } +func (this ServiceConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type ServiceEdge struct { + Node *Service `json:"node"` + Cursor *string `json:"cursor,omitempty"` + Priority *int `json:"priority,omitempty"` +} + +func (ServiceEdge) IsEdge() {} +func (this ServiceEdge) GetNode() Node { return *this.Node } +func (this ServiceEdge) GetCursor() *string { return this.Cursor } + +type ServiceFilter struct { + ServiceName []*string `json:"serviceName,omitempty"` + UserSapID []*string `json:"userSapID,omitempty"` + UserName []*string `json:"userName,omitempty"` + SupportGroupName []*string `json:"supportGroupName,omitempty"` +} + +type ServiceInput struct { + Name *string `json:"name,omitempty"` +} + +type Severity struct { + Value *SeverityValues `json:"value,omitempty"` + Score *float64 `json:"score,omitempty"` + Cvss *Cvss `json:"cvss,omitempty"` +} + +type SeverityInput struct { + Vector *string `json:"vector,omitempty"` +} + +type SupportGroup struct { + ID string `json:"id"` + Name *string `json:"name,omitempty"` + Users *UserConnection `json:"users,omitempty"` + Services *ServiceConnection `json:"services,omitempty"` +} + +func (SupportGroup) IsNode() {} +func (this SupportGroup) GetID() string { return this.ID } + +type SupportGroupConnection struct { + TotalCount int `json:"totalCount"` + Edges []*SupportGroupEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (SupportGroupConnection) IsConnection() {} +func (this SupportGroupConnection) GetTotalCount() int { return this.TotalCount } +func (this SupportGroupConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type SupportGroupEdge struct { + Node *SupportGroup `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (SupportGroupEdge) IsEdge() {} +func (this SupportGroupEdge) GetNode() Node { return *this.Node } +func (this SupportGroupEdge) GetCursor() *string { return this.Cursor } + +type SupportGroupFilter struct { + SupportGroupName []*string `json:"supportGroupName,omitempty"` + UserIds []*string `json:"userIds,omitempty"` +} + +type SupportGroupInput struct { + Name *string `json:"name,omitempty"` +} + +type User struct { + ID string `json:"id"` + SapID *string `json:"sapID,omitempty"` + Name *string `json:"name,omitempty"` + SupportGroups *SupportGroupConnection `json:"supportGroups,omitempty"` + Services *ServiceConnection `json:"services,omitempty"` +} + +func (User) IsNode() {} +func (this User) GetID() string { return this.ID } + +type UserConnection struct { + TotalCount int `json:"totalCount"` + Edges []*UserEdge `json:"edges,omitempty"` + PageInfo *PageInfo `json:"pageInfo,omitempty"` +} + +func (UserConnection) IsConnection() {} +func (this UserConnection) GetTotalCount() int { return this.TotalCount } +func (this UserConnection) GetPageInfo() *PageInfo { return this.PageInfo } + +type UserEdge struct { + Node *User `json:"node"` + Cursor *string `json:"cursor,omitempty"` +} + +func (UserEdge) IsEdge() {} +func (this UserEdge) GetNode() Node { return *this.Node } +func (this UserEdge) GetCursor() *string { return this.Cursor } + +type UserFilter struct { + UserName []*string `json:"userName,omitempty"` + SupportGroupIds []*string `json:"supportGroupIds,omitempty"` +} + +type UserInput struct { + SapID *string `json:"sapID,omitempty"` + Name *string `json:"name,omitempty"` +} + +type ActivityStatusValues string + +const ( + ActivityStatusValuesOpen ActivityStatusValues = "open" + ActivityStatusValuesClosed ActivityStatusValues = "closed" + ActivityStatusValuesInProgress ActivityStatusValues = "in_progress" +) + +var AllActivityStatusValues = []ActivityStatusValues{ + ActivityStatusValuesOpen, + ActivityStatusValuesClosed, + ActivityStatusValuesInProgress, +} + +func (e ActivityStatusValues) IsValid() bool { + switch e { + case ActivityStatusValuesOpen, ActivityStatusValuesClosed, ActivityStatusValuesInProgress: + return true + } + return false +} + +func (e ActivityStatusValues) String() string { + return string(e) +} + +func (e *ActivityStatusValues) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = ActivityStatusValues(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid ActivityStatusValues", str) + } + return nil +} + +func (e ActivityStatusValues) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} + +type ComponentTypeValues string + +const ( + ComponentTypeValuesContainerImage ComponentTypeValues = "containerImage" + ComponentTypeValuesVirtualMachineImage ComponentTypeValues = "virtualMachineImage" + ComponentTypeValuesRepository ComponentTypeValues = "repository" +) + +var AllComponentTypeValues = []ComponentTypeValues{ + ComponentTypeValuesContainerImage, + ComponentTypeValuesVirtualMachineImage, + ComponentTypeValuesRepository, +} + +func (e ComponentTypeValues) IsValid() bool { + switch e { + case ComponentTypeValuesContainerImage, ComponentTypeValuesVirtualMachineImage, ComponentTypeValuesRepository: + return true + } + return false +} + +func (e ComponentTypeValues) String() string { + return string(e) +} + +func (e *ComponentTypeValues) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = ComponentTypeValues(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid ComponentTypeValues", str) + } + return nil +} + +func (e ComponentTypeValues) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} + +type IssueMatchChangeActions string + +const ( + IssueMatchChangeActionsAdd IssueMatchChangeActions = "add" + IssueMatchChangeActionsRemove IssueMatchChangeActions = "remove" +) + +var AllIssueMatchChangeActions = []IssueMatchChangeActions{ + IssueMatchChangeActionsAdd, + IssueMatchChangeActionsRemove, +} + +func (e IssueMatchChangeActions) IsValid() bool { + switch e { + case IssueMatchChangeActionsAdd, IssueMatchChangeActionsRemove: + return true + } + return false +} + +func (e IssueMatchChangeActions) String() string { + return string(e) +} + +func (e *IssueMatchChangeActions) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = IssueMatchChangeActions(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid IssueMatchChangeActions", str) + } + return nil +} + +func (e IssueMatchChangeActions) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} + +type IssueMatchStatusValues string + +const ( + IssueMatchStatusValuesNew IssueMatchStatusValues = "new" + IssueMatchStatusValuesRiskAccepted IssueMatchStatusValues = "risk_accepted" + IssueMatchStatusValuesFalsePositive IssueMatchStatusValues = "false_positive" + IssueMatchStatusValuesMitigated IssueMatchStatusValues = "mitigated" +) + +var AllIssueMatchStatusValues = []IssueMatchStatusValues{ + IssueMatchStatusValuesNew, + IssueMatchStatusValuesRiskAccepted, + IssueMatchStatusValuesFalsePositive, + IssueMatchStatusValuesMitigated, +} + +func (e IssueMatchStatusValues) IsValid() bool { + switch e { + case IssueMatchStatusValuesNew, IssueMatchStatusValuesRiskAccepted, IssueMatchStatusValuesFalsePositive, IssueMatchStatusValuesMitigated: + return true + } + return false +} + +func (e IssueMatchStatusValues) String() string { + return string(e) +} + +func (e *IssueMatchStatusValues) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = IssueMatchStatusValues(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid IssueMatchStatusValues", str) + } + return nil +} + +func (e IssueMatchStatusValues) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} + +type IssueStatusValues string + +const ( + IssueStatusValuesUnaffected IssueStatusValues = "unaffected" + IssueStatusValuesOpen IssueStatusValues = "open" + IssueStatusValuesRemediated IssueStatusValues = "remediated" + IssueStatusValuesOverdue IssueStatusValues = "overdue" +) + +var AllIssueStatusValues = []IssueStatusValues{ + IssueStatusValuesUnaffected, + IssueStatusValuesOpen, + IssueStatusValuesRemediated, + IssueStatusValuesOverdue, +} + +func (e IssueStatusValues) IsValid() bool { + switch e { + case IssueStatusValuesUnaffected, IssueStatusValuesOpen, IssueStatusValuesRemediated, IssueStatusValuesOverdue: + return true + } + return false +} + +func (e IssueStatusValues) String() string { + return string(e) +} + +func (e *IssueStatusValues) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = IssueStatusValues(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid IssueStatusValues", str) + } + return nil +} + +func (e IssueStatusValues) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} + +type IssueTypes string + +const ( + IssueTypesVulnerability IssueTypes = "Vulnerability" + IssueTypesPolicyViolation IssueTypes = "PolicyViolation" + IssueTypesSecurityEvent IssueTypes = "SecurityEvent" +) + +var AllIssueTypes = []IssueTypes{ + IssueTypesVulnerability, + IssueTypesPolicyViolation, + IssueTypesSecurityEvent, +} + +func (e IssueTypes) IsValid() bool { + switch e { + case IssueTypesVulnerability, IssueTypesPolicyViolation, IssueTypesSecurityEvent: + return true + } + return false +} + +func (e IssueTypes) String() string { + return string(e) +} + +func (e *IssueTypes) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = IssueTypes(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid IssueTypes", str) + } + return nil +} + +func (e IssueTypes) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} + +type SeverityValues string + +const ( + SeverityValuesNone SeverityValues = "None" + SeverityValuesLow SeverityValues = "Low" + SeverityValuesMedium SeverityValues = "Medium" + SeverityValuesHigh SeverityValues = "High" + SeverityValuesCritical SeverityValues = "Critical" +) + +var AllSeverityValues = []SeverityValues{ + SeverityValuesNone, + SeverityValuesLow, + SeverityValuesMedium, + SeverityValuesHigh, + SeverityValuesCritical, +} + +func (e SeverityValues) IsValid() bool { + switch e { + case SeverityValuesNone, SeverityValuesLow, SeverityValuesMedium, SeverityValuesHigh, SeverityValuesCritical: + return true + } + return false +} + +func (e SeverityValues) String() string { + return string(e) +} + +func (e *SeverityValues) UnmarshalGQL(v interface{}) error { + str, ok := v.(string) + if !ok { + return fmt.Errorf("enums must be strings") + } + + *e = SeverityValues(str) + if !e.IsValid() { + return fmt.Errorf("%s is not a valid SeverityValues", str) + } + return nil +} + +func (e SeverityValues) MarshalGQL(w io.Writer) { + fmt.Fprint(w, strconv.Quote(e.String())) +} diff --git a/internal/api/graphql/graph/queryCollection/activity/create.graphql b/internal/api/graphql/graph/queryCollection/activity/create.graphql new file mode 100644 index 00000000..273df155 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/activity/create.graphql @@ -0,0 +1,8 @@ +mutation ($input: ActivityInput!) { + createActivity ( + input: $input + ) { + id + status + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/activity/delete.graphql b/internal/api/graphql/graph/queryCollection/activity/delete.graphql new file mode 100644 index 00000000..999a58d1 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/activity/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteActivity ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/activity/directRelations.graphql b/internal/api/graphql/graph/queryCollection/activity/directRelations.graphql new file mode 100644 index 00000000..4b6d7ee8 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/activity/directRelations.graphql @@ -0,0 +1,87 @@ +query ($filter: ActivityFilter, $first: Int, $after: String) { + Activities ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + services { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issues { + totalCount + edges { + node { + id + lastModified + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + evidences { + totalCount + edges { + node { + id + description + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issueMatchChanges { + totalCount + edges { + node { + id + action + issueMatchId + activityId + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/activity/full.graphql b/internal/api/graphql/graph/queryCollection/activity/full.graphql new file mode 100644 index 00000000..d4d57d32 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/activity/full.graphql @@ -0,0 +1,260 @@ +query ($filter: ActivityFilter, $first: Int, $after: String) { + Activities ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + services { + totalCount + edges { + node { + id + name + owners { + totalCount + edges { + node { + id + sapID + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + supportGroups { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + activities { + totalCount + edges { + node { + id + services { + totalCount + } + issues { + totalCount + } + evidences { + totalCount + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issues { + totalCount + edges { + node { + id + lastModified + issueVariants { + totalCount + edges { + node { + id + name + description + severity { + value + score + } + issues { + id + lastModified + } + created_at + updated_at + } + cursor + created_at + updated_at + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issueMatches { + totalCount + edges { + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + evidences { + totalCount + } + issue { + id + lastModified + } + componentInstance { + id + ccrn + count + createdAt + updatedAt + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + metadata { + serviceCount + activityCount + issueMatchCount + componentInstanceCount + earliestDiscoveryDate + earliestTargetRemediationDate + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + evidences { + totalCount + edges { + node { + id + description + author { + id + sapID + name + } + activity { + id + services { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issues { + totalCount + edges { + node { + id + lastModified + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + evidences { + totalCount + edges { + node { + id + description + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + issueMatches { + totalCount + edges { + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + evidences { + totalCount + } + issue { + id + lastModified + } + componentInstance { + id + ccrn + count + createdAt + updatedAt + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/activity/update.graphql b/internal/api/graphql/graph/queryCollection/activity/update.graphql new file mode 100644 index 00000000..4815e467 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/activity/update.graphql @@ -0,0 +1,9 @@ +mutation ($id: ID!, $input: ActivityInput!) { + updateActivity ( + id: $id, + input: $input + ) { + id + status + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/activity/withPageInfo.graphql b/internal/api/graphql/graph/queryCollection/activity/withPageInfo.graphql new file mode 100644 index 00000000..b0ecdc79 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/activity/withPageInfo.graphql @@ -0,0 +1,20 @@ +query ($filter: ActivityFilter, $first: Int, $after: String) { + Activities ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/component/create.graphql b/internal/api/graphql/graph/queryCollection/component/create.graphql new file mode 100644 index 00000000..0bc17e77 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/component/create.graphql @@ -0,0 +1,9 @@ +mutation ($input: ComponentInput!) { + createComponent ( + input: $input + ) { + id + name + type + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/component/delete.graphql b/internal/api/graphql/graph/queryCollection/component/delete.graphql new file mode 100644 index 00000000..bab4b731 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/component/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteComponent ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/component/directRelations.graphql b/internal/api/graphql/graph/queryCollection/component/directRelations.graphql new file mode 100644 index 00000000..2c17114f --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/component/directRelations.graphql @@ -0,0 +1,46 @@ +query ($filter: ComponentFilter, $first: Int, $after: String) { + Components ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + name + type + componentVersions { + totalCount + edges { + node { + id + version + componentId + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/component/minimal.graphql b/internal/api/graphql/graph/queryCollection/component/minimal.graphql new file mode 100644 index 00000000..fab4f035 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/component/minimal.graphql @@ -0,0 +1,18 @@ + +query ($filter: ComponentFilter, $first: Int, $after: String) { + Components ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + name + type + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/component/update.graphql b/internal/api/graphql/graph/queryCollection/component/update.graphql new file mode 100644 index 00000000..88dfb206 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/component/update.graphql @@ -0,0 +1,10 @@ +mutation ($id: ID!, $input: ComponentInput!) { + updateComponent ( + id: $id, + input: $input + ) { + __typename + id + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentInstance/create.graphql b/internal/api/graphql/graph/queryCollection/componentInstance/create.graphql new file mode 100644 index 00000000..c0c93362 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentInstance/create.graphql @@ -0,0 +1,11 @@ +mutation ($input: ComponentInstanceInput!) { + createComponentInstance ( + input: $input + ) { + id + ccrn + count + componentVersionId + serviceId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentInstance/delete.graphql b/internal/api/graphql/graph/queryCollection/componentInstance/delete.graphql new file mode 100644 index 00000000..e99b8575 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentInstance/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteComponentInstance ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentInstance/directRelations.graphql b/internal/api/graphql/graph/queryCollection/componentInstance/directRelations.graphql new file mode 100644 index 00000000..2fd76659 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentInstance/directRelations.graphql @@ -0,0 +1,57 @@ +query ($filter: ComponentInstanceFilter, $first: Int, $after: String) { + ComponentInstances ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + ccrn + count + componentVersionId + componentVersion { + id + version + componentId + } + serviceId + service { + id + name + } + createdAt + updatedAt + issueMatches { + totalCount + edges { + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + } + cursor + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentInstance/minimal.graphql b/internal/api/graphql/graph/queryCollection/componentInstance/minimal.graphql new file mode 100644 index 00000000..05b0a691 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentInstance/minimal.graphql @@ -0,0 +1,17 @@ + +query ($filter: ComponentInstanceFilter, $first: Int, $after: String) { + ComponentInstances ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + ccrn + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentInstance/update.graphql b/internal/api/graphql/graph/queryCollection/componentInstance/update.graphql new file mode 100644 index 00000000..a3ee3299 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentInstance/update.graphql @@ -0,0 +1,13 @@ +mutation ($id: ID!, $input: ComponentInstanceInput!) { + updateComponentInstance ( + id: $id, + input: $input + ) { + __typename + id + ccrn + count + componentVersionId + serviceId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentVersion/create.graphql b/internal/api/graphql/graph/queryCollection/componentVersion/create.graphql new file mode 100644 index 00000000..9850f50d --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentVersion/create.graphql @@ -0,0 +1,9 @@ +mutation ($input: ComponentVersionInput!) { + createComponentVersion ( + input: $input + ) { + id + version + componentId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentVersion/delete.graphql b/internal/api/graphql/graph/queryCollection/componentVersion/delete.graphql new file mode 100644 index 00000000..6827cb53 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentVersion/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteComponentVersion ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentVersion/directRelations.graphql b/internal/api/graphql/graph/queryCollection/componentVersion/directRelations.graphql new file mode 100644 index 00000000..a86a83ec --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentVersion/directRelations.graphql @@ -0,0 +1,50 @@ +query ($filter: ComponentVersionFilter, $first: Int, $after: String) { + ComponentVersions ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + version + componentId + component { + id + name + type + } + issues { + totalCount + edges { + node { + id + lastModified + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentVersion/minimal.graphql b/internal/api/graphql/graph/queryCollection/componentVersion/minimal.graphql new file mode 100644 index 00000000..dab45dff --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentVersion/minimal.graphql @@ -0,0 +1,17 @@ + +query ($filter: ComponentVersionFilter, $first: Int, $after: String) { + ComponentVersions ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + version + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/componentVersion/update.graphql b/internal/api/graphql/graph/queryCollection/componentVersion/update.graphql new file mode 100644 index 00000000..04083526 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/componentVersion/update.graphql @@ -0,0 +1,11 @@ +mutation ($id: ID!, $input: ComponentVersionInput!) { + updateComponentVersion ( + id: $id, + input: $input + ) { + __typename + id + version + componentId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/evidence/create.graphql b/internal/api/graphql/graph/queryCollection/evidence/create.graphql new file mode 100644 index 00000000..be7ae479 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/evidence/create.graphql @@ -0,0 +1,13 @@ +mutation ($input: EvidenceInput!) { + createEvidence ( + input: $input + ) { + id + description + raaEnd + type + vector + authorId + activityId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/evidence/delete.graphql b/internal/api/graphql/graph/queryCollection/evidence/delete.graphql new file mode 100644 index 00000000..8586ad67 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/evidence/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteEvidence ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/evidence/directRelations.graphql b/internal/api/graphql/graph/queryCollection/evidence/directRelations.graphql new file mode 100644 index 00000000..ae969c6c --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/evidence/directRelations.graphql @@ -0,0 +1,57 @@ +query ($filter: EvidenceFilter, $first: Int, $after: String) { + Evidences ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + description + authorId + author { + id + sapID + name + } + activityId + activity { + id + } + issueMatches { + totalCount + edges { + cursor + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + } + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/evidence/minimal.graphql b/internal/api/graphql/graph/queryCollection/evidence/minimal.graphql new file mode 100644 index 00000000..b62f09a6 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/evidence/minimal.graphql @@ -0,0 +1,16 @@ + +query ($filter: EvidenceFilter, $first: Int, $after: String) { + Evidences ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/evidence/update.graphql b/internal/api/graphql/graph/queryCollection/evidence/update.graphql new file mode 100644 index 00000000..85b1b51b --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/evidence/update.graphql @@ -0,0 +1,14 @@ +mutation ($id: ID!, $input: EvidenceInput!) { + updateEvidence ( + id: $id, + input: $input + ) { + id + description + raaEnd + type + vector + authorId + activityId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issue/directRelations.graphql b/internal/api/graphql/graph/queryCollection/issue/directRelations.graphql new file mode 100644 index 00000000..938a63e6 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issue/directRelations.graphql @@ -0,0 +1,95 @@ +query ($filter: IssueFilter, $first: Int, $after: String) { + Issues ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + primaryName + type + lastModified + issueVariants { + totalCount + edges { + node { + id + secondaryName + description + severity { + value + score + } + issueRepositoryId + issueRepository { + id + name + url + created_at + updated_at + } + issueId + created_at + updated_at + } + cursor + created_at + updated_at + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issueMatches { + totalCount + edges { + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + componentInstance { + id + count + createdAt + updatedAt + ccrn + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + metadata { + serviceCount + activityCount + issueMatchCount + componentInstanceCount + earliestDiscoveryDate + earliestTargetRemediationDate + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issue/full.graphql b/internal/api/graphql/graph/queryCollection/issue/full.graphql new file mode 100644 index 00000000..b13de819 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issue/full.graphql @@ -0,0 +1,157 @@ +query ($filter: IssueFilter, $first: Int, $after: String) { + Issues ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + primaryName + lastModified + type + issueVariants { + totalCount + edges { + node { + id + secondaryName + description + severity { + value + score + cvss { + vector + base { + score + attackVector + attackComplexity + privilegesRequired + userInteraction + scope + confidentialityImpact + integrityImpact + availabilityImpact + } + temporal { + score + exploitCodeMaturity + remediationLevel + reportConfidence + } + environmental { + score + modifiedAttackVector + modifiedAttackComplexity + modifiedPrivilegesRequired + modifiedUserInteraction + modifiedScope + modifiedConfidentialityImpact + modifiedIntegrityImpact + modifiedAvailabilityImpact + confidentialityRequirement + availabilityRequirement + integrityRequirement + } + } + } + issueRepository { + id + name + url + created_at + updated_at + } + created_at + updated_at + } + cursor + created_at + updated_at + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issueMatches { + totalCount + edges { + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + componentInstance { + id + componentVersion { + id + version + component { + id + name + type + } + } + service { + id + name + owners { + totalCount + edges { + node { + id + sapID + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + supportGroups { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + metadata { + serviceCount + activityCount + issueMatchCount + componentInstanceCount + earliestDiscoveryDate + earliestTargetRemediationDate + } + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issue/minimal.graphql b/internal/api/graphql/graph/queryCollection/issue/minimal.graphql new file mode 100644 index 00000000..b4242ecc --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issue/minimal.graphql @@ -0,0 +1,16 @@ +query ($filter: IssueFilter, $first: Int, $after: String) { + Issues ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + lastModified + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issue/withMetadata.graphql b/internal/api/graphql/graph/queryCollection/issue/withMetadata.graphql new file mode 100644 index 00000000..2ba46cab --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issue/withMetadata.graphql @@ -0,0 +1,24 @@ +query ($filter: IssueFilter, $first: Int, $after: String) { + Issues ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + lastModified + metadata { + serviceCount + activityCount + issueMatchCount + componentInstanceCount + earliestDiscoveryDate + earliestTargetRemediationDate + } + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issue/withPageInfo.graphql b/internal/api/graphql/graph/queryCollection/issue/withPageInfo.graphql new file mode 100644 index 00000000..054a4f44 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issue/withPageInfo.graphql @@ -0,0 +1,20 @@ +query ($filter: IssueFilter, $first: Int, $after: String) { + Issues ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + lastModified + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatch/create.graphql b/internal/api/graphql/graph/queryCollection/issueMatch/create.graphql new file mode 100644 index 00000000..d1fce1a8 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatch/create.graphql @@ -0,0 +1,21 @@ +mutation ($input: IssueMatchInput!) { + createIssueMatch ( + input: $input + ) { + id + status + remediationDate + discoveryDate + targetRemediationDate + componentInstanceId + issueId + userId + severity { + value + score + cvss { + vector + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatch/delete.graphql b/internal/api/graphql/graph/queryCollection/issueMatch/delete.graphql new file mode 100644 index 00000000..199c08be --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatch/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteIssueMatch ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatch/directRelations.graphql b/internal/api/graphql/graph/queryCollection/issueMatch/directRelations.graphql new file mode 100644 index 00000000..ae2011ea --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatch/directRelations.graphql @@ -0,0 +1,87 @@ +query ($filter: IssueMatchFilter, $first: Int, $after: String) { + IssueMatches ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + status + remediationDate + discoveryDate + targetRemediationDate + severity { + value + score + } + effectiveIssueVariants { + edges { + node { + id + secondaryName + description + } + } + } + evidences { + totalCount + edges { + node { + id + description + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issueId + issue { + id + lastModified + } + componentInstanceId + componentInstance { + id + ccrn + count + } + issueMatchChanges { + totalCount + edges { + node { + id + action + issueMatchId + activityId + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatch/minimal.graphql b/internal/api/graphql/graph/queryCollection/issueMatch/minimal.graphql new file mode 100644 index 00000000..501c063f --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatch/minimal.graphql @@ -0,0 +1,15 @@ +query ($filter: IssueMatchFilter, $first: Int, $after: String) { + IssueMatches ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatch/update.graphql b/internal/api/graphql/graph/queryCollection/issueMatch/update.graphql new file mode 100644 index 00000000..e593f2eb --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatch/update.graphql @@ -0,0 +1,22 @@ +mutation ($id: ID!, $input: IssueMatchInput!) { + updateIssueMatch ( + id: $id, + input: $input + ) { + id + status + remediationDate + discoveryDate + targetRemediationDate + severity { + value + score + cvss { + vector + } + } + componentInstanceId + issueId + userId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatchChange/directRelations.graphql b/internal/api/graphql/graph/queryCollection/issueMatchChange/directRelations.graphql new file mode 100644 index 00000000..e5c7d41e --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatchChange/directRelations.graphql @@ -0,0 +1,44 @@ +query ($filter: IssueMatchChangeFilter, $first: Int, $after: String) { + IssueMatchChanges ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + action + issueMatchId + issueMatch { + id + status + remediationDate + discoveryDate + targetRemediationDate + issueId + componentInstanceId + } + activityId + activity { + id + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueMatchChange/minimal.graphql b/internal/api/graphql/graph/queryCollection/issueMatchChange/minimal.graphql new file mode 100644 index 00000000..23deafe6 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueMatchChange/minimal.graphql @@ -0,0 +1,16 @@ + +query ($filter: IssueMatchChangeFilter, $first: Int, $after: String) { + IssueMatchChanges ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueRepository/create.graphql b/internal/api/graphql/graph/queryCollection/issueRepository/create.graphql new file mode 100644 index 00000000..371250c7 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueRepository/create.graphql @@ -0,0 +1,9 @@ +mutation ($input: IssueRepositoryInput!) { + createIssueRepository ( + input: $input + ) { + id + name + url + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueRepository/delete.graphql b/internal/api/graphql/graph/queryCollection/issueRepository/delete.graphql new file mode 100644 index 00000000..ff2175f6 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueRepository/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteIssueRepository ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueRepository/directRelations.graphql b/internal/api/graphql/graph/queryCollection/issueRepository/directRelations.graphql new file mode 100644 index 00000000..3ec0ebf3 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueRepository/directRelations.graphql @@ -0,0 +1,71 @@ +query ($filter: IssueRepositoryFilter, $first: Int, $after: String) { + IssueRepositories ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + name + url + issueVariants { + totalCount + edges { + node { + id + secondaryName + description + issueRepositoryId + issueId + created_at + updated_at + } + cursor + created_at + updated_at + } + pageInfo { + hasNextPage + nextPageAfter + } + } + services { + totalCount + edges { + node { + id + name + } + cursor + priority + } + pageInfo { + hasNextPage + nextPageAfter + } + } + created_at + updated_at + } + cursor + created_at + updated_at + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueRepository/minimal.graphql b/internal/api/graphql/graph/queryCollection/issueRepository/minimal.graphql new file mode 100644 index 00000000..2ea83458 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueRepository/minimal.graphql @@ -0,0 +1,17 @@ + +query ($filter: IssueRepositoryFilter, $first: Int, $after: String) { + IssueRepositories ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + name + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueRepository/update.graphql b/internal/api/graphql/graph/queryCollection/issueRepository/update.graphql new file mode 100644 index 00000000..887e82f1 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueRepository/update.graphql @@ -0,0 +1,11 @@ +mutation ($id: ID!, $input: IssueRepositoryInput!) { + updateIssueRepository ( + id: $id, + input: $input + ) { + __typename + id + name + url + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueVariant/create.graphql b/internal/api/graphql/graph/queryCollection/issueVariant/create.graphql new file mode 100644 index 00000000..f98366e6 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueVariant/create.graphql @@ -0,0 +1,18 @@ +mutation ($input: IssueVariantInput!) { + createIssueVariant ( + input: $input + ) { + id + secondaryName + description + severity { + value + score + cvss { + vector + } + } + issueRepositoryId + issueId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueVariant/delete.graphql b/internal/api/graphql/graph/queryCollection/issueVariant/delete.graphql new file mode 100644 index 00000000..17389884 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueVariant/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteIssueVariant ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueVariant/directRelations.graphql b/internal/api/graphql/graph/queryCollection/issueVariant/directRelations.graphql new file mode 100644 index 00000000..6adc7707 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueVariant/directRelations.graphql @@ -0,0 +1,52 @@ +query ($filter: IssueVariantFilter, $first: Int, $after: String) { + IssueVariants ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + secondaryName + description + severity { + value + score + } + issueRepositoryId + issueRepository { + id + name + url + created_at + updated_at + } + issueId + issue { + id + lastModified + } + created_at + updated_at + } + cursor + created_at + updated_at + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueVariant/minimal.graphql b/internal/api/graphql/graph/queryCollection/issueVariant/minimal.graphql new file mode 100644 index 00000000..8461ed56 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueVariant/minimal.graphql @@ -0,0 +1,17 @@ + +query ($filter: IssueVariantFilter, $first: Int, $after: String) { + IssueVariants ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + secondaryName + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/issueVariant/update.graphql b/internal/api/graphql/graph/queryCollection/issueVariant/update.graphql new file mode 100644 index 00000000..978c8d79 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/issueVariant/update.graphql @@ -0,0 +1,20 @@ +mutation ($id: ID!, $input: IssueVariantInput!) { + updateIssueVariant ( + id: $id, + input: $input + ) { + __typename + id + secondaryName + description + severity { + value + score + cvss { + vector + } + } + issueRepositoryId + issueId + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/service/create.graphql b/internal/api/graphql/graph/queryCollection/service/create.graphql new file mode 100644 index 00000000..4ec99a57 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/service/create.graphql @@ -0,0 +1,8 @@ +mutation ($input: ServiceInput!) { + createService ( + input: $input + ) { + id + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/service/delete.graphql b/internal/api/graphql/graph/queryCollection/service/delete.graphql new file mode 100644 index 00000000..c3e70410 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/service/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteService ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/service/directRelations.graphql b/internal/api/graphql/graph/queryCollection/service/directRelations.graphql new file mode 100644 index 00000000..765e1d13 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/service/directRelations.graphql @@ -0,0 +1,102 @@ +query ($filter: ServiceFilter, $first: Int, $after: String) { + Services ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + name + owners { + totalCount + edges { + node { + id + sapID + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + supportGroups { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + activities { + totalCount + edges { + node { + id + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + issueRepositories { + totalCount + edges { + node { + id + name + url + created_at + updated_at + } + cursor + priority + created_at + updated_at + } + pageInfo { + hasNextPage + nextPageAfter + } + } + componentInstances { + totalCount + edges { + node { + id + ccrn + count + } + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/service/minimal.graphql b/internal/api/graphql/graph/queryCollection/service/minimal.graphql new file mode 100644 index 00000000..ced7641a --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/service/minimal.graphql @@ -0,0 +1,16 @@ +query ($filter: ServiceFilter, $first: Int, $after: String) { + Services ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + name + } + cursor + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/service/update.graphql b/internal/api/graphql/graph/queryCollection/service/update.graphql new file mode 100644 index 00000000..36c995ac --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/service/update.graphql @@ -0,0 +1,10 @@ +mutation ($id: ID!, $input: ServiceInput!) { + updateService ( + id: $id, + input: $input + ) { + __typename + id + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/supportGroup/create.graphql b/internal/api/graphql/graph/queryCollection/supportGroup/create.graphql new file mode 100644 index 00000000..95e5900b --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/supportGroup/create.graphql @@ -0,0 +1,8 @@ +mutation ($input: SupportGroupInput!) { + createSupportGroup ( + input: $input + ) { + id + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/supportGroup/delete.graphql b/internal/api/graphql/graph/queryCollection/supportGroup/delete.graphql new file mode 100644 index 00000000..46061f29 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/supportGroup/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteSupportGroup ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/supportGroup/directRelations.graphql b/internal/api/graphql/graph/queryCollection/supportGroup/directRelations.graphql new file mode 100644 index 00000000..012a8702 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/supportGroup/directRelations.graphql @@ -0,0 +1,59 @@ +query ($filter: SupportGroupFilter, $first: Int, $after: String) { + SupportGroups ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + name + users { + totalCount + edges { + node { + id + sapID + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + services { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/supportGroup/minimal.graphql b/internal/api/graphql/graph/queryCollection/supportGroup/minimal.graphql new file mode 100644 index 00000000..780d393d --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/supportGroup/minimal.graphql @@ -0,0 +1,16 @@ +query ($filter: SupportGroupFilter, $first: Int, $after: String) { + SupportGroups ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + name + } + cursor + } + } +} diff --git a/internal/api/graphql/graph/queryCollection/supportGroup/update.graphql b/internal/api/graphql/graph/queryCollection/supportGroup/update.graphql new file mode 100644 index 00000000..f050c35b --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/supportGroup/update.graphql @@ -0,0 +1,10 @@ +mutation ($id: ID!, $input: SupportGroupInput!) { + updateSupportGroup ( + id: $id, + input: $input + ) { + __typename + id + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/user/create.graphql b/internal/api/graphql/graph/queryCollection/user/create.graphql new file mode 100644 index 00000000..bcf93296 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/user/create.graphql @@ -0,0 +1,9 @@ +mutation ($input: UserInput!) { + createUser ( + input: $input + ) { + id + sapID + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/user/delete.graphql b/internal/api/graphql/graph/queryCollection/user/delete.graphql new file mode 100644 index 00000000..f5694cd4 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/user/delete.graphql @@ -0,0 +1,5 @@ +mutation ($id: ID!) { + deleteUser ( + id: $id + ) +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/user/directRelations.graphql b/internal/api/graphql/graph/queryCollection/user/directRelations.graphql new file mode 100644 index 00000000..7a0cc07e --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/user/directRelations.graphql @@ -0,0 +1,59 @@ +query ($filter: UserFilter, $first: Int, $after: String) { + Users ( + filter: $filter, + first: $first, + after: $after + ) { + __typename + totalCount + edges { + node { + id + sapID + name + supportGroups { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + services { + totalCount + edges { + node { + id + name + } + cursor + } + pageInfo { + hasNextPage + nextPageAfter + } + } + } + cursor + } + pageInfo { + hasNextPage + hasPreviousPage + isValidPage + pageNumber + nextPageAfter + pages { + after + isCurrent + pageNumber + pageCount + } + } + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/queryCollection/user/minimal.graphql b/internal/api/graphql/graph/queryCollection/user/minimal.graphql new file mode 100644 index 00000000..453df9c4 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/user/minimal.graphql @@ -0,0 +1,17 @@ + +query ($filter: UserFilter, $first: Int, $after: String) { + Users ( + filter: $filter, + first: $first, + after: $after + ) { + totalCount + edges { + node { + id + name + } + cursor + } + } +} diff --git a/internal/api/graphql/graph/queryCollection/user/update.graphql b/internal/api/graphql/graph/queryCollection/user/update.graphql new file mode 100644 index 00000000..90006ac7 --- /dev/null +++ b/internal/api/graphql/graph/queryCollection/user/update.graphql @@ -0,0 +1,11 @@ +mutation ($id: ID!, $input: UserInput!) { + updateUser ( + id: $id, + input: $input + ) { + __typename + id + sapID + name + } +} \ No newline at end of file diff --git a/internal/api/graphql/graph/resolver/activity.go b/internal/api/graphql/graph/resolver/activity.go new file mode 100644 index 00000000..4195da8e --- /dev/null +++ b/internal/api/graphql/graph/resolver/activity.go @@ -0,0 +1,71 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// Services is the resolver for the services field. +func (r *activityResolver) Services(ctx context.Context, obj *model.Activity, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) { + return baseResolver.ServiceBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.ActivityNodeName, + }) +} + +// Issues is the resolver for the issues field. +func (r *activityResolver) Issues(ctx context.Context, obj *model.Activity, filter *model.IssueFilter, first *int, after *string) (*model.IssueConnection, error) { + return baseResolver.IssueBaseResolver( + r.App, + ctx, + filter, + first, + after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ActivityNodeName, + }) +} + +// Evidences is the resolver for the evidences field. +func (r *activityResolver) Evidences(ctx context.Context, obj *model.Activity, filter *model.EvidenceFilter, first *int, after *string) (*model.EvidenceConnection, error) { + return baseResolver.EvidenceBaseResolver( + r.App, + ctx, + filter, + first, + after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ActivityNodeName, + }) +} + +// IssueMatchChanges is the resolver for the issueMatchChanges field. +func (r *activityResolver) IssueMatchChanges(ctx context.Context, obj *model.Activity, filter *model.IssueMatchChangeFilter, first *int, after *string) (*model.IssueMatchChangeConnection, error) { + return baseResolver.IssueMatchChangeBaseResolver( + r.App, + ctx, + filter, + first, + after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ActivityNodeName, + }) +} + +// Activity returns graph.ActivityResolver implementation. +func (r *Resolver) Activity() graph.ActivityResolver { return &activityResolver{r} } + +type activityResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/component.go b/internal/api/graphql/graph/resolver/component.go new file mode 100644 index 00000000..eff197b0 --- /dev/null +++ b/internal/api/graphql/graph/resolver/component.go @@ -0,0 +1,30 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// ComponentVersions is the resolver for the componentVersions field. +func (r *componentResolver) ComponentVersions(ctx context.Context, obj *model.Component, filter *model.ComponentVersionFilter, first *int, after *string) (*model.ComponentVersionConnection, error) { + return baseResolver.ComponentVersionBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ComponentNodeName, + }) +} + +// Component returns graph.ComponentResolver implementation. +func (r *Resolver) Component() graph.ComponentResolver { return &componentResolver{r} } + +type componentResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/component_instance.go b/internal/api/graphql/graph/resolver/component_instance.go new file mode 100644 index 00000000..d7e86254 --- /dev/null +++ b/internal/api/graphql/graph/resolver/component_instance.go @@ -0,0 +1,65 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/util" +) + +// ComponentVersion is the resolver for the componentVersion field. +func (r *componentInstanceResolver) ComponentVersion(ctx context.Context, obj *model.ComponentInstance) (*model.ComponentVersion, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.ComponentVersionID}) + + if err != nil { + logrus.WithField("obj", obj).Error("ComponentInstanceResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleComponentVersionBaseResolver(r.App, ctx, &model.NodeParent{ + Parent: obj, + ParentName: model.ComponentInstanceNodeName, + ChildIds: childIds, + }) +} + +// IssueMatches is the resolver for the issueMatches field. +func (r *componentInstanceResolver) IssueMatches(ctx context.Context, obj *model.ComponentInstance, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) { + return baseResolver.IssueMatchBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.ComponentInstanceNodeName, + }) +} + +// Service is the resolver for the service field. +func (r *componentInstanceResolver) Service(ctx context.Context, obj *model.ComponentInstance) (*model.Service, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.ServiceID}) + + if err != nil { + logrus.WithField("obj", obj).Error("ComponentInstanceResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleServiceBaseResolver(r.App, ctx, &model.NodeParent{ + Parent: obj, + ParentName: model.ComponentInstanceNodeName, + ChildIds: childIds, + }) +} + +// ComponentInstance returns graph.ComponentInstanceResolver implementation. +func (r *Resolver) ComponentInstance() graph.ComponentInstanceResolver { + return &componentInstanceResolver{r} +} + +type componentInstanceResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/component_version.go b/internal/api/graphql/graph/resolver/component_version.go new file mode 100644 index 00000000..2a32bc9f --- /dev/null +++ b/internal/api/graphql/graph/resolver/component_version.go @@ -0,0 +1,52 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/util" +) + +// Component is the resolver for the component field. +func (r *componentVersionResolver) Component(ctx context.Context, obj *model.ComponentVersion) (*model.Component, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.ComponentID}) + + if err != nil { + logrus.WithField("obj", obj).Error("ComponentVersionResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleComponentBaseResolver( + r.App, + ctx, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchNodeName, + ChildIds: childIds, + }) +} + +// Issues is the resolver for the issues field. +func (r *componentVersionResolver) Issues(ctx context.Context, obj *model.ComponentVersion, first *int, after *string) (*model.IssueConnection, error) { + return baseResolver.IssueBaseResolver(r.App, ctx, nil, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.ComponentVersionNodeName, + }) +} + +// ComponentVersion returns graph.ComponentVersionResolver implementation. +func (r *Resolver) ComponentVersion() graph.ComponentVersionResolver { + return &componentVersionResolver{r} +} + +type componentVersionResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/evidence.go b/internal/api/graphql/graph/resolver/evidence.go new file mode 100644 index 00000000..83505ef1 --- /dev/null +++ b/internal/api/graphql/graph/resolver/evidence.go @@ -0,0 +1,63 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/util" +) + +// Author is the resolver for the author field. +func (r *evidenceResolver) Author(ctx context.Context, obj *model.Evidence) (*model.User, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.AuthorID}) + + if err != nil { + logrus.WithField("obj", obj).Error("EvidenceResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleUserBaseResolver(r.App, ctx, &model.NodeParent{ + Parent: obj, + ParentName: model.EvidenceNodeName, + ChildIds: childIds, + }) +} + +// Activity is the resolver for the activity field. +func (r *evidenceResolver) Activity(ctx context.Context, obj *model.Evidence) (*model.Activity, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.ActivityID}) + + if err != nil { + logrus.WithField("obj", obj).Error("EvidenceResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleActivityBaseResolver(r.App, ctx, &model.NodeParent{ + Parent: obj, + ParentName: model.EvidenceNodeName, + ChildIds: childIds, + }) +} + +// IssueMatches is the resolver for the issueMatches field. +func (r *evidenceResolver) IssueMatches(ctx context.Context, obj *model.Evidence, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) { + return baseResolver.IssueMatchBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.EvidenceNodeName, + }) +} + +// Evidence returns graph.EvidenceResolver implementation. +func (r *Resolver) Evidence() graph.EvidenceResolver { return &evidenceResolver{r} } + +type evidenceResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/issue.go b/internal/api/graphql/graph/resolver/issue.go new file mode 100644 index 00000000..26c3962e --- /dev/null +++ b/internal/api/graphql/graph/resolver/issue.go @@ -0,0 +1,53 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// IssueVariants is the resolver for the issueVariants field. +func (r *issueResolver) IssueVariants(ctx context.Context, obj *model.Issue, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) { + return baseResolver.IssueVariantBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueNodeName, + }) +} + +// Activities is the resolver for the activities field. +func (r *issueResolver) Activities(ctx context.Context, obj *model.Issue, filter *model.ActivityFilter, first *int, after *string) (*model.ActivityConnection, error) { + return baseResolver.ActivityBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueNodeName, + }) +} + +// IssueMatches is the resolver for the issueMatches field. +func (r *issueResolver) IssueMatches(ctx context.Context, obj *model.Issue, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) { + return baseResolver.IssueMatchBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueNodeName, + }) +} + +// ComponentVersions is the resolver for the componentVersions field. +func (r *issueResolver) ComponentVersions(ctx context.Context, obj *model.Issue, filter *model.ComponentVersionFilter, first *int, after *string) (*model.ComponentVersionConnection, error) { + return baseResolver.ComponentVersionBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueNodeName, + }) +} + +// Issue returns graph.IssueResolver implementation. +func (r *Resolver) Issue() graph.IssueResolver { return &issueResolver{r} } + +type issueResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/issue_match.go b/internal/api/graphql/graph/resolver/issue_match.go new file mode 100644 index 00000000..27c62754 --- /dev/null +++ b/internal/api/graphql/graph/resolver/issue_match.go @@ -0,0 +1,132 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/entity" + "github.wdf.sap.corp/cc/heureka/internal/util" +) + +// Severity is the resolver for the severity field. +func (r *issueMatchResolver) Severity(ctx context.Context, obj *model.IssueMatch) (*model.Severity, error) { + imIds, err := util.ConvertStrToIntSlice([]*string{&obj.ID}) + if err != nil { + logrus.WithField("obj", obj).Error("IssueMatchResolver: Error while parsing issue match ids'") + return nil, err + } + + filter := entity.SeverityFilter{ + IssueMatchId: imIds, + } + + severity, err := r.App.GetSeverity(&filter) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueMatchResolver: Error while getting severity'") + return nil, err + } + + if severity == nil { + logrus.WithField("obj", obj).Info("IssueMatchResolver: Effective severity not found'") + return nil, err + } + + s := model.NewSeverity(*severity) + return s, nil +} + +// EffectiveIssueVariants is the resolver for the effectiveIssueVariants field. +func (r *issueMatchResolver) EffectiveIssueVariants(ctx context.Context, obj *model.IssueMatch, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) { + return baseResolver.EffectiveIssueVariantBaseResolver( + r.App, + ctx, + filter, + first, + after, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchNodeName, + }) +} + +// Evidences is the resolver for the evidences field. +func (r *issueMatchResolver) Evidences(ctx context.Context, obj *model.IssueMatch, filter *model.EvidenceFilter, first *int, after *string) (*model.EvidenceConnection, error) { + return baseResolver.EvidenceBaseResolver( + r.App, + ctx, + filter, + first, + after, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchNodeName, + }) +} + +// Issue is the resolver for the issue field. +func (r *issueMatchResolver) Issue(ctx context.Context, obj *model.IssueMatch) (*model.Issue, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.IssueID}) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueMatchResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleIssueBaseResolver( + r.App, + ctx, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchNodeName, + ChildIds: childIds, + }) +} + +// ComponentInstance is the resolver for the componentInstance field. +func (r *issueMatchResolver) ComponentInstance(ctx context.Context, obj *model.IssueMatch) (*model.ComponentInstance, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.ComponentInstanceID}) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueMatchResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleComponentInstanceBaseResolver( + r.App, + ctx, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchNodeName, + ChildIds: childIds, + }) +} + +// IssueMatchChanges is the resolver for the issueMatchChanges field. +func (r *issueMatchResolver) IssueMatchChanges(ctx context.Context, obj *model.IssueMatch, filter *model.IssueMatchChangeFilter, first *int, after *string) (*model.IssueMatchChangeConnection, error) { + return baseResolver.IssueMatchChangeBaseResolver( + r.App, + ctx, + filter, + first, + after, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchNodeName, + }) +} + +// IssueMatch returns graph.IssueMatchResolver implementation. +func (r *Resolver) IssueMatch() graph.IssueMatchResolver { return &issueMatchResolver{r} } + +type issueMatchResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/issue_match_change.go b/internal/api/graphql/graph/resolver/issue_match_change.go new file mode 100644 index 00000000..89ba84f4 --- /dev/null +++ b/internal/api/graphql/graph/resolver/issue_match_change.go @@ -0,0 +1,63 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/util" +) + +// IssueMatch is the resolver for the issueMatch field. +func (r *issueMatchChangeResolver) IssueMatch(ctx context.Context, obj *model.IssueMatchChange) (*model.IssueMatch, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.IssueMatchID}) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueMatchChangeResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleIssueMatchBaseResolver( + r.App, + ctx, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchChangeNodeName, + ChildIds: childIds, + }) +} + +// Activity is the resolver for the activity field. +func (r *issueMatchChangeResolver) Activity(ctx context.Context, obj *model.IssueMatchChange) (*model.Activity, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.ActivityID}) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueMatchChangeResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleActivityBaseResolver( + r.App, + ctx, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueMatchChangeNodeName, + ChildIds: childIds, + }) +} + +// IssueMatchChange returns graph.IssueMatchChangeResolver implementation. +func (r *Resolver) IssueMatchChange() graph.IssueMatchChangeResolver { + return &issueMatchChangeResolver{r} +} + +type issueMatchChangeResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/issue_repository.go b/internal/api/graphql/graph/resolver/issue_repository.go new file mode 100644 index 00000000..5c35c1fd --- /dev/null +++ b/internal/api/graphql/graph/resolver/issue_repository.go @@ -0,0 +1,40 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// IssueVariants is the resolver for the issueVariants field. +func (r *issueRepositoryResolver) IssueVariants(ctx context.Context, obj *model.IssueRepository, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) { + return baseResolver.IssueVariantBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueRepositoryNodeName, + }) +} + +// Services is the resolver for the services field. +func (r *issueRepositoryResolver) Services(ctx context.Context, obj *model.IssueRepository, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) { + return baseResolver.ServiceBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.IssueRepositoryNodeName, + }) +} + +// IssueRepository returns graph.IssueRepositoryResolver implementation. +func (r *Resolver) IssueRepository() graph.IssueRepositoryResolver { + return &issueRepositoryResolver{r} +} + +type issueRepositoryResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/issue_variant.go b/internal/api/graphql/graph/resolver/issue_variant.go new file mode 100644 index 00000000..c48c8de5 --- /dev/null +++ b/internal/api/graphql/graph/resolver/issue_variant.go @@ -0,0 +1,55 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.com/sirupsen/logrus" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" + "github.wdf.sap.corp/cc/heureka/internal/util" +) + +// IssueRepository is the resolver for the issueRepository field. +func (r *issueVariantResolver) IssueRepository(ctx context.Context, obj *model.IssueVariant) (*model.IssueRepository, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.IssueRepositoryID}) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueVariantResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleIssueRepositoryBaseResolver(r.App, ctx, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueVariantNodeName, + ChildIds: childIds, + }) +} + +// Issue is the resolver for the issue field. +func (r *issueVariantResolver) Issue(ctx context.Context, obj *model.IssueVariant) (*model.Issue, error) { + childIds, err := util.ConvertStrToIntSlice([]*string{obj.IssueID}) + + if err != nil { + logrus.WithField("obj", obj).Error("IssueVariantResolver: Error while parsing childIds'") + return nil, err + } + + return baseResolver.SingleIssueBaseResolver(r.App, ctx, &model.NodeParent{ + Parent: obj, + ParentName: model.IssueVariantNodeName, + ChildIds: childIds, + }) +} + +// IssueVariant returns graph.IssueVariantResolver implementation. +func (r *Resolver) IssueVariant() graph.IssueVariantResolver { return &issueVariantResolver{r} } + +type issueVariantResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/mutation.go b/internal/api/graphql/graph/resolver/mutation.go new file mode 100644 index 00000000..783a5fef --- /dev/null +++ b/internal/api/graphql/graph/resolver/mutation.go @@ -0,0 +1,461 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// CreateUser is the resolver for the createUser field. +func (r *mutationResolver) CreateUser(ctx context.Context, input model.UserInput) (*model.User, error) { + user := model.NewUserEntity(&input) + newUser, err := r.App.CreateUser(&user) + if err != nil { + return nil, baseResolver.NewResolverError("CreateUserMutationResolver", "Internal Error - when creating user") + } + u := model.NewUser(newUser) + return &u, nil +} + +// UpdateUser is the resolver for the updateUser field. +func (r *mutationResolver) UpdateUser(ctx context.Context, id string, input model.UserInput) (*model.User, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateUserMutationResolver", "Internal Error - when updating user") + } + user := model.NewUserEntity(&input) + user.Id = *idInt + updatedUser, err := r.App.UpdateUser(&user) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateUserMutationResolver", "Internal Error - when updating user") + } + u := model.NewUser(updatedUser) + return &u, nil +} + +// DeleteUser is the resolver for the deleteUser field. +func (r *mutationResolver) DeleteUser(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteUserMutationResolver", "Internal Error - when deleting user") + } + err = r.App.DeleteUser(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteUserMutationResolver", "Internal Error - when deleting user") + } + return id, nil +} + +// CreateSupportGroup is the resolver for the createSupportGroup field. +func (r *mutationResolver) CreateSupportGroup(ctx context.Context, input model.SupportGroupInput) (*model.SupportGroup, error) { + supportGroup := model.NewSupportGroupEntity(&input) + newSupportGroup, err := r.App.CreateSupportGroup(&supportGroup) + if err != nil { + return nil, baseResolver.NewResolverError("CreateSupportGroupMutationResolver", "Internal Error - when creating supportGroup") + } + sg := model.NewSupportGroup(newSupportGroup) + return &sg, nil +} + +// UpdateSupportGroup is the resolver for the updateSupportGroup field. +func (r *mutationResolver) UpdateSupportGroup(ctx context.Context, id string, input model.SupportGroupInput) (*model.SupportGroup, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateSupportGroupMutationResolver", "Internal Error - when updating supportGroup") + } + supportGroup := model.NewSupportGroupEntity(&input) + supportGroup.Id = *idInt + updatedSupportGroup, err := r.App.UpdateSupportGroup(&supportGroup) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateSupportGroupMutationResolver", "Internal Error - when updating supportGroup") + } + sg := model.NewSupportGroup(updatedSupportGroup) + return &sg, nil +} + +// DeleteSupportGroup is the resolver for the deleteSupportGroup field. +func (r *mutationResolver) DeleteSupportGroup(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteSupportGroupMutationResolver", "Internal Error - when deleting supportGroup") + } + err = r.App.DeleteSupportGroup(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteSupportGroupMutationResolver", "Internal Error - when deleting supportGroup") + } + return id, nil +} + +// CreateComponent is the resolver for the createComponent field. +func (r *mutationResolver) CreateComponent(ctx context.Context, input model.ComponentInput) (*model.Component, error) { + component := model.NewComponentEntity(&input) + newComponent, err := r.App.CreateComponent(&component) + if err != nil { + return nil, baseResolver.NewResolverError("CreateComponentMutationResolver", "Internal Error - when creating component") + } + c := model.NewComponent(newComponent) + return &c, nil +} + +// UpdateComponent is the resolver for the updateComponent field. +func (r *mutationResolver) UpdateComponent(ctx context.Context, id string, input model.ComponentInput) (*model.Component, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateComponentMutationResolver", "Internal Error - when updating component") + } + component := model.NewComponentEntity(&input) + component.Id = *idInt + updatedComponent, err := r.App.UpdateComponent(&component) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateComponentMutationResolver", "Internal Error - when updating component") + } + c := model.NewComponent(updatedComponent) + return &c, nil +} + +// DeleteComponent is the resolver for the deleteComponent field. +func (r *mutationResolver) DeleteComponent(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteComponentMutationResolver", "Internal Error - when deleting component") + } + err = r.App.DeleteComponent(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteComponentMutationResolver", "Internal Error - when deleting component") + } + return id, nil +} + +// CreateComponentInstance is the resolver for the createComponentInstance field. +func (r *mutationResolver) CreateComponentInstance(ctx context.Context, input model.ComponentInstanceInput) (*model.ComponentInstance, error) { + componentInstance := model.NewComponentInstanceEntity(&input) + newComponentInstance, err := r.App.CreateComponentInstance(&componentInstance) + if err != nil { + return nil, baseResolver.NewResolverError("CreateComponentInstanceMutationResolver", "Internal Error - when creating componentInstance") + } + ci := model.NewComponentInstance(newComponentInstance) + return &ci, nil +} + +// UpdateComponentInstance is the resolver for the updateComponentInstance field. +func (r *mutationResolver) UpdateComponentInstance(ctx context.Context, id string, input model.ComponentInstanceInput) (*model.ComponentInstance, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateComponentInstanceMutationResolver", "Internal Error - when updating componentInstance") + } + componentInstance := model.NewComponentInstanceEntity(&input) + componentInstance.Id = *idInt + updatedComponentInstance, err := r.App.UpdateComponentInstance(&componentInstance) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateComponentInstanceMutationResolver", "Internal Error - when updating componentInstance") + } + ci := model.NewComponentInstance(updatedComponentInstance) + return &ci, nil +} + +// DeleteComponentInstance is the resolver for the deleteComponentInstance field. +func (r *mutationResolver) DeleteComponentInstance(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteComponentInstanceMutationResolver", "Internal Error - when deleting componentInstance") + } + err = r.App.DeleteComponentInstance(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteComponentInstanceMutationResolver", "Internal Error - when deleting componentInstance") + } + return id, nil +} + +// CreateComponentVersion is the resolver for the createComponentVersion field. +func (r *mutationResolver) CreateComponentVersion(ctx context.Context, input model.ComponentVersionInput) (*model.ComponentVersion, error) { + componentVersion := model.NewComponentVersionEntity(&input) + newComponentVersion, err := r.App.CreateComponentVersion(&componentVersion) + if err != nil { + return nil, baseResolver.NewResolverError("CreateComponentVersionMutationResolver", "Internal Error - when creating componentVersion") + } + cv := model.NewComponentVersion(newComponentVersion) + return &cv, nil +} + +// UpdateComponentVersion is the resolver for the updateComponentVersion field. +func (r *mutationResolver) UpdateComponentVersion(ctx context.Context, id string, input model.ComponentVersionInput) (*model.ComponentVersion, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateComponentVersionMutationResolver", "Internal Error - when updating componentVersion") + } + componentVersion := model.NewComponentVersionEntity(&input) + componentVersion.Id = *idInt + updatedComponentVersion, err := r.App.UpdateComponentVersion(&componentVersion) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateComponentVersionMutationResolver", "Internal Error - when updating componentVersion") + } + cv := model.NewComponentVersion(updatedComponentVersion) + return &cv, nil +} + +// DeleteComponentVersion is the resolver for the deleteComponentVersion field. +func (r *mutationResolver) DeleteComponentVersion(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteComponentVersionMutationResolver", "Internal Error - when deleting componentVersion") + } + err = r.App.DeleteComponentVersion(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteComponentVersionMutationResolver", "Internal Error - when deleting componentVersion") + } + return id, nil +} + +// CreateService is the resolver for the createService field. +func (r *mutationResolver) CreateService(ctx context.Context, input model.ServiceInput) (*model.Service, error) { + service := model.NewServiceEntity(&input) + newService, err := r.App.CreateService(&service) + if err != nil { + return nil, baseResolver.NewResolverError("CreateServiceMutationResolver", "Internal Error - when creating service") + } + s := model.NewService(newService) + return &s, nil +} + +// UpdateService is the resolver for the updateService field. +func (r *mutationResolver) UpdateService(ctx context.Context, id string, input model.ServiceInput) (*model.Service, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateServiceMutationResolver", "Internal Error - when updating service") + } + service := model.NewServiceEntity(&input) + service.Id = *idInt + updatedService, err := r.App.UpdateService(&service) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateServiceMutationResolver", "Internal Error - when updating service") + } + s := model.NewService(updatedService) + return &s, nil +} + +// DeleteService is the resolver for the deleteService field. +func (r *mutationResolver) DeleteService(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteServiceMutationResolver", "Internal Error - when deleting service") + } + err = r.App.DeleteService(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteServiceMutationResolver", "Internal Error - when deleting service") + } + return id, nil +} + +// CreateIssueRepository is the resolver for the createIssueRepository field. +func (r *mutationResolver) CreateIssueRepository(ctx context.Context, input model.IssueRepositoryInput) (*model.IssueRepository, error) { + issueRepository := model.NewIssueRepositoryEntity(&input) + newIssueRepository, err := r.App.CreateIssueRepository(&issueRepository) + if err != nil { + return nil, baseResolver.NewResolverError("CreateIssueRepositoryMutationResolver", "Internal Error - when creating issueRepository") + } + ir := model.NewIssueRepository(newIssueRepository) + return &ir, nil +} + +// UpdateIssueRepository is the resolver for the updateIssueRepository field. +func (r *mutationResolver) UpdateIssueRepository(ctx context.Context, id string, input model.IssueRepositoryInput) (*model.IssueRepository, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateIssueRepositoryMutationResolver", "Internal Error - when updating issueRepository") + } + issueRepository := model.NewIssueRepositoryEntity(&input) + issueRepository.Id = *idInt + updatedIssueRepository, err := r.App.UpdateIssueRepository(&issueRepository) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateIssueRepositoryMutationResolver", "Internal Error - when updating issueRepository") + } + ir := model.NewIssueRepository(updatedIssueRepository) + return &ir, nil +} + +// DeleteIssueRepository is the resolver for the deleteIssueRepository field. +func (r *mutationResolver) DeleteIssueRepository(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteIssueRepositoryMutationResolver", "Internal Error - when deleting issueRepository") + } + err = r.App.DeleteIssueRepository(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteIssueRepositoryMutationResolver", "Internal Error - when deleting issueRepository") + } + return id, nil +} + +// CreateIssueVariant is the resolver for the createIssueVariant field. +func (r *mutationResolver) CreateIssueVariant(ctx context.Context, input model.IssueVariantInput) (*model.IssueVariant, error) { + issueVariant := model.NewIssueVariantEntity(&input) + newIssueVariant, err := r.App.CreateIssueVariant(&issueVariant) + if err != nil { + return nil, baseResolver.NewResolverError("CreateIssueVariantMutationResolver", "Internal Error - when creating issueVariant") + } + iv := model.NewIssueVariant(newIssueVariant) + return &iv, nil +} + +// UpdateIssueVariant is the resolver for the updateIssueVariant field. +func (r *mutationResolver) UpdateIssueVariant(ctx context.Context, id string, input model.IssueVariantInput) (*model.IssueVariant, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateIssueVariantMutationResolver", "Internal Error - when updating issueVariant") + } + issueVariant := model.NewIssueVariantEntity(&input) + issueVariant.Id = *idInt + updatedIssueVariant, err := r.App.UpdateIssueVariant(&issueVariant) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateIssueVariantMutationResolver", "Internal Error - when updating issueVariant") + } + iv := model.NewIssueVariant(updatedIssueVariant) + return &iv, nil +} + +// DeleteIssueVariant is the resolver for the deleteIssueVariant field. +func (r *mutationResolver) DeleteIssueVariant(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteIssueVariantMutationResolver", "Internal Error - when deleting issueVariant") + } + err = r.App.DeleteIssueVariant(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteIssueVariantMutationResolver", "Internal Error - when deleting issueVariant") + } + return id, nil +} + +// CreateEvidence is the resolver for the createEvidence field. +func (r *mutationResolver) CreateEvidence(ctx context.Context, input model.EvidenceInput) (*model.Evidence, error) { + evidence := model.NewEvidenceEntity(&input) + newEvidence, err := r.App.CreateEvidence(&evidence) + if err != nil { + return nil, baseResolver.NewResolverError("CreateEvidenceMutationResolver", "Internal Error - when creating evidence") + } + e := model.NewEvidence(newEvidence) + return &e, nil +} + +// UpdateEvidence is the resolver for the updateEvidence field. +func (r *mutationResolver) UpdateEvidence(ctx context.Context, id string, input model.EvidenceInput) (*model.Evidence, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateEvidenceMutationResolver", "Internal Error - when updating evidence") + } + evidence := model.NewEvidenceEntity(&input) + evidence.Id = *idInt + updatedEvidence, err := r.App.UpdateEvidence(&evidence) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateEvidenceMutationResolver", "Internal Error - when updating evidence") + } + e := model.NewEvidence(updatedEvidence) + return &e, nil +} + +// DeleteEvidence is the resolver for the deleteEvidence field. +func (r *mutationResolver) DeleteEvidence(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteEvidenceMutationResolver", "Internal Error - when deleting evidence") + } + err = r.App.DeleteEvidence(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteEvidenceMutationResolver", "Internal Error - when deleting evidence") + } + return id, nil +} + +// CreateIssueMatch is the resolver for the createIssueMatch field. +func (r *mutationResolver) CreateIssueMatch(ctx context.Context, input model.IssueMatchInput) (*model.IssueMatch, error) { + issueMatch := model.NewIssueMatchEntity(&input) + newIssueMatch, err := r.App.CreateIssueMatch(&issueMatch) + if err != nil { + return nil, baseResolver.NewResolverError("CreateIssueMatchMutationResolver", "Internal Error - when creating issueMatch") + } + im := model.NewIssueMatch(newIssueMatch) + return &im, nil +} + +// UpdateIssueMatch is the resolver for the updateIssueMatch field. +func (r *mutationResolver) UpdateIssueMatch(ctx context.Context, id string, input model.IssueMatchInput) (*model.IssueMatch, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateIssueMatchMutationResolver", "Internal Error - when updating issueMatch") + } + issueMatch := model.NewIssueMatchEntity(&input) + issueMatch.Id = *idInt + updatedIssueMatch, err := r.App.UpdateIssueMatch(&issueMatch) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateIssueMatchMutationResolver", "Internal Error - when updating issueMatch") + } + im := model.NewIssueMatch(updatedIssueMatch) + return &im, nil +} + +// DeleteIssueMatch is the resolver for the deleteIssueMatch field. +func (r *mutationResolver) DeleteIssueMatch(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteIssueMatchMutationResolver", "Internal Error - when deleting issueMatch") + } + err = r.App.DeleteIssueMatch(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteIssueMatchMutationResolver", "Internal Error - when deleting issueMatch") + } + return id, nil +} + +// CreateActivity is the resolver for the createActivity field. +func (r *mutationResolver) CreateActivity(ctx context.Context, input model.ActivityInput) (*model.Activity, error) { + activity := model.NewActivityEntity(&input) + newActivity, err := r.App.CreateActivity(&activity) + if err != nil { + return nil, baseResolver.NewResolverError("CreateActivityMutationResolver", "Internal Error - when creating activity") + } + a := model.NewActivity(newActivity) + return &a, nil +} + +// UpdateActivity is the resolver for the updateActivity field. +func (r *mutationResolver) UpdateActivity(ctx context.Context, id string, input model.ActivityInput) (*model.Activity, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateActivityMutationResolver", "Internal Error - when updating activity") + } + activity := model.NewActivityEntity(&input) + activity.Id = *idInt + updatedActivity, err := r.App.UpdateActivity(&activity) + if err != nil { + return nil, baseResolver.NewResolverError("UpdateActivityMutationResolver", "Internal Error - when updating activity") + } + a := model.NewActivity(updatedActivity) + return &a, nil +} + +// DeleteActivity is the resolver for the deleteActivity field. +func (r *mutationResolver) DeleteActivity(ctx context.Context, id string) (string, error) { + idInt, err := baseResolver.ParseCursor(&id) + if err != nil { + return "", baseResolver.NewResolverError("DeleteActivityResolver", "Internal Error - when deleting activity") + } + err = r.App.DeleteActivity(*idInt) + if err != nil { + return "", baseResolver.NewResolverError("DeleteActivityMutationResolver", "Internal Error - when deleting activity") + } + return id, nil +} + +// Mutation returns graph.MutationResolver implementation. +func (r *Resolver) Mutation() graph.MutationResolver { return &mutationResolver{r} } + +type mutationResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/query.go b/internal/api/graphql/graph/resolver/query.go new file mode 100644 index 00000000..dc657842 --- /dev/null +++ b/internal/api/graphql/graph/resolver/query.go @@ -0,0 +1,86 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// Issues is the resolver for the Issues field. +func (r *queryResolver) Issues(ctx context.Context, filter *model.IssueFilter, first *int, after *string) (*model.IssueConnection, error) { + return baseResolver.IssueBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// IssueMatches is the resolver for the IssueMatches field. +func (r *queryResolver) IssueMatches(ctx context.Context, filter *model.IssueMatchFilter, first *int, after *string) (*model.IssueMatchConnection, error) { + return baseResolver.IssueMatchBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// IssueMatchChanges is the resolver for the IssueMatchChanges field. +func (r *queryResolver) IssueMatchChanges(ctx context.Context, filter *model.IssueMatchChangeFilter, first *int, after *string) (*model.IssueMatchChangeConnection, error) { + return baseResolver.IssueMatchChangeBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// Services is the resolver for the Services field. +func (r *queryResolver) Services(ctx context.Context, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) { + return baseResolver.ServiceBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// Components is the resolver for the Components field. +func (r *queryResolver) Components(ctx context.Context, filter *model.ComponentFilter, first *int, after *string) (*model.ComponentConnection, error) { + return baseResolver.ComponentBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// ComponentVersions is the resolver for the ComponentVersions field. +func (r *queryResolver) ComponentVersions(ctx context.Context, filter *model.ComponentVersionFilter, first *int, after *string) (*model.ComponentVersionConnection, error) { + return baseResolver.ComponentVersionBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// ComponentInstances is the resolver for the ComponentInstances field. +func (r *queryResolver) ComponentInstances(ctx context.Context, filter *model.ComponentInstanceFilter, first *int, after *string) (*model.ComponentInstanceConnection, error) { + return baseResolver.ComponentInstanceBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// Activities is the resolver for the Activities field. +func (r *queryResolver) Activities(ctx context.Context, filter *model.ActivityFilter, first *int, after *string) (*model.ActivityConnection, error) { + return baseResolver.ActivityBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// IssueVariants is the resolver for the IssueVariants field. +func (r *queryResolver) IssueVariants(ctx context.Context, filter *model.IssueVariantFilter, first *int, after *string) (*model.IssueVariantConnection, error) { + return baseResolver.IssueVariantBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// IssueRepositories is the resolver for the IssueRepositories field. +func (r *queryResolver) IssueRepositories(ctx context.Context, filter *model.IssueRepositoryFilter, first *int, after *string) (*model.IssueRepositoryConnection, error) { + return baseResolver.IssueRepositoryBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// Evidences is the resolver for the Evidences field. +func (r *queryResolver) Evidences(ctx context.Context, filter *model.EvidenceFilter, first *int, after *string) (*model.EvidenceConnection, error) { + return baseResolver.EvidenceBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// SupportGroups is the resolver for the SupportGroups field. +func (r *queryResolver) SupportGroups(ctx context.Context, filter *model.SupportGroupFilter, first *int, after *string) (*model.SupportGroupConnection, error) { + return baseResolver.SupportGroupBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// Users is the resolver for the Users field. +func (r *queryResolver) Users(ctx context.Context, filter *model.UserFilter, first *int, after *string) (*model.UserConnection, error) { + return baseResolver.UserBaseResolver(r.App, ctx, filter, first, after, nil) +} + +// Query returns graph.QueryResolver implementation. +func (r *Resolver) Query() graph.QueryResolver { return &queryResolver{r} } + +type queryResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/resolver.go b/internal/api/graphql/graph/resolver/resolver.go new file mode 100644 index 00000000..447c066e --- /dev/null +++ b/internal/api/graphql/graph/resolver/resolver.go @@ -0,0 +1,28 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +import ( + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/app" +) + +// This file will not be regenerated automatically. +// +// It serves as dependency injection for your app, add any dependencies you require here. + +type Resolver struct { + App app.Heureka +} + +func NewResolver(a app.Heureka) graph.Config { + + r := Resolver{ + App: a, + } + + return graph.Config{ + Resolvers: &r, + } +} diff --git a/internal/api/graphql/graph/resolver/service.go b/internal/api/graphql/graph/resolver/service.go new file mode 100644 index 00000000..996426cc --- /dev/null +++ b/internal/api/graphql/graph/resolver/service.go @@ -0,0 +1,66 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// Owners is the resolver for the owners field. +func (r *serviceResolver) Owners(ctx context.Context, obj *model.Service, filter *model.UserFilter, first *int, after *string) (*model.UserConnection, error) { + return baseResolver.UserBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ServiceNodeName, + }) +} + +// SupportGroups is the resolver for the supportGroups field. +func (r *serviceResolver) SupportGroups(ctx context.Context, obj *model.Service, filter *model.SupportGroupFilter, first *int, after *string) (*model.SupportGroupConnection, error) { + return baseResolver.SupportGroupBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ServiceNodeName, + }) +} + +// Activities is the resolver for the activities field. +func (r *serviceResolver) Activities(ctx context.Context, obj *model.Service, filter *model.ActivityFilter, first *int, after *string) (*model.ActivityConnection, error) { + return baseResolver.ActivityBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ServiceNodeName, + }) +} + +// IssueRepositories is the resolver for the issueRepositories field. +func (r *serviceResolver) IssueRepositories(ctx context.Context, obj *model.Service, filter *model.IssueRepositoryFilter, first *int, after *string) (*model.IssueRepositoryConnection, error) { + return baseResolver.IssueRepositoryBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ServiceNodeName, + }) +} + +// ComponentInstances is the resolver for the componentInstances field. +func (r *serviceResolver) ComponentInstances(ctx context.Context, obj *model.Service, filter *model.ComponentInstanceFilter, first *int, after *string) (*model.ComponentInstanceConnection, error) { + return baseResolver.ComponentInstanceBaseResolver(r.App, ctx, filter, first, after, + &model.NodeParent{ + Parent: obj, + ParentName: model.ServiceNodeName, + }) +} + +// Service returns graph.ServiceResolver implementation. +func (r *Resolver) Service() graph.ServiceResolver { return &serviceResolver{r} } + +type serviceResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/support_group.go b/internal/api/graphql/graph/resolver/support_group.go new file mode 100644 index 00000000..7acdd9fb --- /dev/null +++ b/internal/api/graphql/graph/resolver/support_group.go @@ -0,0 +1,37 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// Users is the resolver for the users field. +func (r *supportGroupResolver) Users(ctx context.Context, obj *model.SupportGroup, filter *model.UserFilter, first *int, after *string) (*model.UserConnection, error) { + return baseResolver.UserBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.SupportGroupNodeName, + }) +} + +// Services is the resolver for the services field. +func (r *supportGroupResolver) Services(ctx context.Context, obj *model.SupportGroup, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) { + return baseResolver.ServiceBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.SupportGroupNodeName, + }) +} + +// SupportGroup returns graph.SupportGroupResolver implementation. +func (r *Resolver) SupportGroup() graph.SupportGroupResolver { return &supportGroupResolver{r} } + +type supportGroupResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/resolver/user.go b/internal/api/graphql/graph/resolver/user.go new file mode 100644 index 00000000..1069c631 --- /dev/null +++ b/internal/api/graphql/graph/resolver/user.go @@ -0,0 +1,37 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package resolver + +// This file will be automatically regenerated based on the schema, any resolver implementations +// will be copied through when generating and any unknown code will be moved to the end. +// Code generated by github.com/99designs/gqlgen version v0.17.49 + +import ( + "context" + + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/baseResolver" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/model" +) + +// SupportGroups is the resolver for the supportGroups field. +func (r *userResolver) SupportGroups(ctx context.Context, obj *model.User, filter *model.SupportGroupFilter, first *int, after *string) (*model.SupportGroupConnection, error) { + return baseResolver.SupportGroupBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.UserNodeName, + }) +} + +// Services is the resolver for the services field. +func (r *userResolver) Services(ctx context.Context, obj *model.User, filter *model.ServiceFilter, first *int, after *string) (*model.ServiceConnection, error) { + return baseResolver.ServiceBaseResolver(r.App, ctx, filter, first, after, &model.NodeParent{ + Parent: obj, + ParentName: model.UserNodeName, + }) +} + +// User returns graph.UserResolver implementation. +func (r *Resolver) User() graph.UserResolver { return &userResolver{r} } + +type userResolver struct{ *Resolver } diff --git a/internal/api/graphql/graph/schema/activity.graphqls b/internal/api/graphql/graph/schema/activity.graphqls new file mode 100644 index 00000000..b7ccc630 --- /dev/null +++ b/internal/api/graphql/graph/schema/activity.graphqls @@ -0,0 +1,37 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type Activity implements Node { + id: ID! + status: ActivityStatusValues + services(filter: ServiceFilter, first: Int, after: String): ServiceConnection + issues(filter: IssueFilter, first: Int, after: String): IssueConnection + evidences(filter: EvidenceFilter, first: Int, after: String): EvidenceConnection + issueMatchChanges(filter: IssueMatchChangeFilter, first: Int, after: String): IssueMatchChangeConnection +} + +input ActivityInput { + status: ActivityStatusValues +} + +type ActivityConnection implements Connection { + totalCount: Int! + edges: [ActivityEdge] + pageInfo: PageInfo +} + +type ActivityEdge implements Edge { + node: Activity! + cursor: String +} + +input ActivityFilter { + serviceName: [String] + status: [ActivityStatusValues] +} + +enum ActivityStatusValues { + open, + closed, + in_progress +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/common.graphqls b/internal/api/graphql/graph/schema/common.graphqls new file mode 100644 index 00000000..59e57b85 --- /dev/null +++ b/internal/api/graphql/graph/schema/common.graphqls @@ -0,0 +1,101 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +scalar DateTime @specifiedBy(url: "https://scalars.graphql.org/andimarek/date-time") + +interface Node { + id: ID! +} + +interface Connection { + totalCount: Int! + pageInfo: PageInfo +} + +interface Edge { + node: Node! + cursor: String +} + +type Page { + after: String + isCurrent: Boolean + pageNumber: Int + pageCount: Int +} + +type PageInfo { + hasNextPage: Boolean + hasPreviousPage: Boolean + isValidPage: Boolean + pageNumber: Int + nextPageAfter: String + pages: [Page] +} + +enum SeverityValues { + None, + Low, + Medium, + High, + Critical +} + +input DateTimeFilter { + after: DateTime, + before: DateTime, +} + +type CVSSParameter { + name: String + value: String +} + +type CVSSBase { + score: Float + attackVector: String + attackComplexity: String + privilegesRequired: String + userInteraction: String + scope: String + confidentialityImpact: String + integrityImpact: String + availabilityImpact: String +} +type CVSSTemporal { + score: Float + exploitCodeMaturity: String + remediationLevel: String + reportConfidence: String +} +type CVSSEnvironmental { + score: Float + modifiedAttackVector: String + modifiedAttackComplexity: String + modifiedPrivilegesRequired: String + modifiedUserInteraction: String + modifiedScope: String + modifiedConfidentialityImpact: String + modifiedIntegrityImpact: String + modifiedAvailabilityImpact: String + confidentialityRequirement: String + availabilityRequirement: String + integrityRequirement: String +} + +type CVSS { + vector: String + base: CVSSBase + temporal: CVSSTemporal + environmental: CVSSEnvironmental +} + +type Severity { + value: SeverityValues + score: Float + cvss: CVSS +} + +input SeverityInput { + vector: String +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/component.graphqls b/internal/api/graphql/graph/schema/component.graphqls new file mode 100644 index 00000000..e2805fd1 --- /dev/null +++ b/internal/api/graphql/graph/schema/component.graphqls @@ -0,0 +1,35 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type Component implements Node { + id: ID! + name: String + type: ComponentTypeValues + componentVersions(filter: ComponentVersionFilter, first: Int, after: String): ComponentVersionConnection +} + +input ComponentInput { + name: String + type: ComponentTypeValues +} + +enum ComponentTypeValues { + containerImage, + virtualMachineImage, + repository +} + +input ComponentFilter { + componentName: [String] +} + +type ComponentConnection implements Connection { + totalCount: Int! + edges: [ComponentEdge] + pageInfo: PageInfo +} + +type ComponentEdge implements Edge { + node: Component! + cursor: String +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/component_instance.graphqls b/internal/api/graphql/graph/schema/component_instance.graphqls new file mode 100644 index 00000000..9342c93e --- /dev/null +++ b/internal/api/graphql/graph/schema/component_instance.graphqls @@ -0,0 +1,37 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type ComponentInstance implements Node { + id: ID! + ccrn: String + count: Int + componentVersionId: String + componentVersion: ComponentVersion + issueMatches(filter: IssueMatchFilter, first: Int, after: String): IssueMatchConnection + serviceId: String + service: Service + createdAt: DateTime + updatedAt: DateTime +} + +input ComponentInstanceInput { + ccrn: String + count: Int + componentVersionId: String + serviceId: String +} + +type ComponentInstanceConnection implements Connection { + totalCount: Int! + edges: [ComponentInstanceEdge]! + pageInfo: PageInfo +} + +type ComponentInstanceEdge implements Edge { + node: ComponentInstance! + cursor: String +} + +input ComponentInstanceFilter { + issueMatchId: [String], +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/component_version.graphqls b/internal/api/graphql/graph/schema/component_version.graphqls new file mode 100644 index 00000000..74382730 --- /dev/null +++ b/internal/api/graphql/graph/schema/component_version.graphqls @@ -0,0 +1,30 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type ComponentVersion implements Node { + id: ID! + version: String + componentId: String + component: Component + issues(first: Int, after: String): IssueConnection +} + +input ComponentVersionInput { + version: String + componentId: String +} + +type ComponentVersionConnection implements Connection { + totalCount: Int! + edges: [ComponentVersionEdge]! + pageInfo: PageInfo +} + +type ComponentVersionEdge implements Edge { + node: ComponentVersion! + cursor: String +} + +input ComponentVersionFilter { + issueId: [String], +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/evidence.graphqls b/internal/api/graphql/graph/schema/evidence.graphqls new file mode 100644 index 00000000..9f76a0ed --- /dev/null +++ b/internal/api/graphql/graph/schema/evidence.graphqls @@ -0,0 +1,40 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type Evidence implements Node { + id: ID! + description: String + type: String + vector: String + raaEnd: DateTime + #TODO Severity + authorId: String + author: User + activityId: String + activity: Activity + issueMatches(filter: IssueMatchFilter, first: Int, after: String): IssueMatchConnection +} + +input EvidenceInput { + description: String + type: String + raaEnd: DateTime + authorId: String + activityId: String + severity: SeverityInput +} + +type EvidenceConnection implements Connection { + totalCount: Int! + edges: [EvidenceEdge] + pageInfo: PageInfo +} + +type EvidenceEdge implements Edge { + node: Evidence! + cursor: String +} + +input EvidenceFilter { + placeholder: [Boolean] +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/issue.graphqls b/internal/api/graphql/graph/schema/issue.graphqls new file mode 100644 index 00000000..4257425e --- /dev/null +++ b/internal/api/graphql/graph/schema/issue.graphqls @@ -0,0 +1,65 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + + + +type Issue implements Node { + id: ID! + type: IssueTypes + primaryName: String + lastModified: DateTime + issueVariants(filter: IssueVariantFilter, first: Int, after: String): IssueVariantConnection + activities(filter: ActivityFilter, first: Int, after: String): ActivityConnection + issueMatches(filter: IssueMatchFilter, first: Int, after: String): IssueMatchConnection + componentVersions(filter: ComponentVersionFilter, first: Int, after: String): ComponentVersionConnection + metadata: IssueMetadata +} + +type IssueMetadata { + serviceCount: Int! + activityCount: Int! + issueMatchCount: Int! + componentInstanceCount: Int! + componentVersionCount: Int! + earliestDiscoveryDate: DateTime! + earliestTargetRemediationDate: DateTime! +} + +type IssueConnection implements Connection { + totalCount: Int! + edges: [IssueEdge]! + pageInfo: PageInfo +} + +type IssueEdge implements Edge { + node: Issue! + cursor: String +} + +enum IssueStatusValues { + unaffected, + open, + remediated, + overdue +} + +input IssueFilter { + affectedService: [String], + primaryName: [String], + issueMatchStatus: [IssueMatchStatusValues], + issueType: [IssueTypes], + + componentVersionId: [String], + + # leave away for MVP + # cveDescription: [String] + # fromAdvisory: ID, + # vulnerabilityMatchDiscoveryDate: DateTimeFilter + # vulnerabilityMatchTargetRemediationDate: DateTimeFilter +} + +enum IssueTypes { + Vulnerability, + PolicyViolation, + SecurityEvent +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/issue_match.graphqls b/internal/api/graphql/graph/schema/issue_match.graphqls new file mode 100644 index 00000000..251af764 --- /dev/null +++ b/internal/api/graphql/graph/schema/issue_match.graphqls @@ -0,0 +1,61 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type IssueMatch implements Node { + id: ID! + status: IssueMatchStatusValues + remediationDate: DateTime + discoveryDate: DateTime + targetRemediationDate: DateTime + severity: Severity + effectiveIssueVariants(filter: IssueVariantFilter, first: Int, after: String): IssueVariantConnection + evidences(filter: EvidenceFilter, first: Int, after: String): EvidenceConnection + issueId: String + issue: Issue! + userId: String + user: User + componentInstanceId: String + componentInstance: ComponentInstance! + issueMatchChanges(filter: IssueMatchChangeFilter, first: Int, after: String): IssueMatchChangeConnection +} + +input IssueMatchInput { + status: IssueMatchStatusValues + remediationDate: DateTime + discoveryDate: DateTime + targetRemediationDate: DateTime + issueId: String + componentInstanceId: String + userId: String +} + +input IssueMatchFilter { + status: [IssueMatchStatusValues] + severity: [SeverityValues] + affectedService: [String] + SupportGroupName: [String] +} + +#type CCloudSeverity { +# id:ID! +# rating:SeverityValues! +# comment:String! +#} + +type IssueMatchConnection implements Connection { + totalCount: Int! + edges: [IssueMatchEdge] + pageInfo: PageInfo +} + +type IssueMatchEdge implements Edge { + node: IssueMatch! + cursor: String +} + +enum IssueMatchStatusValues { + new, + risk_accepted + false_positive + mitigated +} diff --git a/internal/api/graphql/graph/schema/issue_match_change.graphqls b/internal/api/graphql/graph/schema/issue_match_change.graphqls new file mode 100644 index 00000000..9116b35c --- /dev/null +++ b/internal/api/graphql/graph/schema/issue_match_change.graphqls @@ -0,0 +1,32 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + + +type IssueMatchChange implements Node { + id: ID! + action: IssueMatchChangeActions + issueMatchId: String + issueMatch: IssueMatch! + activityId: String + activity: Activity! +} + +input IssueMatchChangeFilter { + action: [IssueMatchChangeActions] +} + +type IssueMatchChangeConnection implements Connection { + totalCount: Int! + edges: [IssueMatchChangeEdge] + pageInfo: PageInfo +} + +type IssueMatchChangeEdge implements Edge { + node: IssueMatchChange! + cursor: String +} + +enum IssueMatchChangeActions { + add, + remove +} diff --git a/internal/api/graphql/graph/schema/issue_repository.graphqls b/internal/api/graphql/graph/schema/issue_repository.graphqls new file mode 100644 index 00000000..a85967a7 --- /dev/null +++ b/internal/api/graphql/graph/schema/issue_repository.graphqls @@ -0,0 +1,37 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type IssueRepository implements Node { + id: ID! + name: String + url: String + issueVariants(filter: IssueVariantFilter, first: Int, after: String): IssueVariantConnection + services(filter: ServiceFilter, first: Int, after: String): ServiceConnection + created_at: DateTime + updated_at: DateTime +} + +input IssueRepositoryInput { + name: String + url: String +} + +type IssueRepositoryConnection implements Connection { + totalCount: Int! + edges: [IssueRepositoryEdge] + pageInfo: PageInfo +} + +type IssueRepositoryEdge implements Edge { + node: IssueRepository! + cursor: String + priority: Int + created_at: DateTime + updated_at: DateTime +} + +input IssueRepositoryFilter { + serviceName: [String] + serviceId: [String] + name: [String] +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/issue_variant.graphqls b/internal/api/graphql/graph/schema/issue_variant.graphqls new file mode 100644 index 00000000..f6ffc280 --- /dev/null +++ b/internal/api/graphql/graph/schema/issue_variant.graphqls @@ -0,0 +1,40 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type IssueVariant implements Node { + id: ID! + secondaryName: String + description: String + severity: Severity + issueRepositoryId: String + issueRepository: IssueRepository + issueId: String + issue: Issue + created_at: DateTime + updated_at: DateTime +} + +input IssueVariantInput { + secondaryName: String + description: String + issueRepositoryId: String + issueId: String + severity: SeverityInput +} + +type IssueVariantConnection implements Connection { + totalCount: Int! + edges: [IssueVariantEdge] + pageInfo: PageInfo +} + +type IssueVariantEdge implements Edge { + node: IssueVariant! + cursor: String + created_at: DateTime + updated_at: DateTime +} + +input IssueVariantFilter { + secondaryName: [String] +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/mutation.graphqls b/internal/api/graphql/graph/schema/mutation.graphqls new file mode 100644 index 00000000..96a55c73 --- /dev/null +++ b/internal/api/graphql/graph/schema/mutation.graphqls @@ -0,0 +1,48 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type Mutation { + createUser(input: UserInput!): User! + updateUser(id: ID!, input: UserInput!): User! + deleteUser(id: ID!): String! + + createSupportGroup(input: SupportGroupInput!): SupportGroup! + updateSupportGroup(id: ID!, input: SupportGroupInput!): SupportGroup! + deleteSupportGroup(id: ID!): String! + + createComponent(input: ComponentInput!): Component! + updateComponent(id: ID!, input: ComponentInput!): Component! + deleteComponent(id: ID!): String! + + createComponentInstance(input: ComponentInstanceInput!): ComponentInstance! + updateComponentInstance(id: ID!, input: ComponentInstanceInput!): ComponentInstance! + deleteComponentInstance(id: ID!): String! + + createComponentVersion(input: ComponentVersionInput!): ComponentVersion! + updateComponentVersion(id: ID!, input: ComponentVersionInput!): ComponentVersion! + deleteComponentVersion(id: ID!): String! + + createService(input: ServiceInput!): Service! + updateService(id: ID!, input: ServiceInput!): Service! + deleteService(id: ID!): String! + + createIssueRepository(input: IssueRepositoryInput!): IssueRepository! + updateIssueRepository(id: ID!, input: IssueRepositoryInput!): IssueRepository! + deleteIssueRepository(id: ID!): String! + + createIssueVariant(input: IssueVariantInput!): IssueVariant! + updateIssueVariant(id: ID!, input: IssueVariantInput!): IssueVariant! + deleteIssueVariant(id: ID!): String! + + createEvidence(input: EvidenceInput!): Evidence! + updateEvidence(id: ID!, input: EvidenceInput!): Evidence! + deleteEvidence(id: ID!): String! + + createIssueMatch(input: IssueMatchInput!): IssueMatch! + updateIssueMatch(id: ID!, input: IssueMatchInput!): IssueMatch! + deleteIssueMatch(id: ID!): String! + + createActivity(input: ActivityInput!): Activity! + updateActivity(id: ID!, input: ActivityInput!): Activity! + deleteActivity(id: ID!): String! +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/query.graphqls b/internal/api/graphql/graph/schema/query.graphqls new file mode 100644 index 00000000..ebef272a --- /dev/null +++ b/internal/api/graphql/graph/schema/query.graphqls @@ -0,0 +1,18 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type Query { + Issues(filter: IssueFilter, first: Int, after: String): IssueConnection + IssueMatches(filter: IssueMatchFilter, first: Int, after: String): IssueMatchConnection + IssueMatchChanges(filter: IssueMatchChangeFilter, first: Int, after: String): IssueMatchChangeConnection + Services(filter: ServiceFilter, first: Int, after: String): ServiceConnection + Components(filter: ComponentFilter, first: Int, after: String): ComponentConnection + ComponentVersions(filter: ComponentVersionFilter, first: Int, after: String): ComponentVersionConnection + ComponentInstances(filter: ComponentInstanceFilter, first: Int, after: String): ComponentInstanceConnection + Activities(filter: ActivityFilter, first: Int, after: String): ActivityConnection + IssueVariants(filter: IssueVariantFilter, first: Int, after: String): IssueVariantConnection + IssueRepositories(filter: IssueRepositoryFilter, first: Int, after: String): IssueRepositoryConnection + Evidences(filter: EvidenceFilter, first: Int, after: String): EvidenceConnection + SupportGroups(filter: SupportGroupFilter, first: Int, after: String): SupportGroupConnection + Users(filter: UserFilter, first: Int, after: String): UserConnection +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/service.graphqls b/internal/api/graphql/graph/schema/service.graphqls new file mode 100644 index 00000000..ad619ae0 --- /dev/null +++ b/internal/api/graphql/graph/schema/service.graphqls @@ -0,0 +1,35 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type Service implements Node { + id: ID! + name: String + owners(filter: UserFilter, first: Int, after: String): UserConnection + supportGroups(filter: SupportGroupFilter, first: Int, after: String): SupportGroupConnection + activities(filter: ActivityFilter, first: Int, after: String): ActivityConnection + issueRepositories(filter: IssueRepositoryFilter, first: Int, after: String): IssueRepositoryConnection + componentInstances(filter: ComponentInstanceFilter, first: Int, after: String): ComponentInstanceConnection +} + +input ServiceInput { + name: String +} + +type ServiceConnection implements Connection { + totalCount: Int! + edges: [ServiceEdge] + pageInfo: PageInfo +} + +type ServiceEdge implements Edge { + node: Service! + cursor: String + priority: Int +} + +input ServiceFilter { + serviceName: [String] + userSapID: [String] + userName: [String] + supportGroupName: [String] +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/support_group.graphqls b/internal/api/graphql/graph/schema/support_group.graphqls new file mode 100644 index 00000000..9f1df03d --- /dev/null +++ b/internal/api/graphql/graph/schema/support_group.graphqls @@ -0,0 +1,29 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type SupportGroup implements Node { + id: ID! + name: String + users(filter: UserFilter, first: Int, after: String): UserConnection + services(filter: ServiceFilter, first: Int, after: String): ServiceConnection +} + +input SupportGroupInput { + name: String +} + +type SupportGroupConnection implements Connection { + totalCount: Int! + edges: [SupportGroupEdge] + pageInfo: PageInfo +} + +type SupportGroupEdge implements Edge { + node: SupportGroup! + cursor: String +} + +input SupportGroupFilter { + supportGroupName: [String], + userIds: [String], +} \ No newline at end of file diff --git a/internal/api/graphql/graph/schema/user.graphqls b/internal/api/graphql/graph/schema/user.graphqls new file mode 100644 index 00000000..6e698f84 --- /dev/null +++ b/internal/api/graphql/graph/schema/user.graphqls @@ -0,0 +1,31 @@ +# SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +# SPDX-License-Identifier: Apache-2.0 + +type User implements Node { + id:ID! + sapID: String + name: String + supportGroups(filter: SupportGroupFilter, first: Int, after: String): SupportGroupConnection + services(filter: ServiceFilter, first: Int, after: String): ServiceConnection +} + +input UserInput { + sapID: String + name: String +} + +type UserConnection implements Connection { + totalCount: Int! + edges: [UserEdge] + pageInfo: PageInfo +} + +type UserEdge implements Edge { + node: User! + cursor: String +} + +input UserFilter { + userName: [String], + supportGroupIds: [String], +} \ No newline at end of file diff --git a/internal/api/graphql/server.go b/internal/api/graphql/server.go new file mode 100644 index 00000000..b5154c30 --- /dev/null +++ b/internal/api/graphql/server.go @@ -0,0 +1,45 @@ +// SPDX-FileCopyrightText: 2024 SAP SE or an SAP affiliate company and Greenhouse contributors +// SPDX-License-Identifier: Apache-2.0 + +package graphqlapi + +import ( + "github.com/99designs/gqlgen/graphql/handler" + "github.com/99designs/gqlgen/graphql/playground" + "github.com/gin-gonic/gin" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph" + "github.wdf.sap.corp/cc/heureka/internal/api/graphql/graph/resolver" + "github.wdf.sap.corp/cc/heureka/internal/app" +) + +type GraphQLAPI struct { + Server *handler.Server + App app.Heureka +} + +func NewGraphQLAPI(a app.Heureka) *GraphQLAPI { + graphQLAPI := GraphQLAPI{ + Server: handler.NewDefaultServer(graph.NewExecutableSchema(resolver.NewResolver(a))), + App: a, + } + return &graphQLAPI +} + +func (g *GraphQLAPI) CreateEndpoints(router *gin.Engine) { + router.GET("/playground", g.playgroundHandler()) + router.POST("/query", g.graphqlHandler()) +} + +func (g *GraphQLAPI) graphqlHandler() gin.HandlerFunc { + return func(c *gin.Context) { + g.Server.ServeHTTP(c.Writer, c.Request) + } +} + +func (g *GraphQLAPI) playgroundHandler() gin.HandlerFunc { + h := playground.Handler("GraphQL", "/query") + + return func(c *gin.Context) { + h.ServeHTTP(c.Writer, c.Request) + } +}