Skip to content

Multiple issues with FieldResolvers (Version: 1.5.0) #58

@kobylynskyi

Description

@kobylynskyi

Issue Description

  1. modelNameSuffix and modelNamePrefix are not considered when generating FieldResolver interface which results in build failure.
  2. Gradle plugin ignores some properties:
    0a28021#diff-90e622d874a9fff19c74ff1d1c421f0dR38-R39

Expected Result

public interface ItemResolver {
    ProductTO product(ItemTO itemTO, DataFetchingEnvironment env) throws Exception;
}

Actual Result

public interface ItemResolver {
    ProductTO product(Item item, DataFetchingEnvironment env) throws Exception;
}

Your Environment and Setup

  • graphql-java-codegen: 1.5.0
  • Build tool: Gradle
  • Mapping Config:
task graphqlCodegenOrderService(type: GraphqlCodegenGradleTask) {
    graphqlSchemaPaths = ["$projectDir/src/main/resources/schema.graphqls".toString()]
    outputDir = new File("$buildDir/generated-server")
    apiPackageName = "io.github.kobylynskyi.order.graphql.api"
    modelPackageName = "io.github.kobylynskyi.order.graphql.model"
    customTypesMapping = [
            DateTime: "java.util.Date"
    ]
    modelNameSuffix = "TO"
    fieldsWithResolvers = ["Item.product"]
}

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions