@highstate/backend 0.19.1 → 0.21.1

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.
Files changed (134) hide show
  1. package/dist/chunk-b05q6fm2.js +37 -0
  2. package/dist/{chunk-V2NILDHS.js → chunk-gxjwa93h.js} +704 -604
  3. package/dist/{chunk-X2WG3WGL.js → chunk-vzdz6chj.js} +18 -15
  4. package/dist/highstate.manifest.json +4 -4
  5. package/dist/index.js +7350 -3514
  6. package/dist/library/package-resolution-worker.js +121 -10
  7. package/dist/library/worker/main.js +31 -17
  8. package/dist/shared/index.js +254 -4
  9. package/package.json +19 -20
  10. package/prisma/backend/_schema/object.prisma +12 -0
  11. package/prisma/backend/sqlite/migrations/20260222113554_add_object_tracking/migration.sql +7 -0
  12. package/prisma/project/artifact.prisma +3 -0
  13. package/prisma/project/entity.prisma +125 -0
  14. package/prisma/project/instance.prisma +6 -0
  15. package/prisma/project/migrations/20260301210131_add_entity_tracking/migration.sql +70 -0
  16. package/prisma/project/migrations/20260302212734_add_resource_hooks_flag/migration.sql +1 -0
  17. package/prisma/project/operation.prisma +3 -0
  18. package/src/artifact/factory.ts +3 -2
  19. package/src/business/artifact.test.ts +22 -2
  20. package/src/business/artifact.ts +7 -1
  21. package/src/business/entity-snapshot.test.ts +684 -0
  22. package/src/business/entity-snapshot.ts +904 -0
  23. package/src/business/evaluation.test.ts +56 -0
  24. package/src/business/evaluation.ts +102 -22
  25. package/src/business/global-search.test.ts +344 -0
  26. package/src/business/global-search.ts +902 -0
  27. package/src/business/index.ts +4 -0
  28. package/src/business/instance-lock.ts +58 -74
  29. package/src/business/instance-state.test.ts +15 -1
  30. package/src/business/instance-state.ts +37 -14
  31. package/src/business/object-ref-index.test.ts +140 -0
  32. package/src/business/object-ref-index.ts +193 -0
  33. package/src/business/operation.test.ts +15 -1
  34. package/src/business/operation.ts +4 -0
  35. package/src/business/project-model.ts +154 -13
  36. package/src/business/project-unlock.ts +25 -2
  37. package/src/business/project.ts +9 -0
  38. package/src/business/secret.test.ts +35 -2
  39. package/src/business/secret.ts +32 -9
  40. package/src/business/settings.ts +761 -0
  41. package/src/business/unit-output.test.ts +477 -0
  42. package/src/business/unit-output.ts +461 -0
  43. package/src/business/worker.ts +55 -4
  44. package/src/database/_generated/backend/postgresql/browser.ts +6 -0
  45. package/src/database/_generated/backend/postgresql/client.ts +6 -0
  46. package/src/database/_generated/backend/postgresql/internal/class.ts +23 -5
  47. package/src/database/_generated/backend/postgresql/internal/prismaNamespace.ts +89 -5
  48. package/src/database/_generated/backend/postgresql/internal/prismaNamespaceBrowser.ts +9 -0
  49. package/src/database/_generated/backend/postgresql/models/Object.ts +1076 -0
  50. package/src/database/_generated/backend/postgresql/models.ts +1 -0
  51. package/src/database/_generated/backend/sqlite/browser.ts +6 -0
  52. package/src/database/_generated/backend/sqlite/client.ts +6 -0
  53. package/src/database/_generated/backend/sqlite/internal/class.ts +23 -5
  54. package/src/database/_generated/backend/sqlite/internal/prismaNamespace.ts +89 -5
  55. package/src/database/_generated/backend/sqlite/internal/prismaNamespaceBrowser.ts +9 -0
  56. package/src/database/_generated/backend/sqlite/models/Object.ts +1074 -0
  57. package/src/database/_generated/backend/sqlite/models.ts +1 -0
  58. package/src/database/_generated/project/browser.ts +23 -0
  59. package/src/database/_generated/project/client.ts +23 -0
  60. package/src/database/_generated/project/commonInputTypes.ts +87 -53
  61. package/src/database/_generated/project/enums.ts +8 -0
  62. package/src/database/_generated/project/internal/class.ts +53 -5
  63. package/src/database/_generated/project/internal/prismaNamespace.ts +367 -13
  64. package/src/database/_generated/project/internal/prismaNamespaceBrowser.ts +48 -1
  65. package/src/database/_generated/project/models/Artifact.ts +199 -11
  66. package/src/database/_generated/project/models/Entity.ts +1274 -0
  67. package/src/database/_generated/project/models/EntitySnapshot.ts +2389 -0
  68. package/src/database/_generated/project/models/EntitySnapshotContent.ts +1260 -0
  69. package/src/database/_generated/project/models/EntitySnapshotReference.ts +1449 -0
  70. package/src/database/_generated/project/models/InstanceState.ts +361 -1
  71. package/src/database/_generated/project/models/Operation.ts +148 -3
  72. package/src/database/_generated/project/models/OperationLog.ts +0 -4
  73. package/src/database/_generated/project/models.ts +4 -0
  74. package/src/database/migration.ts +3 -0
  75. package/src/library/find-package-json.test.ts +77 -0
  76. package/src/library/find-package-json.ts +149 -0
  77. package/src/library/package-resolution-worker.ts +7 -3
  78. package/src/library/worker/evaluator.ts +7 -1
  79. package/src/orchestrator/manager.ts +7 -0
  80. package/src/orchestrator/operation-context.captured-outputs.test.ts +118 -0
  81. package/src/orchestrator/operation-context.ts +154 -16
  82. package/src/orchestrator/operation-plan.destroy.test.md +33 -12
  83. package/src/orchestrator/operation-plan.destroy.test.ts +140 -2
  84. package/src/orchestrator/operation-plan.fixtures.ts +2 -0
  85. package/src/orchestrator/operation-plan.md +4 -1
  86. package/src/orchestrator/operation-plan.ts +286 -92
  87. package/src/orchestrator/operation-plan.update.test.md +286 -11
  88. package/src/orchestrator/operation-plan.update.test.ts +656 -5
  89. package/src/orchestrator/operation-workset.ts +72 -22
  90. package/src/orchestrator/operation.cancel.test.ts +4 -0
  91. package/src/orchestrator/operation.composite.test.ts +341 -0
  92. package/src/orchestrator/operation.destroy.test.ts +4 -0
  93. package/src/orchestrator/operation.output-validation.failure.test.ts +124 -0
  94. package/src/orchestrator/operation.preview.test.ts +4 -0
  95. package/src/orchestrator/operation.refresh.test.ts +4 -0
  96. package/src/orchestrator/operation.test-utils.ts +52 -13
  97. package/src/orchestrator/operation.ts +230 -68
  98. package/src/orchestrator/operation.update.failure.test.ts +4 -0
  99. package/src/orchestrator/operation.update.skip.test.ts +196 -0
  100. package/src/orchestrator/operation.update.test.ts +4 -0
  101. package/src/orchestrator/plan-test-builder.ts +1 -0
  102. package/src/orchestrator/unit-input-values.test.ts +450 -0
  103. package/src/orchestrator/unit-input-values.ts +281 -0
  104. package/src/pubsub/manager.ts +3 -0
  105. package/src/runner/abstractions.ts +23 -54
  106. package/src/runner/factory.ts +3 -3
  107. package/src/runner/force-abort.ts +7 -2
  108. package/src/runner/local.ts +116 -87
  109. package/src/runner/pulumi.ts +3 -5
  110. package/src/services.ts +53 -2
  111. package/src/shared/models/prisma.ts +1 -0
  112. package/src/shared/models/project/entity.ts +121 -0
  113. package/src/shared/models/project/index.ts +1 -0
  114. package/src/shared/models/project/operation.ts +61 -3
  115. package/src/shared/models/project/state.ts +10 -0
  116. package/src/shared/models/project/worker.ts +7 -0
  117. package/src/shared/resolvers/effective-output-type.test.ts +494 -0
  118. package/src/shared/resolvers/effective-output-type.ts +162 -0
  119. package/src/shared/resolvers/index.ts +1 -0
  120. package/src/shared/resolvers/input.ts +59 -9
  121. package/src/shared/utils/index.ts +1 -0
  122. package/src/shared/utils/stable-json.ts +41 -0
  123. package/src/terminal/manager.ts +6 -0
  124. package/src/terminal/run.sh.ts +9 -4
  125. package/src/worker/manager.ts +97 -1
  126. package/LICENSE +0 -21
  127. package/dist/chunk-I7BWSAN6.js +0 -49
  128. package/dist/chunk-I7BWSAN6.js.map +0 -1
  129. package/dist/chunk-V2NILDHS.js.map +0 -1
  130. package/dist/chunk-X2WG3WGL.js.map +0 -1
  131. package/dist/index.js.map +0 -1
  132. package/dist/library/package-resolution-worker.js.map +0 -1
  133. package/dist/library/worker/main.js.map +0 -1
  134. package/dist/shared/index.js.map +0 -1
@@ -246,6 +246,7 @@ export type ArtifactWhereInput = {
246
246
  instances?: Prisma.InstanceStateListRelationFilter
247
247
  terminals?: Prisma.TerminalListRelationFilter
248
248
  pages?: Prisma.PageListRelationFilter
249
+ entitySnapshots?: Prisma.EntitySnapshotListRelationFilter
249
250
  }
250
251
 
251
252
  export type ArtifactOrderByWithRelationInput = {
@@ -260,6 +261,7 @@ export type ArtifactOrderByWithRelationInput = {
260
261
  instances?: Prisma.InstanceStateOrderByRelationAggregateInput
261
262
  terminals?: Prisma.TerminalOrderByRelationAggregateInput
262
263
  pages?: Prisma.PageOrderByRelationAggregateInput
264
+ entitySnapshots?: Prisma.EntitySnapshotOrderByRelationAggregateInput
263
265
  }
264
266
 
265
267
  export type ArtifactWhereUniqueInput = Prisma.AtLeast<{
@@ -277,6 +279,7 @@ export type ArtifactWhereUniqueInput = Prisma.AtLeast<{
277
279
  instances?: Prisma.InstanceStateListRelationFilter
278
280
  terminals?: Prisma.TerminalListRelationFilter
279
281
  pages?: Prisma.PageListRelationFilter
282
+ entitySnapshots?: Prisma.EntitySnapshotListRelationFilter
280
283
  }, "id" | "hash">
281
284
 
282
285
  export type ArtifactOrderByWithAggregationInput = {
@@ -319,6 +322,7 @@ export type ArtifactCreateInput = {
319
322
  instances?: Prisma.InstanceStateCreateNestedManyWithoutArtifactsInput
320
323
  terminals?: Prisma.TerminalCreateNestedManyWithoutArtifactsInput
321
324
  pages?: Prisma.PageCreateNestedManyWithoutArtifactsInput
325
+ entitySnapshots?: Prisma.EntitySnapshotCreateNestedManyWithoutArtifactsInput
322
326
  }
323
327
 
324
328
  export type ArtifactUncheckedCreateInput = {
@@ -333,6 +337,7 @@ export type ArtifactUncheckedCreateInput = {
333
337
  instances?: Prisma.InstanceStateUncheckedCreateNestedManyWithoutArtifactsInput
334
338
  terminals?: Prisma.TerminalUncheckedCreateNestedManyWithoutArtifactsInput
335
339
  pages?: Prisma.PageUncheckedCreateNestedManyWithoutArtifactsInput
340
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedCreateNestedManyWithoutArtifactsInput
336
341
  }
337
342
 
338
343
  export type ArtifactUpdateInput = {
@@ -347,6 +352,7 @@ export type ArtifactUpdateInput = {
347
352
  instances?: Prisma.InstanceStateUpdateManyWithoutArtifactsNestedInput
348
353
  terminals?: Prisma.TerminalUpdateManyWithoutArtifactsNestedInput
349
354
  pages?: Prisma.PageUpdateManyWithoutArtifactsNestedInput
355
+ entitySnapshots?: Prisma.EntitySnapshotUpdateManyWithoutArtifactsNestedInput
350
356
  }
351
357
 
352
358
  export type ArtifactUncheckedUpdateInput = {
@@ -361,6 +367,7 @@ export type ArtifactUncheckedUpdateInput = {
361
367
  instances?: Prisma.InstanceStateUncheckedUpdateManyWithoutArtifactsNestedInput
362
368
  terminals?: Prisma.TerminalUncheckedUpdateManyWithoutArtifactsNestedInput
363
369
  pages?: Prisma.PageUncheckedUpdateManyWithoutArtifactsNestedInput
370
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedUpdateManyWithoutArtifactsNestedInput
364
371
  }
365
372
 
366
373
  export type ArtifactCreateManyInput = {
@@ -449,6 +456,44 @@ export type IntFieldUpdateOperationsInput = {
449
456
  divide?: number
450
457
  }
451
458
 
459
+ export type ArtifactCreateNestedManyWithoutEntitySnapshotsInput = {
460
+ create?: Prisma.XOR<Prisma.ArtifactCreateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput> | Prisma.ArtifactCreateWithoutEntitySnapshotsInput[] | Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput[]
461
+ connectOrCreate?: Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput | Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput[]
462
+ connect?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
463
+ }
464
+
465
+ export type ArtifactUncheckedCreateNestedManyWithoutEntitySnapshotsInput = {
466
+ create?: Prisma.XOR<Prisma.ArtifactCreateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput> | Prisma.ArtifactCreateWithoutEntitySnapshotsInput[] | Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput[]
467
+ connectOrCreate?: Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput | Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput[]
468
+ connect?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
469
+ }
470
+
471
+ export type ArtifactUpdateManyWithoutEntitySnapshotsNestedInput = {
472
+ create?: Prisma.XOR<Prisma.ArtifactCreateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput> | Prisma.ArtifactCreateWithoutEntitySnapshotsInput[] | Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput[]
473
+ connectOrCreate?: Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput | Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput[]
474
+ upsert?: Prisma.ArtifactUpsertWithWhereUniqueWithoutEntitySnapshotsInput | Prisma.ArtifactUpsertWithWhereUniqueWithoutEntitySnapshotsInput[]
475
+ set?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
476
+ disconnect?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
477
+ delete?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
478
+ connect?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
479
+ update?: Prisma.ArtifactUpdateWithWhereUniqueWithoutEntitySnapshotsInput | Prisma.ArtifactUpdateWithWhereUniqueWithoutEntitySnapshotsInput[]
480
+ updateMany?: Prisma.ArtifactUpdateManyWithWhereWithoutEntitySnapshotsInput | Prisma.ArtifactUpdateManyWithWhereWithoutEntitySnapshotsInput[]
481
+ deleteMany?: Prisma.ArtifactScalarWhereInput | Prisma.ArtifactScalarWhereInput[]
482
+ }
483
+
484
+ export type ArtifactUncheckedUpdateManyWithoutEntitySnapshotsNestedInput = {
485
+ create?: Prisma.XOR<Prisma.ArtifactCreateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput> | Prisma.ArtifactCreateWithoutEntitySnapshotsInput[] | Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput[]
486
+ connectOrCreate?: Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput | Prisma.ArtifactCreateOrConnectWithoutEntitySnapshotsInput[]
487
+ upsert?: Prisma.ArtifactUpsertWithWhereUniqueWithoutEntitySnapshotsInput | Prisma.ArtifactUpsertWithWhereUniqueWithoutEntitySnapshotsInput[]
488
+ set?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
489
+ disconnect?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
490
+ delete?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
491
+ connect?: Prisma.ArtifactWhereUniqueInput | Prisma.ArtifactWhereUniqueInput[]
492
+ update?: Prisma.ArtifactUpdateWithWhereUniqueWithoutEntitySnapshotsInput | Prisma.ArtifactUpdateWithWhereUniqueWithoutEntitySnapshotsInput[]
493
+ updateMany?: Prisma.ArtifactUpdateManyWithWhereWithoutEntitySnapshotsInput | Prisma.ArtifactUpdateManyWithWhereWithoutEntitySnapshotsInput[]
494
+ deleteMany?: Prisma.ArtifactScalarWhereInput | Prisma.ArtifactScalarWhereInput[]
495
+ }
496
+
452
497
  export type ArtifactCreateNestedManyWithoutInstancesInput = {
453
498
  create?: Prisma.XOR<Prisma.ArtifactCreateWithoutInstancesInput, Prisma.ArtifactUncheckedCreateWithoutInstancesInput> | Prisma.ArtifactCreateWithoutInstancesInput[] | Prisma.ArtifactUncheckedCreateWithoutInstancesInput[]
454
499
  connectOrCreate?: Prisma.ArtifactCreateOrConnectWithoutInstancesInput | Prisma.ArtifactCreateOrConnectWithoutInstancesInput[]
@@ -601,7 +646,7 @@ export type ArtifactUncheckedUpdateManyWithoutTerminalsNestedInput = {
601
646
  deleteMany?: Prisma.ArtifactScalarWhereInput | Prisma.ArtifactScalarWhereInput[]
602
647
  }
603
648
 
604
- export type ArtifactCreateWithoutInstancesInput = {
649
+ export type ArtifactCreateWithoutEntitySnapshotsInput = {
605
650
  id?: string
606
651
  meta:PrismaJson.CommonObjectMeta
607
652
  hash: string
@@ -610,11 +655,12 @@ export type ArtifactCreateWithoutInstancesInput = {
610
655
  createdAt?: Date | string
611
656
  updatedAt?: Date | string
612
657
  serviceAccounts?: Prisma.ServiceAccountCreateNestedManyWithoutArtifactsInput
658
+ instances?: Prisma.InstanceStateCreateNestedManyWithoutArtifactsInput
613
659
  terminals?: Prisma.TerminalCreateNestedManyWithoutArtifactsInput
614
660
  pages?: Prisma.PageCreateNestedManyWithoutArtifactsInput
615
661
  }
616
662
 
617
- export type ArtifactUncheckedCreateWithoutInstancesInput = {
663
+ export type ArtifactUncheckedCreateWithoutEntitySnapshotsInput = {
618
664
  id?: string
619
665
  meta:PrismaJson.CommonObjectMeta
620
666
  hash: string
@@ -623,29 +669,30 @@ export type ArtifactUncheckedCreateWithoutInstancesInput = {
623
669
  createdAt?: Date | string
624
670
  updatedAt?: Date | string
625
671
  serviceAccounts?: Prisma.ServiceAccountUncheckedCreateNestedManyWithoutArtifactsInput
672
+ instances?: Prisma.InstanceStateUncheckedCreateNestedManyWithoutArtifactsInput
626
673
  terminals?: Prisma.TerminalUncheckedCreateNestedManyWithoutArtifactsInput
627
674
  pages?: Prisma.PageUncheckedCreateNestedManyWithoutArtifactsInput
628
675
  }
629
676
 
630
- export type ArtifactCreateOrConnectWithoutInstancesInput = {
677
+ export type ArtifactCreateOrConnectWithoutEntitySnapshotsInput = {
631
678
  where: Prisma.ArtifactWhereUniqueInput
632
- create: Prisma.XOR<Prisma.ArtifactCreateWithoutInstancesInput, Prisma.ArtifactUncheckedCreateWithoutInstancesInput>
679
+ create: Prisma.XOR<Prisma.ArtifactCreateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput>
633
680
  }
634
681
 
635
- export type ArtifactUpsertWithWhereUniqueWithoutInstancesInput = {
682
+ export type ArtifactUpsertWithWhereUniqueWithoutEntitySnapshotsInput = {
636
683
  where: Prisma.ArtifactWhereUniqueInput
637
- update: Prisma.XOR<Prisma.ArtifactUpdateWithoutInstancesInput, Prisma.ArtifactUncheckedUpdateWithoutInstancesInput>
638
- create: Prisma.XOR<Prisma.ArtifactCreateWithoutInstancesInput, Prisma.ArtifactUncheckedCreateWithoutInstancesInput>
684
+ update: Prisma.XOR<Prisma.ArtifactUpdateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedUpdateWithoutEntitySnapshotsInput>
685
+ create: Prisma.XOR<Prisma.ArtifactCreateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedCreateWithoutEntitySnapshotsInput>
639
686
  }
640
687
 
641
- export type ArtifactUpdateWithWhereUniqueWithoutInstancesInput = {
688
+ export type ArtifactUpdateWithWhereUniqueWithoutEntitySnapshotsInput = {
642
689
  where: Prisma.ArtifactWhereUniqueInput
643
- data: Prisma.XOR<Prisma.ArtifactUpdateWithoutInstancesInput, Prisma.ArtifactUncheckedUpdateWithoutInstancesInput>
690
+ data: Prisma.XOR<Prisma.ArtifactUpdateWithoutEntitySnapshotsInput, Prisma.ArtifactUncheckedUpdateWithoutEntitySnapshotsInput>
644
691
  }
645
692
 
646
- export type ArtifactUpdateManyWithWhereWithoutInstancesInput = {
693
+ export type ArtifactUpdateManyWithWhereWithoutEntitySnapshotsInput = {
647
694
  where: Prisma.ArtifactScalarWhereInput
648
- data: Prisma.XOR<Prisma.ArtifactUpdateManyMutationInput, Prisma.ArtifactUncheckedUpdateManyWithoutInstancesInput>
695
+ data: Prisma.XOR<Prisma.ArtifactUpdateManyMutationInput, Prisma.ArtifactUncheckedUpdateManyWithoutEntitySnapshotsInput>
649
696
  }
650
697
 
651
698
  export type ArtifactScalarWhereInput = {
@@ -661,6 +708,55 @@ export type ArtifactScalarWhereInput = {
661
708
  updatedAt?: Prisma.DateTimeFilter<"Artifact"> | Date | string
662
709
  }
663
710
 
711
+ export type ArtifactCreateWithoutInstancesInput = {
712
+ id?: string
713
+ meta:PrismaJson.CommonObjectMeta
714
+ hash: string
715
+ size: number
716
+ chunkSize: number
717
+ createdAt?: Date | string
718
+ updatedAt?: Date | string
719
+ serviceAccounts?: Prisma.ServiceAccountCreateNestedManyWithoutArtifactsInput
720
+ terminals?: Prisma.TerminalCreateNestedManyWithoutArtifactsInput
721
+ pages?: Prisma.PageCreateNestedManyWithoutArtifactsInput
722
+ entitySnapshots?: Prisma.EntitySnapshotCreateNestedManyWithoutArtifactsInput
723
+ }
724
+
725
+ export type ArtifactUncheckedCreateWithoutInstancesInput = {
726
+ id?: string
727
+ meta:PrismaJson.CommonObjectMeta
728
+ hash: string
729
+ size: number
730
+ chunkSize: number
731
+ createdAt?: Date | string
732
+ updatedAt?: Date | string
733
+ serviceAccounts?: Prisma.ServiceAccountUncheckedCreateNestedManyWithoutArtifactsInput
734
+ terminals?: Prisma.TerminalUncheckedCreateNestedManyWithoutArtifactsInput
735
+ pages?: Prisma.PageUncheckedCreateNestedManyWithoutArtifactsInput
736
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedCreateNestedManyWithoutArtifactsInput
737
+ }
738
+
739
+ export type ArtifactCreateOrConnectWithoutInstancesInput = {
740
+ where: Prisma.ArtifactWhereUniqueInput
741
+ create: Prisma.XOR<Prisma.ArtifactCreateWithoutInstancesInput, Prisma.ArtifactUncheckedCreateWithoutInstancesInput>
742
+ }
743
+
744
+ export type ArtifactUpsertWithWhereUniqueWithoutInstancesInput = {
745
+ where: Prisma.ArtifactWhereUniqueInput
746
+ update: Prisma.XOR<Prisma.ArtifactUpdateWithoutInstancesInput, Prisma.ArtifactUncheckedUpdateWithoutInstancesInput>
747
+ create: Prisma.XOR<Prisma.ArtifactCreateWithoutInstancesInput, Prisma.ArtifactUncheckedCreateWithoutInstancesInput>
748
+ }
749
+
750
+ export type ArtifactUpdateWithWhereUniqueWithoutInstancesInput = {
751
+ where: Prisma.ArtifactWhereUniqueInput
752
+ data: Prisma.XOR<Prisma.ArtifactUpdateWithoutInstancesInput, Prisma.ArtifactUncheckedUpdateWithoutInstancesInput>
753
+ }
754
+
755
+ export type ArtifactUpdateManyWithWhereWithoutInstancesInput = {
756
+ where: Prisma.ArtifactScalarWhereInput
757
+ data: Prisma.XOR<Prisma.ArtifactUpdateManyMutationInput, Prisma.ArtifactUncheckedUpdateManyWithoutInstancesInput>
758
+ }
759
+
664
760
  export type ArtifactCreateWithoutPagesInput = {
665
761
  id?: string
666
762
  meta:PrismaJson.CommonObjectMeta
@@ -672,6 +768,7 @@ export type ArtifactCreateWithoutPagesInput = {
672
768
  serviceAccounts?: Prisma.ServiceAccountCreateNestedManyWithoutArtifactsInput
673
769
  instances?: Prisma.InstanceStateCreateNestedManyWithoutArtifactsInput
674
770
  terminals?: Prisma.TerminalCreateNestedManyWithoutArtifactsInput
771
+ entitySnapshots?: Prisma.EntitySnapshotCreateNestedManyWithoutArtifactsInput
675
772
  }
676
773
 
677
774
  export type ArtifactUncheckedCreateWithoutPagesInput = {
@@ -685,6 +782,7 @@ export type ArtifactUncheckedCreateWithoutPagesInput = {
685
782
  serviceAccounts?: Prisma.ServiceAccountUncheckedCreateNestedManyWithoutArtifactsInput
686
783
  instances?: Prisma.InstanceStateUncheckedCreateNestedManyWithoutArtifactsInput
687
784
  terminals?: Prisma.TerminalUncheckedCreateNestedManyWithoutArtifactsInput
785
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedCreateNestedManyWithoutArtifactsInput
688
786
  }
689
787
 
690
788
  export type ArtifactCreateOrConnectWithoutPagesInput = {
@@ -719,6 +817,7 @@ export type ArtifactCreateWithoutServiceAccountsInput = {
719
817
  instances?: Prisma.InstanceStateCreateNestedManyWithoutArtifactsInput
720
818
  terminals?: Prisma.TerminalCreateNestedManyWithoutArtifactsInput
721
819
  pages?: Prisma.PageCreateNestedManyWithoutArtifactsInput
820
+ entitySnapshots?: Prisma.EntitySnapshotCreateNestedManyWithoutArtifactsInput
722
821
  }
723
822
 
724
823
  export type ArtifactUncheckedCreateWithoutServiceAccountsInput = {
@@ -732,6 +831,7 @@ export type ArtifactUncheckedCreateWithoutServiceAccountsInput = {
732
831
  instances?: Prisma.InstanceStateUncheckedCreateNestedManyWithoutArtifactsInput
733
832
  terminals?: Prisma.TerminalUncheckedCreateNestedManyWithoutArtifactsInput
734
833
  pages?: Prisma.PageUncheckedCreateNestedManyWithoutArtifactsInput
834
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedCreateNestedManyWithoutArtifactsInput
735
835
  }
736
836
 
737
837
  export type ArtifactCreateOrConnectWithoutServiceAccountsInput = {
@@ -766,6 +866,7 @@ export type ArtifactCreateWithoutTerminalsInput = {
766
866
  serviceAccounts?: Prisma.ServiceAccountCreateNestedManyWithoutArtifactsInput
767
867
  instances?: Prisma.InstanceStateCreateNestedManyWithoutArtifactsInput
768
868
  pages?: Prisma.PageCreateNestedManyWithoutArtifactsInput
869
+ entitySnapshots?: Prisma.EntitySnapshotCreateNestedManyWithoutArtifactsInput
769
870
  }
770
871
 
771
872
  export type ArtifactUncheckedCreateWithoutTerminalsInput = {
@@ -779,6 +880,7 @@ export type ArtifactUncheckedCreateWithoutTerminalsInput = {
779
880
  serviceAccounts?: Prisma.ServiceAccountUncheckedCreateNestedManyWithoutArtifactsInput
780
881
  instances?: Prisma.InstanceStateUncheckedCreateNestedManyWithoutArtifactsInput
781
882
  pages?: Prisma.PageUncheckedCreateNestedManyWithoutArtifactsInput
883
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedCreateNestedManyWithoutArtifactsInput
782
884
  }
783
885
 
784
886
  export type ArtifactCreateOrConnectWithoutTerminalsInput = {
@@ -802,6 +904,44 @@ export type ArtifactUpdateManyWithWhereWithoutTerminalsInput = {
802
904
  data: Prisma.XOR<Prisma.ArtifactUpdateManyMutationInput, Prisma.ArtifactUncheckedUpdateManyWithoutTerminalsInput>
803
905
  }
804
906
 
907
+ export type ArtifactUpdateWithoutEntitySnapshotsInput = {
908
+ id?: Prisma.StringFieldUpdateOperationsInput | string
909
+ meta?:PrismaJson.CommonObjectMeta
910
+ hash?: Prisma.StringFieldUpdateOperationsInput | string
911
+ size?: Prisma.IntFieldUpdateOperationsInput | number
912
+ chunkSize?: Prisma.IntFieldUpdateOperationsInput | number
913
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
914
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
915
+ serviceAccounts?: Prisma.ServiceAccountUpdateManyWithoutArtifactsNestedInput
916
+ instances?: Prisma.InstanceStateUpdateManyWithoutArtifactsNestedInput
917
+ terminals?: Prisma.TerminalUpdateManyWithoutArtifactsNestedInput
918
+ pages?: Prisma.PageUpdateManyWithoutArtifactsNestedInput
919
+ }
920
+
921
+ export type ArtifactUncheckedUpdateWithoutEntitySnapshotsInput = {
922
+ id?: Prisma.StringFieldUpdateOperationsInput | string
923
+ meta?:PrismaJson.CommonObjectMeta
924
+ hash?: Prisma.StringFieldUpdateOperationsInput | string
925
+ size?: Prisma.IntFieldUpdateOperationsInput | number
926
+ chunkSize?: Prisma.IntFieldUpdateOperationsInput | number
927
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
928
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
929
+ serviceAccounts?: Prisma.ServiceAccountUncheckedUpdateManyWithoutArtifactsNestedInput
930
+ instances?: Prisma.InstanceStateUncheckedUpdateManyWithoutArtifactsNestedInput
931
+ terminals?: Prisma.TerminalUncheckedUpdateManyWithoutArtifactsNestedInput
932
+ pages?: Prisma.PageUncheckedUpdateManyWithoutArtifactsNestedInput
933
+ }
934
+
935
+ export type ArtifactUncheckedUpdateManyWithoutEntitySnapshotsInput = {
936
+ id?: Prisma.StringFieldUpdateOperationsInput | string
937
+ meta?:PrismaJson.CommonObjectMeta
938
+ hash?: Prisma.StringFieldUpdateOperationsInput | string
939
+ size?: Prisma.IntFieldUpdateOperationsInput | number
940
+ chunkSize?: Prisma.IntFieldUpdateOperationsInput | number
941
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
942
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
943
+ }
944
+
805
945
  export type ArtifactUpdateWithoutInstancesInput = {
806
946
  id?: Prisma.StringFieldUpdateOperationsInput | string
807
947
  meta?:PrismaJson.CommonObjectMeta
@@ -813,6 +953,7 @@ export type ArtifactUpdateWithoutInstancesInput = {
813
953
  serviceAccounts?: Prisma.ServiceAccountUpdateManyWithoutArtifactsNestedInput
814
954
  terminals?: Prisma.TerminalUpdateManyWithoutArtifactsNestedInput
815
955
  pages?: Prisma.PageUpdateManyWithoutArtifactsNestedInput
956
+ entitySnapshots?: Prisma.EntitySnapshotUpdateManyWithoutArtifactsNestedInput
816
957
  }
817
958
 
818
959
  export type ArtifactUncheckedUpdateWithoutInstancesInput = {
@@ -826,6 +967,7 @@ export type ArtifactUncheckedUpdateWithoutInstancesInput = {
826
967
  serviceAccounts?: Prisma.ServiceAccountUncheckedUpdateManyWithoutArtifactsNestedInput
827
968
  terminals?: Prisma.TerminalUncheckedUpdateManyWithoutArtifactsNestedInput
828
969
  pages?: Prisma.PageUncheckedUpdateManyWithoutArtifactsNestedInput
970
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedUpdateManyWithoutArtifactsNestedInput
829
971
  }
830
972
 
831
973
  export type ArtifactUncheckedUpdateManyWithoutInstancesInput = {
@@ -849,6 +991,7 @@ export type ArtifactUpdateWithoutPagesInput = {
849
991
  serviceAccounts?: Prisma.ServiceAccountUpdateManyWithoutArtifactsNestedInput
850
992
  instances?: Prisma.InstanceStateUpdateManyWithoutArtifactsNestedInput
851
993
  terminals?: Prisma.TerminalUpdateManyWithoutArtifactsNestedInput
994
+ entitySnapshots?: Prisma.EntitySnapshotUpdateManyWithoutArtifactsNestedInput
852
995
  }
853
996
 
854
997
  export type ArtifactUncheckedUpdateWithoutPagesInput = {
@@ -862,6 +1005,7 @@ export type ArtifactUncheckedUpdateWithoutPagesInput = {
862
1005
  serviceAccounts?: Prisma.ServiceAccountUncheckedUpdateManyWithoutArtifactsNestedInput
863
1006
  instances?: Prisma.InstanceStateUncheckedUpdateManyWithoutArtifactsNestedInput
864
1007
  terminals?: Prisma.TerminalUncheckedUpdateManyWithoutArtifactsNestedInput
1008
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedUpdateManyWithoutArtifactsNestedInput
865
1009
  }
866
1010
 
867
1011
  export type ArtifactUncheckedUpdateManyWithoutPagesInput = {
@@ -885,6 +1029,7 @@ export type ArtifactUpdateWithoutServiceAccountsInput = {
885
1029
  instances?: Prisma.InstanceStateUpdateManyWithoutArtifactsNestedInput
886
1030
  terminals?: Prisma.TerminalUpdateManyWithoutArtifactsNestedInput
887
1031
  pages?: Prisma.PageUpdateManyWithoutArtifactsNestedInput
1032
+ entitySnapshots?: Prisma.EntitySnapshotUpdateManyWithoutArtifactsNestedInput
888
1033
  }
889
1034
 
890
1035
  export type ArtifactUncheckedUpdateWithoutServiceAccountsInput = {
@@ -898,6 +1043,7 @@ export type ArtifactUncheckedUpdateWithoutServiceAccountsInput = {
898
1043
  instances?: Prisma.InstanceStateUncheckedUpdateManyWithoutArtifactsNestedInput
899
1044
  terminals?: Prisma.TerminalUncheckedUpdateManyWithoutArtifactsNestedInput
900
1045
  pages?: Prisma.PageUncheckedUpdateManyWithoutArtifactsNestedInput
1046
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedUpdateManyWithoutArtifactsNestedInput
901
1047
  }
902
1048
 
903
1049
  export type ArtifactUncheckedUpdateManyWithoutServiceAccountsInput = {
@@ -921,6 +1067,7 @@ export type ArtifactUpdateWithoutTerminalsInput = {
921
1067
  serviceAccounts?: Prisma.ServiceAccountUpdateManyWithoutArtifactsNestedInput
922
1068
  instances?: Prisma.InstanceStateUpdateManyWithoutArtifactsNestedInput
923
1069
  pages?: Prisma.PageUpdateManyWithoutArtifactsNestedInput
1070
+ entitySnapshots?: Prisma.EntitySnapshotUpdateManyWithoutArtifactsNestedInput
924
1071
  }
925
1072
 
926
1073
  export type ArtifactUncheckedUpdateWithoutTerminalsInput = {
@@ -934,6 +1081,7 @@ export type ArtifactUncheckedUpdateWithoutTerminalsInput = {
934
1081
  serviceAccounts?: Prisma.ServiceAccountUncheckedUpdateManyWithoutArtifactsNestedInput
935
1082
  instances?: Prisma.InstanceStateUncheckedUpdateManyWithoutArtifactsNestedInput
936
1083
  pages?: Prisma.PageUncheckedUpdateManyWithoutArtifactsNestedInput
1084
+ entitySnapshots?: Prisma.EntitySnapshotUncheckedUpdateManyWithoutArtifactsNestedInput
937
1085
  }
938
1086
 
939
1087
  export type ArtifactUncheckedUpdateManyWithoutTerminalsInput = {
@@ -956,6 +1104,7 @@ export type ArtifactCountOutputType = {
956
1104
  instances: number
957
1105
  terminals: number
958
1106
  pages: number
1107
+ entitySnapshots: number
959
1108
  }
960
1109
 
961
1110
  export type ArtifactCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
@@ -963,6 +1112,7 @@ export type ArtifactCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensio
963
1112
  instances?: boolean | ArtifactCountOutputTypeCountInstancesArgs
964
1113
  terminals?: boolean | ArtifactCountOutputTypeCountTerminalsArgs
965
1114
  pages?: boolean | ArtifactCountOutputTypeCountPagesArgs
1115
+ entitySnapshots?: boolean | ArtifactCountOutputTypeCountEntitySnapshotsArgs
966
1116
  }
967
1117
 
968
1118
  /**
@@ -1003,6 +1153,13 @@ export type ArtifactCountOutputTypeCountPagesArgs<ExtArgs extends runtime.Types.
1003
1153
  where?: Prisma.PageWhereInput
1004
1154
  }
1005
1155
 
1156
+ /**
1157
+ * ArtifactCountOutputType without action
1158
+ */
1159
+ export type ArtifactCountOutputTypeCountEntitySnapshotsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1160
+ where?: Prisma.EntitySnapshotWhereInput
1161
+ }
1162
+
1006
1163
 
1007
1164
  export type ArtifactSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
1008
1165
  id?: boolean
@@ -1016,6 +1173,7 @@ export type ArtifactSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs
1016
1173
  instances?: boolean | Prisma.Artifact$instancesArgs<ExtArgs>
1017
1174
  terminals?: boolean | Prisma.Artifact$terminalsArgs<ExtArgs>
1018
1175
  pages?: boolean | Prisma.Artifact$pagesArgs<ExtArgs>
1176
+ entitySnapshots?: boolean | Prisma.Artifact$entitySnapshotsArgs<ExtArgs>
1019
1177
  _count?: boolean | Prisma.ArtifactCountOutputTypeDefaultArgs<ExtArgs>
1020
1178
  }, ExtArgs["result"]["artifact"]>
1021
1179
 
@@ -1055,6 +1213,7 @@ export type ArtifactInclude<ExtArgs extends runtime.Types.Extensions.InternalArg
1055
1213
  instances?: boolean | Prisma.Artifact$instancesArgs<ExtArgs>
1056
1214
  terminals?: boolean | Prisma.Artifact$terminalsArgs<ExtArgs>
1057
1215
  pages?: boolean | Prisma.Artifact$pagesArgs<ExtArgs>
1216
+ entitySnapshots?: boolean | Prisma.Artifact$entitySnapshotsArgs<ExtArgs>
1058
1217
  _count?: boolean | Prisma.ArtifactCountOutputTypeDefaultArgs<ExtArgs>
1059
1218
  }
1060
1219
  export type ArtifactIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {}
@@ -1079,6 +1238,10 @@ export type $ArtifactPayload<ExtArgs extends runtime.Types.Extensions.InternalAr
1079
1238
  * The pages using this artifact.
1080
1239
  */
1081
1240
  pages: Prisma.$PagePayload<ExtArgs>[]
1241
+ /**
1242
+ * The entity snapshots referenced this artifact.
1243
+ */
1244
+ entitySnapshots: Prisma.$EntitySnapshotPayload<ExtArgs>[]
1082
1245
  }
1083
1246
  scalars: runtime.Types.Extensions.GetPayloadResult<{
1084
1247
  /**
@@ -1516,6 +1679,7 @@ export interface Prisma__ArtifactClient<T, Null = never, ExtArgs extends runtime
1516
1679
  instances<T extends Prisma.Artifact$instancesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Artifact$instancesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$InstanceStatePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1517
1680
  terminals<T extends Prisma.Artifact$terminalsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Artifact$terminalsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$TerminalPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1518
1681
  pages<T extends Prisma.Artifact$pagesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Artifact$pagesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PagePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1682
+ entitySnapshots<T extends Prisma.Artifact$entitySnapshotsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Artifact$entitySnapshotsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$EntitySnapshotPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1519
1683
  /**
1520
1684
  * Attaches callbacks for the resolution and/or rejection of the Promise.
1521
1685
  * @param onfulfilled The callback to execute when the Promise is resolved.
@@ -2033,6 +2197,30 @@ export type Artifact$pagesArgs<ExtArgs extends runtime.Types.Extensions.Internal
2033
2197
  distinct?: Prisma.PageScalarFieldEnum | Prisma.PageScalarFieldEnum[]
2034
2198
  }
2035
2199
 
2200
+ /**
2201
+ * Artifact.entitySnapshots
2202
+ */
2203
+ export type Artifact$entitySnapshotsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2204
+ /**
2205
+ * Select specific fields to fetch from the EntitySnapshot
2206
+ */
2207
+ select?: Prisma.EntitySnapshotSelect<ExtArgs> | null
2208
+ /**
2209
+ * Omit specific fields from the EntitySnapshot
2210
+ */
2211
+ omit?: Prisma.EntitySnapshotOmit<ExtArgs> | null
2212
+ /**
2213
+ * Choose, which related nodes to fetch as well
2214
+ */
2215
+ include?: Prisma.EntitySnapshotInclude<ExtArgs> | null
2216
+ where?: Prisma.EntitySnapshotWhereInput
2217
+ orderBy?: Prisma.EntitySnapshotOrderByWithRelationInput | Prisma.EntitySnapshotOrderByWithRelationInput[]
2218
+ cursor?: Prisma.EntitySnapshotWhereUniqueInput
2219
+ take?: number
2220
+ skip?: number
2221
+ distinct?: Prisma.EntitySnapshotScalarFieldEnum | Prisma.EntitySnapshotScalarFieldEnum[]
2222
+ }
2223
+
2036
2224
  /**
2037
2225
  * Artifact without action
2038
2226
  */