@wundergraph/cosmo-connect 0.151.0 → 0.153.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -495,6 +495,12 @@ export declare class DataSourceConfiguration extends Message<DataSourceConfigura
495
495
  * @generated from field: wg.cosmo.node.v1.CostConfiguration cost_configuration = 16;
496
496
  */
497
497
  costConfiguration?: CostConfiguration;
498
+ /**
499
+ * Entity caching configuration (e.g. request-scoped fields from @openfed__requestScoped).
500
+ *
501
+ * @generated from field: wg.cosmo.node.v1.EntityCachingConfiguration entity_caching_configuration = 17;
502
+ */
503
+ entityCachingConfiguration?: EntityCachingConfiguration;
498
504
  constructor(data?: PartialMessage<DataSourceConfiguration>);
499
505
  static readonly runtime: typeof proto3;
500
506
  static readonly typeName = "wg.cosmo.node.v1.DataSourceConfiguration";
@@ -504,6 +510,147 @@ export declare class DataSourceConfiguration extends Message<DataSourceConfigura
504
510
  static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): DataSourceConfiguration;
505
511
  static equals(a: DataSourceConfiguration | PlainMessage<DataSourceConfiguration> | undefined, b: DataSourceConfiguration | PlainMessage<DataSourceConfiguration> | undefined): boolean;
506
512
  }
513
+ /**
514
+ * Entity caching configuration for a subgraph data source.
515
+ *
516
+ * @generated from message wg.cosmo.node.v1.EntityCachingConfiguration
517
+ */
518
+ export declare class EntityCachingConfiguration extends Message<EntityCachingConfiguration> {
519
+ /**
520
+ * Per-entity cache configurations (from @openfed__entityCache directive)
521
+ *
522
+ * @generated from field: repeated wg.cosmo.node.v1.EntityCacheConfiguration entity_cache_configurations = 1;
523
+ */
524
+ entityCacheConfigurations: EntityCacheConfiguration[];
525
+ /**
526
+ * Per-Mutation/Subscription-field cache eviction configs (from @openfed__cacheInvalidate)
527
+ *
528
+ * @generated from field: repeated wg.cosmo.node.v1.CacheInvalidateConfiguration cache_invalidate_configurations = 2;
529
+ */
530
+ cacheInvalidateConfigurations: CacheInvalidateConfiguration[];
531
+ /**
532
+ * Per-Mutation/Subscription-field cache population configs (from @openfed__cachePopulate)
533
+ *
534
+ * @generated from field: repeated wg.cosmo.node.v1.CachePopulateConfiguration cache_populate_configurations = 3;
535
+ */
536
+ cachePopulateConfigurations: CachePopulateConfiguration[];
537
+ constructor(data?: PartialMessage<EntityCachingConfiguration>);
538
+ static readonly runtime: typeof proto3;
539
+ static readonly typeName = "wg.cosmo.node.v1.EntityCachingConfiguration";
540
+ static readonly fields: FieldList;
541
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): EntityCachingConfiguration;
542
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): EntityCachingConfiguration;
543
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): EntityCachingConfiguration;
544
+ static equals(a: EntityCachingConfiguration | PlainMessage<EntityCachingConfiguration> | undefined, b: EntityCachingConfiguration | PlainMessage<EntityCachingConfiguration> | undefined): boolean;
545
+ }
546
+ /**
547
+ * Per-entity declaration for @openfed__entityCache. Marks a @key entity type as cacheable so the
548
+ * router can store/serve resolved entities from an external store (e.g. Redis).
549
+ *
550
+ * @generated from message wg.cosmo.node.v1.EntityCacheConfiguration
551
+ */
552
+ export declare class EntityCacheConfiguration extends Message<EntityCacheConfiguration> {
553
+ /**
554
+ * @generated from field: string type_name = 1;
555
+ */
556
+ typeName: string;
557
+ /**
558
+ * TTL for cached entity values. Required: composition rejects values <= 0,
559
+ * so omit (zero) does not occur in practice. Interpreted in seconds.
560
+ *
561
+ * @generated from field: int64 max_age_seconds = 2;
562
+ */
563
+ maxAgeSeconds: bigint;
564
+ /**
565
+ * @generated from field: bool include_headers = 3;
566
+ */
567
+ includeHeaders: boolean;
568
+ /**
569
+ * @generated from field: bool partial_cache_load = 4;
570
+ */
571
+ partialCacheLoad: boolean;
572
+ /**
573
+ * @generated from field: bool shadow_mode = 5;
574
+ */
575
+ shadowMode: boolean;
576
+ /**
577
+ * TTL for caching "not found" entity responses (entity returned null from
578
+ * _entities without errors). Omit or 0 disables negative caching and null
579
+ * responses are not cached. Positive values are seconds. Composition rejects
580
+ * negative values at schema validation time.
581
+ *
582
+ * @generated from field: int64 not_found_cache_ttl_seconds = 6;
583
+ */
584
+ notFoundCacheTtlSeconds: bigint;
585
+ constructor(data?: PartialMessage<EntityCacheConfiguration>);
586
+ static readonly runtime: typeof proto3;
587
+ static readonly typeName = "wg.cosmo.node.v1.EntityCacheConfiguration";
588
+ static readonly fields: FieldList;
589
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): EntityCacheConfiguration;
590
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): EntityCacheConfiguration;
591
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): EntityCacheConfiguration;
592
+ static equals(a: EntityCacheConfiguration | PlainMessage<EntityCacheConfiguration> | undefined, b: EntityCacheConfiguration | PlainMessage<EntityCacheConfiguration> | undefined): boolean;
593
+ }
594
+ /**
595
+ * Per-field declaration for @openfed__cacheInvalidate. Tells the router to evict the returned
596
+ * entity from the cache after the (Mutation/Subscription) operation completes.
597
+ *
598
+ * @generated from message wg.cosmo.node.v1.CacheInvalidateConfiguration
599
+ */
600
+ export declare class CacheInvalidateConfiguration extends Message<CacheInvalidateConfiguration> {
601
+ /**
602
+ * @generated from field: string field_name = 1;
603
+ */
604
+ fieldName: string;
605
+ /**
606
+ * @generated from field: string operation_type = 2;
607
+ */
608
+ operationType: string;
609
+ /**
610
+ * @generated from field: string entity_type_name = 3;
611
+ */
612
+ entityTypeName: string;
613
+ constructor(data?: PartialMessage<CacheInvalidateConfiguration>);
614
+ static readonly runtime: typeof proto3;
615
+ static readonly typeName = "wg.cosmo.node.v1.CacheInvalidateConfiguration";
616
+ static readonly fields: FieldList;
617
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CacheInvalidateConfiguration;
618
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CacheInvalidateConfiguration;
619
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CacheInvalidateConfiguration;
620
+ static equals(a: CacheInvalidateConfiguration | PlainMessage<CacheInvalidateConfiguration> | undefined, b: CacheInvalidateConfiguration | PlainMessage<CacheInvalidateConfiguration> | undefined): boolean;
621
+ }
622
+ /**
623
+ * Per-field declaration for @openfed__cachePopulate. Tells the router to populate the entity cache
624
+ * with the (Mutation/Subscription) operation's return value.
625
+ *
626
+ * @generated from message wg.cosmo.node.v1.CachePopulateConfiguration
627
+ */
628
+ export declare class CachePopulateConfiguration extends Message<CachePopulateConfiguration> {
629
+ /**
630
+ * @generated from field: string field_name = 1;
631
+ */
632
+ fieldName: string;
633
+ /**
634
+ * @generated from field: string operation_type = 2;
635
+ */
636
+ operationType: string;
637
+ /**
638
+ * @generated from field: int64 max_age_seconds = 3;
639
+ */
640
+ maxAgeSeconds: bigint;
641
+ /**
642
+ * @generated from field: string entity_type_name = 4;
643
+ */
644
+ entityTypeName: string;
645
+ constructor(data?: PartialMessage<CachePopulateConfiguration>);
646
+ static readonly runtime: typeof proto3;
647
+ static readonly typeName = "wg.cosmo.node.v1.CachePopulateConfiguration";
648
+ static readonly fields: FieldList;
649
+ static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): CachePopulateConfiguration;
650
+ static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): CachePopulateConfiguration;
651
+ static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): CachePopulateConfiguration;
652
+ static equals(a: CachePopulateConfiguration | PlainMessage<CachePopulateConfiguration> | undefined, b: CachePopulateConfiguration | PlainMessage<CachePopulateConfiguration> | undefined): boolean;
653
+ }
507
654
  /**
508
655
  * @generated from message wg.cosmo.node.v1.CostConfiguration
509
656
  */
@@ -711,6 +711,12 @@ export class DataSourceConfiguration extends Message {
711
711
  * @generated from field: wg.cosmo.node.v1.CostConfiguration cost_configuration = 16;
712
712
  */
713
713
  costConfiguration;
714
+ /**
715
+ * Entity caching configuration (e.g. request-scoped fields from @openfed__requestScoped).
716
+ *
717
+ * @generated from field: wg.cosmo.node.v1.EntityCachingConfiguration entity_caching_configuration = 17;
718
+ */
719
+ entityCachingConfiguration;
714
720
  constructor(data) {
715
721
  super();
716
722
  proto3.util.initPartial(data, this);
@@ -734,6 +740,7 @@ export class DataSourceConfiguration extends Message {
734
740
  { no: 14, name: "entity_interfaces", kind: "message", T: EntityInterfaceConfiguration, repeated: true },
735
741
  { no: 15, name: "interface_objects", kind: "message", T: EntityInterfaceConfiguration, repeated: true },
736
742
  { no: 16, name: "cost_configuration", kind: "message", T: CostConfiguration },
743
+ { no: 17, name: "entity_caching_configuration", kind: "message", T: EntityCachingConfiguration },
737
744
  ]);
738
745
  static fromBinary(bytes, options) {
739
746
  return new DataSourceConfiguration().fromBinary(bytes, options);
@@ -748,6 +755,211 @@ export class DataSourceConfiguration extends Message {
748
755
  return proto3.util.equals(DataSourceConfiguration, a, b);
749
756
  }
750
757
  }
758
+ /**
759
+ * Entity caching configuration for a subgraph data source.
760
+ *
761
+ * @generated from message wg.cosmo.node.v1.EntityCachingConfiguration
762
+ */
763
+ export class EntityCachingConfiguration extends Message {
764
+ /**
765
+ * Per-entity cache configurations (from @openfed__entityCache directive)
766
+ *
767
+ * @generated from field: repeated wg.cosmo.node.v1.EntityCacheConfiguration entity_cache_configurations = 1;
768
+ */
769
+ entityCacheConfigurations = [];
770
+ /**
771
+ * Per-Mutation/Subscription-field cache eviction configs (from @openfed__cacheInvalidate)
772
+ *
773
+ * @generated from field: repeated wg.cosmo.node.v1.CacheInvalidateConfiguration cache_invalidate_configurations = 2;
774
+ */
775
+ cacheInvalidateConfigurations = [];
776
+ /**
777
+ * Per-Mutation/Subscription-field cache population configs (from @openfed__cachePopulate)
778
+ *
779
+ * @generated from field: repeated wg.cosmo.node.v1.CachePopulateConfiguration cache_populate_configurations = 3;
780
+ */
781
+ cachePopulateConfigurations = [];
782
+ constructor(data) {
783
+ super();
784
+ proto3.util.initPartial(data, this);
785
+ }
786
+ static runtime = proto3;
787
+ static typeName = "wg.cosmo.node.v1.EntityCachingConfiguration";
788
+ static fields = proto3.util.newFieldList(() => [
789
+ { no: 1, name: "entity_cache_configurations", kind: "message", T: EntityCacheConfiguration, repeated: true },
790
+ { no: 2, name: "cache_invalidate_configurations", kind: "message", T: CacheInvalidateConfiguration, repeated: true },
791
+ { no: 3, name: "cache_populate_configurations", kind: "message", T: CachePopulateConfiguration, repeated: true },
792
+ ]);
793
+ static fromBinary(bytes, options) {
794
+ return new EntityCachingConfiguration().fromBinary(bytes, options);
795
+ }
796
+ static fromJson(jsonValue, options) {
797
+ return new EntityCachingConfiguration().fromJson(jsonValue, options);
798
+ }
799
+ static fromJsonString(jsonString, options) {
800
+ return new EntityCachingConfiguration().fromJsonString(jsonString, options);
801
+ }
802
+ static equals(a, b) {
803
+ return proto3.util.equals(EntityCachingConfiguration, a, b);
804
+ }
805
+ }
806
+ /**
807
+ * Per-entity declaration for @openfed__entityCache. Marks a @key entity type as cacheable so the
808
+ * router can store/serve resolved entities from an external store (e.g. Redis).
809
+ *
810
+ * @generated from message wg.cosmo.node.v1.EntityCacheConfiguration
811
+ */
812
+ export class EntityCacheConfiguration extends Message {
813
+ /**
814
+ * @generated from field: string type_name = 1;
815
+ */
816
+ typeName = "";
817
+ /**
818
+ * TTL for cached entity values. Required: composition rejects values <= 0,
819
+ * so omit (zero) does not occur in practice. Interpreted in seconds.
820
+ *
821
+ * @generated from field: int64 max_age_seconds = 2;
822
+ */
823
+ maxAgeSeconds = protoInt64.zero;
824
+ /**
825
+ * @generated from field: bool include_headers = 3;
826
+ */
827
+ includeHeaders = false;
828
+ /**
829
+ * @generated from field: bool partial_cache_load = 4;
830
+ */
831
+ partialCacheLoad = false;
832
+ /**
833
+ * @generated from field: bool shadow_mode = 5;
834
+ */
835
+ shadowMode = false;
836
+ /**
837
+ * TTL for caching "not found" entity responses (entity returned null from
838
+ * _entities without errors). Omit or 0 disables negative caching and null
839
+ * responses are not cached. Positive values are seconds. Composition rejects
840
+ * negative values at schema validation time.
841
+ *
842
+ * @generated from field: int64 not_found_cache_ttl_seconds = 6;
843
+ */
844
+ notFoundCacheTtlSeconds = protoInt64.zero;
845
+ constructor(data) {
846
+ super();
847
+ proto3.util.initPartial(data, this);
848
+ }
849
+ static runtime = proto3;
850
+ static typeName = "wg.cosmo.node.v1.EntityCacheConfiguration";
851
+ static fields = proto3.util.newFieldList(() => [
852
+ { no: 1, name: "type_name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
853
+ { no: 2, name: "max_age_seconds", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
854
+ { no: 3, name: "include_headers", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
855
+ { no: 4, name: "partial_cache_load", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
856
+ { no: 5, name: "shadow_mode", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
857
+ { no: 6, name: "not_found_cache_ttl_seconds", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
858
+ ]);
859
+ static fromBinary(bytes, options) {
860
+ return new EntityCacheConfiguration().fromBinary(bytes, options);
861
+ }
862
+ static fromJson(jsonValue, options) {
863
+ return new EntityCacheConfiguration().fromJson(jsonValue, options);
864
+ }
865
+ static fromJsonString(jsonString, options) {
866
+ return new EntityCacheConfiguration().fromJsonString(jsonString, options);
867
+ }
868
+ static equals(a, b) {
869
+ return proto3.util.equals(EntityCacheConfiguration, a, b);
870
+ }
871
+ }
872
+ /**
873
+ * Per-field declaration for @openfed__cacheInvalidate. Tells the router to evict the returned
874
+ * entity from the cache after the (Mutation/Subscription) operation completes.
875
+ *
876
+ * @generated from message wg.cosmo.node.v1.CacheInvalidateConfiguration
877
+ */
878
+ export class CacheInvalidateConfiguration extends Message {
879
+ /**
880
+ * @generated from field: string field_name = 1;
881
+ */
882
+ fieldName = "";
883
+ /**
884
+ * @generated from field: string operation_type = 2;
885
+ */
886
+ operationType = "";
887
+ /**
888
+ * @generated from field: string entity_type_name = 3;
889
+ */
890
+ entityTypeName = "";
891
+ constructor(data) {
892
+ super();
893
+ proto3.util.initPartial(data, this);
894
+ }
895
+ static runtime = proto3;
896
+ static typeName = "wg.cosmo.node.v1.CacheInvalidateConfiguration";
897
+ static fields = proto3.util.newFieldList(() => [
898
+ { no: 1, name: "field_name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
899
+ { no: 2, name: "operation_type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
900
+ { no: 3, name: "entity_type_name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
901
+ ]);
902
+ static fromBinary(bytes, options) {
903
+ return new CacheInvalidateConfiguration().fromBinary(bytes, options);
904
+ }
905
+ static fromJson(jsonValue, options) {
906
+ return new CacheInvalidateConfiguration().fromJson(jsonValue, options);
907
+ }
908
+ static fromJsonString(jsonString, options) {
909
+ return new CacheInvalidateConfiguration().fromJsonString(jsonString, options);
910
+ }
911
+ static equals(a, b) {
912
+ return proto3.util.equals(CacheInvalidateConfiguration, a, b);
913
+ }
914
+ }
915
+ /**
916
+ * Per-field declaration for @openfed__cachePopulate. Tells the router to populate the entity cache
917
+ * with the (Mutation/Subscription) operation's return value.
918
+ *
919
+ * @generated from message wg.cosmo.node.v1.CachePopulateConfiguration
920
+ */
921
+ export class CachePopulateConfiguration extends Message {
922
+ /**
923
+ * @generated from field: string field_name = 1;
924
+ */
925
+ fieldName = "";
926
+ /**
927
+ * @generated from field: string operation_type = 2;
928
+ */
929
+ operationType = "";
930
+ /**
931
+ * @generated from field: int64 max_age_seconds = 3;
932
+ */
933
+ maxAgeSeconds = protoInt64.zero;
934
+ /**
935
+ * @generated from field: string entity_type_name = 4;
936
+ */
937
+ entityTypeName = "";
938
+ constructor(data) {
939
+ super();
940
+ proto3.util.initPartial(data, this);
941
+ }
942
+ static runtime = proto3;
943
+ static typeName = "wg.cosmo.node.v1.CachePopulateConfiguration";
944
+ static fields = proto3.util.newFieldList(() => [
945
+ { no: 1, name: "field_name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
946
+ { no: 2, name: "operation_type", kind: "scalar", T: 9 /* ScalarType.STRING */ },
947
+ { no: 3, name: "max_age_seconds", kind: "scalar", T: 3 /* ScalarType.INT64 */ },
948
+ { no: 4, name: "entity_type_name", kind: "scalar", T: 9 /* ScalarType.STRING */ },
949
+ ]);
950
+ static fromBinary(bytes, options) {
951
+ return new CachePopulateConfiguration().fromBinary(bytes, options);
952
+ }
953
+ static fromJson(jsonValue, options) {
954
+ return new CachePopulateConfiguration().fromJson(jsonValue, options);
955
+ }
956
+ static fromJsonString(jsonString, options) {
957
+ return new CachePopulateConfiguration().fromJsonString(jsonString, options);
958
+ }
959
+ static equals(a, b) {
960
+ return proto3.util.equals(CachePopulateConfiguration, a, b);
961
+ }
962
+ }
751
963
  /**
752
964
  * @generated from message wg.cosmo.node.v1.CostConfiguration
753
965
  */