diff --git a/composition/src/directive-definition-data/directive-definition-data.ts b/composition/src/directive-definition-data/directive-definition-data.ts index 9484840bc0..d320ad5263 100644 --- a/composition/src/directive-definition-data/directive-definition-data.ts +++ b/composition/src/directive-definition-data/directive-definition-data.ts @@ -85,10 +85,11 @@ import { OPENFED_CACHE_POPULATE, OPENFED_ENTITY_CACHE, INCLUDE_HEADERS, + OPENFED_IS, MAX_AGE, NEGATIVE_CACHE_TTL, PARTIAL_CACHE_LOAD, - OPENFED_REQUEST_SCOPED, + OPENFED_QUERY_CACHE, SHADOW_MODE, } from '../utils/string-constants'; import { @@ -124,7 +125,8 @@ import { OPENFED_CACHE_INVALIDATE_DEFINITION, OPENFED_CACHE_POPULATE_DEFINITION, OPENFED_ENTITY_CACHE_DEFINITION, - OPENFED_REQUEST_SCOPED_DEFINITION, + OPENFED_IS_DEFINITION, + OPENFED_QUERY_CACHE_DEFINITION, SPECIFIED_BY_DEFINITION, SUBSCRIPTION_FILTER_DEFINITION, TAG_DEFINITION, @@ -1047,20 +1049,60 @@ export const CACHE_POPULATE_DEFINITION_DATA = newDirectiveDefinitionData({ node: OPENFED_CACHE_POPULATE_DEFINITION, optionalArgumentNames: new Set([MAX_AGE]), }); -export const REQUEST_SCOPED_DEFINITION_DATA = newDirectiveDefinitionData({ + +export const QUERY_CACHE_DEFINITION_DATA = newDirectiveDefinitionData({ argumentDataByName: new Map([ [ - KEY, + MAX_AGE, newDirectiveArgumentData({ - directive: `@${OPENFED_REQUEST_SCOPED}`, - name: KEY, + directive: `@${OPENFED_QUERY_CACHE}`, + name: MAX_AGE, namedTypeKind: Kind.SCALAR_TYPE_DEFINITION, - typeNode: REQUIRED_STRING_TYPE_NODE, + typeNode: REQUIRED_INT_TYPE_NODE, + }), + ], + [ + INCLUDE_HEADERS, + newDirectiveArgumentData({ + directive: `@${OPENFED_QUERY_CACHE}`, + defaultValue: { kind: Kind.BOOLEAN, value: false }, + name: INCLUDE_HEADERS, + namedTypeKind: Kind.SCALAR_TYPE_DEFINITION, + typeNode: stringToNamedTypeNode(BOOLEAN_SCALAR), + }), + ], + [ + SHADOW_MODE, + newDirectiveArgumentData({ + directive: `@${OPENFED_QUERY_CACHE}`, + defaultValue: { kind: Kind.BOOLEAN, value: false }, + name: SHADOW_MODE, + namedTypeKind: Kind.SCALAR_TYPE_DEFINITION, + typeNode: stringToNamedTypeNode(BOOLEAN_SCALAR), }), ], ]), locations: new Set([FIELD_DEFINITION_UPPER]), - name: OPENFED_REQUEST_SCOPED, - node: OPENFED_REQUEST_SCOPED_DEFINITION, - requiredArgumentNames: new Set([KEY]), + name: OPENFED_QUERY_CACHE, + node: OPENFED_QUERY_CACHE_DEFINITION, + optionalArgumentNames: new Set([INCLUDE_HEADERS, SHADOW_MODE]), + requiredArgumentNames: new Set([MAX_AGE]), +}); + +export const IS_DEFINITION_DATA = newDirectiveDefinitionData({ + argumentDataByName: new Map([ + [ + FIELDS, + newDirectiveArgumentData({ + directive: `@${OPENFED_IS}`, + name: FIELDS, + namedTypeKind: Kind.SCALAR_TYPE_DEFINITION, + typeNode: REQUIRED_STRING_TYPE_NODE, + }), + ], + ]), + locations: new Set([ARGUMENT_DEFINITION_UPPER]), + name: OPENFED_IS, + node: OPENFED_IS_DEFINITION, + requiredArgumentNames: new Set([FIELDS]), }); diff --git a/composition/src/errors/errors.ts b/composition/src/errors/errors.ts index 0023a0ddd3..22f46f7105 100644 --- a/composition/src/errors/errors.ts +++ b/composition/src/errors/errors.ts @@ -18,6 +18,7 @@ import { type InvalidRepeatedDirectiveErrorParams, type InvalidSubValueFieldLinkDirectiveImportErrorParams, type invalidVersionLinkDirectiveUrlErrorParams, + type MaxAgeNotPositiveIntegerErrorParams, type NonExternalConditionalFieldErrorParams, type OneOfRequiredFieldsErrorParams, type SemanticNonNullLevelsIndexOutOfBoundsErrorParams, @@ -2056,14 +2057,31 @@ export function entityCacheWithoutKeyErrorMessage(typeName: TypeName): string { return `Object "${typeName}" does not define a "@key" directive.`; } -export function maxAgeNotPositiveIntegerErrorMessage(value: number | string | null): string { - return `The argument "maxAge" must be provided a positive integer; received "${value}".`; +export function maxAgeNotPositiveIntegerErrorMessage({ + directiveName, + value, +}: MaxAgeNotPositiveIntegerErrorParams): string { + return `The directive "@${directiveName}" argument "maxAge" must be provided a positive integer; received "${value}".`; } export function negativeCacheTTLNotNonNegativeIntegerErrorMessage(value: number): string { return `The argument "negativeCacheTTL" must be provided zero or a positive integer; received "${value}".`; } +export function queryCacheOnNonQueryFieldErrorMessage(fieldCoords: string): string { + return ( + `@openfed__queryCache must only be defined on fields of the root query type; found on "${fieldCoords}".` + + ` Use @openfed__cachePopulate or @openfed__cacheInvalidate on mutation or subscription fields.` + ); +} + +export function queryCacheOnNonEntityReturnTypeErrorMessage(fieldCoords: string, returnType: string): string { + return ( + `Field "${fieldCoords}" has @openfed__queryCache but returns non-entity type "${returnType}".` + + ` @openfed__queryCache requires the return type to be an entity with @key.` + ); +} + export function invalidMutationOrSubscriptionFieldCoordsErrorMessage(fieldCoords: string): string { return `Field coordinates "${fieldCoords}" are not a Mutation or Subscription root field.`; } @@ -2081,3 +2099,230 @@ export function invalidMutuallyExclusiveCacheDirectivesError(fieldCoords: string ` and "@openfed__cachePopulate".`, ); } + +export function isWithoutQueryCacheErrorMessage(argumentName: string, fieldCoords: string): string { + return `@openfed__is on argument "${argumentName}" of field "${fieldCoords}" has no effect without @openfed__queryCache.`; +} + +export function isReferencesUnknownKeyFieldErrorMessage( + isField: string, + argumentName: string, + fieldCoords: string, + entityType: string, +): string { + return ( + `@openfed__is(fields: "${isField}") on argument "${argumentName}" of field "${fieldCoords}"` + + ` references unknown @key field "${isField}" on type "${entityType}".` + ); +} + +export function duplicateKeyFieldMappingErrorMessage(fieldCoords: string, keyField: string): string { + return `Multiple arguments on field "${fieldCoords}" map to @key field "${keyField}".`; +} + +export function explicitTypeMismatchErrorMessage( + argumentName: string, + fieldCoords: string, + argumentType: string, + isField: string, + entityType: string, + keyFieldType: string, +): string { + return `Argument "${argumentName}" on field "${fieldCoords}" has type "${argumentType}" but @openfed__is(fields: "${isField}") targets @key field "${isField}" of type "${keyFieldType}" on entity "${entityType}".`; +} + +export function nonKeyFieldSpecErrorMessage( + argumentName: string, + fieldCoords: string, + isField: string, + entityType: string, +): string { + return `Argument "${argumentName}" on field "${fieldCoords}" uses @openfed__is(fields: "${isField}"), but "${isField}" is not a @key field on entity "${entityType}". @openfed__is can only target fields that are part of a @key.`; +} + +export function listArgumentToScalarKeySpecErrorMessage( + argumentName: string, + fieldCoords: string, + argumentType: string, + isField: string, + entityType: string, + keyFieldType: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" has type "${argumentType}" but @openfed__is(fields: "${isField}") targets @key field "${isField}" of type "${keyFieldType}" on entity "${entityType}".` + + ' List arguments can only map to scalar key fields when the field returns a list of entities, or to list key fields when the key field itself is a list type.' + ); +} + +export function scalarArgumentToListKeySpecErrorMessage( + argumentName: string, + fieldCoords: string, + argumentType: string, + isField: string, + entityType: string, + keyFieldType: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" has type "${argumentType}" but @openfed__is(fields: "${isField}") targets @key field "${isField}" of type "${keyFieldType}" on entity "${entityType}".` + + ' A scalar argument cannot map to a list key field.' + ); +} + +export function explicitIncompleteCompositeKeyErrorMessage( + fieldCoords: string, + argumentName: string, + mappedField: string, + entityType: string, + compositeKey: string, + missingField: string, +): string { + return `Field "${fieldCoords}" has argument "${argumentName}" with @openfed__is mapping to @key field "${mappedField}" on entity "${entityType}", but composite @key "${compositeKey}" is incomplete because no argument maps to required key field "${missingField}".`; +} + +export function explicitSingularAdditionalNonKeyArgumentErrorMessage( + fieldCoords: string, + argumentName: string, + keyField: string, + entityType: string, + extraArgument: string, +): string { + return `Field "${fieldCoords}" has argument "${argumentName}" with @openfed__is mapping to @key field "${keyField}" on entity "${entityType}", but also has additional argument "${extraArgument}" which is not mapped to a key field. All arguments must be key arguments — additional arguments may filter the response, making the cache key incomplete.`; +} + +export function explicitCompositeAdditionalNonKeyArgumentErrorMessage( + fieldCoords: string, + firstArgument: string, + secondArgument: string, + compositeKey: string, + entityType: string, + extraArgument: string, +): string { + return `Field "${fieldCoords}" has arguments "${firstArgument}" and "${secondArgument}" with @openfed__is mappings covering composite @key "${compositeKey}" on entity "${entityType}", but also has additional argument "${extraArgument}" which is not mapped to a key field. All arguments must be key arguments — additional arguments may filter the response, making the cache key incomplete.`; +} + +export function batchListValuedKeyRequiresNestedListsErrorMessage( + fieldCoords: string, + isField: string, + entityType: string, + actualType: string, +): string { + return `Field "${fieldCoords}" returns a list of entities, so cache lookup is a batch lookup and requires one key value per entity. Because @openfed__is(fields: "${isField}") targets list-valued @key field "${isField}" on entity "${entityType}", the argument must provide a list of tag lists (e.g., "[[String!]!]!"), not ${actualType}.`; +} + +export function explicitBatchAdditionalNonKeyArgumentErrorMessage( + fieldCoords: string, + argumentName: string, + keyField: string, + entityType: string, + extraArgument: string, +): string { + return `Field "${fieldCoords}" returns a list of entities, so cache lookup is a batch lookup and requires a single key input that determines the returned entities. Argument "${argumentName}" uses @openfed__is to map to @key field "${keyField}" on entity "${entityType}", but additional argument "${extraArgument}" is not mapped to a key field and may filter the response, so the batch key would be incomplete.`; +} + +export function explicitScalarArgumentsCannotEstablishBatchMappingErrorMessage( + fieldCoords: string, + entityType: string, +): string { + return `Field "${fieldCoords}" returns a list of entities, so cache lookup is a batch lookup and requires one key value per entity. Scalar arguments with @openfed__is mapping to @key fields on entity "${entityType}" cannot provide a batch of keys, so they cannot establish cache key mappings for this field. Use list arguments for batch cache lookups.`; +} + +export function multipleListArgumentsBatchFactoryMessage(fieldCoords: string, entityType: string): string { + return ( + `Field "${fieldCoords}" has multiple list arguments mapping to @key fields on entity "${entityType}".` + + ' Batch cache lookups require a single list argument.' + + ' For composite keys, use a single list of input objects instead.' + ); +} + +export function inputObjectCompositeTypeMismatchErrorMessage( + argumentName: string, + fieldCoords: string, + keyFields: string, + entityType: string, + inputType: string, + inputFieldName: string, + inputFieldType: string, + entityFieldPath: string, + entityFieldType: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" uses @openfed__is(fields: "${keyFields}") mapping to composite @key on entity "${entityType}",` + + ` but input type "${inputType}" field "${inputFieldName}" has type "${inputFieldType}"` + + ` which does not match key field "${entityFieldPath}" of type "${entityFieldType}".` + ); +} + +export function inputObjectCompositeMissingFieldErrorMessage( + argumentName: string, + fieldCoords: string, + keyFields: string, + entityType: string, + inputType: string, + missingFieldName: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" uses @openfed__is(fields: "${keyFields}") mapping to composite @key on entity "${entityType}",` + + ` but input type "${inputType}" is missing required key field "${missingFieldName}".` + ); +} + +export function nestedKeyRequiresInputObjectErrorMessage( + argumentName: string, + fieldCoords: string, + keyFields: string, + entityType: string, + inputTypeName: string, + entityKeyPath: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" maps to nested @key "${keyFields}" on entity "${entityType}",` + + ` but the input field at key path "${entityKeyPath}" has type "${inputTypeName}",` + + ` which is not an input object type and therefore cannot provide the nested key selection.` + ); +} + +export function nestedInputObjectTypeMismatchErrorMessage( + argumentName: string, + fieldCoords: string, + keyFields: string, + entityType: string, + inputType: string, + inputFieldName: string, + inputFieldType: string, + entityFieldPath: string, + entityFieldType: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" maps to nested @key "${keyFields}" on entity "${entityType}",` + + ` but input type "${inputType}" field "${inputFieldName}" has type "${inputFieldType}"` + + ` which does not match key field "${entityFieldPath}" of type "${entityFieldType}".` + ); +} + +export function nestedInputObjectMissingFieldErrorMessage( + argumentName: string, + fieldCoords: string, + keyFields: string, + entityType: string, + inputType: string, + missingFieldName: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" maps to nested @key "${keyFields}" on entity "${entityType}",` + + ` but input type "${inputType}" is missing required key field "${missingFieldName}".` + ); +} + +export function nonInputArgumentCannotTargetCompositeKeyErrorMessage( + argumentName: string, + fieldCoords: string, + keyFields: string, + entityType: string, + argumentType: string, +): string { + return ( + `Argument "${argumentName}" on field "${fieldCoords}" uses @openfed__is(fields: "${keyFields}") targeting composite @key on entity "${entityType}",` + + ` but argument type "${argumentType}" does not provide nested fields for each key field.` + + ' Use separate arguments or an input object that matches the composite key shape.' + ); +} diff --git a/composition/src/errors/types/params.ts b/composition/src/errors/types/params.ts index 826aa98382..a4b8833fc7 100644 --- a/composition/src/errors/types/params.ts +++ b/composition/src/errors/types/params.ts @@ -99,3 +99,8 @@ export type InvalidEntityReturnTypeErrorParams = { fieldCoords: string; returnTypeName: string; }; + +export type MaxAgeNotPositiveIntegerErrorParams = { + directiveName: DirectiveName; + value: number | string | null; +}; diff --git a/composition/src/router-configuration/types.ts b/composition/src/router-configuration/types.ts index aec0bb1b47..f4de342e17 100644 --- a/composition/src/router-configuration/types.ts +++ b/composition/src/router-configuration/types.ts @@ -87,17 +87,6 @@ export type RequiredFieldConfiguration = { disableEntityResolver?: boolean; }; -export type RequestScopedConfiguration = { - fieldName: FieldName; - typeName: TypeName; - // L1 cache key used to store/lookup this field's value for the duration of a request. - // Format: "{subgraphName}.{key}" where `key` is the @openfed__requestScoped(key:) argument. - // All fields in the same subgraph declaring @openfed__requestScoped with the same key share - // the same L1 entry — the first one to resolve populates it, subsequent ones inject - // from it (subject to widening checks and alias-aware normalization). - l1Key: string; -}; - export type ConfigurationData = { fieldNames: Set; isRootNode: boolean; @@ -131,6 +120,36 @@ export type EntityCacheConfiguration = { shadowMode: boolean; }; +// Maps a single query argument to an entity's @key field. Every mapping is declared explicitly with +// @openfed__is; an argument is never matched to a @key field by name alone. +// Example: product(productId: ID! @openfed__is(fields: "id")) on a @openfed__queryCache field +// → entityKeyField: "id", argumentPath: ["productId"] +export type FieldMappingConfig = { + entityKeyField: FieldName; + argumentPath: Array; + isBatch?: boolean; +}; + +// Groups field mappings for a single entity type returned by a @openfed__queryCache field. +export type EntityKeyMappingConfig = { + entityTypeName: TypeName; + fieldMappings: Array; +}; + +// Extracted from @openfed__queryCache(maxAge: Int!, includeHeaders: Boolean, shadowMode: Boolean) +// on Query fields. Tells the router which query fields can serve entities from cache. +export type QueryCacheConfig = { + fieldName: FieldName; + maxAgeSeconds: number; + includeHeaders: boolean; + shadowMode: boolean; + // The entity type this query field returns (must have @openfed__entityCache). + entityTypeName: TypeName; + // Maps query arguments to entity @key fields so the router can construct cache keys from query + // arguments. Empty for list-returning fields without batch mappings (cache reads are skipped). + entityKeyMappings: Array; +}; + // Extracted from @openfed__cacheInvalidate on Mutation/Subscription fields. // Tells the router to evict the returned entity from the cache after the operation completes. export type CacheInvalidateConfiguration = { @@ -156,8 +175,8 @@ export type EntityCachingConfiguration = { cachePopulateConfigurations: Array; // Attached to an entity type's ConfigurationData (e.g. "Product") from @openfed__entityCache. entityCacheConfigurations: Array; - // Attached to a field's ConfigurationData from @openfed__requestScoped. - requestScopedConfigurations: Array; + // Attached to the Query type's ConfigurationData from @openfed__queryCache. + queryCacheConfigurations?: Array; }; export type Costs = { diff --git a/composition/src/router-configuration/utils.ts b/composition/src/router-configuration/utils.ts index ede1663733..54fb3b7bf0 100644 --- a/composition/src/router-configuration/utils.ts +++ b/composition/src/router-configuration/utils.ts @@ -22,7 +22,6 @@ export function getOrInitializeEntityCaching(configurationData: ConfigurationDat cacheInvalidateConfigurations: [], cachePopulateConfigurations: [], entityCacheConfigurations: [], - requestScopedConfigurations: [], }; } diff --git a/composition/src/utils/string-constants.ts b/composition/src/utils/string-constants.ts index dc18f3083a..f155c7471d 100644 --- a/composition/src/utils/string-constants.ts +++ b/composition/src/utils/string-constants.ts @@ -83,6 +83,7 @@ export const INT_SCALAR = 'Int'; export const INTERFACE = `Interface`; export const INTERFACE_UPPER = 'INTERFACE'; export const INTERFACE_OBJECT = 'interfaceObject'; +export const OPENFED_IS = 'openfed__is'; export const KEY = 'key'; export const LEFT_PARENTHESIS = '('; export const LEVELS = 'levels'; @@ -94,6 +95,7 @@ export const LIST = 'list'; export const LITERAL_AT = '@'; export const LITERAL_SPACE = ' '; export const LITERAL_NEW_LINE = '\n'; +export const LITERAL_OPEN_BRACE = '{'; export const LITERAL_PERIOD = '.'; export const MAX_AGE = 'maxAge'; export const NUMBER = 'number'; @@ -126,13 +128,13 @@ export const PROVIDER_ID = 'providerId'; export const PROVIDES = 'provides'; export const PUBLISH = 'publish'; export const QUERY = 'Query'; +export const OPENFED_QUERY_CACHE = 'openfed__queryCache'; export const QUERY_UPPER = 'QUERY'; export const QUOTATION_JOIN = `", "`; export const REASON = 'reason'; export const REQUEST = 'request'; export const REQUIRE_FETCH_REASONS = 'openfed__requireFetchReasons'; export const REQUIRE_ONE_SLICING_ARGUMENT = 'requireOneSlicingArgument'; -export const OPENFED_REQUEST_SCOPED = 'openfed__requestScoped'; export const REQUIRES = 'requires'; export const REQUIRES_SCOPES = 'requiresScopes'; export const RESOLVABLE = 'resolvable'; diff --git a/composition/src/v1/constants/constants.ts b/composition/src/v1/constants/constants.ts index cf16590b35..3134ed5c90 100644 --- a/composition/src/v1/constants/constants.ts +++ b/composition/src/v1/constants/constants.ts @@ -10,7 +10,8 @@ import { OPENFED_CACHE_POPULATE, COST, OPENFED_ENTITY_CACHE, - OPENFED_REQUEST_SCOPED, + OPENFED_IS, + OPENFED_QUERY_CACHE, DEPRECATED, EDFS_KAFKA_PUBLISH, EDFS_KAFKA_SUBSCRIBE, @@ -81,7 +82,8 @@ import { OPENFED_CACHE_INVALIDATE_DEFINITION, OPENFED_CACHE_POPULATE_DEFINITION, OPENFED_ENTITY_CACHE_DEFINITION, - OPENFED_REQUEST_SCOPED_DEFINITION, + OPENFED_IS_DEFINITION, + OPENFED_QUERY_CACHE_DEFINITION, } from './directive-definitions'; export const DIRECTIVE_DEFINITION_BY_NAME: ReadonlyMap = new Map< @@ -97,7 +99,8 @@ export const DIRECTIVE_DEFINITION_BY_NAME: ReadonlyMap(); - /* Cached entity configs keyed by type name, populated by extractEntityCacheDirective() from - * @openfed__entityCache. Future caching directives (@openfed__queryCache etc.) use this as a lookup + /** + * Cached entity configs keyed by type name, populated by {@link extractEntityCacheDirective} from + * `@openfed__entityCache`. Future caching directives (`@openfed__queryCache` etc.) use this as a lookup * to verify a field's return type is a cached entity. */ entityCacheConfigByTypeName = new Map(); @@ -508,7 +536,6 @@ export class NormalizationFactory { referencedDirectiveNames = new Set(); referencedTypeNames = new Set(); renamedParentTypeName = ''; - requestScopedFieldCoordsByL1Key = new Map>(); schemaData: SchemaData; subgraphName: SubgraphName; unvalidatedExternalFieldCoords = new Set(); @@ -4039,7 +4066,7 @@ export class NormalizationFactory { /* validateDirectives() (run earlier in normalize()) has already guaranteed each argument's type — * Int for maxAge/negativeCacheTTL, Boolean for the flags — so the generic ConstDirectiveNode is - * narrowed once to the precise typed node, mirroring RequestScopedDirectiveNode/ComposeDirectiveNode. + * narrowed once to the precise typed node, mirroring ComposeDirectiveNode. * Optional arguments may be absent (definition defaults are not materialized onto the usage AST), * so the config starts at the directive's documented defaults and each present argument overrides it. */ @@ -4104,7 +4131,7 @@ export class NormalizationFactory { if (config.maxAgeSeconds <= 0) { entityCacheErrors.push( invalidDirectiveError(OPENFED_ENTITY_CACHE, typeName, FIRST_ORDINAL, [ - maxAgeNotPositiveIntegerErrorMessage(config.maxAgeSeconds), + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_ENTITY_CACHE, value: config.maxAgeSeconds }), ]), ); } @@ -4238,7 +4265,10 @@ export class NormalizationFactory { this.errors.push( invalidDirectiveError(OPENFED_CACHE_POPULATE, fieldCoords, FIRST_ORDINAL, [ // If null is explicitly provided in GraphQL the value in JS is undefined. - maxAgeNotPositiveIntegerErrorMessage(maxAgeArgument.value.value ?? null), + maxAgeNotPositiveIntegerErrorMessage({ + directiveName: OPENFED_CACHE_POPULATE, + value: maxAgeArgument.value.value ?? null, + }), ]), ); return true; @@ -4252,36 +4282,921 @@ export class NormalizationFactory { return true; } - // Attaches a single field annotated with @openfed__requestScoped to its type's configurationData. A field - // is both a reader and writer of the coordinate L1 — no receiver/provider. Fields with the same `key` share - // the same L1 entry: whichever is resolved first populates it, subsequent ones inject from it. - extractRequestScopedConfig(fieldData: FieldData) { - const directives = fieldData.directivesByName.get(OPENFED_REQUEST_SCOPED); - if (!directives) { + extractQueryCacheConfig( + parentTypeName: string, + configurationTypeName: string, + fieldName: string, + fieldData: FieldData, + operationType: OperationTypeNode | undefined, + ) { + const fieldCoords = `${parentTypeName}.${fieldName}`; + if (operationType !== OperationTypeNode.QUERY) { + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + queryCacheOnNonQueryFieldErrorMessage(fieldCoords), + ]), + ); + return; + } + const returnTypeName = getTypeNodeNamedTypeName(fieldData.node.type); + if (!this.keyFieldSetDatasByTypeName.has(returnTypeName)) { + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + queryCacheOnNonEntityReturnTypeErrorMessage(fieldCoords, returnTypeName), + ]), + ); + return; + } + // validateDirectives() has already guaranteed the argument types (Int maxAge, Boolean flags), so the + // generic ConstDirectiveNode is narrowed once to the precise typed node — mirroring + // EntityCacheDirectiveNode. Optional args may be absent (definition defaults + // are not materialized onto the usage AST), so each defaults here and present args override. + const queryCacheDirective = fieldData.directivesByName.get(OPENFED_QUERY_CACHE)![0] as QueryCacheDirectiveNode; + let maxAgeSeconds = 0; + let includeHeaders = false; + let shadowModeValue = false; + for (const { name, value } of queryCacheDirective.arguments) { + switch (name.value) { + case MAX_AGE: + if (value.kind === Kind.INT) maxAgeSeconds = parseInt(value.value, 10); + break; + case INCLUDE_HEADERS: + if (value.kind === Kind.BOOLEAN) includeHeaders = value.value; + break; + case SHADOW_MODE: + if (value.kind === Kind.BOOLEAN) shadowModeValue = value.value; + break; + } + } + if (maxAgeSeconds <= 0) { + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_QUERY_CACHE, value: maxAgeSeconds }), + ]), + ); return; } - // validateDirectives() (run earlier in normalize()) has already guaranteed a single, non-repeated - // @openfed__requestScoped with a required String `key`, so the generic ConstDirectiveNode can be - // narrowed to the precise typed node — mirroring handleComposeDirective()/ComposeDirectiveNode. - const directive = directives[0] as RequestScopedDirectiveNode; - const keyArg = directive.arguments.find((arg) => arg.name.value === KEY); - if (!keyArg) { + + // The return entity must have @openfed__entityCache — otherwise there is no L1/L2 backing store + // for queryCache to read from. Warn and skip extraction. Only actionable when the return type is an + // OBJECT (@openfed__entityCache is OBJECT-only), so skip the prereq check for interface/union returns. + const returnTypeData = this.parentDefinitionDataByTypeName.get(returnTypeName); + const isObjectReturn = returnTypeData?.kind === Kind.OBJECT_TYPE_DEFINITION; + if (isObjectReturn && !this.entityCacheConfigByTypeName.has(returnTypeName)) { + this.warnings.push( + queryCacheReturnEntityMissingEntityCacheWarning({ + subgraphName: this.subgraphName, + fieldCoords, + entityType: returnTypeName, + }), + ); return; } - const config: RequestScopedConfiguration = { - fieldName: fieldData.name, - typeName: fieldData.renamedParentTypeName, - l1Key: `${this.subgraphName}.${keyArg.value.value}`, + const isListReturn = isTypeNodeListType(fieldData.node.type); + const keyFieldSets = this.keyFieldSetDatasByTypeName.get(returnTypeName); + const mappings = this.buildArgumentKeyMappings(fieldData, fieldCoords, returnTypeName, keyFieldSets, isListReturn); + + const config: QueryCacheConfig = { + fieldName, + maxAgeSeconds, + includeHeaders, + shadowMode: shadowModeValue, + entityTypeName: returnTypeName, + entityKeyMappings: mappings, }; - const configurationData = getValueOrDefault(this.configurationDataByTypeName, fieldData.renamedParentTypeName, () => - newConfigurationData(false, fieldData.renamedParentTypeName), + const configurationData = getValueOrDefault(this.configurationDataByTypeName, configurationTypeName, () => + newConfigurationData(false, configurationTypeName), ); - getOrInitializeEntityCaching(configurationData).requestScopedConfigurations.push(config); - // Track field coords per L1 key so the single-field warning can be emitted after the walk completes. - getValueOrDefault(this.requestScopedFieldCoordsByL1Key, config.l1Key, () => []).push( - `${config.typeName}.${config.fieldName}`, + const entityCaching = getOrInitializeEntityCaching(configurationData); + entityCaching.queryCacheConfigurations = [...(entityCaching.queryCacheConfigurations ?? []), config]; + } + + validateIsDirectivePlacement(fieldCoords: string, fieldData: FieldData) { + for (const [argumentName, argumentData] of fieldData.argumentDataByName) { + if (!argumentData.directivesByName.has(OPENFED_IS)) { + continue; + } + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argumentName}: ...)`, FIRST_ORDINAL, [ + isWithoutQueryCacheErrorMessage(argumentName, fieldCoords), + ]), + ); + } + } + + /** + * Extracts key field info from a key's `DocumentNode` AST. + * + * @returns An array of `{ path: "store.id", typeNode: TypeNode }` for each leaf field. + */ + extractKeyFieldInfos( + documentNode: DocumentNode, + entityTypeName: string, + ): Array<{ path: string; typeNode: TypeNode }> { + const result: Array<{ path: string; typeNode: TypeNode }> = []; + const operationDef = documentNode.definitions[0]; + if (!operationDef || !('selectionSet' in operationDef) || !operationDef.selectionSet) { + return result; + } + + const walkSelections = (selections: readonly any[], currentTypeName: string, pathPrefix: string) => { + for (const selection of selections) { + if (selection.kind !== Kind.FIELD) { + continue; + } + const fieldName = selection.name.value; + const fieldPath = pathPrefix ? `${pathPrefix}.${fieldName}` : fieldName; + + // Look up the field type on the current parent type + const parentData = this.parentDefinitionDataByTypeName.get(currentTypeName); + if (!parentData || !('fieldDataByName' in parentData)) { + continue; + } + const fieldData = parentData.fieldDataByName.get(fieldName); + if (!fieldData) { + continue; + } + + if (selection.selectionSet && selection.selectionSet.selections.length > 0) { + // Nested: recurse into the named type + const nestedTypeName = getTypeNodeNamedTypeName(fieldData.node.type); + walkSelections(selection.selectionSet.selections, nestedTypeName, fieldPath); + } else { + // Leaf field + result.push({ path: fieldPath, typeNode: fieldData.node.type }); + } + } + }; + + walkSelections(operationDef.selectionSet.selections, entityTypeName, ''); + return result; + } + + // Unwraps one layer of list: [T!]! -> T!, [[T!]!]! -> [T!]! + unwrapListType(typeNode: TypeNode): TypeNode { + if (typeNode.kind === Kind.LIST_TYPE) { + return typeNode.type; + } + if (typeNode.kind === Kind.NON_NULL_TYPE) { + const inner = this.unwrapListType(typeNode.type); + // If inner changed (was a list), return the unwrapped version without non-null wrapper + if (inner !== typeNode.type) { + return inner; + } + } + return typeNode; + } + + // Compare named types (unwrapping NonNull wrappers only, not list wrappers). + namedTypesMatch(a: TypeNode, b: TypeNode): boolean { + return getTypeNodeNamedTypeName(a) === getTypeNodeNamedTypeName(b); + } + + /** + * Structurally compare two `TypeNode`s: named type AND list/NonNull wrapping must match. + * Used at nested composite-key leaves where a printer-level mismatch (e.g., `[ID!]!` vs `ID`) + * must be rejected even though the named type (`ID`) agrees. + * + * @returns `true` if `expected` and `got` match in both named type and list/NonNull structure. + */ + typesMatchIncludingListShape(expected: TypeNode, got: TypeNode): boolean { + if (expected.kind !== got.kind) { + return false; + } + if (expected.kind === Kind.NAMED_TYPE) { + return expected.name.value === (got as typeof expected).name.value; + } + if (expected.kind === Kind.NON_NULL_TYPE || expected.kind === Kind.LIST_TYPE) { + return this.typesMatchIncludingListShape(expected.type, (got as typeof expected).type); + } + return false; + } + + // Get @openfed__is field value from an argument's directives. + getIsFieldValue(isDirective: ConstDirectiveNode): string | undefined { + if (isDirective.arguments) { + for (const arg of isDirective.arguments) { + if (arg.name.value === FIELDS && arg.value.kind === Kind.STRING) { + return (arg.value as StringValueNode).value; + } + } + } + return undefined; + } + + /** + * Validates and builds nested input object mappings against key field infos. + * + * @returns Field mappings, or `null` on error (errors already pushed). + */ + validateNestedInputObjectMapping( + argumentName: string, + fieldCoords: string, + entityTypeName: string, + keyFieldInfos: Array<{ path: string; typeNode: TypeNode }>, + normalizedFieldSet: string, + inputTypeName: string, + argumentPathPrefix: string[], + isBatch: boolean, + isNested: boolean, + entityKeyPathPrefix: string = '', + ): FieldMappingConfig[] | null { + const inputData = this.parentDefinitionDataByTypeName.get(inputTypeName); + if (!inputData || inputData.kind !== Kind.INPUT_OBJECT_TYPE_DEFINITION) { + if (isNested) { + // Mid-recursion the key demands a deeper selection (e.g. "store { id }"), but the + // input field type is scalar/unknown. Callers treat null as "error already pushed", + // so bailing silently here would discard the key without any diagnostic. + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + nestedKeyRequiresInputObjectErrorMessage( + argumentName, + fieldCoords, + normalizedFieldSet, + entityTypeName, + inputTypeName, + entityKeyPathPrefix, + ), + ]), + ); + } + return null; + } + + // Group key field infos by top-level field name for the current level + const topLevelGroups = new Map>(); + for (const info of keyFieldInfos) { + const dotIndex = info.path.indexOf(LITERAL_PERIOD); + const topField = dotIndex >= 0 ? info.path.substring(0, dotIndex) : info.path; + const restPath = dotIndex >= 0 ? info.path.substring(dotIndex + 1) : ''; + if (!topLevelGroups.has(topField)) { + topLevelGroups.set(topField, []); + } + topLevelGroups.get(topField)!.push({ ...info, restPath }); + } + + const fieldMappings: FieldMappingConfig[] = []; + + for (const [topField, infos] of topLevelGroups) { + const inputFieldData = inputData.inputValueDataByName.get(topField); + if (!inputFieldData) { + // Missing field in input type + if (isNested) { + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + nestedInputObjectMissingFieldErrorMessage( + argumentName, + fieldCoords, + normalizedFieldSet, + entityTypeName, + inputTypeName, + topField, + ), + ]), + ); + } else { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argumentName}: ...)`, FIRST_ORDINAL, [ + inputObjectCompositeMissingFieldErrorMessage( + argumentName, + fieldCoords, + normalizedFieldSet, + entityTypeName, + inputTypeName, + topField, + ), + ]), + ); + } + return null; + } + + const fullEntityKeyPath = entityKeyPathPrefix ? `${entityKeyPathPrefix}.${topField}` : topField; + const hasNestedFields = infos.some((i) => i.restPath !== ''); + if (hasNestedFields) { + // Recurse into nested input object + const nestedInfos = infos.map((i) => ({ path: i.restPath, typeNode: i.typeNode })); + const nestedInputTypeName = getTypeNodeNamedTypeName(inputFieldData.type); + const nestedMappings = this.validateNestedInputObjectMapping( + argumentName, + fieldCoords, + entityTypeName, + nestedInfos, + normalizedFieldSet, + nestedInputTypeName, + [...argumentPathPrefix, topField], + isBatch, + true, + fullEntityKeyPath, + ); + if (!nestedMappings) { + return null; + } + fieldMappings.push(...nestedMappings); + } else { + // Leaf: the input field must match the key field in BOTH named type and list/NonNull wrapping. + // Comparing only the named type would wrongly accept an `ID` input for a `[ID!]!` key field. + const keyTypeNode = infos[0].typeNode; + if (!this.typesMatchIncludingListShape(keyTypeNode, inputFieldData.type)) { + // Resolve the entity field's parent type for the error message + // We need to walk the full entity key path to find the parent of the leaf + const fullPath = entityKeyPathPrefix ? `${entityKeyPathPrefix}.${topField}` : topField; + const pathParts = fullPath.split(LITERAL_PERIOD); + let currentType = entityTypeName; + for (let i = 0; i < pathParts.length - 1; i++) { + const pd = this.parentDefinitionDataByTypeName.get(currentType); + if (pd && 'fieldDataByName' in pd) { + const fd = pd.fieldDataByName.get(pathParts[i]); + if (fd) { + currentType = getTypeNodeNamedTypeName(fd.node.type); + } + } + } + const entityFieldCoords = `${currentType}.${pathParts[pathParts.length - 1]}`; + if (isNested) { + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + nestedInputObjectTypeMismatchErrorMessage( + argumentName, + fieldCoords, + normalizedFieldSet, + entityTypeName, + inputTypeName, + topField, + printTypeNode(inputFieldData.node.type), + entityFieldCoords, + printTypeNode(keyTypeNode), + ), + ]), + ); + } else { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argumentName}: ...)`, FIRST_ORDINAL, [ + inputObjectCompositeTypeMismatchErrorMessage( + argumentName, + fieldCoords, + normalizedFieldSet, + entityTypeName, + inputTypeName, + topField, + printTypeNode(inputFieldData.node.type), + entityFieldCoords, + printTypeNode(keyTypeNode), + ), + ]), + ); + } + return null; + } + const mapping: FieldMappingConfig = { + entityKeyField: fullEntityKeyPath, + argumentPath: [...argumentPathPrefix, topField], + }; + if (isBatch) { + mapping.isBatch = true; + } + fieldMappings.push(mapping); + } + } + + return fieldMappings; + } + + // The main mapping builder. Evaluates each @key independently and emits all satisfiable keys. + buildArgumentKeyMappings( + fieldData: FieldData, + fieldCoords: string, + entityTypeName: string, + keyFieldSets: Map | undefined, + isListReturn: boolean, + ): EntityKeyMappingConfig[] { + if (!keyFieldSets || keyFieldSets.size === 0) { + return []; + } + + type ArgumentInfo = { + name: string; + data: InputValueData; + isFieldValue: string | undefined; // @openfed__is(fields: "...") value + isList: boolean; + typeNode: TypeNode; + }; + + const argumentInfos: ArgumentInfo[] = []; + // Mappings are derived exclusively from explicit @openfed__is directives. Argument names are + // never matched to @key fields. If no argument carries @openfed__is, the field has no mappings. + let hasExplicitIs = false; + for (const [argumentName, argumentData] of fieldData.argumentDataByName) { + const isDirectives = argumentData.directivesByName.get(OPENFED_IS); + const hasIs = !!isDirectives && isDirectives.length > 0; + hasExplicitIs = hasExplicitIs || hasIs; + + argumentInfos.push({ + name: argumentName, + data: argumentData, + isFieldValue: hasIs ? this.getIsFieldValue(isDirectives[0]) : undefined, + isList: isTypeNodeListType(argumentData.type), + typeNode: argumentData.type, + }); + } + + if (!hasExplicitIs) { + return []; + } + return this.buildExplicitMappings(fieldCoords, entityTypeName, keyFieldSets, isListReturn, argumentInfos); + } + + buildExplicitMappings( + fieldCoords: string, + entityTypeName: string, + keyFieldSets: Map, + isListReturn: boolean, + argumentInfos: Array<{ + name: string; + data: InputValueData; + isFieldValue: string | undefined; + isList: boolean; + typeNode: TypeNode; + }>, + ): EntityKeyMappingConfig[] { + // Collect all @openfed__is field values and their infos across ALL keys + const allKeyFieldInfosByKey = new Map>(); + // Build a set of ALL key field paths across all keys + const allKeyFieldPaths = new Set(); + // Also build a map from field path -> key field info for type lookups + const fieldInfoByPath = new Map(); + // Track which fields exist on the entity (not necessarily key fields) + const entityFieldNames = new Set(); + const entityParentData = this.parentDefinitionDataByTypeName.get(entityTypeName); + if (entityParentData && 'fieldDataByName' in entityParentData) { + for (const fname of entityParentData.fieldDataByName.keys()) { + entityFieldNames.add(fname); + } + } + + for (const [normalizedFieldSet, keyData] of keyFieldSets) { + const infos = this.extractKeyFieldInfos(keyData.documentNode, entityTypeName); + allKeyFieldInfosByKey.set(normalizedFieldSet, infos); + for (const info of infos) { + allKeyFieldPaths.add(info.path); + fieldInfoByPath.set(info.path, { typeNode: info.typeNode }); + } + } + + // Process each argument with @openfed__is + const explicitMappings: Array<{ + argumentName: string; + isFieldValue: string; + argumentInfo: (typeof argumentInfos)[0]; + }> = []; + const compositeMappings: EntityKeyMappingConfig[] = []; + const mappedKeyFieldToArgumentName = new Map(); + + for (const argInfo of argumentInfos) { + if (!argInfo.isFieldValue) { + continue; + } + + const isFieldValue = argInfo.isFieldValue; + + // Check if @openfed__is targets multiple fields (composite key via input object). A field-set string is + // composite whenever it contains whitespace (e.g. "id sku", "id\nsku") or a nested selection brace + // (e.g. "store{id}") — not only a literal space, or space-less/brace forms would be misread as scalars. + const isCompositeIsSpec = /[\s{]/.test(isFieldValue); + + if (isCompositeIsSpec) { + const errorCount = this.errors.length; + const mappings = this.buildCompositeIsMapping(fieldCoords, entityTypeName, keyFieldSets, isListReturn, argInfo); + if (this.errors.length > errorCount) { + return []; + } + for (const mapping of mappings) { + for (const fieldMapping of mapping.fieldMappings) { + mappedKeyFieldToArgumentName.set(fieldMapping.entityKeyField, argInfo.name); + } + } + compositeMappings.push(...mappings); + continue; + } + + // Check if the field exists on the entity at all but is not a key field + const topLevelFieldName = isFieldValue.split(LITERAL_PERIOD)[0]; + if (!allKeyFieldPaths.has(isFieldValue)) { + if (entityFieldNames.has(topLevelFieldName) && !isFieldValue.includes(LITERAL_PERIOD)) { + // Field exists but is not a key field + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + nonKeyFieldSpecErrorMessage(argInfo.name, fieldCoords, isFieldValue, entityTypeName), + ]), + ); + } else { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + isReferencesUnknownKeyFieldErrorMessage(isFieldValue, argInfo.name, fieldCoords, entityTypeName), + ]), + ); + } + return []; + } + + // Duplicate check + if (mappedKeyFieldToArgumentName.has(isFieldValue)) { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + duplicateKeyFieldMappingErrorMessage(fieldCoords, isFieldValue), + ]), + ); + return []; + } + + const keyFieldTypeNode = fieldInfoByPath.get(isFieldValue)!.typeNode; + const argTypeNode = argInfo.typeNode; + + // Type checking + if (isListReturn) { + // Batch mode + if (isTypeNodeListType(keyFieldTypeNode)) { + // Key field is a list - need list-of-lists argument + if (!argInfo.isList) { + // Scalar arg to list key in batch + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + batchListValuedKeyRequiresNestedListsErrorMessage( + fieldCoords, + isFieldValue, + entityTypeName, + `a scalar tag of type "${printTypeNode(argTypeNode)}"`, + ), + ]), + ); + return []; + } + // List arg but is it list-of-lists? + const unwrapped = this.unwrapListType(argTypeNode); + if (!isTypeNodeListType(unwrapped)) { + // Single list, not list of lists + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + batchListValuedKeyRequiresNestedListsErrorMessage( + fieldCoords, + isFieldValue, + entityTypeName, + `a single tag list of type "${printTypeNode(argTypeNode)}"`, + ), + ]), + ); + return []; + } + // List of lists - check inner type matches + const innerType = this.unwrapListType(unwrapped); + if (!this.namedTypesMatch(innerType, keyFieldTypeNode)) { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + explicitTypeMismatchErrorMessage( + argInfo.name, + fieldCoords, + printTypeNode(argTypeNode), + isFieldValue, + entityTypeName, + printTypeNode(keyFieldTypeNode), + ), + ]), + ); + return []; + } + } else { + // Key field is scalar - need list argument with matching element type + if (argInfo.isList) { + // Check element type + const unwrapped = this.unwrapListType(argTypeNode); + if (!this.namedTypesMatch(unwrapped, keyFieldTypeNode)) { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + explicitTypeMismatchErrorMessage( + argInfo.name, + fieldCoords, + printTypeNode(argTypeNode), + isFieldValue, + entityTypeName, + printTypeNode(keyFieldTypeNode), + ), + ]), + ); + return []; + } + } else { + // Scalar arg in batch mode - could still be valid as a scalar @openfed__is, we'll check later + } + } + } else { + // Singular mode + const argIsList = argInfo.isList; + const keyIsList = isTypeNodeListType(keyFieldTypeNode); + + if (argIsList && !keyIsList) { + // List arg to scalar key on singular return + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + listArgumentToScalarKeySpecErrorMessage( + argInfo.name, + fieldCoords, + printTypeNode(argTypeNode), + isFieldValue, + entityTypeName, + printTypeNode(keyFieldTypeNode), + ), + ]), + ); + return []; + } + + if (!argIsList && keyIsList) { + // Scalar arg to list key on singular return + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + scalarArgumentToListKeySpecErrorMessage( + argInfo.name, + fieldCoords, + printTypeNode(argTypeNode), + isFieldValue, + entityTypeName, + printTypeNode(keyFieldTypeNode), + ), + ]), + ); + return []; + } + + // Named type comparison (handles both scalar-scalar and list-list) + if (!this.namedTypesMatch(argTypeNode, keyFieldTypeNode)) { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + explicitTypeMismatchErrorMessage( + argInfo.name, + fieldCoords, + printTypeNode(argTypeNode), + isFieldValue, + entityTypeName, + printTypeNode(keyFieldTypeNode), + ), + ]), + ); + return []; + } + } + + mappedKeyFieldToArgumentName.set(isFieldValue, argInfo.name); + explicitMappings.push({ argumentName: argInfo.name, isFieldValue, argumentInfo: argInfo }); + } + + if (explicitMappings.length === 0) { + return compositeMappings; + } + + // Check for batch mode: all explicit mappings on list return + if (isListReturn) { + // Check for extra non-key arguments FIRST (not @openfed__is and not a key field in any key) + const extraArgs = argumentInfos.filter((a) => !a.isFieldValue && !allKeyFieldPaths.has(a.name)); + if (extraArgs.length > 0) { + const firstExplicit = explicitMappings[0]; + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${firstExplicit.argumentName}: ...)`, FIRST_ORDINAL, [ + explicitBatchAdditionalNonKeyArgumentErrorMessage( + fieldCoords, + firstExplicit.argumentName, + firstExplicit.isFieldValue, + entityTypeName, + extraArgs[0].name, + ), + ]), + ); + return []; + } + + // Check if all explicit args are scalars + const allScalar = explicitMappings.every((m) => !m.argumentInfo.isList); + const listMappings = explicitMappings.filter((m) => m.argumentInfo.isList); + + if (allScalar) { + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${explicitMappings[0].argumentName}: ...)`, FIRST_ORDINAL, [ + explicitScalarArgumentsCannotEstablishBatchMappingErrorMessage(fieldCoords, entityTypeName), + ]), + ); + return []; + } + + if (listMappings.length > 1) { + this.errors.push( + invalidDirectiveError(OPENFED_QUERY_CACHE, fieldCoords, FIRST_ORDINAL, [ + multipleListArgumentsBatchFactoryMessage(fieldCoords, entityTypeName), + ]), + ); + return []; + } + } else { + // Singular/composite return: check for extra non-key arguments (not @openfed__is and not a key field in any key). + const globalExtraArgs = argumentInfos.filter((a) => !a.isFieldValue && !allKeyFieldPaths.has(a.name)); + if (globalExtraArgs.length > 0) { + // Find which key the explicit mappings target + let targetKeyNormalized: string | undefined; + for (const [normalizedFieldSet] of keyFieldSets) { + const keyInfos = allKeyFieldInfosByKey.get(normalizedFieldSet)!; + const keyPaths = new Set(keyInfos.map((i) => i.path)); + if (explicitMappings.every((m) => keyPaths.has(m.isFieldValue))) { + targetKeyNormalized = normalizedFieldSet; + break; + } + } + + if (explicitMappings.length === 1 && targetKeyNormalized && !targetKeyNormalized.includes(LITERAL_SPACE)) { + this.errors.push( + invalidDirectiveError( + OPENFED_IS, + `${fieldCoords}(${explicitMappings[0].argumentName}: ...)`, + FIRST_ORDINAL, + [ + explicitSingularAdditionalNonKeyArgumentErrorMessage( + fieldCoords, + explicitMappings[0].argumentName, + explicitMappings[0].isFieldValue, + entityTypeName, + globalExtraArgs[0].name, + ), + ], + ), + ); + } else { + // targetKeyNormalized may be undefined here when the explicit @openfed__is mappings span more than + // one alternative @key (no single key contains all of them). The satisfiable-keys loop below could + // still build a valid mapping per key, but the extra non-key argument makes every candidate cache key + // incomplete — so this must error rather than silently discard the mappings. + const isArgNames = explicitMappings.map((m) => m.argumentName); + const coveredKeyFields = + targetKeyNormalized ?? explicitMappings.map((m) => m.isFieldValue).join(LITERAL_SPACE); + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${isArgNames[0]}: ...)`, FIRST_ORDINAL, [ + explicitCompositeAdditionalNonKeyArgumentErrorMessage( + fieldCoords, + isArgNames[0], + isArgNames[1] || isArgNames[0], + coveredKeyFields, + entityTypeName, + globalExtraArgs[0].name, + ), + ]), + ); + } + return []; + } + } + + // Now try to find satisfiable keys + const results: EntityKeyMappingConfig[] = []; + for (const normalizedFieldSet of keyFieldSets.keys()) { + const keyInfos = allKeyFieldInfosByKey.get(normalizedFieldSet)!; + const keyPaths = new Set(keyInfos.map((i) => i.path)); + + // Check which explicit mappings target this key + const explicitForThisKey = explicitMappings.filter((m) => keyPaths.has(m.isFieldValue)); + + // Every field of this key must be covered by an explicit @openfed__is mapping. + const unmappedFields: string[] = []; + let keyFullySatisfied = true; + + for (const info of keyInfos) { + if (explicitForThisKey.some((m) => m.isFieldValue === info.path)) { + continue; + } + unmappedFields.push(info.path); + keyFullySatisfied = false; + } + + if (!keyFullySatisfied) { + // If this key has explicit mappings targeting it but is incomplete, error + if (explicitForThisKey.length > 0 && unmappedFields.length > 0) { + this.errors.push( + invalidDirectiveError( + OPENFED_IS, + `${fieldCoords}(${explicitForThisKey[0].argumentName}: ...)`, + FIRST_ORDINAL, + [ + explicitIncompleteCompositeKeyErrorMessage( + fieldCoords, + explicitForThisKey[0].argumentName, + explicitForThisKey[0].isFieldValue, + entityTypeName, + normalizedFieldSet, + unmappedFields[0], + ), + ], + ), + ); + return []; + } + continue; + } + + // Build field mappings in key field info order + const fieldMappings: FieldMappingConfig[] = []; + for (const info of keyInfos) { + const explicitMatch = explicitForThisKey.find((m) => m.isFieldValue === info.path); + if (explicitMatch) { + const mapping: FieldMappingConfig = { + entityKeyField: explicitMatch.isFieldValue, + argumentPath: [explicitMatch.argumentName], + }; + if (isListReturn && explicitMatch.argumentInfo.isList) { + mapping.isBatch = true; + } + fieldMappings.push(mapping); + } + } + + if (fieldMappings.length > 0) { + results.push({ entityTypeName, fieldMappings }); + } + } + + // Each key remains its own EntityKeyMappingConfig — the router evaluates them + // independently (OR semantics). Do NOT merge single-field results. + return [...compositeMappings, ...results]; + } + + buildCompositeIsMapping( + fieldCoords: string, + entityTypeName: string, + keyFieldSets: Map, + isListReturn: boolean, + argInfo: { + name: string; + data: InputValueData; + isFieldValue: string | undefined; + isList: boolean; + typeNode: TypeNode; + }, + ): EntityKeyMappingConfig[] { + const isFieldValue = argInfo.isFieldValue!; + const { documentNode } = safeParse('{' + isFieldValue + '}'); + const normalizedIsFieldValue = documentNode ? getNormalizedFieldSet(documentNode) : isFieldValue; + + // Find the matching key + for (const [normalizedFieldSet, keyData] of keyFieldSets) { + if (normalizedFieldSet !== normalizedIsFieldValue) { + continue; + } + + const keyInfos = this.extractKeyFieldInfos(keyData.documentNode, entityTypeName); + const argTypeName = getTypeNodeNamedTypeName(argInfo.typeNode); + + // Check if argument is an input object type + const inputData = this.parentDefinitionDataByTypeName.get(argTypeName); + if (!inputData || inputData.kind !== Kind.INPUT_OBJECT_TYPE_DEFINITION) { + // Non-input argument targeting composite key + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + nonInputArgumentCannotTargetCompositeKeyErrorMessage( + argInfo.name, + fieldCoords, + isFieldValue, + entityTypeName, + printTypeNode(argInfo.typeNode), + ), + ]), + ); + return []; + } + + const isBatch = isListReturn && argInfo.isList; + const isNestedKey = normalizedFieldSet.includes(LITERAL_OPEN_BRACE); + + const fieldMappings = this.validateNestedInputObjectMapping( + argInfo.name, + fieldCoords, + entityTypeName, + keyInfos, + normalizedFieldSet, + argTypeName, + [argInfo.name], + isBatch, + isNestedKey, + ); + + if (!fieldMappings) { + return []; + } + + return [{ entityTypeName, fieldMappings }]; + } + + // Key not found + this.errors.push( + invalidDirectiveError(OPENFED_IS, `${fieldCoords}(${argInfo.name}: ...)`, FIRST_ORDINAL, [ + isReferencesUnknownKeyFieldErrorMessage(isFieldValue, argInfo.name, fieldCoords, entityTypeName), + ]), ); + return []; } addFieldNamesToConfigurationData(fieldDataByFieldName: Map, configurationData: ConfigurationData) { @@ -4474,7 +5389,28 @@ export class NormalizationFactory { for (const [fieldName, fieldData] of parentData.fieldDataByName) { if (isObject) { this.handleFieldCacheDirectives(fieldData); - this.extractRequestScopedConfig(fieldData); + + // @openfed__queryCache extraction and @openfed__is placement validation. Key field sets and + // entity-cache configs are already finalized at this point in normalize() (populated by + // upsertParentsAndChildren and extractEntityCacheDirective, invalid keys pruned by + // evaluateExternalKeyFields), so queryCache can read keyFieldSetDatasByTypeName to build + // argument→key mappings. + if (fieldData.directivesByName.has(OPENFED_QUERY_CACHE)) { + // A renamed root type (e.g. `schema { query: MyQuery }`) is keyed in configurationDataByTypeName + // under its federated/canonical name (Query/Mutation/Subscription) by every other config writer. + // Cache configs must use the same key, or the router reads the canonical node and never sees them. + this.extractQueryCacheConfig( + parentTypeName, + getParentTypeName(parentData), + fieldName, + fieldData, + this.getOperationTypeNodeForRootTypeName(parentTypeName), + ); + } else { + // @openfed__is on an argument is only valid alongside @openfed__queryCache on the field, so any + // @openfed__is here (no queryCache) is a misplacement. + this.validateIsDirectivePlacement(`${parentTypeName}.${fieldName}`, fieldData); + } } else if (fieldData.externalFieldDataBySubgraphName.get(this.subgraphName)?.isDefinedExternal) { externalInterfaceFieldNames.push(fieldName); } @@ -4566,21 +5502,6 @@ export class NormalizationFactory { } } } - // @openfed__requestScoped is meaningless unless >= 2 fields share a key (there'd be no second reader to - // benefit), so warn for any key used on only one field across the subgraph. extractRequestScopedConfig() - // populated requestScopedFieldCoordsByL1Key during the type walk above. - for (const [l1Key, fieldCoordsList] of this.requestScopedFieldCoordsByL1Key) { - if (fieldCoordsList.length === 1) { - this.warnings.push( - requestScopedSingleFieldWarning({ - subgraphName: this.subgraphName, - // l1Key is `${this.subgraphName}.${key}`, so strip the prefix to recover the original key. - key: l1Key.slice(this.subgraphName.length + 1), - fieldCoords: fieldCoordsList[0], - }), - ); - } - } this.isSubgraphEventDrivenGraph = this.edfsDirectiveReferences.size > 0; // this is where @provides and @requires configurations are added to the ConfigurationData this.addValidConditionalFieldSetConfigurations(); diff --git a/composition/src/v1/normalization/types/types.ts b/composition/src/v1/normalization/types/types.ts index eb6d08efd5..77eaf20f4e 100644 --- a/composition/src/v1/normalization/types/types.ts +++ b/composition/src/v1/normalization/types/types.ts @@ -148,20 +148,6 @@ export type ComposeDirectiveArgumentNode = { readonly loc?: Location; }; -export type RequestScopedDirectiveNode = { - readonly arguments: ReadonlyArray; - readonly kind: Kind.DIRECTIVE; - readonly name: NameNode; - readonly loc?: Location; -}; - -export type RequestScopedArgumentNode = { - readonly kind: Kind.ARGUMENT; - readonly name: NameNode; - readonly value: StringValueNode; // key: String! — guaranteed by validateDirectives() - readonly loc?: Location; -}; - export type EntityCacheDirectiveNode = { readonly arguments: | readonly [MaxAgeArgumentNode] @@ -218,6 +204,22 @@ export type ShadowModeArgumentNode = { readonly loc?: Location; }; +export type QueryCacheDirectiveNode = { + readonly arguments: ReadonlyArray; + readonly kind: Kind.DIRECTIVE; + readonly name: NameNode; + readonly loc?: Location; +}; + +export type QueryCacheArgumentNode = { + readonly kind: Kind.ARGUMENT; + readonly name: NameNode; + // maxAge is Int; includeHeaders/shadowMode are Boolean. + // validateDirectives() guarantees each argument's value matches its declared type. + readonly value: IntValueNode | BooleanValueNode; + readonly loc?: Location; +}; + export type CachePopulateDirectiveNode = { readonly arguments: ReadonlyArray; readonly kind: Kind.DIRECTIVE; diff --git a/composition/src/v1/normalization/utils.ts b/composition/src/v1/normalization/utils.ts index 8c3b6b470c..51a1a7a98b 100644 --- a/composition/src/v1/normalization/utils.ts +++ b/composition/src/v1/normalization/utils.ts @@ -79,7 +79,8 @@ import { SUBSCRIPTION_FILTER_DEFINITION_DATA, TAG_DEFINITION_DATA, CACHE_POPULATE_DEFINITION_DATA, - REQUEST_SCOPED_DEFINITION_DATA, + IS_DEFINITION_DATA, + QUERY_CACHE_DEFINITION_DATA, } from '../../directive-definition-data/directive-definition-data'; import { AS, @@ -90,7 +91,8 @@ import { CONNECT_FIELD_RESOLVER, OPENFED_CACHE_POPULATE, COST, - OPENFED_REQUEST_SCOPED, + OPENFED_IS, + OPENFED_QUERY_CACHE, DEPRECATED, EDFS_KAFKA_PUBLISH, EDFS_KAFKA_SUBSCRIBE, @@ -484,7 +486,8 @@ export function initializeDirectiveDefinitionDatas(): Map { expect(errors).toHaveLength(1); expect(errors[0]).toStrictEqual( invalidDirectiveError(OPENFED_CACHE_POPULATE, 'Mutation.createProduct', FIRST_ORDINAL, [ - maxAgeNotPositiveIntegerErrorMessage(0), + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_CACHE_POPULATE, value: 0 }), ]), ); }); @@ -241,7 +241,7 @@ describe('@openfed__cachePopulate tests', () => { expect(errors).toHaveLength(1); expect(errors).toStrictEqual([ invalidDirectiveError(OPENFED_CACHE_POPULATE, 'Mutation.createProduct', FIRST_ORDINAL, [ - maxAgeNotPositiveIntegerErrorMessage(0), + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_CACHE_POPULATE, value: 0 }), ]), ]); expect(warnings).toHaveLength(0); @@ -311,7 +311,7 @@ describe('@openfed__cachePopulate tests', () => { expect(errors).toHaveLength(1); expect(errors[0]).toStrictEqual( invalidDirectiveError(OPENFED_CACHE_POPULATE, 'Mutation.updateProduct', FIRST_ORDINAL, [ - maxAgeNotPositiveIntegerErrorMessage(null), + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_CACHE_POPULATE, value: null }), ]), ); }); diff --git a/composition/tests/v1/directives/entity-cache.test.ts b/composition/tests/v1/directives/entity-cache.test.ts index 84aaea0095..e48f97d0e6 100644 --- a/composition/tests/v1/directives/entity-cache.test.ts +++ b/composition/tests/v1/directives/entity-cache.test.ts @@ -56,7 +56,7 @@ describe('@openfed__entityCache tests', () => { expect(errors).toHaveLength(1); expect(errors[0]).toStrictEqual( invalidDirectiveError(OPENFED_ENTITY_CACHE, 'Product', FIRST_ORDINAL, [ - maxAgeNotPositiveIntegerErrorMessage(0), + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_ENTITY_CACHE, value: 0 }), ]), ); }); @@ -75,7 +75,7 @@ describe('@openfed__entityCache tests', () => { expect(errors).toHaveLength(1); expect(errors[0]).toStrictEqual( invalidDirectiveError(OPENFED_ENTITY_CACHE, 'Product', FIRST_ORDINAL, [ - maxAgeNotPositiveIntegerErrorMessage(-5), + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_ENTITY_CACHE, value: -5 }), ]), ); }); diff --git a/composition/tests/v1/directives/query-cache.test.ts b/composition/tests/v1/directives/query-cache.test.ts new file mode 100644 index 0000000000..d457e6c47f --- /dev/null +++ b/composition/tests/v1/directives/query-cache.test.ts @@ -0,0 +1,1138 @@ +import { describe, expect, test } from 'vitest'; +import { + batchListValuedKeyRequiresNestedListsErrorMessage, + duplicateKeyFieldMappingErrorMessage, + explicitBatchAdditionalNonKeyArgumentErrorMessage, + explicitCompositeAdditionalNonKeyArgumentErrorMessage, + explicitIncompleteCompositeKeyErrorMessage, + explicitScalarArgumentsCannotEstablishBatchMappingErrorMessage, + explicitSingularAdditionalNonKeyArgumentErrorMessage, + explicitTypeMismatchErrorMessage, + FIRST_ORDINAL, + inputObjectCompositeMissingFieldErrorMessage, + inputObjectCompositeTypeMismatchErrorMessage, + invalidDirectiveError, + invalidRepeatedDirectiveErrorMessage, + isReferencesUnknownKeyFieldErrorMessage, + isWithoutQueryCacheErrorMessage, + listArgumentToScalarKeySpecErrorMessage, + maxAgeNotPositiveIntegerErrorMessage, + multipleListArgumentsBatchFactoryMessage, + nestedInputObjectMissingFieldErrorMessage, + nestedInputObjectTypeMismatchErrorMessage, + nestedKeyRequiresInputObjectErrorMessage, + nonInputArgumentCannotTargetCompositeKeyErrorMessage, + nonKeyFieldSpecErrorMessage, + OPENFED_IS, + OPENFED_QUERY_CACHE, + queryCacheOnNonEntityReturnTypeErrorMessage, + queryCacheOnNonQueryFieldErrorMessage, + queryCacheReturnEntityMissingEntityCacheWarning, + ROUTER_COMPATIBILITY_VERSION_ONE, + scalarArgumentToListKeySpecErrorMessage, + undefinedRequiredArgumentsErrorMessage, +} from '../../../src'; +import { createSubgraphWithDefaultName, normalizeSubgraphFailure, normalizeSubgraphSuccess } from '../../utils/utils'; + +describe('@openfed__queryCache', () => { + describe('configuration extraction', () => { + test('a queryCache field returning a cached entity produces a rootFieldCacheConfiguration with defaults', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const config = result.configurationDataByTypeName.get('Query'); + const rootFieldConfigs = config!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs).toBeDefined(); + expect(rootFieldConfigs).toHaveLength(1); + expect(rootFieldConfigs![0]).toMatchObject({ + fieldName: 'user', + maxAgeSeconds: 60, + includeHeaders: false, + shadowMode: false, + entityTypeName: 'User', + }); + expect(result.warnings).toHaveLength(0); + }); + + test('explicit includeHeaders and shadowMode are reflected in the extracted config', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 120, includeHeaders: true, shadowMode: true) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0]).toMatchObject({ + fieldName: 'user', + maxAgeSeconds: 120, + includeHeaders: true, + shadowMode: true, + }); + }); + + test('@openfed__is maps an argument to the returned entity @key field', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + user(id: ID! @openfed__is(fields: "id")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'User', + fieldMappings: [{ entityKeyField: 'id', argumentPath: ['id'] }], + }, + ]); + }); + + test('multiple queryCache fields each produce a rootFieldCacheConfiguration', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 60) + product: Product @openfed__queryCache(maxAge: 30) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + type Product @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs).toHaveLength(2); + expect(rootFieldConfigs!.map((c) => c.fieldName)).toEqual(['user', 'product']); + }); + + test('a composite @openfed__is via an input-object argument maps every nested key field', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + product(key: ProductKey! @openfed__is(fields: "id sku")): Product @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID! + sku: String! + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'Product', + fieldMappings: [ + { entityKeyField: 'id', argumentPath: ['key', 'id'] }, + { entityKeyField: 'sku', argumentPath: ['key', 'sku'] }, + ], + }, + ]); + }); + + test('separate scalar arguments together cover a composite @key', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + product(id: ID! @openfed__is(fields: "id"), sku: String! @openfed__is(fields: "sku")): Product @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'Product', + fieldMappings: [ + { entityKeyField: 'id', argumentPath: ['id'] }, + { entityKeyField: 'sku', argumentPath: ['sku'] }, + ], + }, + ]); + }); + + test('a nested @openfed__is selection maps through an input object to a nested @key field', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + review(key: ReviewKey! @openfed__is(fields: "store{id}")): Review @openfed__queryCache(maxAge: 60) + } + input ReviewKey { + store: StoreKey! + } + input StoreKey { + id: ID! + } + type Review @key(fields: "store{id}") @openfed__entityCache(maxAge: 60) { + store: Store! + } + type Store @key(fields: "id") { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'Review', + fieldMappings: [{ entityKeyField: 'store.id', argumentPath: ['key', 'store', 'id'] }], + }, + ]); + }); + + test('a composite @key containing a list-valued field maps through an input object', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + product(key: ProductKey! @openfed__is(fields: "id tags")): Product @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID! + tags: [String!]! + } + type Product @key(fields: "id tags") @openfed__entityCache(maxAge: 60) { + id: ID! + tags: [String!]! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'Product', + fieldMappings: [ + { entityKeyField: 'id', argumentPath: ['key', 'id'] }, + { entityKeyField: 'tags', argumentPath: ['key', 'tags'] }, + ], + }, + ]); + }); + + test('an entity with multiple @keys maps only the @key fully covered by arguments', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + user(id: ID! @openfed__is(fields: "id")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @key(fields: "email") @openfed__entityCache(maxAge: 60) { + id: ID! + email: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'User', + fieldMappings: [{ entityKeyField: 'id', argumentPath: ['id'] }], + }, + ]); + }); + + test('a list-returning field with a list of input objects produces a batch composite mapping', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + products(keys: [ProductKey!]! @openfed__is(fields: "id sku")): [Product] @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID! + sku: String! + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const batchConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(batchConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'Product', + fieldMappings: [ + { entityKeyField: 'id', argumentPath: ['keys', 'id'], isBatch: true }, + { entityKeyField: 'sku', argumentPath: ['keys', 'sku'], isBatch: true }, + ], + }, + ]); + }); + + test('a list-returning field with a list argument produces a batch mapping', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + users(ids: [ID!]! @openfed__is(fields: "id")): [User] @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'User', + fieldMappings: [{ entityKeyField: 'id', argumentPath: ['ids'], isBatch: true }], + }, + ]); + }); + + test('a batch lookup against a list-valued @key field accepts a list-of-lists argument', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + products(tags: [[String!]!]! @openfed__is(fields: "tags")): [Product] @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "tags") @openfed__entityCache(maxAge: 60) { + tags: [String!]! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const rootFieldConfigs = result.configurationDataByTypeName.get('Query')!.entityCaching?.queryCacheConfigurations; + expect(rootFieldConfigs![0].entityKeyMappings).toEqual([ + { + entityTypeName: 'Product', + fieldMappings: [{ entityKeyField: 'tags', argumentPath: ['tags'], isBatch: true }], + }, + ]); + }); + + test('a returned entity without @openfed__entityCache skips extraction and emits a warning', () => { + const result = normalizeSubgraphSuccess( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + const config = result.configurationDataByTypeName.get('Query'); + expect(config!.entityCaching?.queryCacheConfigurations).toBeUndefined(); + expect(result.warnings).toStrictEqual([ + queryCacheReturnEntityMissingEntityCacheWarning({ + subgraphName: 'subgraph-default-a', + fieldCoords: 'Query.user', + entityType: 'User', + }), + ]); + }); + }); + + describe('validation', () => { + test('the required maxAge argument missing is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.user', FIRST_ORDINAL, [ + undefinedRequiredArgumentsErrorMessage(OPENFED_QUERY_CACHE, ['maxAge'], []), + ]), + ); + }); + + test('a non-positive maxAge is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 0) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.user', FIRST_ORDINAL, [ + maxAgeNotPositiveIntegerErrorMessage({ directiveName: OPENFED_QUERY_CACHE, value: 0 }), + ]), + ); + }); + + test('@openfed__queryCache on a non-Query field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user: User + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + friend: User @openfed__queryCache(maxAge: 60) + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'User.friend', FIRST_ORDINAL, [ + queryCacheOnNonQueryFieldErrorMessage('User.friend'), + ]), + ); + }); + + test('@openfed__queryCache on a field returning a non-entity type is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 60) + } + type User { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.user', FIRST_ORDINAL, [ + queryCacheOnNonEntityReturnTypeErrorMessage('Query.user', 'User'), + ]), + ); + }); + + test('the directive is not repeatable — two on the same field fails', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user: User @openfed__queryCache(maxAge: 60) @openfed__queryCache(maxAge: 120) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.user', FIRST_ORDINAL, [ + invalidRepeatedDirectiveErrorMessage(OPENFED_QUERY_CACHE), + ]), + ); + }); + }); +}); + +describe('@openfed__is', () => { + describe('validation', () => { + test('@openfed__is without @openfed__queryCache on the same field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(id: ID! @openfed__is(fields: "id")): User + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(id: ...)', FIRST_ORDINAL, [ + isWithoutQueryCacheErrorMessage('id', 'Query.user'), + ]), + ); + }); + + test('@openfed__is without @openfed__queryCache still fails when other plain arguments are present', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(name: String, id: ID! @openfed__is(fields: "id")): User + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + name: String + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(id: ...)', FIRST_ORDINAL, [ + isWithoutQueryCacheErrorMessage('id', 'Query.user'), + ]), + ); + }); + + test('@openfed__is targeting a non-@key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(name: String! @openfed__is(fields: "name")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + name: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(name: ...)', FIRST_ORDINAL, [ + nonKeyFieldSpecErrorMessage('name', 'Query.user', 'name', 'User'), + ]), + ); + }); + + test('@openfed__is with an argument type that mismatches the @key field type is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(id: String! @openfed__is(fields: "id")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(id: ...)', FIRST_ORDINAL, [ + explicitTypeMismatchErrorMessage('id', 'Query.user', 'String!', 'id', 'User', 'ID!'), + ]), + ); + }); + + test('@openfed__is referencing a field absent from the entity is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(key: ID! @openfed__is(fields: "missing")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(key: ...)', FIRST_ORDINAL, [ + isReferencesUnknownKeyFieldErrorMessage('missing', 'key', 'Query.user', 'User'), + ]), + ); + }); + + test('two arguments mapping to the same @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(a: ID! @openfed__is(fields: "id"), b: ID! @openfed__is(fields: "id")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(b: ...)', FIRST_ORDINAL, [ + duplicateKeyFieldMappingErrorMessage('Query.user', 'id'), + ]), + ); + }); + + test('an incompletely-mapped composite @key is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(id: ID! @openfed__is(fields: "id")): Product @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(id: ...)', FIRST_ORDINAL, [ + explicitIncompleteCompositeKeyErrorMessage('Query.product', 'id', 'id', 'Product', 'id sku', 'sku'), + ]), + ); + }); + + test('an additional non-key argument alongside @openfed__is is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(id: ID! @openfed__is(fields: "id"), locale: String): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(id: ...)', FIRST_ORDINAL, [ + explicitSingularAdditionalNonKeyArgumentErrorMessage('Query.user', 'id', 'id', 'User', 'locale'), + ]), + ); + }); + + test('a single argument covering only part of a composite @key plus an extra argument is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(id: ID! @openfed__is(fields: "id"), x: String): Product @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(id: ...)', FIRST_ORDINAL, [ + explicitCompositeAdditionalNonKeyArgumentErrorMessage('Query.product', 'id', 'id', 'id sku', 'Product', 'x'), + ]), + ); + }); + + test('@openfed__is arguments mapping across two alternative @keys with an extra argument is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user( + id: ID! @openfed__is(fields: "id") + email: String! @openfed__is(fields: "email") + x: String + ): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @key(fields: "email") @openfed__entityCache(maxAge: 60) { + id: ID! + email: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(id: ...)', FIRST_ORDINAL, [ + explicitCompositeAdditionalNonKeyArgumentErrorMessage('Query.user', 'id', 'email', 'id email', 'User', 'x'), + ]), + ); + }); + + test('a list argument mapping to a scalar @key field on a singular return is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(ids: [ID!]! @openfed__is(fields: "id")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(ids: ...)', FIRST_ORDINAL, [ + listArgumentToScalarKeySpecErrorMessage('ids', 'Query.user', '[ID!]!', 'id', 'User', 'ID!'), + ]), + ); + }); + + test('a scalar argument mapping to a list-valued @key field on a singular return is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(tag: String! @openfed__is(fields: "tags")): Product @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "tags") @openfed__entityCache(maxAge: 60) { + tags: [String!]! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(tag: ...)', FIRST_ORDINAL, [ + scalarArgumentToListKeySpecErrorMessage('tag', 'Query.product', 'String!', 'tags', 'Product', '[String!]!'), + ]), + ); + }); + + test('a non-input-object argument cannot target a composite @key', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(key: ID! @openfed__is(fields: "id sku")): Product @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(key: ...)', FIRST_ORDINAL, [ + nonInputArgumentCannotTargetCompositeKeyErrorMessage('key', 'Query.product', 'id sku', 'Product', 'ID!'), + ]), + ); + }); + + test('a composite @openfed__is selection that matches no @key is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(key: ProductKey! @openfed__is(fields: "id name")): Product @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID! + name: String! + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + name: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(key: ...)', FIRST_ORDINAL, [ + isReferencesUnknownKeyFieldErrorMessage('id name', 'key', 'Query.product', 'Product'), + ]), + ); + }); + + test('a composite @key with an additional non-key argument is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product( + id: ID! @openfed__is(fields: "id") + sku: String! @openfed__is(fields: "sku") + filter: String + ): Product @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(id: ...)', FIRST_ORDINAL, [ + explicitCompositeAdditionalNonKeyArgumentErrorMessage( + 'Query.product', + 'id', + 'sku', + 'id sku', + 'Product', + 'filter', + ), + ]), + ); + }); + + describe('batch (list-returning) mappings', () => { + test('only scalar @openfed__is arguments cannot establish a batch mapping', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + users(id: ID! @openfed__is(fields: "id")): [User] @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.users(id: ...)', FIRST_ORDINAL, [ + explicitScalarArgumentsCannotEstablishBatchMappingErrorMessage('Query.users', 'User'), + ]), + ); + }); + + test('a scalar argument to a list-valued @key field requires nested lists', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + products(tag: String! @openfed__is(fields: "tags")): [Product] @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "tags") @openfed__entityCache(maxAge: 60) { + tags: [String!]! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.products(tag: ...)', FIRST_ORDINAL, [ + batchListValuedKeyRequiresNestedListsErrorMessage( + 'Query.products', + 'tags', + 'Product', + 'a scalar tag of type "String!"', + ), + ]), + ); + }); + + test('a single list argument to a list-valued @key field requires nested lists', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + products(tags: [String!]! @openfed__is(fields: "tags")): [Product] @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "tags") @openfed__entityCache(maxAge: 60) { + tags: [String!]! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.products(tags: ...)', FIRST_ORDINAL, [ + batchListValuedKeyRequiresNestedListsErrorMessage( + 'Query.products', + 'tags', + 'Product', + 'a single tag list of type "[String!]!"', + ), + ]), + ); + }); + + test('a list-of-lists argument whose inner type mismatches the list @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + products(tags: [[Int!]!]! @openfed__is(fields: "tags")): [Product] @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "tags") @openfed__entityCache(maxAge: 60) { + tags: [String!]! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.products(tags: ...)', FIRST_ORDINAL, [ + explicitTypeMismatchErrorMessage('tags', 'Query.products', '[[Int!]!]!', 'tags', 'Product', '[String!]!'), + ]), + ); + }); + + test('a list argument whose element type mismatches the scalar @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + users(ids: [String!]! @openfed__is(fields: "id")): [User] @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.users(ids: ...)', FIRST_ORDINAL, [ + explicitTypeMismatchErrorMessage('ids', 'Query.users', '[String!]!', 'id', 'User', 'ID!'), + ]), + ); + }); + + test('an additional non-key argument alongside a batch mapping is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + users(ids: [ID!]! @openfed__is(fields: "id"), filter: String): [User] @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.users(ids: ...)', FIRST_ORDINAL, [ + explicitBatchAdditionalNonKeyArgumentErrorMessage('Query.users', 'ids', 'id', 'User', 'filter'), + ]), + ); + }); + + test('multiple list arguments for a batch lookup is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + products( + ids: [ID!]! @openfed__is(fields: "id") + skus: [String!]! @openfed__is(fields: "sku") + ): [Product] @openfed__queryCache(maxAge: 60) + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.products', FIRST_ORDINAL, [ + multipleListArgumentsBatchFactoryMessage('Query.products', 'Product'), + ]), + ); + }); + }); + + describe('input-object composite mappings', () => { + test('an input-object field whose type mismatches a flat composite @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(key: ProductKey! @openfed__is(fields: "id sku")): Product @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID! + sku: Int! + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(key: ...)', FIRST_ORDINAL, [ + inputObjectCompositeTypeMismatchErrorMessage( + 'key', + 'Query.product', + 'id sku', + 'Product', + 'ProductKey', + 'sku', + 'Int!', + 'Product.sku', + 'String!', + ), + ]), + ); + }); + + test('an input-object field whose nullability differs from the composite @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(key: ProductKey! @openfed__is(fields: "id sku")): Product @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID + sku: String! + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(key: ...)', FIRST_ORDINAL, [ + inputObjectCompositeTypeMismatchErrorMessage( + 'key', + 'Query.product', + 'id sku', + 'Product', + 'ProductKey', + 'id', + 'ID', + 'Product.id', + 'ID!', + ), + ]), + ); + }); + + test('an input object missing a flat composite @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + product(key: ProductKey! @openfed__is(fields: "id sku")): Product @openfed__queryCache(maxAge: 60) + } + input ProductKey { + id: ID! + } + type Product @key(fields: "id sku") @openfed__entityCache(maxAge: 60) { + id: ID! + sku: String! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.product(key: ...)', FIRST_ORDINAL, [ + inputObjectCompositeMissingFieldErrorMessage( + 'key', + 'Query.product', + 'id sku', + 'Product', + 'ProductKey', + 'sku', + ), + ]), + ); + }); + + test('a nested @key selection backed by a scalar input field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + review(key: ReviewKey! @openfed__is(fields: "store{id}")): Review @openfed__queryCache(maxAge: 60) + } + input ReviewKey { + store: ID! + } + type Review @key(fields: "store{id}") @openfed__entityCache(maxAge: 60) { + store: Store! + } + type Store @key(fields: "id") { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.review', FIRST_ORDINAL, [ + nestedKeyRequiresInputObjectErrorMessage('key', 'Query.review', 'store { id }', 'Review', 'ID', 'store'), + ]), + ); + }); + + test('a nested input object missing the nested @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + review(key: ReviewKey! @openfed__is(fields: "store{id}")): Review @openfed__queryCache(maxAge: 60) + } + input ReviewKey { + store: StoreKey! + } + input StoreKey { + other: String! + } + type Review @key(fields: "store{id}") @openfed__entityCache(maxAge: 60) { + store: Store! + } + type Store @key(fields: "id") { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.review', FIRST_ORDINAL, [ + nestedInputObjectMissingFieldErrorMessage( + 'key', + 'Query.review', + 'store { id }', + 'Review', + 'StoreKey', + 'id', + ), + ]), + ); + }); + + test('a nested input object field whose type mismatches the nested @key field is a failure', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + review(key: ReviewKey! @openfed__is(fields: "store{id}")): Review @openfed__queryCache(maxAge: 60) + } + input ReviewKey { + store: StoreKey! + } + input StoreKey { + id: Int! + } + type Review @key(fields: "store{id}") @openfed__entityCache(maxAge: 60) { + store: Store! + } + type Store @key(fields: "id") { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_QUERY_CACHE, 'Query.review', FIRST_ORDINAL, [ + nestedInputObjectTypeMismatchErrorMessage( + 'key', + 'Query.review', + 'store { id }', + 'Review', + 'StoreKey', + 'id', + 'Int!', + 'Store.id', + 'ID!', + ), + ]), + ); + }); + }); + + test('the directive is not repeatable — two on the same argument fails', () => { + const { errors } = normalizeSubgraphFailure( + createSubgraphWithDefaultName(` + type Query { + user(id: ID! @openfed__is(fields: "id") @openfed__is(fields: "id")): User @openfed__queryCache(maxAge: 60) + } + type User @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + } + `), + ROUTER_COMPATIBILITY_VERSION_ONE, + ); + expect(errors[0]).toStrictEqual( + invalidDirectiveError(OPENFED_IS, 'Query.user(id: ...)', FIRST_ORDINAL, [ + invalidRepeatedDirectiveErrorMessage(OPENFED_IS), + ]), + ); + }); + }); +}); diff --git a/composition/tests/v1/directives/request-scoped.test.ts b/composition/tests/v1/directives/request-scoped.test.ts deleted file mode 100644 index 19cb72838d..0000000000 --- a/composition/tests/v1/directives/request-scoped.test.ts +++ /dev/null @@ -1,139 +0,0 @@ -import { describe, expect, test } from 'vitest'; -import { - FIRST_ORDINAL, - invalidDirectiveError, - invalidRepeatedDirectiveErrorMessage, - OPENFED_REQUEST_SCOPED, - OPENFED_REQUEST_SCOPED_DEFINITION, - requestScopedSingleFieldWarning, - ROUTER_COMPATIBILITY_VERSION_ONE, - undefinedRequiredArgumentsErrorMessage, -} from '../../../src'; -import { createSubgraphWithDefaultName, normalizeSubgraphFailure, normalizeSubgraphSuccess } from '../../utils/utils'; - -describe('@openfed__requestScoped tests', () => { - describe('registry tests', () => { - test('that the directive is materialized in the normalized subgraph output', () => { - const { directiveDefinitionByName } = normalizeSubgraphSuccess( - createSubgraphWithDefaultName(` - type Query { - me: User @openfed__requestScoped(key: "u") - viewer: User @openfed__requestScoped(key: "u") - } - type User @key(fields: "id") { - id: ID! - } - `), - ROUTER_COMPATIBILITY_VERSION_ONE, - ); - expect(directiveDefinitionByName.has(OPENFED_REQUEST_SCOPED)).toBe(true); - expect(directiveDefinitionByName.get(OPENFED_REQUEST_SCOPED)).toBe(OPENFED_REQUEST_SCOPED_DEFINITION); - }); - }); - - describe('configuration extraction tests', () => { - test('that ≥ 2 fields sharing the same key produce a subgraph-prefixed l1Key and no warning', () => { - const result = normalizeSubgraphSuccess( - createSubgraphWithDefaultName(` - type Query { - me: User @openfed__requestScoped(key: "me") - viewer: User @openfed__requestScoped(key: "me") - } - type User @key(fields: "id") { - id: ID! - } - `), - ROUTER_COMPATIBILITY_VERSION_ONE, - ); - const config = result.configurationDataByTypeName.get('Query'); - expect(config!.entityCaching?.requestScopedConfigurations).toBeDefined(); - expect(config!.entityCaching?.requestScopedConfigurations).toHaveLength(2); - expect(config!.entityCaching!.requestScopedConfigurations!.map((f) => f.l1Key)).toEqual([ - 'subgraph-default-a.me', - 'subgraph-default-a.me', - ]); - expect(result.warnings).toHaveLength(0); - }); - - test('that it works on a non-entity object type field', () => { - const result = normalizeSubgraphSuccess( - createSubgraphWithDefaultName(` - type Query { - currentLocale: String @openfed__requestScoped(key: "locale") - articleLocale: String @openfed__requestScoped(key: "locale") - } - `), - ROUTER_COMPATIBILITY_VERSION_ONE, - ); - const config = result.configurationDataByTypeName.get('Query'); - expect(config!.entityCaching?.requestScopedConfigurations).toBeDefined(); - expect(config!.entityCaching?.requestScopedConfigurations).toHaveLength(2); - expect(config!.entityCaching!.requestScopedConfigurations![0].fieldName).toBe('currentLocale'); - expect(config!.entityCaching!.requestScopedConfigurations![0].l1Key).toBe('subgraph-default-a.locale'); - }); - - test('that a key declared on only one field still populates config but emits a warning', () => { - const result = normalizeSubgraphSuccess( - createSubgraphWithDefaultName(` - type Query { - currentUser: User @openfed__requestScoped(key: "lonely") - } - type User @key(fields: "id") { - id: ID! - } - `), - ROUTER_COMPATIBILITY_VERSION_ONE, - ); - const config = result.configurationDataByTypeName.get('Query'); - expect(config!.entityCaching?.requestScopedConfigurations).toHaveLength(1); - expect(config!.entityCaching!.requestScopedConfigurations![0].l1Key).toBe('subgraph-default-a.lonely'); - expect(result.warnings).toStrictEqual([ - requestScopedSingleFieldWarning({ - subgraphName: 'subgraph-default-a', - key: 'lonely', - fieldCoords: 'Query.currentUser', - }), - ]); - }); - }); - - describe('validation tests', () => { - test('that a missing key argument is a failure', () => { - const { errors } = normalizeSubgraphFailure( - createSubgraphWithDefaultName(` - type Query { - currentUser: User @openfed__requestScoped - } - type User @key(fields: "id") { - id: ID! - } - `), - ROUTER_COMPATIBILITY_VERSION_ONE, - ); - expect(errors[0]).toStrictEqual( - invalidDirectiveError(OPENFED_REQUEST_SCOPED, 'Query.currentUser', FIRST_ORDINAL, [ - undefinedRequiredArgumentsErrorMessage(OPENFED_REQUEST_SCOPED, ['key'], []), - ]), - ); - }); - - test('that the directive is not repeatable — two on the same field fails', () => { - const { errors } = normalizeSubgraphFailure( - createSubgraphWithDefaultName(` - type Query { - currentUser: User @openfed__requestScoped(key: "a") @openfed__requestScoped(key: "b") - } - type User @key(fields: "id") { - id: ID! - } - `), - ROUTER_COMPATIBILITY_VERSION_ONE, - ); - expect(errors[0]).toStrictEqual( - invalidDirectiveError(OPENFED_REQUEST_SCOPED, 'Query.currentUser', FIRST_ORDINAL, [ - invalidRepeatedDirectiveErrorMessage(OPENFED_REQUEST_SCOPED), - ]), - ); - }); - }); -}); diff --git a/connect-go/gen/proto/wg/cosmo/node/v1/node.pb.go b/connect-go/gen/proto/wg/cosmo/node/v1/node.pb.go index 711017cdbf..f736dc5fb4 100644 --- a/connect-go/gen/proto/wg/cosmo/node/v1/node.pb.go +++ b/connect-go/gen/proto/wg/cosmo/node/v1/node.pb.go @@ -1234,10 +1234,10 @@ type EntityCachingConfiguration struct { CacheInvalidateConfigurations []*CacheInvalidateConfiguration `protobuf:"bytes,2,rep,name=cache_invalidate_configurations,json=cacheInvalidateConfigurations,proto3" json:"cache_invalidate_configurations,omitempty"` // Per-Mutation/Subscription-field cache population configs (from @openfed__cachePopulate) CachePopulateConfigurations []*CachePopulateConfiguration `protobuf:"bytes,3,rep,name=cache_populate_configurations,json=cachePopulateConfigurations,proto3" json:"cache_populate_configurations,omitempty"` - // Request-scoped field configurations (from @openfed__requestScoped directive) - RequestScopedConfigurations []*RequestScopedConfiguration `protobuf:"bytes,4,rep,name=request_scoped_configurations,json=requestScopedConfigurations,proto3" json:"request_scoped_configurations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache + // Per-Query-field cache configurations (from @openfed__queryCache / @openfed__is directives) + QueryCacheConfigurations []*QueryCacheConfiguration `protobuf:"bytes,5,rep,name=query_cache_configurations,json=queryCacheConfigurations,proto3" json:"query_cache_configurations,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *EntityCachingConfiguration) Reset() { @@ -1291,9 +1291,9 @@ func (x *EntityCachingConfiguration) GetCachePopulateConfigurations() []*CachePo return nil } -func (x *EntityCachingConfiguration) GetRequestScopedConfigurations() []*RequestScopedConfiguration { +func (x *EntityCachingConfiguration) GetQueryCacheConfigurations() []*QueryCacheConfiguration { if x != nil { - return x.RequestScopedConfigurations + return x.QueryCacheConfigurations } return nil } @@ -1522,33 +1522,36 @@ func (x *CachePopulateConfiguration) GetEntityTypeName() string { return "" } -// Per-field declaration for @openfed__requestScoped. All fields in the same subgraph declaring -// @openfed__requestScoped(key: "X") share L1 key "{subgraphName}.X". The first field to resolve -// populates L1; subsequent fields with the same key inject from L1 and can skip their -// fetch when all required sub-fields are present. -type RequestScopedConfiguration struct { - state protoimpl.MessageState `protogen:"open.v1"` - FieldName string `protobuf:"bytes,1,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` - TypeName string `protobuf:"bytes,2,opt,name=type_name,json=typeName,proto3" json:"type_name,omitempty"` - L1Key string `protobuf:"bytes,3,opt,name=l1_key,json=l1Key,proto3" json:"l1_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache +// Per-Query-field declaration for @openfed__queryCache. Tells the router a query field can serve +// its returned entity from the entity cache, with argument-to-@key mappings for cache-key construction. +type QueryCacheConfiguration struct { + state protoimpl.MessageState `protogen:"open.v1"` + FieldName string `protobuf:"bytes,1,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` + // TTL for cached root-field responses. Required: composition rejects values + // <= 0. Interpreted in seconds. + MaxAgeSeconds int64 `protobuf:"varint,2,opt,name=max_age_seconds,json=maxAgeSeconds,proto3" json:"max_age_seconds,omitempty"` + IncludeHeaders bool `protobuf:"varint,3,opt,name=include_headers,json=includeHeaders,proto3" json:"include_headers,omitempty"` + ShadowMode bool `protobuf:"varint,4,opt,name=shadow_mode,json=shadowMode,proto3" json:"shadow_mode,omitempty"` + EntityTypeName string `protobuf:"bytes,5,opt,name=entity_type_name,json=entityTypeName,proto3" json:"entity_type_name,omitempty"` + EntityKeyMappings []*EntityKeyMapping `protobuf:"bytes,6,rep,name=entity_key_mappings,json=entityKeyMappings,proto3" json:"entity_key_mappings,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } -func (x *RequestScopedConfiguration) Reset() { - *x = RequestScopedConfiguration{} +func (x *QueryCacheConfiguration) Reset() { + *x = QueryCacheConfiguration{} mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } -func (x *RequestScopedConfiguration) String() string { +func (x *QueryCacheConfiguration) String() string { return protoimpl.X.MessageStringOf(x) } -func (*RequestScopedConfiguration) ProtoMessage() {} +func (*QueryCacheConfiguration) ProtoMessage() {} -func (x *RequestScopedConfiguration) ProtoReflect() protoreflect.Message { +func (x *QueryCacheConfiguration) ProtoReflect() protoreflect.Message { mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[16] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1560,32 +1563,165 @@ func (x *RequestScopedConfiguration) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use RequestScopedConfiguration.ProtoReflect.Descriptor instead. -func (*RequestScopedConfiguration) Descriptor() ([]byte, []int) { +// Deprecated: Use QueryCacheConfiguration.ProtoReflect.Descriptor instead. +func (*QueryCacheConfiguration) Descriptor() ([]byte, []int) { return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{16} } -func (x *RequestScopedConfiguration) GetFieldName() string { +func (x *QueryCacheConfiguration) GetFieldName() string { if x != nil { return x.FieldName } return "" } -func (x *RequestScopedConfiguration) GetTypeName() string { +func (x *QueryCacheConfiguration) GetMaxAgeSeconds() int64 { if x != nil { - return x.TypeName + return x.MaxAgeSeconds + } + return 0 +} + +func (x *QueryCacheConfiguration) GetIncludeHeaders() bool { + if x != nil { + return x.IncludeHeaders + } + return false +} + +func (x *QueryCacheConfiguration) GetShadowMode() bool { + if x != nil { + return x.ShadowMode + } + return false +} + +func (x *QueryCacheConfiguration) GetEntityTypeName() string { + if x != nil { + return x.EntityTypeName + } + return "" +} + +func (x *QueryCacheConfiguration) GetEntityKeyMappings() []*EntityKeyMapping { + if x != nil { + return x.EntityKeyMappings + } + return nil +} + +type EntityKeyMapping struct { + state protoimpl.MessageState `protogen:"open.v1"` + EntityTypeName string `protobuf:"bytes,1,opt,name=entity_type_name,json=entityTypeName,proto3" json:"entity_type_name,omitempty"` + FieldMappings []*EntityCacheFieldMapping `protobuf:"bytes,2,rep,name=field_mappings,json=fieldMappings,proto3" json:"field_mappings,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *EntityKeyMapping) Reset() { + *x = EntityKeyMapping{} + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *EntityKeyMapping) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*EntityKeyMapping) ProtoMessage() {} + +func (x *EntityKeyMapping) ProtoReflect() protoreflect.Message { + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use EntityKeyMapping.ProtoReflect.Descriptor instead. +func (*EntityKeyMapping) Descriptor() ([]byte, []int) { + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{17} +} + +func (x *EntityKeyMapping) GetEntityTypeName() string { + if x != nil { + return x.EntityTypeName } return "" } -func (x *RequestScopedConfiguration) GetL1Key() string { +func (x *EntityKeyMapping) GetFieldMappings() []*EntityCacheFieldMapping { if x != nil { - return x.L1Key + return x.FieldMappings + } + return nil +} + +type EntityCacheFieldMapping struct { + state protoimpl.MessageState `protogen:"open.v1"` + EntityKeyField string `protobuf:"bytes,1,opt,name=entity_key_field,json=entityKeyField,proto3" json:"entity_key_field,omitempty"` + ArgumentPath []string `protobuf:"bytes,2,rep,name=argument_path,json=argumentPath,proto3" json:"argument_path,omitempty"` + IsBatch bool `protobuf:"varint,3,opt,name=is_batch,json=isBatch,proto3" json:"is_batch,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *EntityCacheFieldMapping) Reset() { + *x = EntityCacheFieldMapping{} + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *EntityCacheFieldMapping) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*EntityCacheFieldMapping) ProtoMessage() {} + +func (x *EntityCacheFieldMapping) ProtoReflect() protoreflect.Message { + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use EntityCacheFieldMapping.ProtoReflect.Descriptor instead. +func (*EntityCacheFieldMapping) Descriptor() ([]byte, []int) { + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{18} +} + +func (x *EntityCacheFieldMapping) GetEntityKeyField() string { + if x != nil { + return x.EntityKeyField } return "" } +func (x *EntityCacheFieldMapping) GetArgumentPath() []string { + if x != nil { + return x.ArgumentPath + } + return nil +} + +func (x *EntityCacheFieldMapping) GetIsBatch() bool { + if x != nil { + return x.IsBatch + } + return false +} + type CostConfiguration struct { state protoimpl.MessageState `protogen:"open.v1"` FieldWeights []*FieldWeightConfiguration `protobuf:"bytes,1,rep,name=field_weights,json=fieldWeights,proto3" json:"field_weights,omitempty"` @@ -1598,7 +1734,7 @@ type CostConfiguration struct { func (x *CostConfiguration) Reset() { *x = CostConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1610,7 +1746,7 @@ func (x *CostConfiguration) String() string { func (*CostConfiguration) ProtoMessage() {} func (x *CostConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1623,7 +1759,7 @@ func (x *CostConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use CostConfiguration.ProtoReflect.Descriptor instead. func (*CostConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{17} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{19} } func (x *CostConfiguration) GetFieldWeights() []*FieldWeightConfiguration { @@ -1667,7 +1803,7 @@ type FieldWeightConfiguration struct { func (x *FieldWeightConfiguration) Reset() { *x = FieldWeightConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1679,7 +1815,7 @@ func (x *FieldWeightConfiguration) String() string { func (*FieldWeightConfiguration) ProtoMessage() {} func (x *FieldWeightConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1692,7 +1828,7 @@ func (x *FieldWeightConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldWeightConfiguration.ProtoReflect.Descriptor instead. func (*FieldWeightConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{18} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{20} } func (x *FieldWeightConfiguration) GetTypeName() string { @@ -1744,7 +1880,7 @@ type FieldListSizeConfiguration struct { func (x *FieldListSizeConfiguration) Reset() { *x = FieldListSizeConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1756,7 +1892,7 @@ func (x *FieldListSizeConfiguration) String() string { func (*FieldListSizeConfiguration) ProtoMessage() {} func (x *FieldListSizeConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1769,7 +1905,7 @@ func (x *FieldListSizeConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldListSizeConfiguration.ProtoReflect.Descriptor instead. func (*FieldListSizeConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{19} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{21} } func (x *FieldListSizeConfiguration) GetTypeName() string { @@ -1824,7 +1960,7 @@ type ArgumentConfiguration struct { func (x *ArgumentConfiguration) Reset() { *x = ArgumentConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1836,7 +1972,7 @@ func (x *ArgumentConfiguration) String() string { func (*ArgumentConfiguration) ProtoMessage() {} func (x *ArgumentConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1849,7 +1985,7 @@ func (x *ArgumentConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use ArgumentConfiguration.ProtoReflect.Descriptor instead. func (*ArgumentConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{20} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{22} } func (x *ArgumentConfiguration) GetName() string { @@ -1875,7 +2011,7 @@ type Scopes struct { func (x *Scopes) Reset() { *x = Scopes{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1887,7 +2023,7 @@ func (x *Scopes) String() string { func (*Scopes) ProtoMessage() {} func (x *Scopes) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1900,7 +2036,7 @@ func (x *Scopes) ProtoReflect() protoreflect.Message { // Deprecated: Use Scopes.ProtoReflect.Descriptor instead. func (*Scopes) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{21} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{23} } func (x *Scopes) GetRequiredAndScopes() []string { @@ -1921,7 +2057,7 @@ type AuthorizationConfiguration struct { func (x *AuthorizationConfiguration) Reset() { *x = AuthorizationConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1933,7 +2069,7 @@ func (x *AuthorizationConfiguration) String() string { func (*AuthorizationConfiguration) ProtoMessage() {} func (x *AuthorizationConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1946,7 +2082,7 @@ func (x *AuthorizationConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use AuthorizationConfiguration.ProtoReflect.Descriptor instead. func (*AuthorizationConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{22} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{24} } func (x *AuthorizationConfiguration) GetRequiresAuthentication() bool { @@ -1983,7 +2119,7 @@ type FieldConfiguration struct { func (x *FieldConfiguration) Reset() { *x = FieldConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1995,7 +2131,7 @@ func (x *FieldConfiguration) String() string { func (*FieldConfiguration) ProtoMessage() {} func (x *FieldConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2008,7 +2144,7 @@ func (x *FieldConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldConfiguration.ProtoReflect.Descriptor instead. func (*FieldConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{23} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{25} } func (x *FieldConfiguration) GetTypeName() string { @@ -2056,7 +2192,7 @@ type TypeConfiguration struct { func (x *TypeConfiguration) Reset() { *x = TypeConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2068,7 +2204,7 @@ func (x *TypeConfiguration) String() string { func (*TypeConfiguration) ProtoMessage() {} func (x *TypeConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2081,7 +2217,7 @@ func (x *TypeConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use TypeConfiguration.ProtoReflect.Descriptor instead. func (*TypeConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{24} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{26} } func (x *TypeConfiguration) GetTypeName() string { @@ -2110,7 +2246,7 @@ type TypeField struct { func (x *TypeField) Reset() { *x = TypeField{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2122,7 +2258,7 @@ func (x *TypeField) String() string { func (*TypeField) ProtoMessage() {} func (x *TypeField) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2135,7 +2271,7 @@ func (x *TypeField) ProtoReflect() protoreflect.Message { // Deprecated: Use TypeField.ProtoReflect.Descriptor instead. func (*TypeField) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{25} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{27} } func (x *TypeField) GetTypeName() string { @@ -2176,7 +2312,7 @@ type FieldCoordinates struct { func (x *FieldCoordinates) Reset() { *x = FieldCoordinates{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2188,7 +2324,7 @@ func (x *FieldCoordinates) String() string { func (*FieldCoordinates) ProtoMessage() {} func (x *FieldCoordinates) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2201,7 +2337,7 @@ func (x *FieldCoordinates) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldCoordinates.ProtoReflect.Descriptor instead. func (*FieldCoordinates) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{26} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{28} } func (x *FieldCoordinates) GetFieldName() string { @@ -2228,7 +2364,7 @@ type FieldSetCondition struct { func (x *FieldSetCondition) Reset() { *x = FieldSetCondition{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2240,7 +2376,7 @@ func (x *FieldSetCondition) String() string { func (*FieldSetCondition) ProtoMessage() {} func (x *FieldSetCondition) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2253,7 +2389,7 @@ func (x *FieldSetCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldSetCondition.ProtoReflect.Descriptor instead. func (*FieldSetCondition) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{27} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{29} } func (x *FieldSetCondition) GetFieldCoordinatesPath() []*FieldCoordinates { @@ -2283,7 +2419,7 @@ type RequiredField struct { func (x *RequiredField) Reset() { *x = RequiredField{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2295,7 +2431,7 @@ func (x *RequiredField) String() string { func (*RequiredField) ProtoMessage() {} func (x *RequiredField) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2308,7 +2444,7 @@ func (x *RequiredField) ProtoReflect() protoreflect.Message { // Deprecated: Use RequiredField.ProtoReflect.Descriptor instead. func (*RequiredField) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{28} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{30} } func (x *RequiredField) GetTypeName() string { @@ -2356,7 +2492,7 @@ type EntityInterfaceConfiguration struct { func (x *EntityInterfaceConfiguration) Reset() { *x = EntityInterfaceConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2368,7 +2504,7 @@ func (x *EntityInterfaceConfiguration) String() string { func (*EntityInterfaceConfiguration) ProtoMessage() {} func (x *EntityInterfaceConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2381,7 +2517,7 @@ func (x *EntityInterfaceConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use EntityInterfaceConfiguration.ProtoReflect.Descriptor instead. func (*EntityInterfaceConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{29} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{31} } func (x *EntityInterfaceConfiguration) GetInterfaceTypeName() string { @@ -2424,7 +2560,7 @@ type FetchConfiguration struct { func (x *FetchConfiguration) Reset() { *x = FetchConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2436,7 +2572,7 @@ func (x *FetchConfiguration) String() string { func (*FetchConfiguration) ProtoMessage() {} func (x *FetchConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2449,7 +2585,7 @@ func (x *FetchConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FetchConfiguration.ProtoReflect.Descriptor instead. func (*FetchConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{30} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{32} } func (x *FetchConfiguration) GetUrl() *ConfigurationVariable { @@ -2533,7 +2669,7 @@ type StatusCodeTypeMapping struct { func (x *StatusCodeTypeMapping) Reset() { *x = StatusCodeTypeMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2545,7 +2681,7 @@ func (x *StatusCodeTypeMapping) String() string { func (*StatusCodeTypeMapping) ProtoMessage() {} func (x *StatusCodeTypeMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2558,7 +2694,7 @@ func (x *StatusCodeTypeMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use StatusCodeTypeMapping.ProtoReflect.Descriptor instead. func (*StatusCodeTypeMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{31} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{33} } func (x *StatusCodeTypeMapping) GetStatusCode() int64 { @@ -2596,7 +2732,7 @@ type DataSourceCustom_GraphQL struct { func (x *DataSourceCustom_GraphQL) Reset() { *x = DataSourceCustom_GraphQL{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2608,7 +2744,7 @@ func (x *DataSourceCustom_GraphQL) String() string { func (*DataSourceCustom_GraphQL) ProtoMessage() {} func (x *DataSourceCustom_GraphQL) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2621,7 +2757,7 @@ func (x *DataSourceCustom_GraphQL) ProtoReflect() protoreflect.Message { // Deprecated: Use DataSourceCustom_GraphQL.ProtoReflect.Descriptor instead. func (*DataSourceCustom_GraphQL) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{32} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{34} } func (x *DataSourceCustom_GraphQL) GetFetch() *FetchConfiguration { @@ -2677,7 +2813,7 @@ type GRPCConfiguration struct { func (x *GRPCConfiguration) Reset() { *x = GRPCConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2689,7 +2825,7 @@ func (x *GRPCConfiguration) String() string { func (*GRPCConfiguration) ProtoMessage() {} func (x *GRPCConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2702,7 +2838,7 @@ func (x *GRPCConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use GRPCConfiguration.ProtoReflect.Descriptor instead. func (*GRPCConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{33} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{35} } func (x *GRPCConfiguration) GetMapping() *GRPCMapping { @@ -2736,7 +2872,7 @@ type ImageReference struct { func (x *ImageReference) Reset() { *x = ImageReference{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2748,7 +2884,7 @@ func (x *ImageReference) String() string { func (*ImageReference) ProtoMessage() {} func (x *ImageReference) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2761,7 +2897,7 @@ func (x *ImageReference) ProtoReflect() protoreflect.Message { // Deprecated: Use ImageReference.ProtoReflect.Descriptor instead. func (*ImageReference) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{34} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{36} } func (x *ImageReference) GetRepository() string { @@ -2791,7 +2927,7 @@ type PluginConfiguration struct { func (x *PluginConfiguration) Reset() { *x = PluginConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2803,7 +2939,7 @@ func (x *PluginConfiguration) String() string { func (*PluginConfiguration) ProtoMessage() {} func (x *PluginConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2816,7 +2952,7 @@ func (x *PluginConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use PluginConfiguration.ProtoReflect.Descriptor instead. func (*PluginConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{35} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{37} } func (x *PluginConfiguration) GetName() string { @@ -2850,7 +2986,7 @@ type SSLConfiguration struct { func (x *SSLConfiguration) Reset() { *x = SSLConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2862,7 +2998,7 @@ func (x *SSLConfiguration) String() string { func (*SSLConfiguration) ProtoMessage() {} func (x *SSLConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2875,7 +3011,7 @@ func (x *SSLConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use SSLConfiguration.ProtoReflect.Descriptor instead. func (*SSLConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{36} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{38} } func (x *SSLConfiguration) GetEnabled() bool { @@ -2908,7 +3044,7 @@ type GRPCMapping struct { func (x *GRPCMapping) Reset() { *x = GRPCMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2920,7 +3056,7 @@ func (x *GRPCMapping) String() string { func (*GRPCMapping) ProtoMessage() {} func (x *GRPCMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2933,7 +3069,7 @@ func (x *GRPCMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use GRPCMapping.ProtoReflect.Descriptor instead. func (*GRPCMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{37} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{39} } func (x *GRPCMapping) GetVersion() int32 { @@ -3004,7 +3140,7 @@ type LookupMapping struct { func (x *LookupMapping) Reset() { *x = LookupMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3016,7 +3152,7 @@ func (x *LookupMapping) String() string { func (*LookupMapping) ProtoMessage() {} func (x *LookupMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3029,7 +3165,7 @@ func (x *LookupMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use LookupMapping.ProtoReflect.Descriptor instead. func (*LookupMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{38} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{40} } func (x *LookupMapping) GetType() LookupType { @@ -3080,7 +3216,7 @@ type LookupFieldMapping struct { func (x *LookupFieldMapping) Reset() { *x = LookupFieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3092,7 +3228,7 @@ func (x *LookupFieldMapping) String() string { func (*LookupFieldMapping) ProtoMessage() {} func (x *LookupFieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3105,7 +3241,7 @@ func (x *LookupFieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use LookupFieldMapping.ProtoReflect.Descriptor instead. func (*LookupFieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{39} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{41} } func (x *LookupFieldMapping) GetType() string { @@ -3141,7 +3277,7 @@ type OperationMapping struct { func (x *OperationMapping) Reset() { *x = OperationMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3153,7 +3289,7 @@ func (x *OperationMapping) String() string { func (*OperationMapping) ProtoMessage() {} func (x *OperationMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3166,7 +3302,7 @@ func (x *OperationMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use OperationMapping.ProtoReflect.Descriptor instead. func (*OperationMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{40} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{42} } func (x *OperationMapping) GetType() OperationType { @@ -3227,7 +3363,7 @@ type EntityMapping struct { func (x *EntityMapping) Reset() { *x = EntityMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3239,7 +3375,7 @@ func (x *EntityMapping) String() string { func (*EntityMapping) ProtoMessage() {} func (x *EntityMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3252,7 +3388,7 @@ func (x *EntityMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use EntityMapping.ProtoReflect.Descriptor instead. func (*EntityMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{41} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{43} } func (x *EntityMapping) GetTypeName() string { @@ -3320,7 +3456,7 @@ type RequiredFieldMapping struct { func (x *RequiredFieldMapping) Reset() { *x = RequiredFieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3332,7 +3468,7 @@ func (x *RequiredFieldMapping) String() string { func (*RequiredFieldMapping) ProtoMessage() {} func (x *RequiredFieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3345,7 +3481,7 @@ func (x *RequiredFieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use RequiredFieldMapping.ProtoReflect.Descriptor instead. func (*RequiredFieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{42} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{44} } func (x *RequiredFieldMapping) GetFieldMapping() *FieldMapping { @@ -3389,7 +3525,7 @@ type TypeFieldMapping struct { func (x *TypeFieldMapping) Reset() { *x = TypeFieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3401,7 +3537,7 @@ func (x *TypeFieldMapping) String() string { func (*TypeFieldMapping) ProtoMessage() {} func (x *TypeFieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3414,7 +3550,7 @@ func (x *TypeFieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use TypeFieldMapping.ProtoReflect.Descriptor instead. func (*TypeFieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{43} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{45} } func (x *TypeFieldMapping) GetType() string { @@ -3446,7 +3582,7 @@ type FieldMapping struct { func (x *FieldMapping) Reset() { *x = FieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3458,7 +3594,7 @@ func (x *FieldMapping) String() string { func (*FieldMapping) ProtoMessage() {} func (x *FieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3471,7 +3607,7 @@ func (x *FieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldMapping.ProtoReflect.Descriptor instead. func (*FieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{44} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{46} } func (x *FieldMapping) GetOriginal() string { @@ -3508,7 +3644,7 @@ type ArgumentMapping struct { func (x *ArgumentMapping) Reset() { *x = ArgumentMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3520,7 +3656,7 @@ func (x *ArgumentMapping) String() string { func (*ArgumentMapping) ProtoMessage() {} func (x *ArgumentMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3533,7 +3669,7 @@ func (x *ArgumentMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use ArgumentMapping.ProtoReflect.Descriptor instead. func (*ArgumentMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{45} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{47} } func (x *ArgumentMapping) GetOriginal() string { @@ -3560,7 +3696,7 @@ type EnumMapping struct { func (x *EnumMapping) Reset() { *x = EnumMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3572,7 +3708,7 @@ func (x *EnumMapping) String() string { func (*EnumMapping) ProtoMessage() {} func (x *EnumMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3585,7 +3721,7 @@ func (x *EnumMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use EnumMapping.ProtoReflect.Descriptor instead. func (*EnumMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{46} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{48} } func (x *EnumMapping) GetType() string { @@ -3612,7 +3748,7 @@ type EnumValueMapping struct { func (x *EnumValueMapping) Reset() { *x = EnumValueMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3624,7 +3760,7 @@ func (x *EnumValueMapping) String() string { func (*EnumValueMapping) ProtoMessage() {} func (x *EnumValueMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3637,7 +3773,7 @@ func (x *EnumValueMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use EnumValueMapping.ProtoReflect.Descriptor instead. func (*EnumValueMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{47} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{49} } func (x *EnumValueMapping) GetOriginal() string { @@ -3665,7 +3801,7 @@ type NatsStreamConfiguration struct { func (x *NatsStreamConfiguration) Reset() { *x = NatsStreamConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3677,7 +3813,7 @@ func (x *NatsStreamConfiguration) String() string { func (*NatsStreamConfiguration) ProtoMessage() {} func (x *NatsStreamConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3690,7 +3826,7 @@ func (x *NatsStreamConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use NatsStreamConfiguration.ProtoReflect.Descriptor instead. func (*NatsStreamConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{48} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{50} } func (x *NatsStreamConfiguration) GetConsumerName() string { @@ -3725,7 +3861,7 @@ type NatsEventConfiguration struct { func (x *NatsEventConfiguration) Reset() { *x = NatsEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3737,7 +3873,7 @@ func (x *NatsEventConfiguration) String() string { func (*NatsEventConfiguration) ProtoMessage() {} func (x *NatsEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3750,7 +3886,7 @@ func (x *NatsEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use NatsEventConfiguration.ProtoReflect.Descriptor instead. func (*NatsEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{49} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{51} } func (x *NatsEventConfiguration) GetEngineEventConfiguration() *EngineEventConfiguration { @@ -3784,7 +3920,7 @@ type KafkaEventConfiguration struct { func (x *KafkaEventConfiguration) Reset() { *x = KafkaEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3796,7 +3932,7 @@ func (x *KafkaEventConfiguration) String() string { func (*KafkaEventConfiguration) ProtoMessage() {} func (x *KafkaEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3809,7 +3945,7 @@ func (x *KafkaEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use KafkaEventConfiguration.ProtoReflect.Descriptor instead. func (*KafkaEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{50} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{52} } func (x *KafkaEventConfiguration) GetEngineEventConfiguration() *EngineEventConfiguration { @@ -3836,7 +3972,7 @@ type RedisEventConfiguration struct { func (x *RedisEventConfiguration) Reset() { *x = RedisEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3848,7 +3984,7 @@ func (x *RedisEventConfiguration) String() string { func (*RedisEventConfiguration) ProtoMessage() {} func (x *RedisEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3861,7 +3997,7 @@ func (x *RedisEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use RedisEventConfiguration.ProtoReflect.Descriptor instead. func (*RedisEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{51} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{53} } func (x *RedisEventConfiguration) GetEngineEventConfiguration() *EngineEventConfiguration { @@ -3890,7 +4026,7 @@ type EngineEventConfiguration struct { func (x *EngineEventConfiguration) Reset() { *x = EngineEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3902,7 +4038,7 @@ func (x *EngineEventConfiguration) String() string { func (*EngineEventConfiguration) ProtoMessage() {} func (x *EngineEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3915,7 +4051,7 @@ func (x *EngineEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use EngineEventConfiguration.ProtoReflect.Descriptor instead. func (*EngineEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{52} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{54} } func (x *EngineEventConfiguration) GetProviderId() string { @@ -3957,7 +4093,7 @@ type DataSourceCustomEvents struct { func (x *DataSourceCustomEvents) Reset() { *x = DataSourceCustomEvents{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3969,7 +4105,7 @@ func (x *DataSourceCustomEvents) String() string { func (*DataSourceCustomEvents) ProtoMessage() {} func (x *DataSourceCustomEvents) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3982,7 +4118,7 @@ func (x *DataSourceCustomEvents) ProtoReflect() protoreflect.Message { // Deprecated: Use DataSourceCustomEvents.ProtoReflect.Descriptor instead. func (*DataSourceCustomEvents) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{53} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{55} } func (x *DataSourceCustomEvents) GetNats() []*NatsEventConfiguration { @@ -4015,7 +4151,7 @@ type DataSourceCustom_Static struct { func (x *DataSourceCustom_Static) Reset() { *x = DataSourceCustom_Static{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4027,7 +4163,7 @@ func (x *DataSourceCustom_Static) String() string { func (*DataSourceCustom_Static) ProtoMessage() {} func (x *DataSourceCustom_Static) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4040,7 +4176,7 @@ func (x *DataSourceCustom_Static) ProtoReflect() protoreflect.Message { // Deprecated: Use DataSourceCustom_Static.ProtoReflect.Descriptor instead. func (*DataSourceCustom_Static) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{54} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{56} } func (x *DataSourceCustom_Static) GetData() *ConfigurationVariable { @@ -4063,7 +4199,7 @@ type ConfigurationVariable struct { func (x *ConfigurationVariable) Reset() { *x = ConfigurationVariable{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4075,7 +4211,7 @@ func (x *ConfigurationVariable) String() string { func (*ConfigurationVariable) ProtoMessage() {} func (x *ConfigurationVariable) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4088,7 +4224,7 @@ func (x *ConfigurationVariable) ProtoReflect() protoreflect.Message { // Deprecated: Use ConfigurationVariable.ProtoReflect.Descriptor instead. func (*ConfigurationVariable) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{55} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{57} } func (x *ConfigurationVariable) GetKind() ConfigurationVariableKind { @@ -4136,7 +4272,7 @@ type DirectiveConfiguration struct { func (x *DirectiveConfiguration) Reset() { *x = DirectiveConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4148,7 +4284,7 @@ func (x *DirectiveConfiguration) String() string { func (*DirectiveConfiguration) ProtoMessage() {} func (x *DirectiveConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4161,7 +4297,7 @@ func (x *DirectiveConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use DirectiveConfiguration.ProtoReflect.Descriptor instead. func (*DirectiveConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{56} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{58} } func (x *DirectiveConfiguration) GetDirectiveName() string { @@ -4188,7 +4324,7 @@ type URLQueryConfiguration struct { func (x *URLQueryConfiguration) Reset() { *x = URLQueryConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4200,7 +4336,7 @@ func (x *URLQueryConfiguration) String() string { func (*URLQueryConfiguration) ProtoMessage() {} func (x *URLQueryConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4213,7 +4349,7 @@ func (x *URLQueryConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use URLQueryConfiguration.ProtoReflect.Descriptor instead. func (*URLQueryConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{57} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{59} } func (x *URLQueryConfiguration) GetName() string { @@ -4239,7 +4375,7 @@ type HTTPHeader struct { func (x *HTTPHeader) Reset() { *x = HTTPHeader{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4251,7 +4387,7 @@ func (x *HTTPHeader) String() string { func (*HTTPHeader) ProtoMessage() {} func (x *HTTPHeader) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4264,7 +4400,7 @@ func (x *HTTPHeader) ProtoReflect() protoreflect.Message { // Deprecated: Use HTTPHeader.ProtoReflect.Descriptor instead. func (*HTTPHeader) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{58} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{60} } func (x *HTTPHeader) GetValues() []*ConfigurationVariable { @@ -4285,7 +4421,7 @@ type MTLSConfiguration struct { func (x *MTLSConfiguration) Reset() { *x = MTLSConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4297,7 +4433,7 @@ func (x *MTLSConfiguration) String() string { func (*MTLSConfiguration) ProtoMessage() {} func (x *MTLSConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4310,7 +4446,7 @@ func (x *MTLSConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use MTLSConfiguration.ProtoReflect.Descriptor instead. func (*MTLSConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{59} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{61} } func (x *MTLSConfiguration) GetKey() *ConfigurationVariable { @@ -4348,7 +4484,7 @@ type GraphQLSubscriptionConfiguration struct { func (x *GraphQLSubscriptionConfiguration) Reset() { *x = GraphQLSubscriptionConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4360,7 +4496,7 @@ func (x *GraphQLSubscriptionConfiguration) String() string { func (*GraphQLSubscriptionConfiguration) ProtoMessage() {} func (x *GraphQLSubscriptionConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4373,7 +4509,7 @@ func (x *GraphQLSubscriptionConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use GraphQLSubscriptionConfiguration.ProtoReflect.Descriptor instead. func (*GraphQLSubscriptionConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{60} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{62} } func (x *GraphQLSubscriptionConfiguration) GetEnabled() bool { @@ -4421,7 +4557,7 @@ type GraphQLFederationConfiguration struct { func (x *GraphQLFederationConfiguration) Reset() { *x = GraphQLFederationConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4433,7 +4569,7 @@ func (x *GraphQLFederationConfiguration) String() string { func (*GraphQLFederationConfiguration) ProtoMessage() {} func (x *GraphQLFederationConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4446,7 +4582,7 @@ func (x *GraphQLFederationConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use GraphQLFederationConfiguration.ProtoReflect.Descriptor instead. func (*GraphQLFederationConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{61} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{63} } func (x *GraphQLFederationConfiguration) GetEnabled() bool { @@ -4473,7 +4609,7 @@ type InternedString struct { func (x *InternedString) Reset() { *x = InternedString{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4485,7 +4621,7 @@ func (x *InternedString) String() string { func (*InternedString) ProtoMessage() {} func (x *InternedString) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4498,7 +4634,7 @@ func (x *InternedString) ProtoReflect() protoreflect.Message { // Deprecated: Use InternedString.ProtoReflect.Descriptor instead. func (*InternedString) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{62} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{64} } func (x *InternedString) GetKey() string { @@ -4518,7 +4654,7 @@ type SingleTypeField struct { func (x *SingleTypeField) Reset() { *x = SingleTypeField{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4530,7 +4666,7 @@ func (x *SingleTypeField) String() string { func (*SingleTypeField) ProtoMessage() {} func (x *SingleTypeField) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4543,7 +4679,7 @@ func (x *SingleTypeField) ProtoReflect() protoreflect.Message { // Deprecated: Use SingleTypeField.ProtoReflect.Descriptor instead. func (*SingleTypeField) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{63} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{65} } func (x *SingleTypeField) GetTypeName() string { @@ -4570,7 +4706,7 @@ type SubscriptionFieldCondition struct { func (x *SubscriptionFieldCondition) Reset() { *x = SubscriptionFieldCondition{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4582,7 +4718,7 @@ func (x *SubscriptionFieldCondition) String() string { func (*SubscriptionFieldCondition) ProtoMessage() {} func (x *SubscriptionFieldCondition) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4595,7 +4731,7 @@ func (x *SubscriptionFieldCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use SubscriptionFieldCondition.ProtoReflect.Descriptor instead. func (*SubscriptionFieldCondition) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{64} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{66} } func (x *SubscriptionFieldCondition) GetFieldPath() []string { @@ -4624,7 +4760,7 @@ type SubscriptionFilterCondition struct { func (x *SubscriptionFilterCondition) Reset() { *x = SubscriptionFilterCondition{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4636,7 +4772,7 @@ func (x *SubscriptionFilterCondition) String() string { func (*SubscriptionFilterCondition) ProtoMessage() {} func (x *SubscriptionFilterCondition) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4649,7 +4785,7 @@ func (x *SubscriptionFilterCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use SubscriptionFilterCondition.ProtoReflect.Descriptor instead. func (*SubscriptionFilterCondition) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{65} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{67} } func (x *SubscriptionFilterCondition) GetAnd() []*SubscriptionFilterCondition { @@ -4689,7 +4825,7 @@ type CacheWarmerOperations struct { func (x *CacheWarmerOperations) Reset() { *x = CacheWarmerOperations{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4701,7 +4837,7 @@ func (x *CacheWarmerOperations) String() string { func (*CacheWarmerOperations) ProtoMessage() {} func (x *CacheWarmerOperations) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4714,7 +4850,7 @@ func (x *CacheWarmerOperations) ProtoReflect() protoreflect.Message { // Deprecated: Use CacheWarmerOperations.ProtoReflect.Descriptor instead. func (*CacheWarmerOperations) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{66} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{68} } func (x *CacheWarmerOperations) GetOperations() []*Operation { @@ -4734,7 +4870,7 @@ type Operation struct { func (x *Operation) Reset() { *x = Operation{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4746,7 +4882,7 @@ func (x *Operation) String() string { func (*Operation) ProtoMessage() {} func (x *Operation) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4759,7 +4895,7 @@ func (x *Operation) ProtoReflect() protoreflect.Message { // Deprecated: Use Operation.ProtoReflect.Descriptor instead. func (*Operation) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{67} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{69} } func (x *Operation) GetRequest() *OperationRequest { @@ -4787,7 +4923,7 @@ type OperationRequest struct { func (x *OperationRequest) Reset() { *x = OperationRequest{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4799,7 +4935,7 @@ func (x *OperationRequest) String() string { func (*OperationRequest) ProtoMessage() {} func (x *OperationRequest) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4812,7 +4948,7 @@ func (x *OperationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use OperationRequest.ProtoReflect.Descriptor instead. func (*OperationRequest) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{68} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{70} } func (x *OperationRequest) GetOperationName() string { @@ -4845,7 +4981,7 @@ type Extension struct { func (x *Extension) Reset() { *x = Extension{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4857,7 +4993,7 @@ func (x *Extension) String() string { func (*Extension) ProtoMessage() {} func (x *Extension) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4870,7 +5006,7 @@ func (x *Extension) ProtoReflect() protoreflect.Message { // Deprecated: Use Extension.ProtoReflect.Descriptor instead. func (*Extension) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{69} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{71} } func (x *Extension) GetPersistedQuery() *PersistedQuery { @@ -4890,7 +5026,7 @@ type PersistedQuery struct { func (x *PersistedQuery) Reset() { *x = PersistedQuery{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[72] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4902,7 +5038,7 @@ func (x *PersistedQuery) String() string { func (*PersistedQuery) ProtoMessage() {} func (x *PersistedQuery) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[72] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4915,7 +5051,7 @@ func (x *PersistedQuery) ProtoReflect() protoreflect.Message { // Deprecated: Use PersistedQuery.ProtoReflect.Descriptor instead. func (*PersistedQuery) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{70} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{72} } func (x *PersistedQuery) GetSha256Hash() string { @@ -4942,7 +5078,7 @@ type ClientInfo struct { func (x *ClientInfo) Reset() { *x = ClientInfo{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[73] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4954,7 +5090,7 @@ func (x *ClientInfo) String() string { func (*ClientInfo) ProtoMessage() {} func (x *ClientInfo) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[73] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4967,7 +5103,7 @@ func (x *ClientInfo) ProtoReflect() protoreflect.Message { // Deprecated: Use ClientInfo.ProtoReflect.Descriptor instead. func (*ClientInfo) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{71} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{73} } func (x *ClientInfo) GetName() string { @@ -5062,12 +5198,12 @@ const file_wg_cosmo_node_v1_node_proto_rawDesc = "" + "\x11entity_interfaces\x18\x0e \x03(\v2..wg.cosmo.node.v1.EntityInterfaceConfigurationR\x10entityInterfaces\x12[\n" + "\x11interface_objects\x18\x0f \x03(\v2..wg.cosmo.node.v1.EntityInterfaceConfigurationR\x10interfaceObjects\x12R\n" + "\x12cost_configuration\x18\x10 \x01(\v2#.wg.cosmo.node.v1.CostConfigurationR\x11costConfiguration\x12n\n" + - "\x1centity_caching_configuration\x18\x11 \x01(\v2,.wg.cosmo.node.v1.EntityCachingConfigurationR\x1aentityCachingConfiguration\"\xc7\x03\n" + + "\x1centity_caching_configuration\x18\x11 \x01(\v2,.wg.cosmo.node.v1.EntityCachingConfigurationR\x1aentityCachingConfiguration\"\xbe\x03\n" + "\x1aEntityCachingConfiguration\x12M\n" + "\fentity_cache\x18\x01 \x03(\v2*.wg.cosmo.node.v1.EntityCacheConfigurationR\ventityCache\x12v\n" + "\x1fcache_invalidate_configurations\x18\x02 \x03(\v2..wg.cosmo.node.v1.CacheInvalidateConfigurationR\x1dcacheInvalidateConfigurations\x12p\n" + - "\x1dcache_populate_configurations\x18\x03 \x03(\v2,.wg.cosmo.node.v1.CachePopulateConfigurationR\x1bcachePopulateConfigurations\x12p\n" + - "\x1drequest_scoped_configurations\x18\x04 \x03(\v2,.wg.cosmo.node.v1.RequestScopedConfigurationR\x1brequestScopedConfigurations\"\x95\x02\n" + + "\x1dcache_populate_configurations\x18\x03 \x03(\v2,.wg.cosmo.node.v1.CachePopulateConfigurationR\x1bcachePopulateConfigurations\x12g\n" + + "\x1aquery_cache_configurations\x18\x05 \x03(\v2).wg.cosmo.node.v1.QueryCacheConfigurationR\x18queryCacheConfigurations\"\x95\x02\n" + "\x18EntityCacheConfiguration\x12\x1b\n" + "\ttype_name\x18\x01 \x01(\tR\btypeName\x12&\n" + "\x0fmax_age_seconds\x18\x02 \x01(\x03R\rmaxAgeSeconds\x12'\n" + @@ -5086,12 +5222,23 @@ const file_wg_cosmo_node_v1_node_proto_rawDesc = "" + "field_name\x18\x01 \x01(\tR\tfieldName\x12%\n" + "\x0eoperation_type\x18\x02 \x01(\tR\roperationType\x12&\n" + "\x0fmax_age_seconds\x18\x03 \x01(\x03R\rmaxAgeSeconds\x12(\n" + - "\x10entity_type_name\x18\x04 \x01(\tR\x0eentityTypeName\"o\n" + - "\x1aRequestScopedConfiguration\x12\x1d\n" + + "\x10entity_type_name\x18\x04 \x01(\tR\x0eentityTypeName\"\xa8\x02\n" + + "\x17QueryCacheConfiguration\x12\x1d\n" + "\n" + - "field_name\x18\x01 \x01(\tR\tfieldName\x12\x1b\n" + - "\ttype_name\x18\x02 \x01(\tR\btypeName\x12\x15\n" + - "\x06l1_key\x18\x03 \x01(\tR\x05l1Key\"\x98\x04\n" + + "field_name\x18\x01 \x01(\tR\tfieldName\x12&\n" + + "\x0fmax_age_seconds\x18\x02 \x01(\x03R\rmaxAgeSeconds\x12'\n" + + "\x0finclude_headers\x18\x03 \x01(\bR\x0eincludeHeaders\x12\x1f\n" + + "\vshadow_mode\x18\x04 \x01(\bR\n" + + "shadowMode\x12(\n" + + "\x10entity_type_name\x18\x05 \x01(\tR\x0eentityTypeName\x12R\n" + + "\x13entity_key_mappings\x18\x06 \x03(\v2\".wg.cosmo.node.v1.EntityKeyMappingR\x11entityKeyMappings\"\x8e\x01\n" + + "\x10EntityKeyMapping\x12(\n" + + "\x10entity_type_name\x18\x01 \x01(\tR\x0eentityTypeName\x12P\n" + + "\x0efield_mappings\x18\x02 \x03(\v2).wg.cosmo.node.v1.EntityCacheFieldMappingR\rfieldMappings\"\x83\x01\n" + + "\x17EntityCacheFieldMapping\x12(\n" + + "\x10entity_key_field\x18\x01 \x01(\tR\x0eentityKeyField\x12#\n" + + "\rargument_path\x18\x02 \x03(\tR\fargumentPath\x12\x19\n" + + "\bis_batch\x18\x03 \x01(\bR\aisBatch\"\x98\x04\n" + "\x11CostConfiguration\x12O\n" + "\rfield_weights\x18\x01 \x03(\v2*.wg.cosmo.node.v1.FieldWeightConfigurationR\ffieldWeights\x12K\n" + "\n" + @@ -5430,7 +5577,7 @@ func file_wg_cosmo_node_v1_node_proto_rawDescGZIP() []byte { } var file_wg_cosmo_node_v1_node_proto_enumTypes = make([]protoimpl.EnumInfo, 8) -var file_wg_cosmo_node_v1_node_proto_msgTypes = make([]protoimpl.MessageInfo, 79) +var file_wg_cosmo_node_v1_node_proto_msgTypes = make([]protoimpl.MessageInfo, 81) var file_wg_cosmo_node_v1_node_proto_goTypes = []any{ (ArgumentRenderConfiguration)(0), // 0: wg.cosmo.node.v1.ArgumentRenderConfiguration (ArgumentSource)(0), // 1: wg.cosmo.node.v1.ArgumentSource @@ -5456,186 +5603,190 @@ var file_wg_cosmo_node_v1_node_proto_goTypes = []any{ (*EntityCacheConfiguration)(nil), // 21: wg.cosmo.node.v1.EntityCacheConfiguration (*CacheInvalidateConfiguration)(nil), // 22: wg.cosmo.node.v1.CacheInvalidateConfiguration (*CachePopulateConfiguration)(nil), // 23: wg.cosmo.node.v1.CachePopulateConfiguration - (*RequestScopedConfiguration)(nil), // 24: wg.cosmo.node.v1.RequestScopedConfiguration - (*CostConfiguration)(nil), // 25: wg.cosmo.node.v1.CostConfiguration - (*FieldWeightConfiguration)(nil), // 26: wg.cosmo.node.v1.FieldWeightConfiguration - (*FieldListSizeConfiguration)(nil), // 27: wg.cosmo.node.v1.FieldListSizeConfiguration - (*ArgumentConfiguration)(nil), // 28: wg.cosmo.node.v1.ArgumentConfiguration - (*Scopes)(nil), // 29: wg.cosmo.node.v1.Scopes - (*AuthorizationConfiguration)(nil), // 30: wg.cosmo.node.v1.AuthorizationConfiguration - (*FieldConfiguration)(nil), // 31: wg.cosmo.node.v1.FieldConfiguration - (*TypeConfiguration)(nil), // 32: wg.cosmo.node.v1.TypeConfiguration - (*TypeField)(nil), // 33: wg.cosmo.node.v1.TypeField - (*FieldCoordinates)(nil), // 34: wg.cosmo.node.v1.FieldCoordinates - (*FieldSetCondition)(nil), // 35: wg.cosmo.node.v1.FieldSetCondition - (*RequiredField)(nil), // 36: wg.cosmo.node.v1.RequiredField - (*EntityInterfaceConfiguration)(nil), // 37: wg.cosmo.node.v1.EntityInterfaceConfiguration - (*FetchConfiguration)(nil), // 38: wg.cosmo.node.v1.FetchConfiguration - (*StatusCodeTypeMapping)(nil), // 39: wg.cosmo.node.v1.StatusCodeTypeMapping - (*DataSourceCustom_GraphQL)(nil), // 40: wg.cosmo.node.v1.DataSourceCustom_GraphQL - (*GRPCConfiguration)(nil), // 41: wg.cosmo.node.v1.GRPCConfiguration - (*ImageReference)(nil), // 42: wg.cosmo.node.v1.ImageReference - (*PluginConfiguration)(nil), // 43: wg.cosmo.node.v1.PluginConfiguration - (*SSLConfiguration)(nil), // 44: wg.cosmo.node.v1.SSLConfiguration - (*GRPCMapping)(nil), // 45: wg.cosmo.node.v1.GRPCMapping - (*LookupMapping)(nil), // 46: wg.cosmo.node.v1.LookupMapping - (*LookupFieldMapping)(nil), // 47: wg.cosmo.node.v1.LookupFieldMapping - (*OperationMapping)(nil), // 48: wg.cosmo.node.v1.OperationMapping - (*EntityMapping)(nil), // 49: wg.cosmo.node.v1.EntityMapping - (*RequiredFieldMapping)(nil), // 50: wg.cosmo.node.v1.RequiredFieldMapping - (*TypeFieldMapping)(nil), // 51: wg.cosmo.node.v1.TypeFieldMapping - (*FieldMapping)(nil), // 52: wg.cosmo.node.v1.FieldMapping - (*ArgumentMapping)(nil), // 53: wg.cosmo.node.v1.ArgumentMapping - (*EnumMapping)(nil), // 54: wg.cosmo.node.v1.EnumMapping - (*EnumValueMapping)(nil), // 55: wg.cosmo.node.v1.EnumValueMapping - (*NatsStreamConfiguration)(nil), // 56: wg.cosmo.node.v1.NatsStreamConfiguration - (*NatsEventConfiguration)(nil), // 57: wg.cosmo.node.v1.NatsEventConfiguration - (*KafkaEventConfiguration)(nil), // 58: wg.cosmo.node.v1.KafkaEventConfiguration - (*RedisEventConfiguration)(nil), // 59: wg.cosmo.node.v1.RedisEventConfiguration - (*EngineEventConfiguration)(nil), // 60: wg.cosmo.node.v1.EngineEventConfiguration - (*DataSourceCustomEvents)(nil), // 61: wg.cosmo.node.v1.DataSourceCustomEvents - (*DataSourceCustom_Static)(nil), // 62: wg.cosmo.node.v1.DataSourceCustom_Static - (*ConfigurationVariable)(nil), // 63: wg.cosmo.node.v1.ConfigurationVariable - (*DirectiveConfiguration)(nil), // 64: wg.cosmo.node.v1.DirectiveConfiguration - (*URLQueryConfiguration)(nil), // 65: wg.cosmo.node.v1.URLQueryConfiguration - (*HTTPHeader)(nil), // 66: wg.cosmo.node.v1.HTTPHeader - (*MTLSConfiguration)(nil), // 67: wg.cosmo.node.v1.MTLSConfiguration - (*GraphQLSubscriptionConfiguration)(nil), // 68: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration - (*GraphQLFederationConfiguration)(nil), // 69: wg.cosmo.node.v1.GraphQLFederationConfiguration - (*InternedString)(nil), // 70: wg.cosmo.node.v1.InternedString - (*SingleTypeField)(nil), // 71: wg.cosmo.node.v1.SingleTypeField - (*SubscriptionFieldCondition)(nil), // 72: wg.cosmo.node.v1.SubscriptionFieldCondition - (*SubscriptionFilterCondition)(nil), // 73: wg.cosmo.node.v1.SubscriptionFilterCondition - (*CacheWarmerOperations)(nil), // 74: wg.cosmo.node.v1.CacheWarmerOperations - (*Operation)(nil), // 75: wg.cosmo.node.v1.Operation - (*OperationRequest)(nil), // 76: wg.cosmo.node.v1.OperationRequest - (*Extension)(nil), // 77: wg.cosmo.node.v1.Extension - (*PersistedQuery)(nil), // 78: wg.cosmo.node.v1.PersistedQuery - (*ClientInfo)(nil), // 79: wg.cosmo.node.v1.ClientInfo - nil, // 80: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry - nil, // 81: wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry - nil, // 82: wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry - nil, // 83: wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry - nil, // 84: wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry - nil, // 85: wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry - nil, // 86: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry - (common.EnumStatusCode)(0), // 87: wg.cosmo.common.EnumStatusCode - (common.GraphQLSubscriptionProtocol)(0), // 88: wg.cosmo.common.GraphQLSubscriptionProtocol - (common.GraphQLWebsocketSubprotocol)(0), // 89: wg.cosmo.common.GraphQLWebsocketSubprotocol + (*QueryCacheConfiguration)(nil), // 24: wg.cosmo.node.v1.QueryCacheConfiguration + (*EntityKeyMapping)(nil), // 25: wg.cosmo.node.v1.EntityKeyMapping + (*EntityCacheFieldMapping)(nil), // 26: wg.cosmo.node.v1.EntityCacheFieldMapping + (*CostConfiguration)(nil), // 27: wg.cosmo.node.v1.CostConfiguration + (*FieldWeightConfiguration)(nil), // 28: wg.cosmo.node.v1.FieldWeightConfiguration + (*FieldListSizeConfiguration)(nil), // 29: wg.cosmo.node.v1.FieldListSizeConfiguration + (*ArgumentConfiguration)(nil), // 30: wg.cosmo.node.v1.ArgumentConfiguration + (*Scopes)(nil), // 31: wg.cosmo.node.v1.Scopes + (*AuthorizationConfiguration)(nil), // 32: wg.cosmo.node.v1.AuthorizationConfiguration + (*FieldConfiguration)(nil), // 33: wg.cosmo.node.v1.FieldConfiguration + (*TypeConfiguration)(nil), // 34: wg.cosmo.node.v1.TypeConfiguration + (*TypeField)(nil), // 35: wg.cosmo.node.v1.TypeField + (*FieldCoordinates)(nil), // 36: wg.cosmo.node.v1.FieldCoordinates + (*FieldSetCondition)(nil), // 37: wg.cosmo.node.v1.FieldSetCondition + (*RequiredField)(nil), // 38: wg.cosmo.node.v1.RequiredField + (*EntityInterfaceConfiguration)(nil), // 39: wg.cosmo.node.v1.EntityInterfaceConfiguration + (*FetchConfiguration)(nil), // 40: wg.cosmo.node.v1.FetchConfiguration + (*StatusCodeTypeMapping)(nil), // 41: wg.cosmo.node.v1.StatusCodeTypeMapping + (*DataSourceCustom_GraphQL)(nil), // 42: wg.cosmo.node.v1.DataSourceCustom_GraphQL + (*GRPCConfiguration)(nil), // 43: wg.cosmo.node.v1.GRPCConfiguration + (*ImageReference)(nil), // 44: wg.cosmo.node.v1.ImageReference + (*PluginConfiguration)(nil), // 45: wg.cosmo.node.v1.PluginConfiguration + (*SSLConfiguration)(nil), // 46: wg.cosmo.node.v1.SSLConfiguration + (*GRPCMapping)(nil), // 47: wg.cosmo.node.v1.GRPCMapping + (*LookupMapping)(nil), // 48: wg.cosmo.node.v1.LookupMapping + (*LookupFieldMapping)(nil), // 49: wg.cosmo.node.v1.LookupFieldMapping + (*OperationMapping)(nil), // 50: wg.cosmo.node.v1.OperationMapping + (*EntityMapping)(nil), // 51: wg.cosmo.node.v1.EntityMapping + (*RequiredFieldMapping)(nil), // 52: wg.cosmo.node.v1.RequiredFieldMapping + (*TypeFieldMapping)(nil), // 53: wg.cosmo.node.v1.TypeFieldMapping + (*FieldMapping)(nil), // 54: wg.cosmo.node.v1.FieldMapping + (*ArgumentMapping)(nil), // 55: wg.cosmo.node.v1.ArgumentMapping + (*EnumMapping)(nil), // 56: wg.cosmo.node.v1.EnumMapping + (*EnumValueMapping)(nil), // 57: wg.cosmo.node.v1.EnumValueMapping + (*NatsStreamConfiguration)(nil), // 58: wg.cosmo.node.v1.NatsStreamConfiguration + (*NatsEventConfiguration)(nil), // 59: wg.cosmo.node.v1.NatsEventConfiguration + (*KafkaEventConfiguration)(nil), // 60: wg.cosmo.node.v1.KafkaEventConfiguration + (*RedisEventConfiguration)(nil), // 61: wg.cosmo.node.v1.RedisEventConfiguration + (*EngineEventConfiguration)(nil), // 62: wg.cosmo.node.v1.EngineEventConfiguration + (*DataSourceCustomEvents)(nil), // 63: wg.cosmo.node.v1.DataSourceCustomEvents + (*DataSourceCustom_Static)(nil), // 64: wg.cosmo.node.v1.DataSourceCustom_Static + (*ConfigurationVariable)(nil), // 65: wg.cosmo.node.v1.ConfigurationVariable + (*DirectiveConfiguration)(nil), // 66: wg.cosmo.node.v1.DirectiveConfiguration + (*URLQueryConfiguration)(nil), // 67: wg.cosmo.node.v1.URLQueryConfiguration + (*HTTPHeader)(nil), // 68: wg.cosmo.node.v1.HTTPHeader + (*MTLSConfiguration)(nil), // 69: wg.cosmo.node.v1.MTLSConfiguration + (*GraphQLSubscriptionConfiguration)(nil), // 70: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration + (*GraphQLFederationConfiguration)(nil), // 71: wg.cosmo.node.v1.GraphQLFederationConfiguration + (*InternedString)(nil), // 72: wg.cosmo.node.v1.InternedString + (*SingleTypeField)(nil), // 73: wg.cosmo.node.v1.SingleTypeField + (*SubscriptionFieldCondition)(nil), // 74: wg.cosmo.node.v1.SubscriptionFieldCondition + (*SubscriptionFilterCondition)(nil), // 75: wg.cosmo.node.v1.SubscriptionFilterCondition + (*CacheWarmerOperations)(nil), // 76: wg.cosmo.node.v1.CacheWarmerOperations + (*Operation)(nil), // 77: wg.cosmo.node.v1.Operation + (*OperationRequest)(nil), // 78: wg.cosmo.node.v1.OperationRequest + (*Extension)(nil), // 79: wg.cosmo.node.v1.Extension + (*PersistedQuery)(nil), // 80: wg.cosmo.node.v1.PersistedQuery + (*ClientInfo)(nil), // 81: wg.cosmo.node.v1.ClientInfo + nil, // 82: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry + nil, // 83: wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry + nil, // 84: wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry + nil, // 85: wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry + nil, // 86: wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry + nil, // 87: wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry + nil, // 88: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry + (common.EnumStatusCode)(0), // 89: wg.cosmo.common.EnumStatusCode + (common.GraphQLSubscriptionProtocol)(0), // 90: wg.cosmo.common.GraphQLSubscriptionProtocol + (common.GraphQLWebsocketSubprotocol)(0), // 91: wg.cosmo.common.GraphQLWebsocketSubprotocol } var file_wg_cosmo_node_v1_node_proto_depIdxs = []int32{ - 80, // 0: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.config_by_feature_flag_name:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry + 82, // 0: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.config_by_feature_flag_name:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry 18, // 1: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig.engine_config:type_name -> wg.cosmo.node.v1.EngineConfiguration 8, // 2: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig.subgraphs:type_name -> wg.cosmo.node.v1.Subgraph 18, // 3: wg.cosmo.node.v1.RouterConfig.engine_config:type_name -> wg.cosmo.node.v1.EngineConfiguration 8, // 4: wg.cosmo.node.v1.RouterConfig.subgraphs:type_name -> wg.cosmo.node.v1.Subgraph 9, // 5: wg.cosmo.node.v1.RouterConfig.feature_flag_configs:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs - 87, // 6: wg.cosmo.node.v1.Response.code:type_name -> wg.cosmo.common.EnumStatusCode + 89, // 6: wg.cosmo.node.v1.Response.code:type_name -> wg.cosmo.common.EnumStatusCode 15, // 7: wg.cosmo.node.v1.RegistrationInfo.account_limits:type_name -> wg.cosmo.node.v1.AccountLimits 12, // 8: wg.cosmo.node.v1.SelfRegisterResponse.response:type_name -> wg.cosmo.node.v1.Response 14, // 9: wg.cosmo.node.v1.SelfRegisterResponse.registrationInfo:type_name -> wg.cosmo.node.v1.RegistrationInfo 19, // 10: wg.cosmo.node.v1.EngineConfiguration.datasource_configurations:type_name -> wg.cosmo.node.v1.DataSourceConfiguration - 31, // 11: wg.cosmo.node.v1.EngineConfiguration.field_configurations:type_name -> wg.cosmo.node.v1.FieldConfiguration - 32, // 12: wg.cosmo.node.v1.EngineConfiguration.type_configurations:type_name -> wg.cosmo.node.v1.TypeConfiguration - 81, // 13: wg.cosmo.node.v1.EngineConfiguration.string_storage:type_name -> wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry + 33, // 11: wg.cosmo.node.v1.EngineConfiguration.field_configurations:type_name -> wg.cosmo.node.v1.FieldConfiguration + 34, // 12: wg.cosmo.node.v1.EngineConfiguration.type_configurations:type_name -> wg.cosmo.node.v1.TypeConfiguration + 83, // 13: wg.cosmo.node.v1.EngineConfiguration.string_storage:type_name -> wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry 2, // 14: wg.cosmo.node.v1.DataSourceConfiguration.kind:type_name -> wg.cosmo.node.v1.DataSourceKind - 33, // 15: wg.cosmo.node.v1.DataSourceConfiguration.root_nodes:type_name -> wg.cosmo.node.v1.TypeField - 33, // 16: wg.cosmo.node.v1.DataSourceConfiguration.child_nodes:type_name -> wg.cosmo.node.v1.TypeField - 40, // 17: wg.cosmo.node.v1.DataSourceConfiguration.custom_graphql:type_name -> wg.cosmo.node.v1.DataSourceCustom_GraphQL - 62, // 18: wg.cosmo.node.v1.DataSourceConfiguration.custom_static:type_name -> wg.cosmo.node.v1.DataSourceCustom_Static - 64, // 19: wg.cosmo.node.v1.DataSourceConfiguration.directives:type_name -> wg.cosmo.node.v1.DirectiveConfiguration - 36, // 20: wg.cosmo.node.v1.DataSourceConfiguration.keys:type_name -> wg.cosmo.node.v1.RequiredField - 36, // 21: wg.cosmo.node.v1.DataSourceConfiguration.provides:type_name -> wg.cosmo.node.v1.RequiredField - 36, // 22: wg.cosmo.node.v1.DataSourceConfiguration.requires:type_name -> wg.cosmo.node.v1.RequiredField - 61, // 23: wg.cosmo.node.v1.DataSourceConfiguration.custom_events:type_name -> wg.cosmo.node.v1.DataSourceCustomEvents - 37, // 24: wg.cosmo.node.v1.DataSourceConfiguration.entity_interfaces:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration - 37, // 25: wg.cosmo.node.v1.DataSourceConfiguration.interface_objects:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration - 25, // 26: wg.cosmo.node.v1.DataSourceConfiguration.cost_configuration:type_name -> wg.cosmo.node.v1.CostConfiguration + 35, // 15: wg.cosmo.node.v1.DataSourceConfiguration.root_nodes:type_name -> wg.cosmo.node.v1.TypeField + 35, // 16: wg.cosmo.node.v1.DataSourceConfiguration.child_nodes:type_name -> wg.cosmo.node.v1.TypeField + 42, // 17: wg.cosmo.node.v1.DataSourceConfiguration.custom_graphql:type_name -> wg.cosmo.node.v1.DataSourceCustom_GraphQL + 64, // 18: wg.cosmo.node.v1.DataSourceConfiguration.custom_static:type_name -> wg.cosmo.node.v1.DataSourceCustom_Static + 66, // 19: wg.cosmo.node.v1.DataSourceConfiguration.directives:type_name -> wg.cosmo.node.v1.DirectiveConfiguration + 38, // 20: wg.cosmo.node.v1.DataSourceConfiguration.keys:type_name -> wg.cosmo.node.v1.RequiredField + 38, // 21: wg.cosmo.node.v1.DataSourceConfiguration.provides:type_name -> wg.cosmo.node.v1.RequiredField + 38, // 22: wg.cosmo.node.v1.DataSourceConfiguration.requires:type_name -> wg.cosmo.node.v1.RequiredField + 63, // 23: wg.cosmo.node.v1.DataSourceConfiguration.custom_events:type_name -> wg.cosmo.node.v1.DataSourceCustomEvents + 39, // 24: wg.cosmo.node.v1.DataSourceConfiguration.entity_interfaces:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration + 39, // 25: wg.cosmo.node.v1.DataSourceConfiguration.interface_objects:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration + 27, // 26: wg.cosmo.node.v1.DataSourceConfiguration.cost_configuration:type_name -> wg.cosmo.node.v1.CostConfiguration 20, // 27: wg.cosmo.node.v1.DataSourceConfiguration.entity_caching_configuration:type_name -> wg.cosmo.node.v1.EntityCachingConfiguration 21, // 28: wg.cosmo.node.v1.EntityCachingConfiguration.entity_cache:type_name -> wg.cosmo.node.v1.EntityCacheConfiguration 22, // 29: wg.cosmo.node.v1.EntityCachingConfiguration.cache_invalidate_configurations:type_name -> wg.cosmo.node.v1.CacheInvalidateConfiguration 23, // 30: wg.cosmo.node.v1.EntityCachingConfiguration.cache_populate_configurations:type_name -> wg.cosmo.node.v1.CachePopulateConfiguration - 24, // 31: wg.cosmo.node.v1.EntityCachingConfiguration.request_scoped_configurations:type_name -> wg.cosmo.node.v1.RequestScopedConfiguration - 26, // 32: wg.cosmo.node.v1.CostConfiguration.field_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration - 27, // 33: wg.cosmo.node.v1.CostConfiguration.list_sizes:type_name -> wg.cosmo.node.v1.FieldListSizeConfiguration - 82, // 34: wg.cosmo.node.v1.CostConfiguration.type_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry - 83, // 35: wg.cosmo.node.v1.CostConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry - 84, // 36: wg.cosmo.node.v1.FieldWeightConfiguration.argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry - 85, // 37: wg.cosmo.node.v1.FieldWeightConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry - 1, // 38: wg.cosmo.node.v1.ArgumentConfiguration.source_type:type_name -> wg.cosmo.node.v1.ArgumentSource - 29, // 39: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes:type_name -> wg.cosmo.node.v1.Scopes - 29, // 40: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes_by_or:type_name -> wg.cosmo.node.v1.Scopes - 28, // 41: wg.cosmo.node.v1.FieldConfiguration.arguments_configuration:type_name -> wg.cosmo.node.v1.ArgumentConfiguration - 30, // 42: wg.cosmo.node.v1.FieldConfiguration.authorization_configuration:type_name -> wg.cosmo.node.v1.AuthorizationConfiguration - 73, // 43: wg.cosmo.node.v1.FieldConfiguration.subscription_filter_condition:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 34, // 44: wg.cosmo.node.v1.FieldSetCondition.field_coordinates_path:type_name -> wg.cosmo.node.v1.FieldCoordinates - 35, // 45: wg.cosmo.node.v1.RequiredField.conditions:type_name -> wg.cosmo.node.v1.FieldSetCondition - 63, // 46: wg.cosmo.node.v1.FetchConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 7, // 47: wg.cosmo.node.v1.FetchConfiguration.method:type_name -> wg.cosmo.node.v1.HTTPMethod - 86, // 48: wg.cosmo.node.v1.FetchConfiguration.header:type_name -> wg.cosmo.node.v1.FetchConfiguration.HeaderEntry - 63, // 49: wg.cosmo.node.v1.FetchConfiguration.body:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 65, // 50: wg.cosmo.node.v1.FetchConfiguration.query:type_name -> wg.cosmo.node.v1.URLQueryConfiguration - 67, // 51: wg.cosmo.node.v1.FetchConfiguration.mtls:type_name -> wg.cosmo.node.v1.MTLSConfiguration - 63, // 52: wg.cosmo.node.v1.FetchConfiguration.base_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 53: wg.cosmo.node.v1.FetchConfiguration.path:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 54: wg.cosmo.node.v1.FetchConfiguration.http_proxy_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 38, // 55: wg.cosmo.node.v1.DataSourceCustom_GraphQL.fetch:type_name -> wg.cosmo.node.v1.FetchConfiguration - 68, // 56: wg.cosmo.node.v1.DataSourceCustom_GraphQL.subscription:type_name -> wg.cosmo.node.v1.GraphQLSubscriptionConfiguration - 69, // 57: wg.cosmo.node.v1.DataSourceCustom_GraphQL.federation:type_name -> wg.cosmo.node.v1.GraphQLFederationConfiguration - 70, // 58: wg.cosmo.node.v1.DataSourceCustom_GraphQL.upstream_schema:type_name -> wg.cosmo.node.v1.InternedString - 71, // 59: wg.cosmo.node.v1.DataSourceCustom_GraphQL.custom_scalar_type_fields:type_name -> wg.cosmo.node.v1.SingleTypeField - 41, // 60: wg.cosmo.node.v1.DataSourceCustom_GraphQL.grpc:type_name -> wg.cosmo.node.v1.GRPCConfiguration - 45, // 61: wg.cosmo.node.v1.GRPCConfiguration.mapping:type_name -> wg.cosmo.node.v1.GRPCMapping - 43, // 62: wg.cosmo.node.v1.GRPCConfiguration.plugin:type_name -> wg.cosmo.node.v1.PluginConfiguration - 42, // 63: wg.cosmo.node.v1.PluginConfiguration.image_reference:type_name -> wg.cosmo.node.v1.ImageReference - 48, // 64: wg.cosmo.node.v1.GRPCMapping.operation_mappings:type_name -> wg.cosmo.node.v1.OperationMapping - 49, // 65: wg.cosmo.node.v1.GRPCMapping.entity_mappings:type_name -> wg.cosmo.node.v1.EntityMapping - 51, // 66: wg.cosmo.node.v1.GRPCMapping.type_field_mappings:type_name -> wg.cosmo.node.v1.TypeFieldMapping - 54, // 67: wg.cosmo.node.v1.GRPCMapping.enum_mappings:type_name -> wg.cosmo.node.v1.EnumMapping - 46, // 68: wg.cosmo.node.v1.GRPCMapping.resolve_mappings:type_name -> wg.cosmo.node.v1.LookupMapping - 3, // 69: wg.cosmo.node.v1.LookupMapping.type:type_name -> wg.cosmo.node.v1.LookupType - 47, // 70: wg.cosmo.node.v1.LookupMapping.lookup_mapping:type_name -> wg.cosmo.node.v1.LookupFieldMapping - 52, // 71: wg.cosmo.node.v1.LookupFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping - 4, // 72: wg.cosmo.node.v1.OperationMapping.type:type_name -> wg.cosmo.node.v1.OperationType - 50, // 73: wg.cosmo.node.v1.EntityMapping.required_field_mappings:type_name -> wg.cosmo.node.v1.RequiredFieldMapping - 52, // 74: wg.cosmo.node.v1.RequiredFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping - 52, // 75: wg.cosmo.node.v1.TypeFieldMapping.field_mappings:type_name -> wg.cosmo.node.v1.FieldMapping - 53, // 76: wg.cosmo.node.v1.FieldMapping.argument_mappings:type_name -> wg.cosmo.node.v1.ArgumentMapping - 55, // 77: wg.cosmo.node.v1.EnumMapping.values:type_name -> wg.cosmo.node.v1.EnumValueMapping - 60, // 78: wg.cosmo.node.v1.NatsEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration - 56, // 79: wg.cosmo.node.v1.NatsEventConfiguration.stream_configuration:type_name -> wg.cosmo.node.v1.NatsStreamConfiguration - 60, // 80: wg.cosmo.node.v1.KafkaEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration - 60, // 81: wg.cosmo.node.v1.RedisEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration - 5, // 82: wg.cosmo.node.v1.EngineEventConfiguration.type:type_name -> wg.cosmo.node.v1.EventType - 57, // 83: wg.cosmo.node.v1.DataSourceCustomEvents.nats:type_name -> wg.cosmo.node.v1.NatsEventConfiguration - 58, // 84: wg.cosmo.node.v1.DataSourceCustomEvents.kafka:type_name -> wg.cosmo.node.v1.KafkaEventConfiguration - 59, // 85: wg.cosmo.node.v1.DataSourceCustomEvents.redis:type_name -> wg.cosmo.node.v1.RedisEventConfiguration - 63, // 86: wg.cosmo.node.v1.DataSourceCustom_Static.data:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 6, // 87: wg.cosmo.node.v1.ConfigurationVariable.kind:type_name -> wg.cosmo.node.v1.ConfigurationVariableKind - 63, // 88: wg.cosmo.node.v1.HTTPHeader.values:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 89: wg.cosmo.node.v1.MTLSConfiguration.key:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 90: wg.cosmo.node.v1.MTLSConfiguration.cert:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 91: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 88, // 92: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.protocol:type_name -> wg.cosmo.common.GraphQLSubscriptionProtocol - 89, // 93: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.websocketSubprotocol:type_name -> wg.cosmo.common.GraphQLWebsocketSubprotocol - 73, // 94: wg.cosmo.node.v1.SubscriptionFilterCondition.and:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 72, // 95: wg.cosmo.node.v1.SubscriptionFilterCondition.in:type_name -> wg.cosmo.node.v1.SubscriptionFieldCondition - 73, // 96: wg.cosmo.node.v1.SubscriptionFilterCondition.not:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 73, // 97: wg.cosmo.node.v1.SubscriptionFilterCondition.or:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 75, // 98: wg.cosmo.node.v1.CacheWarmerOperations.operations:type_name -> wg.cosmo.node.v1.Operation - 76, // 99: wg.cosmo.node.v1.Operation.request:type_name -> wg.cosmo.node.v1.OperationRequest - 79, // 100: wg.cosmo.node.v1.Operation.client:type_name -> wg.cosmo.node.v1.ClientInfo - 77, // 101: wg.cosmo.node.v1.OperationRequest.extensions:type_name -> wg.cosmo.node.v1.Extension - 78, // 102: wg.cosmo.node.v1.Extension.persisted_query:type_name -> wg.cosmo.node.v1.PersistedQuery - 10, // 103: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry.value:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig - 66, // 104: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry.value:type_name -> wg.cosmo.node.v1.HTTPHeader - 16, // 105: wg.cosmo.node.v1.NodeService.SelfRegister:input_type -> wg.cosmo.node.v1.SelfRegisterRequest - 17, // 106: wg.cosmo.node.v1.NodeService.SelfRegister:output_type -> wg.cosmo.node.v1.SelfRegisterResponse - 106, // [106:107] is the sub-list for method output_type - 105, // [105:106] is the sub-list for method input_type - 105, // [105:105] is the sub-list for extension type_name - 105, // [105:105] is the sub-list for extension extendee - 0, // [0:105] is the sub-list for field type_name + 24, // 31: wg.cosmo.node.v1.EntityCachingConfiguration.query_cache_configurations:type_name -> wg.cosmo.node.v1.QueryCacheConfiguration + 25, // 32: wg.cosmo.node.v1.QueryCacheConfiguration.entity_key_mappings:type_name -> wg.cosmo.node.v1.EntityKeyMapping + 26, // 33: wg.cosmo.node.v1.EntityKeyMapping.field_mappings:type_name -> wg.cosmo.node.v1.EntityCacheFieldMapping + 28, // 34: wg.cosmo.node.v1.CostConfiguration.field_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration + 29, // 35: wg.cosmo.node.v1.CostConfiguration.list_sizes:type_name -> wg.cosmo.node.v1.FieldListSizeConfiguration + 84, // 36: wg.cosmo.node.v1.CostConfiguration.type_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry + 85, // 37: wg.cosmo.node.v1.CostConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry + 86, // 38: wg.cosmo.node.v1.FieldWeightConfiguration.argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry + 87, // 39: wg.cosmo.node.v1.FieldWeightConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry + 1, // 40: wg.cosmo.node.v1.ArgumentConfiguration.source_type:type_name -> wg.cosmo.node.v1.ArgumentSource + 31, // 41: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes:type_name -> wg.cosmo.node.v1.Scopes + 31, // 42: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes_by_or:type_name -> wg.cosmo.node.v1.Scopes + 30, // 43: wg.cosmo.node.v1.FieldConfiguration.arguments_configuration:type_name -> wg.cosmo.node.v1.ArgumentConfiguration + 32, // 44: wg.cosmo.node.v1.FieldConfiguration.authorization_configuration:type_name -> wg.cosmo.node.v1.AuthorizationConfiguration + 75, // 45: wg.cosmo.node.v1.FieldConfiguration.subscription_filter_condition:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 36, // 46: wg.cosmo.node.v1.FieldSetCondition.field_coordinates_path:type_name -> wg.cosmo.node.v1.FieldCoordinates + 37, // 47: wg.cosmo.node.v1.RequiredField.conditions:type_name -> wg.cosmo.node.v1.FieldSetCondition + 65, // 48: wg.cosmo.node.v1.FetchConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 7, // 49: wg.cosmo.node.v1.FetchConfiguration.method:type_name -> wg.cosmo.node.v1.HTTPMethod + 88, // 50: wg.cosmo.node.v1.FetchConfiguration.header:type_name -> wg.cosmo.node.v1.FetchConfiguration.HeaderEntry + 65, // 51: wg.cosmo.node.v1.FetchConfiguration.body:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 67, // 52: wg.cosmo.node.v1.FetchConfiguration.query:type_name -> wg.cosmo.node.v1.URLQueryConfiguration + 69, // 53: wg.cosmo.node.v1.FetchConfiguration.mtls:type_name -> wg.cosmo.node.v1.MTLSConfiguration + 65, // 54: wg.cosmo.node.v1.FetchConfiguration.base_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 55: wg.cosmo.node.v1.FetchConfiguration.path:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 56: wg.cosmo.node.v1.FetchConfiguration.http_proxy_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 40, // 57: wg.cosmo.node.v1.DataSourceCustom_GraphQL.fetch:type_name -> wg.cosmo.node.v1.FetchConfiguration + 70, // 58: wg.cosmo.node.v1.DataSourceCustom_GraphQL.subscription:type_name -> wg.cosmo.node.v1.GraphQLSubscriptionConfiguration + 71, // 59: wg.cosmo.node.v1.DataSourceCustom_GraphQL.federation:type_name -> wg.cosmo.node.v1.GraphQLFederationConfiguration + 72, // 60: wg.cosmo.node.v1.DataSourceCustom_GraphQL.upstream_schema:type_name -> wg.cosmo.node.v1.InternedString + 73, // 61: wg.cosmo.node.v1.DataSourceCustom_GraphQL.custom_scalar_type_fields:type_name -> wg.cosmo.node.v1.SingleTypeField + 43, // 62: wg.cosmo.node.v1.DataSourceCustom_GraphQL.grpc:type_name -> wg.cosmo.node.v1.GRPCConfiguration + 47, // 63: wg.cosmo.node.v1.GRPCConfiguration.mapping:type_name -> wg.cosmo.node.v1.GRPCMapping + 45, // 64: wg.cosmo.node.v1.GRPCConfiguration.plugin:type_name -> wg.cosmo.node.v1.PluginConfiguration + 44, // 65: wg.cosmo.node.v1.PluginConfiguration.image_reference:type_name -> wg.cosmo.node.v1.ImageReference + 50, // 66: wg.cosmo.node.v1.GRPCMapping.operation_mappings:type_name -> wg.cosmo.node.v1.OperationMapping + 51, // 67: wg.cosmo.node.v1.GRPCMapping.entity_mappings:type_name -> wg.cosmo.node.v1.EntityMapping + 53, // 68: wg.cosmo.node.v1.GRPCMapping.type_field_mappings:type_name -> wg.cosmo.node.v1.TypeFieldMapping + 56, // 69: wg.cosmo.node.v1.GRPCMapping.enum_mappings:type_name -> wg.cosmo.node.v1.EnumMapping + 48, // 70: wg.cosmo.node.v1.GRPCMapping.resolve_mappings:type_name -> wg.cosmo.node.v1.LookupMapping + 3, // 71: wg.cosmo.node.v1.LookupMapping.type:type_name -> wg.cosmo.node.v1.LookupType + 49, // 72: wg.cosmo.node.v1.LookupMapping.lookup_mapping:type_name -> wg.cosmo.node.v1.LookupFieldMapping + 54, // 73: wg.cosmo.node.v1.LookupFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping + 4, // 74: wg.cosmo.node.v1.OperationMapping.type:type_name -> wg.cosmo.node.v1.OperationType + 52, // 75: wg.cosmo.node.v1.EntityMapping.required_field_mappings:type_name -> wg.cosmo.node.v1.RequiredFieldMapping + 54, // 76: wg.cosmo.node.v1.RequiredFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping + 54, // 77: wg.cosmo.node.v1.TypeFieldMapping.field_mappings:type_name -> wg.cosmo.node.v1.FieldMapping + 55, // 78: wg.cosmo.node.v1.FieldMapping.argument_mappings:type_name -> wg.cosmo.node.v1.ArgumentMapping + 57, // 79: wg.cosmo.node.v1.EnumMapping.values:type_name -> wg.cosmo.node.v1.EnumValueMapping + 62, // 80: wg.cosmo.node.v1.NatsEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration + 58, // 81: wg.cosmo.node.v1.NatsEventConfiguration.stream_configuration:type_name -> wg.cosmo.node.v1.NatsStreamConfiguration + 62, // 82: wg.cosmo.node.v1.KafkaEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration + 62, // 83: wg.cosmo.node.v1.RedisEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration + 5, // 84: wg.cosmo.node.v1.EngineEventConfiguration.type:type_name -> wg.cosmo.node.v1.EventType + 59, // 85: wg.cosmo.node.v1.DataSourceCustomEvents.nats:type_name -> wg.cosmo.node.v1.NatsEventConfiguration + 60, // 86: wg.cosmo.node.v1.DataSourceCustomEvents.kafka:type_name -> wg.cosmo.node.v1.KafkaEventConfiguration + 61, // 87: wg.cosmo.node.v1.DataSourceCustomEvents.redis:type_name -> wg.cosmo.node.v1.RedisEventConfiguration + 65, // 88: wg.cosmo.node.v1.DataSourceCustom_Static.data:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 6, // 89: wg.cosmo.node.v1.ConfigurationVariable.kind:type_name -> wg.cosmo.node.v1.ConfigurationVariableKind + 65, // 90: wg.cosmo.node.v1.HTTPHeader.values:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 91: wg.cosmo.node.v1.MTLSConfiguration.key:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 92: wg.cosmo.node.v1.MTLSConfiguration.cert:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 93: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 90, // 94: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.protocol:type_name -> wg.cosmo.common.GraphQLSubscriptionProtocol + 91, // 95: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.websocketSubprotocol:type_name -> wg.cosmo.common.GraphQLWebsocketSubprotocol + 75, // 96: wg.cosmo.node.v1.SubscriptionFilterCondition.and:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 74, // 97: wg.cosmo.node.v1.SubscriptionFilterCondition.in:type_name -> wg.cosmo.node.v1.SubscriptionFieldCondition + 75, // 98: wg.cosmo.node.v1.SubscriptionFilterCondition.not:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 75, // 99: wg.cosmo.node.v1.SubscriptionFilterCondition.or:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 77, // 100: wg.cosmo.node.v1.CacheWarmerOperations.operations:type_name -> wg.cosmo.node.v1.Operation + 78, // 101: wg.cosmo.node.v1.Operation.request:type_name -> wg.cosmo.node.v1.OperationRequest + 81, // 102: wg.cosmo.node.v1.Operation.client:type_name -> wg.cosmo.node.v1.ClientInfo + 79, // 103: wg.cosmo.node.v1.OperationRequest.extensions:type_name -> wg.cosmo.node.v1.Extension + 80, // 104: wg.cosmo.node.v1.Extension.persisted_query:type_name -> wg.cosmo.node.v1.PersistedQuery + 10, // 105: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry.value:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig + 68, // 106: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry.value:type_name -> wg.cosmo.node.v1.HTTPHeader + 16, // 107: wg.cosmo.node.v1.NodeService.SelfRegister:input_type -> wg.cosmo.node.v1.SelfRegisterRequest + 17, // 108: wg.cosmo.node.v1.NodeService.SelfRegister:output_type -> wg.cosmo.node.v1.SelfRegisterResponse + 108, // [108:109] is the sub-list for method output_type + 107, // [107:108] is the sub-list for method input_type + 107, // [107:107] is the sub-list for extension type_name + 107, // [107:107] is the sub-list for extension extendee + 0, // [0:107] is the sub-list for field type_name } func init() { file_wg_cosmo_node_v1_node_proto_init() } @@ -5647,20 +5798,20 @@ func file_wg_cosmo_node_v1_node_proto_init() { file_wg_cosmo_node_v1_node_proto_msgTypes[4].OneofWrappers = []any{} file_wg_cosmo_node_v1_node_proto_msgTypes[9].OneofWrappers = []any{} file_wg_cosmo_node_v1_node_proto_msgTypes[10].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[18].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[19].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[23].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[30].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[35].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[60].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[65].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[20].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[21].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[25].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[32].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[37].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[62].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[67].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_wg_cosmo_node_v1_node_proto_rawDesc), len(file_wg_cosmo_node_v1_node_proto_rawDesc)), NumEnums: 8, - NumMessages: 79, + NumMessages: 81, NumExtensions: 0, NumServices: 1, }, diff --git a/connect/src/wg/cosmo/node/v1/node_pb.ts b/connect/src/wg/cosmo/node/v1/node_pb.ts index 01c8658e7a..b64885645a 100644 --- a/connect/src/wg/cosmo/node/v1/node_pb.ts +++ b/connect/src/wg/cosmo/node/v1/node_pb.ts @@ -922,11 +922,11 @@ export class EntityCachingConfiguration extends Message) { super(); @@ -939,7 +939,7 @@ export class EntityCachingConfiguration extends Message): EntityCachingConfiguration { @@ -1148,56 +1148,167 @@ export class CachePopulateConfiguration extends Message { +export class QueryCacheConfiguration extends Message { /** * @generated from field: string field_name = 1; */ fieldName = ""; /** - * @generated from field: string type_name = 2; + * TTL for cached root-field responses. Required: composition rejects values + * <= 0. Interpreted in seconds. + * + * @generated from field: int64 max_age_seconds = 2; */ - typeName = ""; + maxAgeSeconds = protoInt64.zero; /** - * @generated from field: string l1_key = 3; + * @generated from field: bool include_headers = 3; */ - l1Key = ""; + includeHeaders = false; - constructor(data?: PartialMessage) { + /** + * @generated from field: bool shadow_mode = 4; + */ + shadowMode = false; + + /** + * @generated from field: string entity_type_name = 5; + */ + entityTypeName = ""; + + /** + * @generated from field: repeated wg.cosmo.node.v1.EntityKeyMapping entity_key_mappings = 6; + */ + entityKeyMappings: EntityKeyMapping[] = []; + + constructor(data?: PartialMessage) { super(); proto3.util.initPartial(data, this); } static readonly runtime: typeof proto3 = proto3; - static readonly typeName = "wg.cosmo.node.v1.RequestScopedConfiguration"; + static readonly typeName = "wg.cosmo.node.v1.QueryCacheConfiguration"; static readonly fields: FieldList = proto3.util.newFieldList(() => [ { no: 1, name: "field_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, - { no: 2, name: "type_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, - { no: 3, name: "l1_key", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "max_age_seconds", kind: "scalar", T: 3 /* ScalarType.INT64 */ }, + { no: 3, name: "include_headers", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + { no: 4, name: "shadow_mode", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, + { no: 5, name: "entity_type_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 6, name: "entity_key_mappings", kind: "message", T: EntityKeyMapping, repeated: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): QueryCacheConfiguration { + return new QueryCacheConfiguration().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): QueryCacheConfiguration { + return new QueryCacheConfiguration().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): QueryCacheConfiguration { + return new QueryCacheConfiguration().fromJsonString(jsonString, options); + } + + static equals(a: QueryCacheConfiguration | PlainMessage | undefined, b: QueryCacheConfiguration | PlainMessage | undefined): boolean { + return proto3.util.equals(QueryCacheConfiguration, a, b); + } +} + +/** + * @generated from message wg.cosmo.node.v1.EntityKeyMapping + */ +export class EntityKeyMapping extends Message { + /** + * @generated from field: string entity_type_name = 1; + */ + entityTypeName = ""; + + /** + * @generated from field: repeated wg.cosmo.node.v1.EntityCacheFieldMapping field_mappings = 2; + */ + fieldMappings: EntityCacheFieldMapping[] = []; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "wg.cosmo.node.v1.EntityKeyMapping"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "entity_type_name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "field_mappings", kind: "message", T: EntityCacheFieldMapping, repeated: true }, + ]); + + static fromBinary(bytes: Uint8Array, options?: Partial): EntityKeyMapping { + return new EntityKeyMapping().fromBinary(bytes, options); + } + + static fromJson(jsonValue: JsonValue, options?: Partial): EntityKeyMapping { + return new EntityKeyMapping().fromJson(jsonValue, options); + } + + static fromJsonString(jsonString: string, options?: Partial): EntityKeyMapping { + return new EntityKeyMapping().fromJsonString(jsonString, options); + } + + static equals(a: EntityKeyMapping | PlainMessage | undefined, b: EntityKeyMapping | PlainMessage | undefined): boolean { + return proto3.util.equals(EntityKeyMapping, a, b); + } +} + +/** + * @generated from message wg.cosmo.node.v1.EntityCacheFieldMapping + */ +export class EntityCacheFieldMapping extends Message { + /** + * @generated from field: string entity_key_field = 1; + */ + entityKeyField = ""; + + /** + * @generated from field: repeated string argument_path = 2; + */ + argumentPath: string[] = []; + + /** + * @generated from field: bool is_batch = 3; + */ + isBatch = false; + + constructor(data?: PartialMessage) { + super(); + proto3.util.initPartial(data, this); + } + + static readonly runtime: typeof proto3 = proto3; + static readonly typeName = "wg.cosmo.node.v1.EntityCacheFieldMapping"; + static readonly fields: FieldList = proto3.util.newFieldList(() => [ + { no: 1, name: "entity_key_field", kind: "scalar", T: 9 /* ScalarType.STRING */ }, + { no: 2, name: "argument_path", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true }, + { no: 3, name: "is_batch", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, ]); - static fromBinary(bytes: Uint8Array, options?: Partial): RequestScopedConfiguration { - return new RequestScopedConfiguration().fromBinary(bytes, options); + static fromBinary(bytes: Uint8Array, options?: Partial): EntityCacheFieldMapping { + return new EntityCacheFieldMapping().fromBinary(bytes, options); } - static fromJson(jsonValue: JsonValue, options?: Partial): RequestScopedConfiguration { - return new RequestScopedConfiguration().fromJson(jsonValue, options); + static fromJson(jsonValue: JsonValue, options?: Partial): EntityCacheFieldMapping { + return new EntityCacheFieldMapping().fromJson(jsonValue, options); } - static fromJsonString(jsonString: string, options?: Partial): RequestScopedConfiguration { - return new RequestScopedConfiguration().fromJsonString(jsonString, options); + static fromJsonString(jsonString: string, options?: Partial): EntityCacheFieldMapping { + return new EntityCacheFieldMapping().fromJsonString(jsonString, options); } - static equals(a: RequestScopedConfiguration | PlainMessage | undefined, b: RequestScopedConfiguration | PlainMessage | undefined): boolean { - return proto3.util.equals(RequestScopedConfiguration, a, b); + static equals(a: EntityCacheFieldMapping | PlainMessage | undefined, b: EntityCacheFieldMapping | PlainMessage | undefined): boolean { + return proto3.util.equals(EntityCacheFieldMapping, a, b); } } diff --git a/proto/wg/cosmo/node/v1/node.proto b/proto/wg/cosmo/node/v1/node.proto index e75b2d5e6e..d5b3c5af0a 100644 --- a/proto/wg/cosmo/node/v1/node.proto +++ b/proto/wg/cosmo/node/v1/node.proto @@ -103,8 +103,8 @@ message EntityCachingConfiguration { repeated CacheInvalidateConfiguration cache_invalidate_configurations = 2; // Per-Mutation/Subscription-field cache population configs (from @openfed__cachePopulate) repeated CachePopulateConfiguration cache_populate_configurations = 3; - // Request-scoped field configurations (from @openfed__requestScoped directive) - repeated RequestScopedConfiguration request_scoped_configurations = 4; + // Per-Query-field cache configurations (from @openfed__queryCache / @openfed__is directives) + repeated QueryCacheConfiguration query_cache_configurations = 5; } // Per-entity declaration for @openfed__entityCache. Marks a @key entity type as cacheable so the @@ -141,14 +141,28 @@ message CachePopulateConfiguration { string entity_type_name = 4; } -// Per-field declaration for @openfed__requestScoped. All fields in the same subgraph declaring -// @openfed__requestScoped(key: "X") share L1 key "{subgraphName}.X". The first field to resolve -// populates L1; subsequent fields with the same key inject from L1 and can skip their -// fetch when all required sub-fields are present. -message RequestScopedConfiguration { +// Per-Query-field declaration for @openfed__queryCache. Tells the router a query field can serve +// its returned entity from the entity cache, with argument-to-@key mappings for cache-key construction. +message QueryCacheConfiguration { string field_name = 1; - string type_name = 2; - string l1_key = 3; + // TTL for cached root-field responses. Required: composition rejects values + // <= 0. Interpreted in seconds. + int64 max_age_seconds = 2; + bool include_headers = 3; + bool shadow_mode = 4; + string entity_type_name = 5; + repeated EntityKeyMapping entity_key_mappings = 6; +} + +message EntityKeyMapping { + string entity_type_name = 1; + repeated EntityCacheFieldMapping field_mappings = 2; +} + +message EntityCacheFieldMapping { + string entity_key_field = 1; + repeated string argument_path = 2; + bool is_batch = 3; } message CostConfiguration { diff --git a/router/gen/proto/wg/cosmo/node/v1/node.pb.go b/router/gen/proto/wg/cosmo/node/v1/node.pb.go index af73ae9b12..314c75f677 100644 --- a/router/gen/proto/wg/cosmo/node/v1/node.pb.go +++ b/router/gen/proto/wg/cosmo/node/v1/node.pb.go @@ -1234,10 +1234,10 @@ type EntityCachingConfiguration struct { CacheInvalidateConfigurations []*CacheInvalidateConfiguration `protobuf:"bytes,2,rep,name=cache_invalidate_configurations,json=cacheInvalidateConfigurations,proto3" json:"cache_invalidate_configurations,omitempty"` // Per-Mutation/Subscription-field cache population configs (from @openfed__cachePopulate) CachePopulateConfigurations []*CachePopulateConfiguration `protobuf:"bytes,3,rep,name=cache_populate_configurations,json=cachePopulateConfigurations,proto3" json:"cache_populate_configurations,omitempty"` - // Request-scoped field configurations (from @openfed__requestScoped directive) - RequestScopedConfigurations []*RequestScopedConfiguration `protobuf:"bytes,4,rep,name=request_scoped_configurations,json=requestScopedConfigurations,proto3" json:"request_scoped_configurations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache + // Per-Query-field cache configurations (from @openfed__queryCache / @openfed__is directives) + QueryCacheConfigurations []*QueryCacheConfiguration `protobuf:"bytes,5,rep,name=query_cache_configurations,json=queryCacheConfigurations,proto3" json:"query_cache_configurations,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *EntityCachingConfiguration) Reset() { @@ -1291,9 +1291,9 @@ func (x *EntityCachingConfiguration) GetCachePopulateConfigurations() []*CachePo return nil } -func (x *EntityCachingConfiguration) GetRequestScopedConfigurations() []*RequestScopedConfiguration { +func (x *EntityCachingConfiguration) GetQueryCacheConfigurations() []*QueryCacheConfiguration { if x != nil { - return x.RequestScopedConfigurations + return x.QueryCacheConfigurations } return nil } @@ -1522,33 +1522,36 @@ func (x *CachePopulateConfiguration) GetEntityTypeName() string { return "" } -// Per-field declaration for @openfed__requestScoped. All fields in the same subgraph declaring -// @openfed__requestScoped(key: "X") share L1 key "{subgraphName}.X". The first field to resolve -// populates L1; subsequent fields with the same key inject from L1 and can skip their -// fetch when all required sub-fields are present. -type RequestScopedConfiguration struct { - state protoimpl.MessageState `protogen:"open.v1"` - FieldName string `protobuf:"bytes,1,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` - TypeName string `protobuf:"bytes,2,opt,name=type_name,json=typeName,proto3" json:"type_name,omitempty"` - L1Key string `protobuf:"bytes,3,opt,name=l1_key,json=l1Key,proto3" json:"l1_key,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache +// Per-Query-field declaration for @openfed__queryCache. Tells the router a query field can serve +// its returned entity from the entity cache, with argument-to-@key mappings for cache-key construction. +type QueryCacheConfiguration struct { + state protoimpl.MessageState `protogen:"open.v1"` + FieldName string `protobuf:"bytes,1,opt,name=field_name,json=fieldName,proto3" json:"field_name,omitempty"` + // TTL for cached root-field responses. Required: composition rejects values + // <= 0. Interpreted in seconds. + MaxAgeSeconds int64 `protobuf:"varint,2,opt,name=max_age_seconds,json=maxAgeSeconds,proto3" json:"max_age_seconds,omitempty"` + IncludeHeaders bool `protobuf:"varint,3,opt,name=include_headers,json=includeHeaders,proto3" json:"include_headers,omitempty"` + ShadowMode bool `protobuf:"varint,4,opt,name=shadow_mode,json=shadowMode,proto3" json:"shadow_mode,omitempty"` + EntityTypeName string `protobuf:"bytes,5,opt,name=entity_type_name,json=entityTypeName,proto3" json:"entity_type_name,omitempty"` + EntityKeyMappings []*EntityKeyMapping `protobuf:"bytes,6,rep,name=entity_key_mappings,json=entityKeyMappings,proto3" json:"entity_key_mappings,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } -func (x *RequestScopedConfiguration) Reset() { - *x = RequestScopedConfiguration{} +func (x *QueryCacheConfiguration) Reset() { + *x = QueryCacheConfiguration{} mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } -func (x *RequestScopedConfiguration) String() string { +func (x *QueryCacheConfiguration) String() string { return protoimpl.X.MessageStringOf(x) } -func (*RequestScopedConfiguration) ProtoMessage() {} +func (*QueryCacheConfiguration) ProtoMessage() {} -func (x *RequestScopedConfiguration) ProtoReflect() protoreflect.Message { +func (x *QueryCacheConfiguration) ProtoReflect() protoreflect.Message { mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[16] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -1560,32 +1563,165 @@ func (x *RequestScopedConfiguration) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use RequestScopedConfiguration.ProtoReflect.Descriptor instead. -func (*RequestScopedConfiguration) Descriptor() ([]byte, []int) { +// Deprecated: Use QueryCacheConfiguration.ProtoReflect.Descriptor instead. +func (*QueryCacheConfiguration) Descriptor() ([]byte, []int) { return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{16} } -func (x *RequestScopedConfiguration) GetFieldName() string { +func (x *QueryCacheConfiguration) GetFieldName() string { if x != nil { return x.FieldName } return "" } -func (x *RequestScopedConfiguration) GetTypeName() string { +func (x *QueryCacheConfiguration) GetMaxAgeSeconds() int64 { if x != nil { - return x.TypeName + return x.MaxAgeSeconds + } + return 0 +} + +func (x *QueryCacheConfiguration) GetIncludeHeaders() bool { + if x != nil { + return x.IncludeHeaders + } + return false +} + +func (x *QueryCacheConfiguration) GetShadowMode() bool { + if x != nil { + return x.ShadowMode + } + return false +} + +func (x *QueryCacheConfiguration) GetEntityTypeName() string { + if x != nil { + return x.EntityTypeName + } + return "" +} + +func (x *QueryCacheConfiguration) GetEntityKeyMappings() []*EntityKeyMapping { + if x != nil { + return x.EntityKeyMappings + } + return nil +} + +type EntityKeyMapping struct { + state protoimpl.MessageState `protogen:"open.v1"` + EntityTypeName string `protobuf:"bytes,1,opt,name=entity_type_name,json=entityTypeName,proto3" json:"entity_type_name,omitempty"` + FieldMappings []*EntityCacheFieldMapping `protobuf:"bytes,2,rep,name=field_mappings,json=fieldMappings,proto3" json:"field_mappings,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *EntityKeyMapping) Reset() { + *x = EntityKeyMapping{} + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *EntityKeyMapping) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*EntityKeyMapping) ProtoMessage() {} + +func (x *EntityKeyMapping) ProtoReflect() protoreflect.Message { + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use EntityKeyMapping.ProtoReflect.Descriptor instead. +func (*EntityKeyMapping) Descriptor() ([]byte, []int) { + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{17} +} + +func (x *EntityKeyMapping) GetEntityTypeName() string { + if x != nil { + return x.EntityTypeName } return "" } -func (x *RequestScopedConfiguration) GetL1Key() string { +func (x *EntityKeyMapping) GetFieldMappings() []*EntityCacheFieldMapping { if x != nil { - return x.L1Key + return x.FieldMappings + } + return nil +} + +type EntityCacheFieldMapping struct { + state protoimpl.MessageState `protogen:"open.v1"` + EntityKeyField string `protobuf:"bytes,1,opt,name=entity_key_field,json=entityKeyField,proto3" json:"entity_key_field,omitempty"` + ArgumentPath []string `protobuf:"bytes,2,rep,name=argument_path,json=argumentPath,proto3" json:"argument_path,omitempty"` + IsBatch bool `protobuf:"varint,3,opt,name=is_batch,json=isBatch,proto3" json:"is_batch,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *EntityCacheFieldMapping) Reset() { + *x = EntityCacheFieldMapping{} + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *EntityCacheFieldMapping) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*EntityCacheFieldMapping) ProtoMessage() {} + +func (x *EntityCacheFieldMapping) ProtoReflect() protoreflect.Message { + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use EntityCacheFieldMapping.ProtoReflect.Descriptor instead. +func (*EntityCacheFieldMapping) Descriptor() ([]byte, []int) { + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{18} +} + +func (x *EntityCacheFieldMapping) GetEntityKeyField() string { + if x != nil { + return x.EntityKeyField } return "" } +func (x *EntityCacheFieldMapping) GetArgumentPath() []string { + if x != nil { + return x.ArgumentPath + } + return nil +} + +func (x *EntityCacheFieldMapping) GetIsBatch() bool { + if x != nil { + return x.IsBatch + } + return false +} + type CostConfiguration struct { state protoimpl.MessageState `protogen:"open.v1"` FieldWeights []*FieldWeightConfiguration `protobuf:"bytes,1,rep,name=field_weights,json=fieldWeights,proto3" json:"field_weights,omitempty"` @@ -1598,7 +1734,7 @@ type CostConfiguration struct { func (x *CostConfiguration) Reset() { *x = CostConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1610,7 +1746,7 @@ func (x *CostConfiguration) String() string { func (*CostConfiguration) ProtoMessage() {} func (x *CostConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[17] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1623,7 +1759,7 @@ func (x *CostConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use CostConfiguration.ProtoReflect.Descriptor instead. func (*CostConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{17} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{19} } func (x *CostConfiguration) GetFieldWeights() []*FieldWeightConfiguration { @@ -1667,7 +1803,7 @@ type FieldWeightConfiguration struct { func (x *FieldWeightConfiguration) Reset() { *x = FieldWeightConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1679,7 +1815,7 @@ func (x *FieldWeightConfiguration) String() string { func (*FieldWeightConfiguration) ProtoMessage() {} func (x *FieldWeightConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[18] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1692,7 +1828,7 @@ func (x *FieldWeightConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldWeightConfiguration.ProtoReflect.Descriptor instead. func (*FieldWeightConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{18} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{20} } func (x *FieldWeightConfiguration) GetTypeName() string { @@ -1744,7 +1880,7 @@ type FieldListSizeConfiguration struct { func (x *FieldListSizeConfiguration) Reset() { *x = FieldListSizeConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1756,7 +1892,7 @@ func (x *FieldListSizeConfiguration) String() string { func (*FieldListSizeConfiguration) ProtoMessage() {} func (x *FieldListSizeConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[19] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1769,7 +1905,7 @@ func (x *FieldListSizeConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldListSizeConfiguration.ProtoReflect.Descriptor instead. func (*FieldListSizeConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{19} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{21} } func (x *FieldListSizeConfiguration) GetTypeName() string { @@ -1824,7 +1960,7 @@ type ArgumentConfiguration struct { func (x *ArgumentConfiguration) Reset() { *x = ArgumentConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1836,7 +1972,7 @@ func (x *ArgumentConfiguration) String() string { func (*ArgumentConfiguration) ProtoMessage() {} func (x *ArgumentConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[20] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1849,7 +1985,7 @@ func (x *ArgumentConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use ArgumentConfiguration.ProtoReflect.Descriptor instead. func (*ArgumentConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{20} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{22} } func (x *ArgumentConfiguration) GetName() string { @@ -1875,7 +2011,7 @@ type Scopes struct { func (x *Scopes) Reset() { *x = Scopes{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1887,7 +2023,7 @@ func (x *Scopes) String() string { func (*Scopes) ProtoMessage() {} func (x *Scopes) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[21] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1900,7 +2036,7 @@ func (x *Scopes) ProtoReflect() protoreflect.Message { // Deprecated: Use Scopes.ProtoReflect.Descriptor instead. func (*Scopes) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{21} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{23} } func (x *Scopes) GetRequiredAndScopes() []string { @@ -1921,7 +2057,7 @@ type AuthorizationConfiguration struct { func (x *AuthorizationConfiguration) Reset() { *x = AuthorizationConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1933,7 +2069,7 @@ func (x *AuthorizationConfiguration) String() string { func (*AuthorizationConfiguration) ProtoMessage() {} func (x *AuthorizationConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[22] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1946,7 +2082,7 @@ func (x *AuthorizationConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use AuthorizationConfiguration.ProtoReflect.Descriptor instead. func (*AuthorizationConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{22} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{24} } func (x *AuthorizationConfiguration) GetRequiresAuthentication() bool { @@ -1983,7 +2119,7 @@ type FieldConfiguration struct { func (x *FieldConfiguration) Reset() { *x = FieldConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1995,7 +2131,7 @@ func (x *FieldConfiguration) String() string { func (*FieldConfiguration) ProtoMessage() {} func (x *FieldConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[23] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2008,7 +2144,7 @@ func (x *FieldConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldConfiguration.ProtoReflect.Descriptor instead. func (*FieldConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{23} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{25} } func (x *FieldConfiguration) GetTypeName() string { @@ -2056,7 +2192,7 @@ type TypeConfiguration struct { func (x *TypeConfiguration) Reset() { *x = TypeConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2068,7 +2204,7 @@ func (x *TypeConfiguration) String() string { func (*TypeConfiguration) ProtoMessage() {} func (x *TypeConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[24] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2081,7 +2217,7 @@ func (x *TypeConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use TypeConfiguration.ProtoReflect.Descriptor instead. func (*TypeConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{24} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{26} } func (x *TypeConfiguration) GetTypeName() string { @@ -2110,7 +2246,7 @@ type TypeField struct { func (x *TypeField) Reset() { *x = TypeField{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2122,7 +2258,7 @@ func (x *TypeField) String() string { func (*TypeField) ProtoMessage() {} func (x *TypeField) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[25] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2135,7 +2271,7 @@ func (x *TypeField) ProtoReflect() protoreflect.Message { // Deprecated: Use TypeField.ProtoReflect.Descriptor instead. func (*TypeField) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{25} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{27} } func (x *TypeField) GetTypeName() string { @@ -2176,7 +2312,7 @@ type FieldCoordinates struct { func (x *FieldCoordinates) Reset() { *x = FieldCoordinates{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2188,7 +2324,7 @@ func (x *FieldCoordinates) String() string { func (*FieldCoordinates) ProtoMessage() {} func (x *FieldCoordinates) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[26] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2201,7 +2337,7 @@ func (x *FieldCoordinates) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldCoordinates.ProtoReflect.Descriptor instead. func (*FieldCoordinates) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{26} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{28} } func (x *FieldCoordinates) GetFieldName() string { @@ -2228,7 +2364,7 @@ type FieldSetCondition struct { func (x *FieldSetCondition) Reset() { *x = FieldSetCondition{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2240,7 +2376,7 @@ func (x *FieldSetCondition) String() string { func (*FieldSetCondition) ProtoMessage() {} func (x *FieldSetCondition) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[27] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2253,7 +2389,7 @@ func (x *FieldSetCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldSetCondition.ProtoReflect.Descriptor instead. func (*FieldSetCondition) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{27} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{29} } func (x *FieldSetCondition) GetFieldCoordinatesPath() []*FieldCoordinates { @@ -2283,7 +2419,7 @@ type RequiredField struct { func (x *RequiredField) Reset() { *x = RequiredField{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2295,7 +2431,7 @@ func (x *RequiredField) String() string { func (*RequiredField) ProtoMessage() {} func (x *RequiredField) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[28] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2308,7 +2444,7 @@ func (x *RequiredField) ProtoReflect() protoreflect.Message { // Deprecated: Use RequiredField.ProtoReflect.Descriptor instead. func (*RequiredField) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{28} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{30} } func (x *RequiredField) GetTypeName() string { @@ -2356,7 +2492,7 @@ type EntityInterfaceConfiguration struct { func (x *EntityInterfaceConfiguration) Reset() { *x = EntityInterfaceConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2368,7 +2504,7 @@ func (x *EntityInterfaceConfiguration) String() string { func (*EntityInterfaceConfiguration) ProtoMessage() {} func (x *EntityInterfaceConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[29] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2381,7 +2517,7 @@ func (x *EntityInterfaceConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use EntityInterfaceConfiguration.ProtoReflect.Descriptor instead. func (*EntityInterfaceConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{29} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{31} } func (x *EntityInterfaceConfiguration) GetInterfaceTypeName() string { @@ -2424,7 +2560,7 @@ type FetchConfiguration struct { func (x *FetchConfiguration) Reset() { *x = FetchConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2436,7 +2572,7 @@ func (x *FetchConfiguration) String() string { func (*FetchConfiguration) ProtoMessage() {} func (x *FetchConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[30] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2449,7 +2585,7 @@ func (x *FetchConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use FetchConfiguration.ProtoReflect.Descriptor instead. func (*FetchConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{30} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{32} } func (x *FetchConfiguration) GetUrl() *ConfigurationVariable { @@ -2533,7 +2669,7 @@ type StatusCodeTypeMapping struct { func (x *StatusCodeTypeMapping) Reset() { *x = StatusCodeTypeMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2545,7 +2681,7 @@ func (x *StatusCodeTypeMapping) String() string { func (*StatusCodeTypeMapping) ProtoMessage() {} func (x *StatusCodeTypeMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[31] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2558,7 +2694,7 @@ func (x *StatusCodeTypeMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use StatusCodeTypeMapping.ProtoReflect.Descriptor instead. func (*StatusCodeTypeMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{31} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{33} } func (x *StatusCodeTypeMapping) GetStatusCode() int64 { @@ -2596,7 +2732,7 @@ type DataSourceCustom_GraphQL struct { func (x *DataSourceCustom_GraphQL) Reset() { *x = DataSourceCustom_GraphQL{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2608,7 +2744,7 @@ func (x *DataSourceCustom_GraphQL) String() string { func (*DataSourceCustom_GraphQL) ProtoMessage() {} func (x *DataSourceCustom_GraphQL) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[32] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2621,7 +2757,7 @@ func (x *DataSourceCustom_GraphQL) ProtoReflect() protoreflect.Message { // Deprecated: Use DataSourceCustom_GraphQL.ProtoReflect.Descriptor instead. func (*DataSourceCustom_GraphQL) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{32} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{34} } func (x *DataSourceCustom_GraphQL) GetFetch() *FetchConfiguration { @@ -2677,7 +2813,7 @@ type GRPCConfiguration struct { func (x *GRPCConfiguration) Reset() { *x = GRPCConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2689,7 +2825,7 @@ func (x *GRPCConfiguration) String() string { func (*GRPCConfiguration) ProtoMessage() {} func (x *GRPCConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[33] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2702,7 +2838,7 @@ func (x *GRPCConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use GRPCConfiguration.ProtoReflect.Descriptor instead. func (*GRPCConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{33} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{35} } func (x *GRPCConfiguration) GetMapping() *GRPCMapping { @@ -2736,7 +2872,7 @@ type ImageReference struct { func (x *ImageReference) Reset() { *x = ImageReference{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2748,7 +2884,7 @@ func (x *ImageReference) String() string { func (*ImageReference) ProtoMessage() {} func (x *ImageReference) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[34] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2761,7 +2897,7 @@ func (x *ImageReference) ProtoReflect() protoreflect.Message { // Deprecated: Use ImageReference.ProtoReflect.Descriptor instead. func (*ImageReference) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{34} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{36} } func (x *ImageReference) GetRepository() string { @@ -2791,7 +2927,7 @@ type PluginConfiguration struct { func (x *PluginConfiguration) Reset() { *x = PluginConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2803,7 +2939,7 @@ func (x *PluginConfiguration) String() string { func (*PluginConfiguration) ProtoMessage() {} func (x *PluginConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[35] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2816,7 +2952,7 @@ func (x *PluginConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use PluginConfiguration.ProtoReflect.Descriptor instead. func (*PluginConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{35} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{37} } func (x *PluginConfiguration) GetName() string { @@ -2850,7 +2986,7 @@ type SSLConfiguration struct { func (x *SSLConfiguration) Reset() { *x = SSLConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2862,7 +2998,7 @@ func (x *SSLConfiguration) String() string { func (*SSLConfiguration) ProtoMessage() {} func (x *SSLConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[36] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2875,7 +3011,7 @@ func (x *SSLConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use SSLConfiguration.ProtoReflect.Descriptor instead. func (*SSLConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{36} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{38} } func (x *SSLConfiguration) GetEnabled() bool { @@ -2908,7 +3044,7 @@ type GRPCMapping struct { func (x *GRPCMapping) Reset() { *x = GRPCMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2920,7 +3056,7 @@ func (x *GRPCMapping) String() string { func (*GRPCMapping) ProtoMessage() {} func (x *GRPCMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[37] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2933,7 +3069,7 @@ func (x *GRPCMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use GRPCMapping.ProtoReflect.Descriptor instead. func (*GRPCMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{37} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{39} } func (x *GRPCMapping) GetVersion() int32 { @@ -3004,7 +3140,7 @@ type LookupMapping struct { func (x *LookupMapping) Reset() { *x = LookupMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3016,7 +3152,7 @@ func (x *LookupMapping) String() string { func (*LookupMapping) ProtoMessage() {} func (x *LookupMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[38] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3029,7 +3165,7 @@ func (x *LookupMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use LookupMapping.ProtoReflect.Descriptor instead. func (*LookupMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{38} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{40} } func (x *LookupMapping) GetType() LookupType { @@ -3080,7 +3216,7 @@ type LookupFieldMapping struct { func (x *LookupFieldMapping) Reset() { *x = LookupFieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3092,7 +3228,7 @@ func (x *LookupFieldMapping) String() string { func (*LookupFieldMapping) ProtoMessage() {} func (x *LookupFieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[39] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3105,7 +3241,7 @@ func (x *LookupFieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use LookupFieldMapping.ProtoReflect.Descriptor instead. func (*LookupFieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{39} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{41} } func (x *LookupFieldMapping) GetType() string { @@ -3141,7 +3277,7 @@ type OperationMapping struct { func (x *OperationMapping) Reset() { *x = OperationMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3153,7 +3289,7 @@ func (x *OperationMapping) String() string { func (*OperationMapping) ProtoMessage() {} func (x *OperationMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[40] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3166,7 +3302,7 @@ func (x *OperationMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use OperationMapping.ProtoReflect.Descriptor instead. func (*OperationMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{40} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{42} } func (x *OperationMapping) GetType() OperationType { @@ -3227,7 +3363,7 @@ type EntityMapping struct { func (x *EntityMapping) Reset() { *x = EntityMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3239,7 +3375,7 @@ func (x *EntityMapping) String() string { func (*EntityMapping) ProtoMessage() {} func (x *EntityMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[41] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3252,7 +3388,7 @@ func (x *EntityMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use EntityMapping.ProtoReflect.Descriptor instead. func (*EntityMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{41} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{43} } func (x *EntityMapping) GetTypeName() string { @@ -3320,7 +3456,7 @@ type RequiredFieldMapping struct { func (x *RequiredFieldMapping) Reset() { *x = RequiredFieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3332,7 +3468,7 @@ func (x *RequiredFieldMapping) String() string { func (*RequiredFieldMapping) ProtoMessage() {} func (x *RequiredFieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[42] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3345,7 +3481,7 @@ func (x *RequiredFieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use RequiredFieldMapping.ProtoReflect.Descriptor instead. func (*RequiredFieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{42} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{44} } func (x *RequiredFieldMapping) GetFieldMapping() *FieldMapping { @@ -3389,7 +3525,7 @@ type TypeFieldMapping struct { func (x *TypeFieldMapping) Reset() { *x = TypeFieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3401,7 +3537,7 @@ func (x *TypeFieldMapping) String() string { func (*TypeFieldMapping) ProtoMessage() {} func (x *TypeFieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[43] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3414,7 +3550,7 @@ func (x *TypeFieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use TypeFieldMapping.ProtoReflect.Descriptor instead. func (*TypeFieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{43} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{45} } func (x *TypeFieldMapping) GetType() string { @@ -3446,7 +3582,7 @@ type FieldMapping struct { func (x *FieldMapping) Reset() { *x = FieldMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3458,7 +3594,7 @@ func (x *FieldMapping) String() string { func (*FieldMapping) ProtoMessage() {} func (x *FieldMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[44] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3471,7 +3607,7 @@ func (x *FieldMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use FieldMapping.ProtoReflect.Descriptor instead. func (*FieldMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{44} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{46} } func (x *FieldMapping) GetOriginal() string { @@ -3508,7 +3644,7 @@ type ArgumentMapping struct { func (x *ArgumentMapping) Reset() { *x = ArgumentMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3520,7 +3656,7 @@ func (x *ArgumentMapping) String() string { func (*ArgumentMapping) ProtoMessage() {} func (x *ArgumentMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[45] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3533,7 +3669,7 @@ func (x *ArgumentMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use ArgumentMapping.ProtoReflect.Descriptor instead. func (*ArgumentMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{45} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{47} } func (x *ArgumentMapping) GetOriginal() string { @@ -3560,7 +3696,7 @@ type EnumMapping struct { func (x *EnumMapping) Reset() { *x = EnumMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3572,7 +3708,7 @@ func (x *EnumMapping) String() string { func (*EnumMapping) ProtoMessage() {} func (x *EnumMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[46] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3585,7 +3721,7 @@ func (x *EnumMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use EnumMapping.ProtoReflect.Descriptor instead. func (*EnumMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{46} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{48} } func (x *EnumMapping) GetType() string { @@ -3612,7 +3748,7 @@ type EnumValueMapping struct { func (x *EnumValueMapping) Reset() { *x = EnumValueMapping{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3624,7 +3760,7 @@ func (x *EnumValueMapping) String() string { func (*EnumValueMapping) ProtoMessage() {} func (x *EnumValueMapping) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[47] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3637,7 +3773,7 @@ func (x *EnumValueMapping) ProtoReflect() protoreflect.Message { // Deprecated: Use EnumValueMapping.ProtoReflect.Descriptor instead. func (*EnumValueMapping) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{47} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{49} } func (x *EnumValueMapping) GetOriginal() string { @@ -3665,7 +3801,7 @@ type NatsStreamConfiguration struct { func (x *NatsStreamConfiguration) Reset() { *x = NatsStreamConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3677,7 +3813,7 @@ func (x *NatsStreamConfiguration) String() string { func (*NatsStreamConfiguration) ProtoMessage() {} func (x *NatsStreamConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[48] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3690,7 +3826,7 @@ func (x *NatsStreamConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use NatsStreamConfiguration.ProtoReflect.Descriptor instead. func (*NatsStreamConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{48} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{50} } func (x *NatsStreamConfiguration) GetConsumerName() string { @@ -3725,7 +3861,7 @@ type NatsEventConfiguration struct { func (x *NatsEventConfiguration) Reset() { *x = NatsEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3737,7 +3873,7 @@ func (x *NatsEventConfiguration) String() string { func (*NatsEventConfiguration) ProtoMessage() {} func (x *NatsEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[49] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3750,7 +3886,7 @@ func (x *NatsEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use NatsEventConfiguration.ProtoReflect.Descriptor instead. func (*NatsEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{49} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{51} } func (x *NatsEventConfiguration) GetEngineEventConfiguration() *EngineEventConfiguration { @@ -3784,7 +3920,7 @@ type KafkaEventConfiguration struct { func (x *KafkaEventConfiguration) Reset() { *x = KafkaEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3796,7 +3932,7 @@ func (x *KafkaEventConfiguration) String() string { func (*KafkaEventConfiguration) ProtoMessage() {} func (x *KafkaEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[50] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3809,7 +3945,7 @@ func (x *KafkaEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use KafkaEventConfiguration.ProtoReflect.Descriptor instead. func (*KafkaEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{50} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{52} } func (x *KafkaEventConfiguration) GetEngineEventConfiguration() *EngineEventConfiguration { @@ -3836,7 +3972,7 @@ type RedisEventConfiguration struct { func (x *RedisEventConfiguration) Reset() { *x = RedisEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3848,7 +3984,7 @@ func (x *RedisEventConfiguration) String() string { func (*RedisEventConfiguration) ProtoMessage() {} func (x *RedisEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[51] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3861,7 +3997,7 @@ func (x *RedisEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use RedisEventConfiguration.ProtoReflect.Descriptor instead. func (*RedisEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{51} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{53} } func (x *RedisEventConfiguration) GetEngineEventConfiguration() *EngineEventConfiguration { @@ -3890,7 +4026,7 @@ type EngineEventConfiguration struct { func (x *EngineEventConfiguration) Reset() { *x = EngineEventConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3902,7 +4038,7 @@ func (x *EngineEventConfiguration) String() string { func (*EngineEventConfiguration) ProtoMessage() {} func (x *EngineEventConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[52] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3915,7 +4051,7 @@ func (x *EngineEventConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use EngineEventConfiguration.ProtoReflect.Descriptor instead. func (*EngineEventConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{52} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{54} } func (x *EngineEventConfiguration) GetProviderId() string { @@ -3957,7 +4093,7 @@ type DataSourceCustomEvents struct { func (x *DataSourceCustomEvents) Reset() { *x = DataSourceCustomEvents{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -3969,7 +4105,7 @@ func (x *DataSourceCustomEvents) String() string { func (*DataSourceCustomEvents) ProtoMessage() {} func (x *DataSourceCustomEvents) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[53] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -3982,7 +4118,7 @@ func (x *DataSourceCustomEvents) ProtoReflect() protoreflect.Message { // Deprecated: Use DataSourceCustomEvents.ProtoReflect.Descriptor instead. func (*DataSourceCustomEvents) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{53} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{55} } func (x *DataSourceCustomEvents) GetNats() []*NatsEventConfiguration { @@ -4015,7 +4151,7 @@ type DataSourceCustom_Static struct { func (x *DataSourceCustom_Static) Reset() { *x = DataSourceCustom_Static{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4027,7 +4163,7 @@ func (x *DataSourceCustom_Static) String() string { func (*DataSourceCustom_Static) ProtoMessage() {} func (x *DataSourceCustom_Static) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[54] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4040,7 +4176,7 @@ func (x *DataSourceCustom_Static) ProtoReflect() protoreflect.Message { // Deprecated: Use DataSourceCustom_Static.ProtoReflect.Descriptor instead. func (*DataSourceCustom_Static) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{54} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{56} } func (x *DataSourceCustom_Static) GetData() *ConfigurationVariable { @@ -4063,7 +4199,7 @@ type ConfigurationVariable struct { func (x *ConfigurationVariable) Reset() { *x = ConfigurationVariable{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4075,7 +4211,7 @@ func (x *ConfigurationVariable) String() string { func (*ConfigurationVariable) ProtoMessage() {} func (x *ConfigurationVariable) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[55] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4088,7 +4224,7 @@ func (x *ConfigurationVariable) ProtoReflect() protoreflect.Message { // Deprecated: Use ConfigurationVariable.ProtoReflect.Descriptor instead. func (*ConfigurationVariable) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{55} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{57} } func (x *ConfigurationVariable) GetKind() ConfigurationVariableKind { @@ -4136,7 +4272,7 @@ type DirectiveConfiguration struct { func (x *DirectiveConfiguration) Reset() { *x = DirectiveConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4148,7 +4284,7 @@ func (x *DirectiveConfiguration) String() string { func (*DirectiveConfiguration) ProtoMessage() {} func (x *DirectiveConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[56] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4161,7 +4297,7 @@ func (x *DirectiveConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use DirectiveConfiguration.ProtoReflect.Descriptor instead. func (*DirectiveConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{56} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{58} } func (x *DirectiveConfiguration) GetDirectiveName() string { @@ -4188,7 +4324,7 @@ type URLQueryConfiguration struct { func (x *URLQueryConfiguration) Reset() { *x = URLQueryConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4200,7 +4336,7 @@ func (x *URLQueryConfiguration) String() string { func (*URLQueryConfiguration) ProtoMessage() {} func (x *URLQueryConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[57] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4213,7 +4349,7 @@ func (x *URLQueryConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use URLQueryConfiguration.ProtoReflect.Descriptor instead. func (*URLQueryConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{57} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{59} } func (x *URLQueryConfiguration) GetName() string { @@ -4239,7 +4375,7 @@ type HTTPHeader struct { func (x *HTTPHeader) Reset() { *x = HTTPHeader{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4251,7 +4387,7 @@ func (x *HTTPHeader) String() string { func (*HTTPHeader) ProtoMessage() {} func (x *HTTPHeader) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[58] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4264,7 +4400,7 @@ func (x *HTTPHeader) ProtoReflect() protoreflect.Message { // Deprecated: Use HTTPHeader.ProtoReflect.Descriptor instead. func (*HTTPHeader) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{58} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{60} } func (x *HTTPHeader) GetValues() []*ConfigurationVariable { @@ -4285,7 +4421,7 @@ type MTLSConfiguration struct { func (x *MTLSConfiguration) Reset() { *x = MTLSConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4297,7 +4433,7 @@ func (x *MTLSConfiguration) String() string { func (*MTLSConfiguration) ProtoMessage() {} func (x *MTLSConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[59] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4310,7 +4446,7 @@ func (x *MTLSConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use MTLSConfiguration.ProtoReflect.Descriptor instead. func (*MTLSConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{59} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{61} } func (x *MTLSConfiguration) GetKey() *ConfigurationVariable { @@ -4348,7 +4484,7 @@ type GraphQLSubscriptionConfiguration struct { func (x *GraphQLSubscriptionConfiguration) Reset() { *x = GraphQLSubscriptionConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4360,7 +4496,7 @@ func (x *GraphQLSubscriptionConfiguration) String() string { func (*GraphQLSubscriptionConfiguration) ProtoMessage() {} func (x *GraphQLSubscriptionConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[60] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4373,7 +4509,7 @@ func (x *GraphQLSubscriptionConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use GraphQLSubscriptionConfiguration.ProtoReflect.Descriptor instead. func (*GraphQLSubscriptionConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{60} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{62} } func (x *GraphQLSubscriptionConfiguration) GetEnabled() bool { @@ -4421,7 +4557,7 @@ type GraphQLFederationConfiguration struct { func (x *GraphQLFederationConfiguration) Reset() { *x = GraphQLFederationConfiguration{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4433,7 +4569,7 @@ func (x *GraphQLFederationConfiguration) String() string { func (*GraphQLFederationConfiguration) ProtoMessage() {} func (x *GraphQLFederationConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[61] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4446,7 +4582,7 @@ func (x *GraphQLFederationConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use GraphQLFederationConfiguration.ProtoReflect.Descriptor instead. func (*GraphQLFederationConfiguration) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{61} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{63} } func (x *GraphQLFederationConfiguration) GetEnabled() bool { @@ -4473,7 +4609,7 @@ type InternedString struct { func (x *InternedString) Reset() { *x = InternedString{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4485,7 +4621,7 @@ func (x *InternedString) String() string { func (*InternedString) ProtoMessage() {} func (x *InternedString) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[62] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4498,7 +4634,7 @@ func (x *InternedString) ProtoReflect() protoreflect.Message { // Deprecated: Use InternedString.ProtoReflect.Descriptor instead. func (*InternedString) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{62} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{64} } func (x *InternedString) GetKey() string { @@ -4518,7 +4654,7 @@ type SingleTypeField struct { func (x *SingleTypeField) Reset() { *x = SingleTypeField{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4530,7 +4666,7 @@ func (x *SingleTypeField) String() string { func (*SingleTypeField) ProtoMessage() {} func (x *SingleTypeField) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[63] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4543,7 +4679,7 @@ func (x *SingleTypeField) ProtoReflect() protoreflect.Message { // Deprecated: Use SingleTypeField.ProtoReflect.Descriptor instead. func (*SingleTypeField) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{63} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{65} } func (x *SingleTypeField) GetTypeName() string { @@ -4570,7 +4706,7 @@ type SubscriptionFieldCondition struct { func (x *SubscriptionFieldCondition) Reset() { *x = SubscriptionFieldCondition{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4582,7 +4718,7 @@ func (x *SubscriptionFieldCondition) String() string { func (*SubscriptionFieldCondition) ProtoMessage() {} func (x *SubscriptionFieldCondition) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[64] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4595,7 +4731,7 @@ func (x *SubscriptionFieldCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use SubscriptionFieldCondition.ProtoReflect.Descriptor instead. func (*SubscriptionFieldCondition) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{64} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{66} } func (x *SubscriptionFieldCondition) GetFieldPath() []string { @@ -4624,7 +4760,7 @@ type SubscriptionFilterCondition struct { func (x *SubscriptionFilterCondition) Reset() { *x = SubscriptionFilterCondition{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4636,7 +4772,7 @@ func (x *SubscriptionFilterCondition) String() string { func (*SubscriptionFilterCondition) ProtoMessage() {} func (x *SubscriptionFilterCondition) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[65] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4649,7 +4785,7 @@ func (x *SubscriptionFilterCondition) ProtoReflect() protoreflect.Message { // Deprecated: Use SubscriptionFilterCondition.ProtoReflect.Descriptor instead. func (*SubscriptionFilterCondition) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{65} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{67} } func (x *SubscriptionFilterCondition) GetAnd() []*SubscriptionFilterCondition { @@ -4689,7 +4825,7 @@ type CacheWarmerOperations struct { func (x *CacheWarmerOperations) Reset() { *x = CacheWarmerOperations{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4701,7 +4837,7 @@ func (x *CacheWarmerOperations) String() string { func (*CacheWarmerOperations) ProtoMessage() {} func (x *CacheWarmerOperations) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[66] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4714,7 +4850,7 @@ func (x *CacheWarmerOperations) ProtoReflect() protoreflect.Message { // Deprecated: Use CacheWarmerOperations.ProtoReflect.Descriptor instead. func (*CacheWarmerOperations) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{66} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{68} } func (x *CacheWarmerOperations) GetOperations() []*Operation { @@ -4734,7 +4870,7 @@ type Operation struct { func (x *Operation) Reset() { *x = Operation{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4746,7 +4882,7 @@ func (x *Operation) String() string { func (*Operation) ProtoMessage() {} func (x *Operation) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[67] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4759,7 +4895,7 @@ func (x *Operation) ProtoReflect() protoreflect.Message { // Deprecated: Use Operation.ProtoReflect.Descriptor instead. func (*Operation) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{67} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{69} } func (x *Operation) GetRequest() *OperationRequest { @@ -4787,7 +4923,7 @@ type OperationRequest struct { func (x *OperationRequest) Reset() { *x = OperationRequest{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4799,7 +4935,7 @@ func (x *OperationRequest) String() string { func (*OperationRequest) ProtoMessage() {} func (x *OperationRequest) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[68] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4812,7 +4948,7 @@ func (x *OperationRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use OperationRequest.ProtoReflect.Descriptor instead. func (*OperationRequest) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{68} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{70} } func (x *OperationRequest) GetOperationName() string { @@ -4845,7 +4981,7 @@ type Extension struct { func (x *Extension) Reset() { *x = Extension{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4857,7 +4993,7 @@ func (x *Extension) String() string { func (*Extension) ProtoMessage() {} func (x *Extension) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[69] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4870,7 +5006,7 @@ func (x *Extension) ProtoReflect() protoreflect.Message { // Deprecated: Use Extension.ProtoReflect.Descriptor instead. func (*Extension) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{69} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{71} } func (x *Extension) GetPersistedQuery() *PersistedQuery { @@ -4890,7 +5026,7 @@ type PersistedQuery struct { func (x *PersistedQuery) Reset() { *x = PersistedQuery{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[72] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4902,7 +5038,7 @@ func (x *PersistedQuery) String() string { func (*PersistedQuery) ProtoMessage() {} func (x *PersistedQuery) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[70] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[72] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4915,7 +5051,7 @@ func (x *PersistedQuery) ProtoReflect() protoreflect.Message { // Deprecated: Use PersistedQuery.ProtoReflect.Descriptor instead. func (*PersistedQuery) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{70} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{72} } func (x *PersistedQuery) GetSha256Hash() string { @@ -4942,7 +5078,7 @@ type ClientInfo struct { func (x *ClientInfo) Reset() { *x = ClientInfo{} - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[73] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -4954,7 +5090,7 @@ func (x *ClientInfo) String() string { func (*ClientInfo) ProtoMessage() {} func (x *ClientInfo) ProtoReflect() protoreflect.Message { - mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[71] + mi := &file_wg_cosmo_node_v1_node_proto_msgTypes[73] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -4967,7 +5103,7 @@ func (x *ClientInfo) ProtoReflect() protoreflect.Message { // Deprecated: Use ClientInfo.ProtoReflect.Descriptor instead. func (*ClientInfo) Descriptor() ([]byte, []int) { - return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{71} + return file_wg_cosmo_node_v1_node_proto_rawDescGZIP(), []int{73} } func (x *ClientInfo) GetName() string { @@ -5062,12 +5198,12 @@ const file_wg_cosmo_node_v1_node_proto_rawDesc = "" + "\x11entity_interfaces\x18\x0e \x03(\v2..wg.cosmo.node.v1.EntityInterfaceConfigurationR\x10entityInterfaces\x12[\n" + "\x11interface_objects\x18\x0f \x03(\v2..wg.cosmo.node.v1.EntityInterfaceConfigurationR\x10interfaceObjects\x12R\n" + "\x12cost_configuration\x18\x10 \x01(\v2#.wg.cosmo.node.v1.CostConfigurationR\x11costConfiguration\x12n\n" + - "\x1centity_caching_configuration\x18\x11 \x01(\v2,.wg.cosmo.node.v1.EntityCachingConfigurationR\x1aentityCachingConfiguration\"\xc7\x03\n" + + "\x1centity_caching_configuration\x18\x11 \x01(\v2,.wg.cosmo.node.v1.EntityCachingConfigurationR\x1aentityCachingConfiguration\"\xbe\x03\n" + "\x1aEntityCachingConfiguration\x12M\n" + "\fentity_cache\x18\x01 \x03(\v2*.wg.cosmo.node.v1.EntityCacheConfigurationR\ventityCache\x12v\n" + "\x1fcache_invalidate_configurations\x18\x02 \x03(\v2..wg.cosmo.node.v1.CacheInvalidateConfigurationR\x1dcacheInvalidateConfigurations\x12p\n" + - "\x1dcache_populate_configurations\x18\x03 \x03(\v2,.wg.cosmo.node.v1.CachePopulateConfigurationR\x1bcachePopulateConfigurations\x12p\n" + - "\x1drequest_scoped_configurations\x18\x04 \x03(\v2,.wg.cosmo.node.v1.RequestScopedConfigurationR\x1brequestScopedConfigurations\"\x95\x02\n" + + "\x1dcache_populate_configurations\x18\x03 \x03(\v2,.wg.cosmo.node.v1.CachePopulateConfigurationR\x1bcachePopulateConfigurations\x12g\n" + + "\x1aquery_cache_configurations\x18\x05 \x03(\v2).wg.cosmo.node.v1.QueryCacheConfigurationR\x18queryCacheConfigurations\"\x95\x02\n" + "\x18EntityCacheConfiguration\x12\x1b\n" + "\ttype_name\x18\x01 \x01(\tR\btypeName\x12&\n" + "\x0fmax_age_seconds\x18\x02 \x01(\x03R\rmaxAgeSeconds\x12'\n" + @@ -5086,12 +5222,23 @@ const file_wg_cosmo_node_v1_node_proto_rawDesc = "" + "field_name\x18\x01 \x01(\tR\tfieldName\x12%\n" + "\x0eoperation_type\x18\x02 \x01(\tR\roperationType\x12&\n" + "\x0fmax_age_seconds\x18\x03 \x01(\x03R\rmaxAgeSeconds\x12(\n" + - "\x10entity_type_name\x18\x04 \x01(\tR\x0eentityTypeName\"o\n" + - "\x1aRequestScopedConfiguration\x12\x1d\n" + + "\x10entity_type_name\x18\x04 \x01(\tR\x0eentityTypeName\"\xa8\x02\n" + + "\x17QueryCacheConfiguration\x12\x1d\n" + "\n" + - "field_name\x18\x01 \x01(\tR\tfieldName\x12\x1b\n" + - "\ttype_name\x18\x02 \x01(\tR\btypeName\x12\x15\n" + - "\x06l1_key\x18\x03 \x01(\tR\x05l1Key\"\x98\x04\n" + + "field_name\x18\x01 \x01(\tR\tfieldName\x12&\n" + + "\x0fmax_age_seconds\x18\x02 \x01(\x03R\rmaxAgeSeconds\x12'\n" + + "\x0finclude_headers\x18\x03 \x01(\bR\x0eincludeHeaders\x12\x1f\n" + + "\vshadow_mode\x18\x04 \x01(\bR\n" + + "shadowMode\x12(\n" + + "\x10entity_type_name\x18\x05 \x01(\tR\x0eentityTypeName\x12R\n" + + "\x13entity_key_mappings\x18\x06 \x03(\v2\".wg.cosmo.node.v1.EntityKeyMappingR\x11entityKeyMappings\"\x8e\x01\n" + + "\x10EntityKeyMapping\x12(\n" + + "\x10entity_type_name\x18\x01 \x01(\tR\x0eentityTypeName\x12P\n" + + "\x0efield_mappings\x18\x02 \x03(\v2).wg.cosmo.node.v1.EntityCacheFieldMappingR\rfieldMappings\"\x83\x01\n" + + "\x17EntityCacheFieldMapping\x12(\n" + + "\x10entity_key_field\x18\x01 \x01(\tR\x0eentityKeyField\x12#\n" + + "\rargument_path\x18\x02 \x03(\tR\fargumentPath\x12\x19\n" + + "\bis_batch\x18\x03 \x01(\bR\aisBatch\"\x98\x04\n" + "\x11CostConfiguration\x12O\n" + "\rfield_weights\x18\x01 \x03(\v2*.wg.cosmo.node.v1.FieldWeightConfigurationR\ffieldWeights\x12K\n" + "\n" + @@ -5430,7 +5577,7 @@ func file_wg_cosmo_node_v1_node_proto_rawDescGZIP() []byte { } var file_wg_cosmo_node_v1_node_proto_enumTypes = make([]protoimpl.EnumInfo, 8) -var file_wg_cosmo_node_v1_node_proto_msgTypes = make([]protoimpl.MessageInfo, 79) +var file_wg_cosmo_node_v1_node_proto_msgTypes = make([]protoimpl.MessageInfo, 81) var file_wg_cosmo_node_v1_node_proto_goTypes = []any{ (ArgumentRenderConfiguration)(0), // 0: wg.cosmo.node.v1.ArgumentRenderConfiguration (ArgumentSource)(0), // 1: wg.cosmo.node.v1.ArgumentSource @@ -5456,186 +5603,190 @@ var file_wg_cosmo_node_v1_node_proto_goTypes = []any{ (*EntityCacheConfiguration)(nil), // 21: wg.cosmo.node.v1.EntityCacheConfiguration (*CacheInvalidateConfiguration)(nil), // 22: wg.cosmo.node.v1.CacheInvalidateConfiguration (*CachePopulateConfiguration)(nil), // 23: wg.cosmo.node.v1.CachePopulateConfiguration - (*RequestScopedConfiguration)(nil), // 24: wg.cosmo.node.v1.RequestScopedConfiguration - (*CostConfiguration)(nil), // 25: wg.cosmo.node.v1.CostConfiguration - (*FieldWeightConfiguration)(nil), // 26: wg.cosmo.node.v1.FieldWeightConfiguration - (*FieldListSizeConfiguration)(nil), // 27: wg.cosmo.node.v1.FieldListSizeConfiguration - (*ArgumentConfiguration)(nil), // 28: wg.cosmo.node.v1.ArgumentConfiguration - (*Scopes)(nil), // 29: wg.cosmo.node.v1.Scopes - (*AuthorizationConfiguration)(nil), // 30: wg.cosmo.node.v1.AuthorizationConfiguration - (*FieldConfiguration)(nil), // 31: wg.cosmo.node.v1.FieldConfiguration - (*TypeConfiguration)(nil), // 32: wg.cosmo.node.v1.TypeConfiguration - (*TypeField)(nil), // 33: wg.cosmo.node.v1.TypeField - (*FieldCoordinates)(nil), // 34: wg.cosmo.node.v1.FieldCoordinates - (*FieldSetCondition)(nil), // 35: wg.cosmo.node.v1.FieldSetCondition - (*RequiredField)(nil), // 36: wg.cosmo.node.v1.RequiredField - (*EntityInterfaceConfiguration)(nil), // 37: wg.cosmo.node.v1.EntityInterfaceConfiguration - (*FetchConfiguration)(nil), // 38: wg.cosmo.node.v1.FetchConfiguration - (*StatusCodeTypeMapping)(nil), // 39: wg.cosmo.node.v1.StatusCodeTypeMapping - (*DataSourceCustom_GraphQL)(nil), // 40: wg.cosmo.node.v1.DataSourceCustom_GraphQL - (*GRPCConfiguration)(nil), // 41: wg.cosmo.node.v1.GRPCConfiguration - (*ImageReference)(nil), // 42: wg.cosmo.node.v1.ImageReference - (*PluginConfiguration)(nil), // 43: wg.cosmo.node.v1.PluginConfiguration - (*SSLConfiguration)(nil), // 44: wg.cosmo.node.v1.SSLConfiguration - (*GRPCMapping)(nil), // 45: wg.cosmo.node.v1.GRPCMapping - (*LookupMapping)(nil), // 46: wg.cosmo.node.v1.LookupMapping - (*LookupFieldMapping)(nil), // 47: wg.cosmo.node.v1.LookupFieldMapping - (*OperationMapping)(nil), // 48: wg.cosmo.node.v1.OperationMapping - (*EntityMapping)(nil), // 49: wg.cosmo.node.v1.EntityMapping - (*RequiredFieldMapping)(nil), // 50: wg.cosmo.node.v1.RequiredFieldMapping - (*TypeFieldMapping)(nil), // 51: wg.cosmo.node.v1.TypeFieldMapping - (*FieldMapping)(nil), // 52: wg.cosmo.node.v1.FieldMapping - (*ArgumentMapping)(nil), // 53: wg.cosmo.node.v1.ArgumentMapping - (*EnumMapping)(nil), // 54: wg.cosmo.node.v1.EnumMapping - (*EnumValueMapping)(nil), // 55: wg.cosmo.node.v1.EnumValueMapping - (*NatsStreamConfiguration)(nil), // 56: wg.cosmo.node.v1.NatsStreamConfiguration - (*NatsEventConfiguration)(nil), // 57: wg.cosmo.node.v1.NatsEventConfiguration - (*KafkaEventConfiguration)(nil), // 58: wg.cosmo.node.v1.KafkaEventConfiguration - (*RedisEventConfiguration)(nil), // 59: wg.cosmo.node.v1.RedisEventConfiguration - (*EngineEventConfiguration)(nil), // 60: wg.cosmo.node.v1.EngineEventConfiguration - (*DataSourceCustomEvents)(nil), // 61: wg.cosmo.node.v1.DataSourceCustomEvents - (*DataSourceCustom_Static)(nil), // 62: wg.cosmo.node.v1.DataSourceCustom_Static - (*ConfigurationVariable)(nil), // 63: wg.cosmo.node.v1.ConfigurationVariable - (*DirectiveConfiguration)(nil), // 64: wg.cosmo.node.v1.DirectiveConfiguration - (*URLQueryConfiguration)(nil), // 65: wg.cosmo.node.v1.URLQueryConfiguration - (*HTTPHeader)(nil), // 66: wg.cosmo.node.v1.HTTPHeader - (*MTLSConfiguration)(nil), // 67: wg.cosmo.node.v1.MTLSConfiguration - (*GraphQLSubscriptionConfiguration)(nil), // 68: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration - (*GraphQLFederationConfiguration)(nil), // 69: wg.cosmo.node.v1.GraphQLFederationConfiguration - (*InternedString)(nil), // 70: wg.cosmo.node.v1.InternedString - (*SingleTypeField)(nil), // 71: wg.cosmo.node.v1.SingleTypeField - (*SubscriptionFieldCondition)(nil), // 72: wg.cosmo.node.v1.SubscriptionFieldCondition - (*SubscriptionFilterCondition)(nil), // 73: wg.cosmo.node.v1.SubscriptionFilterCondition - (*CacheWarmerOperations)(nil), // 74: wg.cosmo.node.v1.CacheWarmerOperations - (*Operation)(nil), // 75: wg.cosmo.node.v1.Operation - (*OperationRequest)(nil), // 76: wg.cosmo.node.v1.OperationRequest - (*Extension)(nil), // 77: wg.cosmo.node.v1.Extension - (*PersistedQuery)(nil), // 78: wg.cosmo.node.v1.PersistedQuery - (*ClientInfo)(nil), // 79: wg.cosmo.node.v1.ClientInfo - nil, // 80: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry - nil, // 81: wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry - nil, // 82: wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry - nil, // 83: wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry - nil, // 84: wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry - nil, // 85: wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry - nil, // 86: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry - (common.EnumStatusCode)(0), // 87: wg.cosmo.common.EnumStatusCode - (common.GraphQLSubscriptionProtocol)(0), // 88: wg.cosmo.common.GraphQLSubscriptionProtocol - (common.GraphQLWebsocketSubprotocol)(0), // 89: wg.cosmo.common.GraphQLWebsocketSubprotocol + (*QueryCacheConfiguration)(nil), // 24: wg.cosmo.node.v1.QueryCacheConfiguration + (*EntityKeyMapping)(nil), // 25: wg.cosmo.node.v1.EntityKeyMapping + (*EntityCacheFieldMapping)(nil), // 26: wg.cosmo.node.v1.EntityCacheFieldMapping + (*CostConfiguration)(nil), // 27: wg.cosmo.node.v1.CostConfiguration + (*FieldWeightConfiguration)(nil), // 28: wg.cosmo.node.v1.FieldWeightConfiguration + (*FieldListSizeConfiguration)(nil), // 29: wg.cosmo.node.v1.FieldListSizeConfiguration + (*ArgumentConfiguration)(nil), // 30: wg.cosmo.node.v1.ArgumentConfiguration + (*Scopes)(nil), // 31: wg.cosmo.node.v1.Scopes + (*AuthorizationConfiguration)(nil), // 32: wg.cosmo.node.v1.AuthorizationConfiguration + (*FieldConfiguration)(nil), // 33: wg.cosmo.node.v1.FieldConfiguration + (*TypeConfiguration)(nil), // 34: wg.cosmo.node.v1.TypeConfiguration + (*TypeField)(nil), // 35: wg.cosmo.node.v1.TypeField + (*FieldCoordinates)(nil), // 36: wg.cosmo.node.v1.FieldCoordinates + (*FieldSetCondition)(nil), // 37: wg.cosmo.node.v1.FieldSetCondition + (*RequiredField)(nil), // 38: wg.cosmo.node.v1.RequiredField + (*EntityInterfaceConfiguration)(nil), // 39: wg.cosmo.node.v1.EntityInterfaceConfiguration + (*FetchConfiguration)(nil), // 40: wg.cosmo.node.v1.FetchConfiguration + (*StatusCodeTypeMapping)(nil), // 41: wg.cosmo.node.v1.StatusCodeTypeMapping + (*DataSourceCustom_GraphQL)(nil), // 42: wg.cosmo.node.v1.DataSourceCustom_GraphQL + (*GRPCConfiguration)(nil), // 43: wg.cosmo.node.v1.GRPCConfiguration + (*ImageReference)(nil), // 44: wg.cosmo.node.v1.ImageReference + (*PluginConfiguration)(nil), // 45: wg.cosmo.node.v1.PluginConfiguration + (*SSLConfiguration)(nil), // 46: wg.cosmo.node.v1.SSLConfiguration + (*GRPCMapping)(nil), // 47: wg.cosmo.node.v1.GRPCMapping + (*LookupMapping)(nil), // 48: wg.cosmo.node.v1.LookupMapping + (*LookupFieldMapping)(nil), // 49: wg.cosmo.node.v1.LookupFieldMapping + (*OperationMapping)(nil), // 50: wg.cosmo.node.v1.OperationMapping + (*EntityMapping)(nil), // 51: wg.cosmo.node.v1.EntityMapping + (*RequiredFieldMapping)(nil), // 52: wg.cosmo.node.v1.RequiredFieldMapping + (*TypeFieldMapping)(nil), // 53: wg.cosmo.node.v1.TypeFieldMapping + (*FieldMapping)(nil), // 54: wg.cosmo.node.v1.FieldMapping + (*ArgumentMapping)(nil), // 55: wg.cosmo.node.v1.ArgumentMapping + (*EnumMapping)(nil), // 56: wg.cosmo.node.v1.EnumMapping + (*EnumValueMapping)(nil), // 57: wg.cosmo.node.v1.EnumValueMapping + (*NatsStreamConfiguration)(nil), // 58: wg.cosmo.node.v1.NatsStreamConfiguration + (*NatsEventConfiguration)(nil), // 59: wg.cosmo.node.v1.NatsEventConfiguration + (*KafkaEventConfiguration)(nil), // 60: wg.cosmo.node.v1.KafkaEventConfiguration + (*RedisEventConfiguration)(nil), // 61: wg.cosmo.node.v1.RedisEventConfiguration + (*EngineEventConfiguration)(nil), // 62: wg.cosmo.node.v1.EngineEventConfiguration + (*DataSourceCustomEvents)(nil), // 63: wg.cosmo.node.v1.DataSourceCustomEvents + (*DataSourceCustom_Static)(nil), // 64: wg.cosmo.node.v1.DataSourceCustom_Static + (*ConfigurationVariable)(nil), // 65: wg.cosmo.node.v1.ConfigurationVariable + (*DirectiveConfiguration)(nil), // 66: wg.cosmo.node.v1.DirectiveConfiguration + (*URLQueryConfiguration)(nil), // 67: wg.cosmo.node.v1.URLQueryConfiguration + (*HTTPHeader)(nil), // 68: wg.cosmo.node.v1.HTTPHeader + (*MTLSConfiguration)(nil), // 69: wg.cosmo.node.v1.MTLSConfiguration + (*GraphQLSubscriptionConfiguration)(nil), // 70: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration + (*GraphQLFederationConfiguration)(nil), // 71: wg.cosmo.node.v1.GraphQLFederationConfiguration + (*InternedString)(nil), // 72: wg.cosmo.node.v1.InternedString + (*SingleTypeField)(nil), // 73: wg.cosmo.node.v1.SingleTypeField + (*SubscriptionFieldCondition)(nil), // 74: wg.cosmo.node.v1.SubscriptionFieldCondition + (*SubscriptionFilterCondition)(nil), // 75: wg.cosmo.node.v1.SubscriptionFilterCondition + (*CacheWarmerOperations)(nil), // 76: wg.cosmo.node.v1.CacheWarmerOperations + (*Operation)(nil), // 77: wg.cosmo.node.v1.Operation + (*OperationRequest)(nil), // 78: wg.cosmo.node.v1.OperationRequest + (*Extension)(nil), // 79: wg.cosmo.node.v1.Extension + (*PersistedQuery)(nil), // 80: wg.cosmo.node.v1.PersistedQuery + (*ClientInfo)(nil), // 81: wg.cosmo.node.v1.ClientInfo + nil, // 82: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry + nil, // 83: wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry + nil, // 84: wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry + nil, // 85: wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry + nil, // 86: wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry + nil, // 87: wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry + nil, // 88: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry + (common.EnumStatusCode)(0), // 89: wg.cosmo.common.EnumStatusCode + (common.GraphQLSubscriptionProtocol)(0), // 90: wg.cosmo.common.GraphQLSubscriptionProtocol + (common.GraphQLWebsocketSubprotocol)(0), // 91: wg.cosmo.common.GraphQLWebsocketSubprotocol } var file_wg_cosmo_node_v1_node_proto_depIdxs = []int32{ - 80, // 0: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.config_by_feature_flag_name:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry + 82, // 0: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.config_by_feature_flag_name:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry 18, // 1: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig.engine_config:type_name -> wg.cosmo.node.v1.EngineConfiguration 8, // 2: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig.subgraphs:type_name -> wg.cosmo.node.v1.Subgraph 18, // 3: wg.cosmo.node.v1.RouterConfig.engine_config:type_name -> wg.cosmo.node.v1.EngineConfiguration 8, // 4: wg.cosmo.node.v1.RouterConfig.subgraphs:type_name -> wg.cosmo.node.v1.Subgraph 9, // 5: wg.cosmo.node.v1.RouterConfig.feature_flag_configs:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs - 87, // 6: wg.cosmo.node.v1.Response.code:type_name -> wg.cosmo.common.EnumStatusCode + 89, // 6: wg.cosmo.node.v1.Response.code:type_name -> wg.cosmo.common.EnumStatusCode 15, // 7: wg.cosmo.node.v1.RegistrationInfo.account_limits:type_name -> wg.cosmo.node.v1.AccountLimits 12, // 8: wg.cosmo.node.v1.SelfRegisterResponse.response:type_name -> wg.cosmo.node.v1.Response 14, // 9: wg.cosmo.node.v1.SelfRegisterResponse.registrationInfo:type_name -> wg.cosmo.node.v1.RegistrationInfo 19, // 10: wg.cosmo.node.v1.EngineConfiguration.datasource_configurations:type_name -> wg.cosmo.node.v1.DataSourceConfiguration - 31, // 11: wg.cosmo.node.v1.EngineConfiguration.field_configurations:type_name -> wg.cosmo.node.v1.FieldConfiguration - 32, // 12: wg.cosmo.node.v1.EngineConfiguration.type_configurations:type_name -> wg.cosmo.node.v1.TypeConfiguration - 81, // 13: wg.cosmo.node.v1.EngineConfiguration.string_storage:type_name -> wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry + 33, // 11: wg.cosmo.node.v1.EngineConfiguration.field_configurations:type_name -> wg.cosmo.node.v1.FieldConfiguration + 34, // 12: wg.cosmo.node.v1.EngineConfiguration.type_configurations:type_name -> wg.cosmo.node.v1.TypeConfiguration + 83, // 13: wg.cosmo.node.v1.EngineConfiguration.string_storage:type_name -> wg.cosmo.node.v1.EngineConfiguration.StringStorageEntry 2, // 14: wg.cosmo.node.v1.DataSourceConfiguration.kind:type_name -> wg.cosmo.node.v1.DataSourceKind - 33, // 15: wg.cosmo.node.v1.DataSourceConfiguration.root_nodes:type_name -> wg.cosmo.node.v1.TypeField - 33, // 16: wg.cosmo.node.v1.DataSourceConfiguration.child_nodes:type_name -> wg.cosmo.node.v1.TypeField - 40, // 17: wg.cosmo.node.v1.DataSourceConfiguration.custom_graphql:type_name -> wg.cosmo.node.v1.DataSourceCustom_GraphQL - 62, // 18: wg.cosmo.node.v1.DataSourceConfiguration.custom_static:type_name -> wg.cosmo.node.v1.DataSourceCustom_Static - 64, // 19: wg.cosmo.node.v1.DataSourceConfiguration.directives:type_name -> wg.cosmo.node.v1.DirectiveConfiguration - 36, // 20: wg.cosmo.node.v1.DataSourceConfiguration.keys:type_name -> wg.cosmo.node.v1.RequiredField - 36, // 21: wg.cosmo.node.v1.DataSourceConfiguration.provides:type_name -> wg.cosmo.node.v1.RequiredField - 36, // 22: wg.cosmo.node.v1.DataSourceConfiguration.requires:type_name -> wg.cosmo.node.v1.RequiredField - 61, // 23: wg.cosmo.node.v1.DataSourceConfiguration.custom_events:type_name -> wg.cosmo.node.v1.DataSourceCustomEvents - 37, // 24: wg.cosmo.node.v1.DataSourceConfiguration.entity_interfaces:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration - 37, // 25: wg.cosmo.node.v1.DataSourceConfiguration.interface_objects:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration - 25, // 26: wg.cosmo.node.v1.DataSourceConfiguration.cost_configuration:type_name -> wg.cosmo.node.v1.CostConfiguration + 35, // 15: wg.cosmo.node.v1.DataSourceConfiguration.root_nodes:type_name -> wg.cosmo.node.v1.TypeField + 35, // 16: wg.cosmo.node.v1.DataSourceConfiguration.child_nodes:type_name -> wg.cosmo.node.v1.TypeField + 42, // 17: wg.cosmo.node.v1.DataSourceConfiguration.custom_graphql:type_name -> wg.cosmo.node.v1.DataSourceCustom_GraphQL + 64, // 18: wg.cosmo.node.v1.DataSourceConfiguration.custom_static:type_name -> wg.cosmo.node.v1.DataSourceCustom_Static + 66, // 19: wg.cosmo.node.v1.DataSourceConfiguration.directives:type_name -> wg.cosmo.node.v1.DirectiveConfiguration + 38, // 20: wg.cosmo.node.v1.DataSourceConfiguration.keys:type_name -> wg.cosmo.node.v1.RequiredField + 38, // 21: wg.cosmo.node.v1.DataSourceConfiguration.provides:type_name -> wg.cosmo.node.v1.RequiredField + 38, // 22: wg.cosmo.node.v1.DataSourceConfiguration.requires:type_name -> wg.cosmo.node.v1.RequiredField + 63, // 23: wg.cosmo.node.v1.DataSourceConfiguration.custom_events:type_name -> wg.cosmo.node.v1.DataSourceCustomEvents + 39, // 24: wg.cosmo.node.v1.DataSourceConfiguration.entity_interfaces:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration + 39, // 25: wg.cosmo.node.v1.DataSourceConfiguration.interface_objects:type_name -> wg.cosmo.node.v1.EntityInterfaceConfiguration + 27, // 26: wg.cosmo.node.v1.DataSourceConfiguration.cost_configuration:type_name -> wg.cosmo.node.v1.CostConfiguration 20, // 27: wg.cosmo.node.v1.DataSourceConfiguration.entity_caching_configuration:type_name -> wg.cosmo.node.v1.EntityCachingConfiguration 21, // 28: wg.cosmo.node.v1.EntityCachingConfiguration.entity_cache:type_name -> wg.cosmo.node.v1.EntityCacheConfiguration 22, // 29: wg.cosmo.node.v1.EntityCachingConfiguration.cache_invalidate_configurations:type_name -> wg.cosmo.node.v1.CacheInvalidateConfiguration 23, // 30: wg.cosmo.node.v1.EntityCachingConfiguration.cache_populate_configurations:type_name -> wg.cosmo.node.v1.CachePopulateConfiguration - 24, // 31: wg.cosmo.node.v1.EntityCachingConfiguration.request_scoped_configurations:type_name -> wg.cosmo.node.v1.RequestScopedConfiguration - 26, // 32: wg.cosmo.node.v1.CostConfiguration.field_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration - 27, // 33: wg.cosmo.node.v1.CostConfiguration.list_sizes:type_name -> wg.cosmo.node.v1.FieldListSizeConfiguration - 82, // 34: wg.cosmo.node.v1.CostConfiguration.type_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry - 83, // 35: wg.cosmo.node.v1.CostConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry - 84, // 36: wg.cosmo.node.v1.FieldWeightConfiguration.argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry - 85, // 37: wg.cosmo.node.v1.FieldWeightConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry - 1, // 38: wg.cosmo.node.v1.ArgumentConfiguration.source_type:type_name -> wg.cosmo.node.v1.ArgumentSource - 29, // 39: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes:type_name -> wg.cosmo.node.v1.Scopes - 29, // 40: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes_by_or:type_name -> wg.cosmo.node.v1.Scopes - 28, // 41: wg.cosmo.node.v1.FieldConfiguration.arguments_configuration:type_name -> wg.cosmo.node.v1.ArgumentConfiguration - 30, // 42: wg.cosmo.node.v1.FieldConfiguration.authorization_configuration:type_name -> wg.cosmo.node.v1.AuthorizationConfiguration - 73, // 43: wg.cosmo.node.v1.FieldConfiguration.subscription_filter_condition:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 34, // 44: wg.cosmo.node.v1.FieldSetCondition.field_coordinates_path:type_name -> wg.cosmo.node.v1.FieldCoordinates - 35, // 45: wg.cosmo.node.v1.RequiredField.conditions:type_name -> wg.cosmo.node.v1.FieldSetCondition - 63, // 46: wg.cosmo.node.v1.FetchConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 7, // 47: wg.cosmo.node.v1.FetchConfiguration.method:type_name -> wg.cosmo.node.v1.HTTPMethod - 86, // 48: wg.cosmo.node.v1.FetchConfiguration.header:type_name -> wg.cosmo.node.v1.FetchConfiguration.HeaderEntry - 63, // 49: wg.cosmo.node.v1.FetchConfiguration.body:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 65, // 50: wg.cosmo.node.v1.FetchConfiguration.query:type_name -> wg.cosmo.node.v1.URLQueryConfiguration - 67, // 51: wg.cosmo.node.v1.FetchConfiguration.mtls:type_name -> wg.cosmo.node.v1.MTLSConfiguration - 63, // 52: wg.cosmo.node.v1.FetchConfiguration.base_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 53: wg.cosmo.node.v1.FetchConfiguration.path:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 54: wg.cosmo.node.v1.FetchConfiguration.http_proxy_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 38, // 55: wg.cosmo.node.v1.DataSourceCustom_GraphQL.fetch:type_name -> wg.cosmo.node.v1.FetchConfiguration - 68, // 56: wg.cosmo.node.v1.DataSourceCustom_GraphQL.subscription:type_name -> wg.cosmo.node.v1.GraphQLSubscriptionConfiguration - 69, // 57: wg.cosmo.node.v1.DataSourceCustom_GraphQL.federation:type_name -> wg.cosmo.node.v1.GraphQLFederationConfiguration - 70, // 58: wg.cosmo.node.v1.DataSourceCustom_GraphQL.upstream_schema:type_name -> wg.cosmo.node.v1.InternedString - 71, // 59: wg.cosmo.node.v1.DataSourceCustom_GraphQL.custom_scalar_type_fields:type_name -> wg.cosmo.node.v1.SingleTypeField - 41, // 60: wg.cosmo.node.v1.DataSourceCustom_GraphQL.grpc:type_name -> wg.cosmo.node.v1.GRPCConfiguration - 45, // 61: wg.cosmo.node.v1.GRPCConfiguration.mapping:type_name -> wg.cosmo.node.v1.GRPCMapping - 43, // 62: wg.cosmo.node.v1.GRPCConfiguration.plugin:type_name -> wg.cosmo.node.v1.PluginConfiguration - 42, // 63: wg.cosmo.node.v1.PluginConfiguration.image_reference:type_name -> wg.cosmo.node.v1.ImageReference - 48, // 64: wg.cosmo.node.v1.GRPCMapping.operation_mappings:type_name -> wg.cosmo.node.v1.OperationMapping - 49, // 65: wg.cosmo.node.v1.GRPCMapping.entity_mappings:type_name -> wg.cosmo.node.v1.EntityMapping - 51, // 66: wg.cosmo.node.v1.GRPCMapping.type_field_mappings:type_name -> wg.cosmo.node.v1.TypeFieldMapping - 54, // 67: wg.cosmo.node.v1.GRPCMapping.enum_mappings:type_name -> wg.cosmo.node.v1.EnumMapping - 46, // 68: wg.cosmo.node.v1.GRPCMapping.resolve_mappings:type_name -> wg.cosmo.node.v1.LookupMapping - 3, // 69: wg.cosmo.node.v1.LookupMapping.type:type_name -> wg.cosmo.node.v1.LookupType - 47, // 70: wg.cosmo.node.v1.LookupMapping.lookup_mapping:type_name -> wg.cosmo.node.v1.LookupFieldMapping - 52, // 71: wg.cosmo.node.v1.LookupFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping - 4, // 72: wg.cosmo.node.v1.OperationMapping.type:type_name -> wg.cosmo.node.v1.OperationType - 50, // 73: wg.cosmo.node.v1.EntityMapping.required_field_mappings:type_name -> wg.cosmo.node.v1.RequiredFieldMapping - 52, // 74: wg.cosmo.node.v1.RequiredFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping - 52, // 75: wg.cosmo.node.v1.TypeFieldMapping.field_mappings:type_name -> wg.cosmo.node.v1.FieldMapping - 53, // 76: wg.cosmo.node.v1.FieldMapping.argument_mappings:type_name -> wg.cosmo.node.v1.ArgumentMapping - 55, // 77: wg.cosmo.node.v1.EnumMapping.values:type_name -> wg.cosmo.node.v1.EnumValueMapping - 60, // 78: wg.cosmo.node.v1.NatsEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration - 56, // 79: wg.cosmo.node.v1.NatsEventConfiguration.stream_configuration:type_name -> wg.cosmo.node.v1.NatsStreamConfiguration - 60, // 80: wg.cosmo.node.v1.KafkaEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration - 60, // 81: wg.cosmo.node.v1.RedisEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration - 5, // 82: wg.cosmo.node.v1.EngineEventConfiguration.type:type_name -> wg.cosmo.node.v1.EventType - 57, // 83: wg.cosmo.node.v1.DataSourceCustomEvents.nats:type_name -> wg.cosmo.node.v1.NatsEventConfiguration - 58, // 84: wg.cosmo.node.v1.DataSourceCustomEvents.kafka:type_name -> wg.cosmo.node.v1.KafkaEventConfiguration - 59, // 85: wg.cosmo.node.v1.DataSourceCustomEvents.redis:type_name -> wg.cosmo.node.v1.RedisEventConfiguration - 63, // 86: wg.cosmo.node.v1.DataSourceCustom_Static.data:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 6, // 87: wg.cosmo.node.v1.ConfigurationVariable.kind:type_name -> wg.cosmo.node.v1.ConfigurationVariableKind - 63, // 88: wg.cosmo.node.v1.HTTPHeader.values:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 89: wg.cosmo.node.v1.MTLSConfiguration.key:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 90: wg.cosmo.node.v1.MTLSConfiguration.cert:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 63, // 91: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable - 88, // 92: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.protocol:type_name -> wg.cosmo.common.GraphQLSubscriptionProtocol - 89, // 93: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.websocketSubprotocol:type_name -> wg.cosmo.common.GraphQLWebsocketSubprotocol - 73, // 94: wg.cosmo.node.v1.SubscriptionFilterCondition.and:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 72, // 95: wg.cosmo.node.v1.SubscriptionFilterCondition.in:type_name -> wg.cosmo.node.v1.SubscriptionFieldCondition - 73, // 96: wg.cosmo.node.v1.SubscriptionFilterCondition.not:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 73, // 97: wg.cosmo.node.v1.SubscriptionFilterCondition.or:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition - 75, // 98: wg.cosmo.node.v1.CacheWarmerOperations.operations:type_name -> wg.cosmo.node.v1.Operation - 76, // 99: wg.cosmo.node.v1.Operation.request:type_name -> wg.cosmo.node.v1.OperationRequest - 79, // 100: wg.cosmo.node.v1.Operation.client:type_name -> wg.cosmo.node.v1.ClientInfo - 77, // 101: wg.cosmo.node.v1.OperationRequest.extensions:type_name -> wg.cosmo.node.v1.Extension - 78, // 102: wg.cosmo.node.v1.Extension.persisted_query:type_name -> wg.cosmo.node.v1.PersistedQuery - 10, // 103: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry.value:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig - 66, // 104: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry.value:type_name -> wg.cosmo.node.v1.HTTPHeader - 16, // 105: wg.cosmo.node.v1.NodeService.SelfRegister:input_type -> wg.cosmo.node.v1.SelfRegisterRequest - 17, // 106: wg.cosmo.node.v1.NodeService.SelfRegister:output_type -> wg.cosmo.node.v1.SelfRegisterResponse - 106, // [106:107] is the sub-list for method output_type - 105, // [105:106] is the sub-list for method input_type - 105, // [105:105] is the sub-list for extension type_name - 105, // [105:105] is the sub-list for extension extendee - 0, // [0:105] is the sub-list for field type_name + 24, // 31: wg.cosmo.node.v1.EntityCachingConfiguration.query_cache_configurations:type_name -> wg.cosmo.node.v1.QueryCacheConfiguration + 25, // 32: wg.cosmo.node.v1.QueryCacheConfiguration.entity_key_mappings:type_name -> wg.cosmo.node.v1.EntityKeyMapping + 26, // 33: wg.cosmo.node.v1.EntityKeyMapping.field_mappings:type_name -> wg.cosmo.node.v1.EntityCacheFieldMapping + 28, // 34: wg.cosmo.node.v1.CostConfiguration.field_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration + 29, // 35: wg.cosmo.node.v1.CostConfiguration.list_sizes:type_name -> wg.cosmo.node.v1.FieldListSizeConfiguration + 84, // 36: wg.cosmo.node.v1.CostConfiguration.type_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.TypeWeightsEntry + 85, // 37: wg.cosmo.node.v1.CostConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.CostConfiguration.DirectiveArgumentWeightsEntry + 86, // 38: wg.cosmo.node.v1.FieldWeightConfiguration.argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.ArgumentWeightsEntry + 87, // 39: wg.cosmo.node.v1.FieldWeightConfiguration.directive_argument_weights:type_name -> wg.cosmo.node.v1.FieldWeightConfiguration.DirectiveArgumentWeightsEntry + 1, // 40: wg.cosmo.node.v1.ArgumentConfiguration.source_type:type_name -> wg.cosmo.node.v1.ArgumentSource + 31, // 41: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes:type_name -> wg.cosmo.node.v1.Scopes + 31, // 42: wg.cosmo.node.v1.AuthorizationConfiguration.required_or_scopes_by_or:type_name -> wg.cosmo.node.v1.Scopes + 30, // 43: wg.cosmo.node.v1.FieldConfiguration.arguments_configuration:type_name -> wg.cosmo.node.v1.ArgumentConfiguration + 32, // 44: wg.cosmo.node.v1.FieldConfiguration.authorization_configuration:type_name -> wg.cosmo.node.v1.AuthorizationConfiguration + 75, // 45: wg.cosmo.node.v1.FieldConfiguration.subscription_filter_condition:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 36, // 46: wg.cosmo.node.v1.FieldSetCondition.field_coordinates_path:type_name -> wg.cosmo.node.v1.FieldCoordinates + 37, // 47: wg.cosmo.node.v1.RequiredField.conditions:type_name -> wg.cosmo.node.v1.FieldSetCondition + 65, // 48: wg.cosmo.node.v1.FetchConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 7, // 49: wg.cosmo.node.v1.FetchConfiguration.method:type_name -> wg.cosmo.node.v1.HTTPMethod + 88, // 50: wg.cosmo.node.v1.FetchConfiguration.header:type_name -> wg.cosmo.node.v1.FetchConfiguration.HeaderEntry + 65, // 51: wg.cosmo.node.v1.FetchConfiguration.body:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 67, // 52: wg.cosmo.node.v1.FetchConfiguration.query:type_name -> wg.cosmo.node.v1.URLQueryConfiguration + 69, // 53: wg.cosmo.node.v1.FetchConfiguration.mtls:type_name -> wg.cosmo.node.v1.MTLSConfiguration + 65, // 54: wg.cosmo.node.v1.FetchConfiguration.base_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 55: wg.cosmo.node.v1.FetchConfiguration.path:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 56: wg.cosmo.node.v1.FetchConfiguration.http_proxy_url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 40, // 57: wg.cosmo.node.v1.DataSourceCustom_GraphQL.fetch:type_name -> wg.cosmo.node.v1.FetchConfiguration + 70, // 58: wg.cosmo.node.v1.DataSourceCustom_GraphQL.subscription:type_name -> wg.cosmo.node.v1.GraphQLSubscriptionConfiguration + 71, // 59: wg.cosmo.node.v1.DataSourceCustom_GraphQL.federation:type_name -> wg.cosmo.node.v1.GraphQLFederationConfiguration + 72, // 60: wg.cosmo.node.v1.DataSourceCustom_GraphQL.upstream_schema:type_name -> wg.cosmo.node.v1.InternedString + 73, // 61: wg.cosmo.node.v1.DataSourceCustom_GraphQL.custom_scalar_type_fields:type_name -> wg.cosmo.node.v1.SingleTypeField + 43, // 62: wg.cosmo.node.v1.DataSourceCustom_GraphQL.grpc:type_name -> wg.cosmo.node.v1.GRPCConfiguration + 47, // 63: wg.cosmo.node.v1.GRPCConfiguration.mapping:type_name -> wg.cosmo.node.v1.GRPCMapping + 45, // 64: wg.cosmo.node.v1.GRPCConfiguration.plugin:type_name -> wg.cosmo.node.v1.PluginConfiguration + 44, // 65: wg.cosmo.node.v1.PluginConfiguration.image_reference:type_name -> wg.cosmo.node.v1.ImageReference + 50, // 66: wg.cosmo.node.v1.GRPCMapping.operation_mappings:type_name -> wg.cosmo.node.v1.OperationMapping + 51, // 67: wg.cosmo.node.v1.GRPCMapping.entity_mappings:type_name -> wg.cosmo.node.v1.EntityMapping + 53, // 68: wg.cosmo.node.v1.GRPCMapping.type_field_mappings:type_name -> wg.cosmo.node.v1.TypeFieldMapping + 56, // 69: wg.cosmo.node.v1.GRPCMapping.enum_mappings:type_name -> wg.cosmo.node.v1.EnumMapping + 48, // 70: wg.cosmo.node.v1.GRPCMapping.resolve_mappings:type_name -> wg.cosmo.node.v1.LookupMapping + 3, // 71: wg.cosmo.node.v1.LookupMapping.type:type_name -> wg.cosmo.node.v1.LookupType + 49, // 72: wg.cosmo.node.v1.LookupMapping.lookup_mapping:type_name -> wg.cosmo.node.v1.LookupFieldMapping + 54, // 73: wg.cosmo.node.v1.LookupFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping + 4, // 74: wg.cosmo.node.v1.OperationMapping.type:type_name -> wg.cosmo.node.v1.OperationType + 52, // 75: wg.cosmo.node.v1.EntityMapping.required_field_mappings:type_name -> wg.cosmo.node.v1.RequiredFieldMapping + 54, // 76: wg.cosmo.node.v1.RequiredFieldMapping.field_mapping:type_name -> wg.cosmo.node.v1.FieldMapping + 54, // 77: wg.cosmo.node.v1.TypeFieldMapping.field_mappings:type_name -> wg.cosmo.node.v1.FieldMapping + 55, // 78: wg.cosmo.node.v1.FieldMapping.argument_mappings:type_name -> wg.cosmo.node.v1.ArgumentMapping + 57, // 79: wg.cosmo.node.v1.EnumMapping.values:type_name -> wg.cosmo.node.v1.EnumValueMapping + 62, // 80: wg.cosmo.node.v1.NatsEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration + 58, // 81: wg.cosmo.node.v1.NatsEventConfiguration.stream_configuration:type_name -> wg.cosmo.node.v1.NatsStreamConfiguration + 62, // 82: wg.cosmo.node.v1.KafkaEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration + 62, // 83: wg.cosmo.node.v1.RedisEventConfiguration.engine_event_configuration:type_name -> wg.cosmo.node.v1.EngineEventConfiguration + 5, // 84: wg.cosmo.node.v1.EngineEventConfiguration.type:type_name -> wg.cosmo.node.v1.EventType + 59, // 85: wg.cosmo.node.v1.DataSourceCustomEvents.nats:type_name -> wg.cosmo.node.v1.NatsEventConfiguration + 60, // 86: wg.cosmo.node.v1.DataSourceCustomEvents.kafka:type_name -> wg.cosmo.node.v1.KafkaEventConfiguration + 61, // 87: wg.cosmo.node.v1.DataSourceCustomEvents.redis:type_name -> wg.cosmo.node.v1.RedisEventConfiguration + 65, // 88: wg.cosmo.node.v1.DataSourceCustom_Static.data:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 6, // 89: wg.cosmo.node.v1.ConfigurationVariable.kind:type_name -> wg.cosmo.node.v1.ConfigurationVariableKind + 65, // 90: wg.cosmo.node.v1.HTTPHeader.values:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 91: wg.cosmo.node.v1.MTLSConfiguration.key:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 92: wg.cosmo.node.v1.MTLSConfiguration.cert:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 65, // 93: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.url:type_name -> wg.cosmo.node.v1.ConfigurationVariable + 90, // 94: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.protocol:type_name -> wg.cosmo.common.GraphQLSubscriptionProtocol + 91, // 95: wg.cosmo.node.v1.GraphQLSubscriptionConfiguration.websocketSubprotocol:type_name -> wg.cosmo.common.GraphQLWebsocketSubprotocol + 75, // 96: wg.cosmo.node.v1.SubscriptionFilterCondition.and:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 74, // 97: wg.cosmo.node.v1.SubscriptionFilterCondition.in:type_name -> wg.cosmo.node.v1.SubscriptionFieldCondition + 75, // 98: wg.cosmo.node.v1.SubscriptionFilterCondition.not:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 75, // 99: wg.cosmo.node.v1.SubscriptionFilterCondition.or:type_name -> wg.cosmo.node.v1.SubscriptionFilterCondition + 77, // 100: wg.cosmo.node.v1.CacheWarmerOperations.operations:type_name -> wg.cosmo.node.v1.Operation + 78, // 101: wg.cosmo.node.v1.Operation.request:type_name -> wg.cosmo.node.v1.OperationRequest + 81, // 102: wg.cosmo.node.v1.Operation.client:type_name -> wg.cosmo.node.v1.ClientInfo + 79, // 103: wg.cosmo.node.v1.OperationRequest.extensions:type_name -> wg.cosmo.node.v1.Extension + 80, // 104: wg.cosmo.node.v1.Extension.persisted_query:type_name -> wg.cosmo.node.v1.PersistedQuery + 10, // 105: wg.cosmo.node.v1.FeatureFlagRouterExecutionConfigs.ConfigByFeatureFlagNameEntry.value:type_name -> wg.cosmo.node.v1.FeatureFlagRouterExecutionConfig + 68, // 106: wg.cosmo.node.v1.FetchConfiguration.HeaderEntry.value:type_name -> wg.cosmo.node.v1.HTTPHeader + 16, // 107: wg.cosmo.node.v1.NodeService.SelfRegister:input_type -> wg.cosmo.node.v1.SelfRegisterRequest + 17, // 108: wg.cosmo.node.v1.NodeService.SelfRegister:output_type -> wg.cosmo.node.v1.SelfRegisterResponse + 108, // [108:109] is the sub-list for method output_type + 107, // [107:108] is the sub-list for method input_type + 107, // [107:107] is the sub-list for extension type_name + 107, // [107:107] is the sub-list for extension extendee + 0, // [0:107] is the sub-list for field type_name } func init() { file_wg_cosmo_node_v1_node_proto_init() } @@ -5647,20 +5798,20 @@ func file_wg_cosmo_node_v1_node_proto_init() { file_wg_cosmo_node_v1_node_proto_msgTypes[4].OneofWrappers = []any{} file_wg_cosmo_node_v1_node_proto_msgTypes[9].OneofWrappers = []any{} file_wg_cosmo_node_v1_node_proto_msgTypes[10].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[18].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[19].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[23].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[30].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[35].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[60].OneofWrappers = []any{} - file_wg_cosmo_node_v1_node_proto_msgTypes[65].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[20].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[21].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[25].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[32].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[37].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[62].OneofWrappers = []any{} + file_wg_cosmo_node_v1_node_proto_msgTypes[67].OneofWrappers = []any{} type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_wg_cosmo_node_v1_node_proto_rawDesc), len(file_wg_cosmo_node_v1_node_proto_rawDesc)), NumEnums: 8, - NumMessages: 79, + NumMessages: 81, NumExtensions: 0, NumServices: 1, }, diff --git a/shared/src/router-config/builder.ts b/shared/src/router-config/builder.ts index a020ef4879..c2d0bfb774 100644 --- a/shared/src/router-config/builder.ts +++ b/shared/src/router-config/builder.ts @@ -28,7 +28,9 @@ import { DataSourceKind, EngineConfiguration, EntityCacheConfiguration, + EntityCacheFieldMapping, EntityCachingConfiguration, + EntityKeyMapping, FieldListSizeConfiguration, FieldWeightConfiguration, GraphQLSubscriptionConfiguration, @@ -38,7 +40,7 @@ import { ImageReference, InternedString, PluginConfiguration, - RequestScopedConfiguration, + QueryCacheConfiguration, RouterConfig, TypeField, } from '@wundergraph/cosmo-connect/dist/node/v1/node_pb'; @@ -89,7 +91,7 @@ function extractEntityCachingConfiguration( const entityCache: EntityCacheConfiguration[] = []; const cacheInvalidateConfigurations: CacheInvalidateConfiguration[] = []; const cachePopulateConfigurations: CachePopulateConfiguration[] = []; - const requestScopedConfigurations: RequestScopedConfiguration[] = []; + const queryCacheConfigurations: QueryCacheConfiguration[] = []; for (const data of dataByTypeName.values()) { if (!data.entityCaching) { continue; @@ -128,12 +130,28 @@ function extractEntityCachingConfiguration( }), ); } - for (const field of data.entityCaching?.requestScopedConfigurations) { - requestScopedConfigurations.push( - new RequestScopedConfiguration({ - fieldName: field.fieldName, - typeName: field.typeName, - l1Key: field.l1Key, + for (const rfc of data.entityCaching?.queryCacheConfigurations ?? []) { + queryCacheConfigurations.push( + new QueryCacheConfiguration({ + fieldName: rfc.fieldName, + maxAgeSeconds: BigInt(rfc.maxAgeSeconds), + includeHeaders: rfc.includeHeaders, + shadowMode: rfc.shadowMode, + entityTypeName: rfc.entityTypeName, + entityKeyMappings: rfc.entityKeyMappings.map( + (m) => + new EntityKeyMapping({ + entityTypeName: m.entityTypeName, + fieldMappings: m.fieldMappings.map( + (fm) => + new EntityCacheFieldMapping({ + entityKeyField: fm.entityKeyField, + argumentPath: fm.argumentPath, + isBatch: fm.isBatch || false, + }), + ), + }), + ), }), ); } @@ -142,13 +160,13 @@ function extractEntityCachingConfiguration( entityCache.length > 0 || cacheInvalidateConfigurations.length > 0 || cachePopulateConfigurations.length > 0 || - requestScopedConfigurations.length > 0 + queryCacheConfigurations.length > 0 ) { return new EntityCachingConfiguration({ entityCache, cacheInvalidateConfigurations, cachePopulateConfigurations, - requestScopedConfigurations, + queryCacheConfigurations, }); } } diff --git a/shared/test/entity-caching.test.ts b/shared/test/entity-caching.test.ts new file mode 100644 index 0000000000..c465089316 --- /dev/null +++ b/shared/test/entity-caching.test.ts @@ -0,0 +1,155 @@ +import { describe, expect, test } from 'vitest'; +import { + federateSubgraphs, + FederationSuccess, + LATEST_ROUTER_COMPATIBILITY_VERSION, + parse, +} from '@wundergraph/composition'; +import { EntityCachingConfiguration } from '@wundergraph/cosmo-connect/dist/node/v1/node_pb'; +import { buildRouterConfig, ComposedSubgraph, SubgraphKind } from '../src'; + +// Drives a single subgraph through federation + buildRouterConfig and returns the EntityCachingConfiguration +// proto message attached to its datasource configuration (or undefined when no caching directives +// are present). Exercises builder.ts#extractEntityCachingConfiguration end-to-end. +function buildEntityCaching(sdl: string): EntityCachingConfiguration | undefined { + const result = federateSubgraphs({ + subgraphs: [{ name: 'test', url: '', definitions: parse(sdl) }], + version: LATEST_ROUTER_COMPATIBILITY_VERSION, + }) as FederationSuccess; + expect(result.success).toBe(true); + const cfg = result.subgraphConfigBySubgraphName.get('test')!; + const subgraph: ComposedSubgraph = { + kind: SubgraphKind.Standard, + id: '0', + name: 'test', + sdl, + url: '', + subscriptionUrl: '', + subscriptionProtocol: 'ws', + websocketSubprotocol: 'auto', + schema: cfg.schema, + configurationDataByTypeName: cfg.configurationDataByTypeName, + } as ComposedSubgraph; + const routerConfig = buildRouterConfig({ + federatedClientSDL: '', + fieldConfigurations: [], + routerCompatibilityVersion: LATEST_ROUTER_COMPATIBILITY_VERSION, + subgraphs: [subgraph], + federatedSDL: sdl, + schemaVersionId: '', + }); + return routerConfig.engineConfig!.datasourceConfigurations[0].entityCachingConfiguration; +} + +describe('Entity caching router-config builder (extractEntityCachingConfiguration)', () => { + test('maps every entity-caching directive type into the EntityCachingConfiguration message', () => { + const ec = buildEntityCaching(` + type Query { + product(id: ID! @openfed__is(fields: "id")): Product @openfed__queryCache(maxAge: 30) + } + type Mutation { + updateProduct(id: ID!): Product @openfed__cacheInvalidate + createProduct(name: String!): Product @openfed__cachePopulate(maxAge: 45) + } + type Product @key(fields: "id") @openfed__entityCache(maxAge: 60, includeHeaders: true, negativeCacheTTL: 5) { + id: ID! + name: String! + } + `); + + expect(ec).toBeDefined(); + + // @openfed__entityCache (Int args become BigInt; flag defaults preserved) + expect(ec!.entityCache).toHaveLength(1); + expect(ec!.entityCache[0].typeName).toBe('Product'); + expect(ec!.entityCache[0].maxAgeSeconds).toBe(60n); + expect(ec!.entityCache[0].notFoundCacheTtlSeconds).toBe(5n); + expect(ec!.entityCache[0].includeHeaders).toBe(true); + expect(ec!.entityCache[0].partialCacheLoad).toBe(false); + expect(ec!.entityCache[0].shadowMode).toBe(false); + + // @openfed__queryCache with @openfed__is mapping (non-batch) + expect(ec!.queryCacheConfigurations).toHaveLength(1); + const rfc = ec!.queryCacheConfigurations[0]; + expect(rfc.fieldName).toBe('product'); + expect(rfc.maxAgeSeconds).toBe(30n); + expect(rfc.entityTypeName).toBe('Product'); + expect(rfc.entityKeyMappings).toHaveLength(1); + expect(rfc.entityKeyMappings[0].entityTypeName).toBe('Product'); + expect(rfc.entityKeyMappings[0].fieldMappings).toHaveLength(1); + const fm = rfc.entityKeyMappings[0].fieldMappings[0]; + expect(fm.entityKeyField).toBe('id'); + expect(fm.argumentPath).toStrictEqual(['id']); + expect(fm.isBatch).toBe(false); + + // @openfed__cacheInvalidate + expect(ec!.cacheInvalidateConfigurations).toHaveLength(1); + expect(ec!.cacheInvalidateConfigurations[0].fieldName).toBe('updateProduct'); + expect(ec!.cacheInvalidateConfigurations[0].operationType).toBe('mutation'); + expect(ec!.cacheInvalidateConfigurations[0].entityTypeName).toBe('Product'); + + // @openfed__cachePopulate with explicit maxAge + expect(ec!.cachePopulateConfigurations).toHaveLength(1); + expect(ec!.cachePopulateConfigurations[0].fieldName).toBe('createProduct'); + expect(ec!.cachePopulateConfigurations[0].operationType).toBe('mutation'); + expect(ec!.cachePopulateConfigurations[0].entityTypeName).toBe('Product'); + expect(ec!.cachePopulateConfigurations[0].maxAgeSeconds).toBe(45n); + }); + + test('maps a batched @openfed__is mapping with isBatch=true on a list-returning queryCache field', () => { + const ec = buildEntityCaching(` + type Query { + products(ids: [ID!]! @openfed__is(fields: "id")): [Product!]! @openfed__queryCache(maxAge: 20) + } + type Product @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + name: String! + } + `); + + expect(ec).toBeDefined(); + expect(ec!.queryCacheConfigurations).toHaveLength(1); + const fm = ec!.queryCacheConfigurations[0].entityKeyMappings[0].fieldMappings[0]; + expect(fm.entityKeyField).toBe('id'); + expect(fm.argumentPath).toStrictEqual(['ids']); + expect(fm.isBatch).toBe(true); + }); + + test('a Subscription @openfed__cachePopulate without maxAge falls back to the entityCache TTL', () => { + const ec = buildEntityCaching(` + type Query { + dummy: String! + } + type Subscription { + productStream: Product @openfed__cachePopulate + } + type Product @key(fields: "id") @openfed__entityCache(maxAge: 60) { + id: ID! + name: String! + } + `); + + expect(ec).toBeDefined(); + expect(ec!.cachePopulateConfigurations).toHaveLength(1); + const cp = ec!.cachePopulateConfigurations[0]; + expect(cp.fieldName).toBe('productStream'); + expect(cp.operationType).toBe('subscription'); + expect(cp.entityTypeName).toBe('Product'); + // maxAge omitted on the directive → composition falls back to the entity's @openfed__entityCache TTL (60s). + expect(cp.maxAgeSeconds).toBe(60n); + }); + + test('a subgraph with no entity-caching directives omits the EntityCaching message', () => { + const ec = buildEntityCaching(` + type Query { + product(id: ID!): Product + } + type Product @key(fields: "id") { + id: ID! + name: String! + } + `); + + expect(ec).toBeUndefined(); + }); +});