Repository navigation
Releases
v0.2.0
Code-first schemas and support for Adobe ColdFusion.
New
-
Code-first schemas.
modelPathsandservicePathsbuild the schema from annotated CFCs:@graphqlType,@graphqlInputand@graphqlEnumclasses;@graphqlQueryand@graphqlMutationservice functions;@graphqlCrud, which adds the CRUD shapes.
The annotations can be doc-comment tags or attributes, and the generated schema can be used alongside hand-written
.graphqlsfiles or instead of them. -
Authorization.
@graphqlRequireson properties, resolver methods and service functions, checked bysettings.authorizer. -
Batch loaders.
settings.loaders, with nothing cached between requests. -
Interfaces and unions. Resolved through
{Type}Resolver.resolveType, then__typename, then the class name. -
Scalars. DateTime and Long are built in;
settings.scalarsadds your own as closures. -
Errors. Errors follow the GraphQL spec's shape, with
onErrorandmaskErrors. -
Limits.
maxQueryDepthandmaxQueryComplexity. -
API.
execute()andhandle()return plain structs. -
Instances.
instanceFactorybuilds services, resolvers and input beans yourself.
Engines
- Tested on Lucee 5.4.8.2 and Adobe ColdFusion 2023 (update 26): 138 specs pass on both.
- The module now runs on ACF, which it did not before.
- BoxLang apps should use bx-graphql.
Behaviour changes
- The HTTP endpoint answers 400 when
variablesisn't an object, and leaveserrorsout when there are none. resolverBasePackageandschemaPathsare optional whenmodelPathsorservicePathsis set.- A custom scalar that can't serialize a resolver's value fails the whole request, on both engines.