tgstation-server 6.12.0
The /tg/station 13 server suite
Loading...
Searching...
No Matches
20200511011048_MYAddHeartbeat.Designer.cs
Go to the documentation of this file.
1// <auto-generated />
2using System;
3using Microsoft.EntityFrameworkCore;
4using Microsoft.EntityFrameworkCore.Infrastructure;
5using Microsoft.EntityFrameworkCore.Migrations;
6
8{
9 [DbContext(typeof(MySqlDatabaseContext))]
10 [Migration("20200511011048_MYAddHeartbeat")]
11 partial class MYAddHeartbeat
12 {
14 protected override void BuildTargetModel(ModelBuilder modelBuilder)
15 {
16#pragma warning disable 612, 618
17 modelBuilder
18 .HasAnnotation("ProductVersion", "3.1.3")
19 .HasAnnotation("Relational:MaxIdentifierLength", 64);
20
21 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
22 {
23 b.Property<long>("Id")
24 .ValueGeneratedOnAdd()
25 .HasColumnType("bigint");
26
27 b.Property<ushort?>("ChannelLimit")
28 .IsRequired()
29 .HasColumnType("smallint unsigned");
30
31 b.Property<string>("ConnectionString")
32 .IsRequired()
33 .HasColumnType("longtext CHARACTER SET utf8mb4")
34 .HasMaxLength(10000);
35
36 b.Property<bool?>("Enabled")
37 .HasColumnType("tinyint(1)");
38
39 b.Property<long>("InstanceId")
40 .HasColumnType("bigint");
41
42 b.Property<string>("Name")
43 .IsRequired()
44 .HasColumnType("varchar(100) CHARACTER SET utf8mb4")
45 .HasMaxLength(100);
46
47 b.Property<int>("Provider")
48 .HasColumnType("int");
49
50 b.Property<uint?>("ReconnectionInterval")
51 .IsRequired()
52 .HasColumnType("int unsigned");
53
54 b.HasKey("Id");
55
56 b.HasIndex("InstanceId", "Name")
57 .IsUnique();
58
59 b.ToTable("ChatBots");
60 });
61
62 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatChannel", b =>
63 {
64 b.Property<long>("Id")
65 .ValueGeneratedOnAdd()
66 .HasColumnType("bigint");
67
68 b.Property<long>("ChatSettingsId")
69 .HasColumnType("bigint");
70
71 b.Property<ulong?>("DiscordChannelId")
72 .HasColumnType("bigint unsigned");
73
74 b.Property<string>("IrcChannel")
75 .HasColumnType("varchar(100) CHARACTER SET utf8mb4")
76 .HasMaxLength(100);
77
78 b.Property<bool?>("IsAdminChannel")
79 .IsRequired()
80 .HasColumnType("tinyint(1)");
81
82 b.Property<bool?>("IsUpdatesChannel")
83 .IsRequired()
84 .HasColumnType("tinyint(1)");
85
86 b.Property<bool?>("IsWatchdogChannel")
87 .IsRequired()
88 .HasColumnType("tinyint(1)");
89
90 b.Property<string>("Tag")
91 .HasColumnType("longtext CHARACTER SET utf8mb4")
92 .HasMaxLength(10000);
93
94 b.HasKey("Id");
95
96 b.HasIndex("ChatSettingsId", "DiscordChannelId")
97 .IsUnique();
98
99 b.HasIndex("ChatSettingsId", "IrcChannel")
100 .IsUnique();
101
102 b.ToTable("ChatChannels");
103 });
104
105 modelBuilder.Entity("Tgstation.Server.Host.Models.CompileJob", b =>
106 {
107 b.Property<long>("Id")
108 .ValueGeneratedOnAdd()
109 .HasColumnType("bigint");
110
111 b.Property<string>("ByondVersion")
112 .IsRequired()
113 .HasColumnType("longtext CHARACTER SET utf8mb4");
114
115 b.Property<int?>("DMApiMajorVersion")
116 .HasColumnType("int");
117
118 b.Property<int?>("DMApiMinorVersion")
119 .HasColumnType("int");
120
121 b.Property<int?>("DMApiPatchVersion")
122 .HasColumnType("int");
123
124 b.Property<Guid?>("DirectoryName")
125 .IsRequired()
126 .HasColumnType("char(36)");
127
128 b.Property<string>("DmeName")
129 .IsRequired()
130 .HasColumnType("longtext CHARACTER SET utf8mb4");
131
132 b.Property<long>("JobId")
133 .HasColumnType("bigint");
134
135 b.Property<int>("MinimumSecurityLevel")
136 .HasColumnType("int");
137
138 b.Property<string>("Output")
139 .IsRequired()
140 .HasColumnType("longtext CHARACTER SET utf8mb4");
141
142 b.Property<long>("RevisionInformationId")
143 .HasColumnType("bigint");
144
145 b.HasKey("Id");
146
147 b.HasIndex("DirectoryName");
148
149 b.HasIndex("JobId")
150 .IsUnique();
151
152 b.HasIndex("RevisionInformationId");
153
154 b.ToTable("CompileJobs");
155 });
156
157 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
158 {
159 b.Property<long>("Id")
160 .ValueGeneratedOnAdd()
161 .HasColumnType("bigint");
162
163 b.Property<string>("AccessToken")
164 .HasColumnType("longtext CHARACTER SET utf8mb4");
165
166 b.Property<bool?>("AllowWebClient")
167 .IsRequired()
168 .HasColumnType("tinyint(1)");
169
170 b.Property<bool?>("AutoStart")
171 .IsRequired()
172 .HasColumnType("tinyint(1)");
173
174 b.Property<uint?>("HeartbeatSeconds")
175 .IsRequired()
176 .HasColumnType("int unsigned");
177
178 b.Property<long>("InstanceId")
179 .HasColumnType("bigint");
180
181 b.Property<ushort?>("PrimaryPort")
182 .IsRequired()
183 .HasColumnType("smallint unsigned");
184
185 b.Property<int?>("ProcessId")
186 .HasColumnType("int");
187
188 b.Property<ushort?>("SecondaryPort")
189 .IsRequired()
190 .HasColumnType("smallint unsigned");
191
192 b.Property<int>("SecurityLevel")
193 .HasColumnType("int");
194
195 b.Property<bool?>("SoftRestart")
196 .IsRequired()
197 .HasColumnType("tinyint(1)");
198
199 b.Property<bool?>("SoftShutdown")
200 .IsRequired()
201 .HasColumnType("tinyint(1)");
202
203 b.Property<uint?>("StartupTimeout")
204 .IsRequired()
205 .HasColumnType("int unsigned");
206
207 b.HasKey("Id");
208
209 b.HasIndex("InstanceId")
210 .IsUnique();
211
212 b.ToTable("DreamDaemonSettings");
213 });
214
215 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamMakerSettings", b =>
216 {
217 b.Property<long>("Id")
218 .ValueGeneratedOnAdd()
219 .HasColumnType("bigint");
220
221 b.Property<ushort?>("ApiValidationPort")
222 .IsRequired()
223 .HasColumnType("smallint unsigned");
224
225 b.Property<int>("ApiValidationSecurityLevel")
226 .HasColumnType("int");
227
228 b.Property<long>("InstanceId")
229 .HasColumnType("bigint");
230
231 b.Property<string>("ProjectName")
232 .HasColumnType("longtext CHARACTER SET utf8mb4")
233 .HasMaxLength(10000);
234
235 b.HasKey("Id");
236
237 b.HasIndex("InstanceId")
238 .IsUnique();
239
240 b.ToTable("DreamMakerSettings");
241 });
242
243 modelBuilder.Entity("Tgstation.Server.Host.Models.Instance", b =>
244 {
245 b.Property<long>("Id")
246 .ValueGeneratedOnAdd()
247 .HasColumnType("bigint");
248
249 b.Property<uint?>("AutoUpdateInterval")
250 .IsRequired()
251 .HasColumnType("int unsigned");
252
253 b.Property<ushort?>("ChatBotLimit")
254 .IsRequired()
255 .HasColumnType("smallint unsigned");
256
257 b.Property<int>("ConfigurationType")
258 .HasColumnType("int");
259
260 b.Property<string>("Name")
261 .IsRequired()
262 .HasColumnType("longtext CHARACTER SET utf8mb4")
263 .HasMaxLength(10000);
264
265 b.Property<bool?>("Online")
266 .IsRequired()
267 .HasColumnType("tinyint(1)");
268
269 b.Property<string>("Path")
270 .IsRequired()
271 .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
272
273 b.HasKey("Id");
274
275 b.HasIndex("Path")
276 .IsUnique();
277
278 b.ToTable("Instances");
279 });
280
281 modelBuilder.Entity("Tgstation.Server.Host.Models.InstanceUser", b =>
282 {
283 b.Property<long>("Id")
284 .ValueGeneratedOnAdd()
285 .HasColumnType("bigint");
286
287 b.Property<ulong>("ByondRights")
288 .HasColumnType("bigint unsigned");
289
290 b.Property<ulong>("ChatBotRights")
291 .HasColumnType("bigint unsigned");
292
293 b.Property<ulong>("ConfigurationRights")
294 .HasColumnType("bigint unsigned");
295
296 b.Property<ulong>("DreamDaemonRights")
297 .HasColumnType("bigint unsigned");
298
299 b.Property<ulong>("DreamMakerRights")
300 .HasColumnType("bigint unsigned");
301
302 b.Property<long>("InstanceId")
303 .HasColumnType("bigint");
304
305 b.Property<ulong>("InstanceUserRights")
306 .HasColumnType("bigint unsigned");
307
308 b.Property<ulong>("RepositoryRights")
309 .HasColumnType("bigint unsigned");
310
311 b.Property<long?>("UserId")
312 .IsRequired()
313 .HasColumnType("bigint");
314
315 b.HasKey("Id");
316
317 b.HasIndex("InstanceId");
318
319 b.HasIndex("UserId", "InstanceId")
320 .IsUnique();
321
322 b.ToTable("InstanceUsers");
323 });
324
325 modelBuilder.Entity("Tgstation.Server.Host.Models.Job", b =>
326 {
327 b.Property<long>("Id")
328 .ValueGeneratedOnAdd()
329 .HasColumnType("bigint");
330
331 b.Property<ulong?>("CancelRight")
332 .HasColumnType("bigint unsigned");
333
334 b.Property<ulong?>("CancelRightsType")
335 .HasColumnType("bigint unsigned");
336
337 b.Property<bool?>("Cancelled")
338 .IsRequired()
339 .HasColumnType("tinyint(1)");
340
341 b.Property<long?>("CancelledById")
342 .HasColumnType("bigint");
343
344 b.Property<string>("Description")
345 .IsRequired()
346 .HasColumnType("longtext CHARACTER SET utf8mb4");
347
348 b.Property<uint?>("ErrorCode")
349 .HasColumnType("int unsigned");
350
351 b.Property<string>("ExceptionDetails")
352 .HasColumnType("longtext CHARACTER SET utf8mb4");
353
354 b.Property<long>("InstanceId")
355 .HasColumnType("bigint");
356
357 b.Property<DateTimeOffset?>("StartedAt")
358 .IsRequired()
359 .HasColumnType("datetime(6)");
360
361 b.Property<long>("StartedById")
362 .HasColumnType("bigint");
363
364 b.Property<DateTimeOffset?>("StoppedAt")
365 .HasColumnType("datetime(6)");
366
367 b.HasKey("Id");
368
369 b.HasIndex("CancelledById");
370
371 b.HasIndex("InstanceId");
372
373 b.HasIndex("StartedById");
374
375 b.ToTable("Jobs");
376 });
377
378 modelBuilder.Entity("Tgstation.Server.Host.Models.ReattachInformation", b =>
379 {
380 b.Property<long>("Id")
381 .ValueGeneratedOnAdd()
382 .HasColumnType("bigint");
383
384 b.Property<string>("AccessIdentifier")
385 .IsRequired()
386 .HasColumnType("longtext CHARACTER SET utf8mb4");
387
388 b.Property<long>("CompileJobId")
389 .HasColumnType("bigint");
390
391 b.Property<bool>("IsPrimary")
392 .HasColumnType("tinyint(1)");
393
394 b.Property<int>("LaunchSecurityLevel")
395 .HasColumnType("int");
396
397 b.Property<ushort>("Port")
398 .HasColumnType("smallint unsigned");
399
400 b.Property<int>("ProcessId")
401 .HasColumnType("int");
402
403 b.Property<int>("RebootState")
404 .HasColumnType("int");
405
406 b.HasKey("Id");
407
408 b.HasIndex("CompileJobId");
409
410 b.ToTable("ReattachInformations");
411 });
412
413 modelBuilder.Entity("Tgstation.Server.Host.Models.RepositorySettings", b =>
414 {
415 b.Property<long>("Id")
416 .ValueGeneratedOnAdd()
417 .HasColumnType("bigint");
418
419 b.Property<string>("AccessToken")
420 .HasColumnType("longtext CHARACTER SET utf8mb4")
421 .HasMaxLength(10000);
422
423 b.Property<string>("AccessUser")
424 .HasColumnType("longtext CHARACTER SET utf8mb4")
425 .HasMaxLength(10000);
426
427 b.Property<bool?>("AutoUpdatesKeepTestMerges")
428 .IsRequired()
429 .HasColumnType("tinyint(1)");
430
431 b.Property<bool?>("AutoUpdatesSynchronize")
432 .IsRequired()
433 .HasColumnType("tinyint(1)");
434
435 b.Property<string>("CommitterEmail")
436 .IsRequired()
437 .HasColumnType("longtext CHARACTER SET utf8mb4")
438 .HasMaxLength(10000);
439
440 b.Property<string>("CommitterName")
441 .IsRequired()
442 .HasColumnType("longtext CHARACTER SET utf8mb4")
443 .HasMaxLength(10000);
444
445 b.Property<long>("InstanceId")
446 .HasColumnType("bigint");
447
448 b.Property<bool?>("PostTestMergeComment")
449 .IsRequired()
450 .HasColumnType("tinyint(1)");
451
452 b.Property<bool?>("PushTestMergeCommits")
453 .IsRequired()
454 .HasColumnType("tinyint(1)");
455
456 b.Property<bool?>("ShowTestMergeCommitters")
457 .IsRequired()
458 .HasColumnType("tinyint(1)");
459
460 b.HasKey("Id");
461
462 b.HasIndex("InstanceId")
463 .IsUnique();
464
465 b.ToTable("RepositorySettings");
466 });
467
468 modelBuilder.Entity("Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
469 {
470 b.Property<long>("Id")
471 .ValueGeneratedOnAdd()
472 .HasColumnType("bigint");
473
474 b.Property<long>("RevisionInformationId")
475 .HasColumnType("bigint");
476
477 b.Property<long>("TestMergeId")
478 .HasColumnType("bigint");
479
480 b.HasKey("Id");
481
482 b.HasIndex("RevisionInformationId");
483
484 b.HasIndex("TestMergeId");
485
486 b.ToTable("RevInfoTestMerges");
487 });
488
489 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
490 {
491 b.Property<long>("Id")
492 .ValueGeneratedOnAdd()
493 .HasColumnType("bigint");
494
495 b.Property<string>("CommitSha")
496 .IsRequired()
497 .HasColumnType("varchar(40) CHARACTER SET utf8mb4")
498 .HasMaxLength(40);
499
500 b.Property<long>("InstanceId")
501 .HasColumnType("bigint");
502
503 b.Property<string>("OriginCommitSha")
504 .IsRequired()
505 .HasColumnType("varchar(40) CHARACTER SET utf8mb4")
506 .HasMaxLength(40);
507
508 b.HasKey("Id");
509
510 b.HasIndex("InstanceId", "CommitSha")
511 .IsUnique();
512
513 b.ToTable("RevisionInformations");
514 });
515
516 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
517 {
518 b.Property<long>("Id")
519 .ValueGeneratedOnAdd()
520 .HasColumnType("bigint");
521
522 b.Property<string>("Author")
523 .IsRequired()
524 .HasColumnType("longtext CHARACTER SET utf8mb4");
525
526 b.Property<string>("BodyAtMerge")
527 .IsRequired()
528 .HasColumnType("longtext CHARACTER SET utf8mb4");
529
530 b.Property<string>("Comment")
531 .HasColumnType("longtext CHARACTER SET utf8mb4")
532 .HasMaxLength(10000);
533
534 b.Property<DateTimeOffset>("MergedAt")
535 .HasColumnType("datetime(6)");
536
537 b.Property<long>("MergedById")
538 .HasColumnType("bigint");
539
540 b.Property<int>("Number")
541 .HasColumnType("int");
542
543 b.Property<long?>("PrimaryRevisionInformationId")
544 .IsRequired()
545 .HasColumnType("bigint");
546
547 b.Property<string>("PullRequestRevision")
548 .IsRequired()
549 .HasColumnType("varchar(40) CHARACTER SET utf8mb4")
550 .HasMaxLength(40);
551
552 b.Property<string>("TitleAtMerge")
553 .IsRequired()
554 .HasColumnType("longtext CHARACTER SET utf8mb4");
555
556 b.Property<string>("Url")
557 .IsRequired()
558 .HasColumnType("longtext CHARACTER SET utf8mb4");
559
560 b.HasKey("Id");
561
562 b.HasIndex("MergedById");
563
564 b.HasIndex("PrimaryRevisionInformationId")
565 .IsUnique();
566
567 b.ToTable("TestMerges");
568 });
569
570 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
571 {
572 b.Property<long?>("Id")
573 .ValueGeneratedOnAdd()
574 .HasColumnType("bigint");
575
576 b.Property<ulong>("AdministrationRights")
577 .HasColumnType("bigint unsigned");
578
579 b.Property<string>("CanonicalName")
580 .IsRequired()
581 .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
582
583 b.Property<DateTimeOffset?>("CreatedAt")
584 .IsRequired()
585 .HasColumnType("datetime(6)");
586
587 b.Property<long?>("CreatedById")
588 .HasColumnType("bigint");
589
590 b.Property<bool?>("Enabled")
591 .IsRequired()
592 .HasColumnType("tinyint(1)");
593
594 b.Property<ulong>("InstanceManagerRights")
595 .HasColumnType("bigint unsigned");
596
597 b.Property<DateTimeOffset?>("LastPasswordUpdate")
598 .HasColumnType("datetime(6)");
599
600 b.Property<string>("Name")
601 .IsRequired()
602 .HasColumnType("longtext CHARACTER SET utf8mb4")
603 .HasMaxLength(10000);
604
605 b.Property<string>("PasswordHash")
606 .HasColumnType("longtext CHARACTER SET utf8mb4");
607
608 b.Property<string>("SystemIdentifier")
609 .HasColumnType("varchar(255) CHARACTER SET utf8mb4");
610
611 b.HasKey("Id");
612
613 b.HasIndex("CanonicalName")
614 .IsUnique();
615
616 b.HasIndex("CreatedById");
617
618 b.HasIndex("SystemIdentifier")
619 .IsUnique();
620
621 b.ToTable("Users");
622 });
623
624 modelBuilder.Entity("Tgstation.Server.Host.Models.WatchdogReattachInformation", b =>
625 {
626 b.Property<long>("Id")
627 .ValueGeneratedOnAdd()
628 .HasColumnType("bigint");
629
630 b.Property<long?>("AlphaId")
631 .HasColumnType("bigint");
632
633 b.Property<bool>("AlphaIsActive")
634 .HasColumnType("tinyint(1)");
635
636 b.Property<long?>("BravoId")
637 .HasColumnType("bigint");
638
639 b.Property<long>("InstanceId")
640 .HasColumnType("bigint");
641
642 b.HasKey("Id");
643
644 b.HasIndex("AlphaId");
645
646 b.HasIndex("BravoId");
647
648 b.HasIndex("InstanceId")
649 .IsUnique();
650
651 b.ToTable("WatchdogReattachInformations");
652 });
653
654 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
655 {
656 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
657 .WithMany("ChatSettings")
658 .HasForeignKey("InstanceId")
659 .OnDelete(DeleteBehavior.Cascade)
660 .IsRequired();
661 });
662
663 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatChannel", b =>
664 {
665 b.HasOne("Tgstation.Server.Host.Models.ChatBot", "ChatSettings")
666 .WithMany("Channels")
667 .HasForeignKey("ChatSettingsId")
668 .OnDelete(DeleteBehavior.Cascade)
669 .IsRequired();
670 });
671
672 modelBuilder.Entity("Tgstation.Server.Host.Models.CompileJob", b =>
673 {
674 b.HasOne("Tgstation.Server.Host.Models.Job", "Job")
675 .WithOne()
676 .HasForeignKey("Tgstation.Server.Host.Models.CompileJob", "JobId")
677 .OnDelete(DeleteBehavior.Cascade)
678 .IsRequired();
679
680 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "RevisionInformation")
681 .WithMany("CompileJobs")
682 .HasForeignKey("RevisionInformationId")
683 .OnDelete(DeleteBehavior.ClientNoAction)
684 .IsRequired();
685 });
686
687 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
688 {
689 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
690 .WithOne("DreamDaemonSettings")
691 .HasForeignKey("Tgstation.Server.Host.Models.DreamDaemonSettings", "InstanceId")
692 .OnDelete(DeleteBehavior.Cascade)
693 .IsRequired();
694 });
695
696 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamMakerSettings", b =>
697 {
698 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
699 .WithOne("DreamMakerSettings")
700 .HasForeignKey("Tgstation.Server.Host.Models.DreamMakerSettings", "InstanceId")
701 .OnDelete(DeleteBehavior.Cascade)
702 .IsRequired();
703 });
704
705 modelBuilder.Entity("Tgstation.Server.Host.Models.InstanceUser", b =>
706 {
707 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
708 .WithMany("InstanceUsers")
709 .HasForeignKey("InstanceId")
710 .OnDelete(DeleteBehavior.Cascade)
711 .IsRequired();
712
713 b.HasOne("Tgstation.Server.Host.Models.User", null)
714 .WithMany("InstanceUsers")
715 .HasForeignKey("UserId")
716 .OnDelete(DeleteBehavior.Cascade)
717 .IsRequired();
718 });
719
720 modelBuilder.Entity("Tgstation.Server.Host.Models.Job", b =>
721 {
722 b.HasOne("Tgstation.Server.Host.Models.User", "CancelledBy")
723 .WithMany()
724 .HasForeignKey("CancelledById");
725
726 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
727 .WithMany("Jobs")
728 .HasForeignKey("InstanceId")
729 .OnDelete(DeleteBehavior.Cascade)
730 .IsRequired();
731
732 b.HasOne("Tgstation.Server.Host.Models.User", "StartedBy")
733 .WithMany()
734 .HasForeignKey("StartedById")
735 .OnDelete(DeleteBehavior.Cascade)
736 .IsRequired();
737 });
738
739 modelBuilder.Entity("Tgstation.Server.Host.Models.ReattachInformation", b =>
740 {
741 b.HasOne("Tgstation.Server.Host.Models.CompileJob", "CompileJob")
742 .WithMany()
743 .HasForeignKey("CompileJobId")
744 .OnDelete(DeleteBehavior.Cascade)
745 .IsRequired();
746 });
747
748 modelBuilder.Entity("Tgstation.Server.Host.Models.RepositorySettings", b =>
749 {
750 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
751 .WithOne("RepositorySettings")
752 .HasForeignKey("Tgstation.Server.Host.Models.RepositorySettings", "InstanceId")
753 .OnDelete(DeleteBehavior.Cascade)
754 .IsRequired();
755 });
756
757 modelBuilder.Entity("Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
758 {
759 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "RevisionInformation")
760 .WithMany("ActiveTestMerges")
761 .HasForeignKey("RevisionInformationId")
762 .OnDelete(DeleteBehavior.Cascade)
763 .IsRequired();
764
765 b.HasOne("Tgstation.Server.Host.Models.TestMerge", "TestMerge")
766 .WithMany("RevisonInformations")
767 .HasForeignKey("TestMergeId")
768 .OnDelete(DeleteBehavior.ClientNoAction)
769 .IsRequired();
770 });
771
772 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
773 {
774 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
775 .WithMany("RevisionInformations")
776 .HasForeignKey("InstanceId")
777 .OnDelete(DeleteBehavior.Cascade)
778 .IsRequired();
779 });
780
781 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
782 {
783 b.HasOne("Tgstation.Server.Host.Models.User", "MergedBy")
784 .WithMany("TestMerges")
785 .HasForeignKey("MergedById")
786 .OnDelete(DeleteBehavior.Restrict)
787 .IsRequired();
788
789 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "PrimaryRevisionInformation")
790 .WithOne("PrimaryTestMerge")
791 .HasForeignKey("Tgstation.Server.Host.Models.TestMerge", "PrimaryRevisionInformationId")
792 .OnDelete(DeleteBehavior.Cascade)
793 .IsRequired();
794 });
795
796 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
797 {
798 b.HasOne("Tgstation.Server.Host.Models.User", "CreatedBy")
799 .WithMany("CreatedUsers")
800 .HasForeignKey("CreatedById");
801 });
802
803 modelBuilder.Entity("Tgstation.Server.Host.Models.WatchdogReattachInformation", b =>
804 {
805 b.HasOne("Tgstation.Server.Host.Models.ReattachInformation", "Alpha")
806 .WithMany()
807 .HasForeignKey("AlphaId");
808
809 b.HasOne("Tgstation.Server.Host.Models.ReattachInformation", "Bravo")
810 .WithMany()
811 .HasForeignKey("BravoId");
812
813 b.HasOne("Tgstation.Server.Host.Models.Instance", null)
814 .WithOne("WatchdogReattachInformation")
815 .HasForeignKey("Tgstation.Server.Host.Models.WatchdogReattachInformation", "InstanceId")
816 .OnDelete(DeleteBehavior.Cascade)
817 .IsRequired();
818 });
819#pragma warning restore 612, 618
820 }
821 }
822}