Skip to content

/AWS1/CL_APY=>UPDATERESOLVER()

About UpdateResolver

Updates a Resolver object.

Method Signature

IMPORTING

Required arguments:

IV_APIID TYPE /AWS1/APYSTRING /AWS1/APYSTRING

The API ID.

IV_TYPENAME TYPE /AWS1/APYRESOURCENAME /AWS1/APYRESOURCENAME

The new type name.

IV_FIELDNAME TYPE /AWS1/APYRESOURCENAME /AWS1/APYRESOURCENAME

The new field name.

Optional arguments:

IV_DATASOURCENAME TYPE /AWS1/APYRESOURCENAME /AWS1/APYRESOURCENAME

The new data source name.

IV_REQUESTMAPPINGTEMPLATE TYPE /AWS1/APYMAPPINGTEMPLATE /AWS1/APYMAPPINGTEMPLATE

The new request mapping template.

A resolver uses a request mapping template to convert a GraphQL expression into a format that a data source can understand. Mapping templates are written in Apache Velocity Template Language (VTL).

VTL request mapping templates are optional when using an Lambda data source. For all other data sources, VTL request and response mapping templates are required.

IV_RESPONSEMAPPINGTEMPLATE TYPE /AWS1/APYMAPPINGTEMPLATE /AWS1/APYMAPPINGTEMPLATE

The new response mapping template.

IV_KIND TYPE /AWS1/APYRESOLVERKIND /AWS1/APYRESOLVERKIND

The resolver type.

  • UNIT: A UNIT resolver type. A UNIT resolver is the default resolver type. You can use a UNIT resolver to run a GraphQL query against a single data source.

  • PIPELINE: A PIPELINE resolver type. You can use a PIPELINE resolver to invoke a series of Function objects in a serial manner. You can use a pipeline resolver to run a GraphQL query against multiple data sources.

IO_PIPELINECONFIG TYPE REF TO /AWS1/CL_APYPIPELINECONFIG /AWS1/CL_APYPIPELINECONFIG

The PipelineConfig.

IO_SYNCCONFIG TYPE REF TO /AWS1/CL_APYSYNCCONFIG /AWS1/CL_APYSYNCCONFIG

The SyncConfig for a resolver attached to a versioned data source.

IO_CACHINGCONFIG TYPE REF TO /AWS1/CL_APYCACHINGCONFIG /AWS1/CL_APYCACHINGCONFIG

The caching configuration for the resolver.

IV_MAXBATCHSIZE TYPE /AWS1/APYMAXBATCHSIZE /AWS1/APYMAXBATCHSIZE

The maximum batching size for a resolver.

IO_RUNTIME TYPE REF TO /AWS1/CL_APYAPPSYNCRUNTIME /AWS1/CL_APYAPPSYNCRUNTIME

runtime

IV_CODE TYPE /AWS1/APYCODE /AWS1/APYCODE

The resolver code that contains the request and response functions. When code is used, the runtime is required. The runtime value must be APPSYNC_JS.

IV_METRICSCONFIG TYPE /AWS1/APYRESOLVERLEVELMETCFG /AWS1/APYRESOLVERLEVELMETCFG

Enables or disables enhanced resolver metrics for specified resolvers. Note that metricsConfig won't be used unless the resolverLevelMetricsBehavior value is set to PER_RESOLVER_METRICS. If the resolverLevelMetricsBehavior is set to FULL_REQUEST_RESOLVER_METRICS instead, metricsConfig will be ignored. However, you can still set its value.

metricsConfig can be ENABLED or DISABLED.

RETURNING

OO_OUTPUT TYPE REF TO /AWS1/CL_APYUPDATERESOLVERRSP /AWS1/CL_APYUPDATERESOLVERRSP