KlusterKite  0.0.0
A framework to create scalable and redundant services based on awesome Akka.Net project.
20170720151448_Init.Designer.cs
Go to the documentation of this file.
1 //<aut-generated/>
2 using System;
3 using Microsoft.EntityFrameworkCore;
4 using Microsoft.EntityFrameworkCore.Infrastructure;
5 using Microsoft.EntityFrameworkCore.Metadata;
6 using Microsoft.EntityFrameworkCore.Migrations;
9 
10 namespace KlusterKite.NodeManager.ConfigurationSource.Migrations
11 {
12  [DbContext(typeof(ConfigurationContext))]
13  [Migration("20170720151448_Init")]
14  partial class Init
15  {
16  protected override void BuildTargetModel(ModelBuilder modelBuilder)
17  {
18  modelBuilder
19  .HasAnnotation("ProductVersion", "1.1.2");
20 
21  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.CompatibleTemplate", b =>
22  {
23  b.Property<int>("Id")
24  .ValueGeneratedOnAdd()
25  .HasColumnType("serial");
26 
27  b.Property<int>("CompatibleConfigurationId");
28 
29  b.Property<int>("ConfigurationId");
30 
31  b.Property<string>("TemplateCode");
32 
33  b.HasKey("Id");
34 
35  b.HasIndex("CompatibleConfigurationId");
36 
37  b.HasIndex("ConfigurationId");
38 
39  b.ToTable("CompatibleTemplate");
40  });
41 
42  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.Configuration", b =>
43  {
44  b.Property<int>("Id")
45  .ValueGeneratedOnAdd()
46  .HasColumnType("serial");
47 
48  b.Property<DateTimeOffset>("Created");
49 
50  b.Property<DateTimeOffset?>("Finished");
51 
52  b.Property<bool>("IsStable");
53 
54  b.Property<int>("MajorVersion");
55 
56  b.Property<int>("MinorVersion");
57 
58  b.Property<string>("Name");
59 
60  b.Property<string>("Notes");
61 
62  b.Property<string>("SettingsJson");
63 
64  b.Property<DateTimeOffset?>("Started");
65 
66  b.Property<int>("State");
67 
68  b.HasKey("Id");
69 
70  b.ToTable("Configurations");
71  });
72 
73  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.Migration", b =>
74  {
75  b.Property<int>("Id")
76  .ValueGeneratedOnAdd()
77  .HasColumnType("serial");
78 
79  b.Property<DateTimeOffset?>("Finished");
80 
81  b.Property<int>("FromConfigurationId");
82 
83  b.Property<bool>("IsActive");
84 
85  b.Property<DateTimeOffset>("Started");
86 
87  b.Property<int>("State");
88 
89  b.Property<int>("ToConfigurationId");
90 
91  b.HasKey("Id");
92 
93  b.HasIndex("FromConfigurationId");
94 
95  b.HasIndex("ToConfigurationId");
96 
97  b.ToTable("Migrations");
98  });
99 
100  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.MigrationLogRecord", b =>
101  {
102  b.Property<int>("Id")
103  .ValueGeneratedOnAdd()
104  .HasColumnType("serial");
105 
106  b.Property<int>("ConfigurationId");
107 
108  b.Property<string>("DestinationPoint");
109 
110  b.Property<string>("ErrorStackTrace");
111 
112  b.Property<DateTimeOffset?>("Finished");
113 
114  b.Property<string>("Message");
115 
116  b.Property<int?>("MigrationId");
117 
118  b.Property<string>("MigratorName");
119 
120  b.Property<string>("MigratorTemplateCode");
121 
122  b.Property<string>("MigratorTemplateName");
123 
124  b.Property<string>("MigratorTypeName");
125 
126  b.Property<string>("ResourceCode");
127 
128  b.Property<string>("ResourceName");
129 
130  b.Property<string>("SourcePoint");
131 
132  b.Property<DateTimeOffset>("Started");
133 
134  b.Property<int>("Type");
135 
136  b.HasKey("Id");
137 
138  b.HasIndex("ConfigurationId");
139 
140  b.HasIndex("MigrationId");
141 
142  b.ToTable("MigrationLogRecords");
143  });
144 
145  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.Role", b =>
146  {
147  b.Property<Guid>("Uid")
148  .ValueGeneratedOnAdd();
149 
150  b.Property<string>("AllowedScopeJson");
151 
152  b.Property<string>("DeniedScopeJson");
153 
154  b.Property<string>("Name");
155 
156  b.HasKey("Uid");
157 
158  b.ToTable("Roles");
159  });
160 
161  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.RoleUser", b =>
162  {
163  b.Property<Guid>("UserUid");
164 
165  b.Property<Guid>("RoleUid");
166 
167  b.Property<int>("Id")
168  .ValueGeneratedOnAdd()
169  .HasColumnType("serial");
170 
171  b.HasKey("UserUid", "RoleUid");
172 
173  b.HasAlternateKey("Id");
174 
175  b.HasIndex("RoleUid");
176 
177  b.ToTable("RoleUsers");
178  });
179 
180  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.User", b =>
181  {
182  b.Property<Guid>("Uid")
183  .ValueGeneratedOnAdd();
184 
185  b.Property<DateTimeOffset?>("ActiveTill");
186 
187  b.Property<DateTimeOffset?>("BlockedTill");
188 
189  b.Property<bool>("IsBlocked");
190 
191  b.Property<bool>("IsDeleted");
192 
193  b.Property<string>("Login");
194 
195  b.Property<string>("Password");
196 
197  b.HasKey("Uid");
198 
199  b.HasIndex("Login");
200 
201  b.ToTable("Users");
202  });
203 
204  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.CompatibleTemplate", b =>
205  {
206  b.HasOne("KlusterKite.NodeManager.Client.ORM.Configuration", "CompatibleConfiguration")
207  .WithMany("CompatibleTemplatesForward")
208  .HasForeignKey("CompatibleConfigurationId")
209  .OnDelete(DeleteBehavior.Cascade);
210 
211  b.HasOne("KlusterKite.NodeManager.Client.ORM.Configuration", "Configuration")
212  .WithMany("CompatibleTemplatesBackward")
213  .HasForeignKey("ConfigurationId")
214  .OnDelete(DeleteBehavior.Cascade);
215  });
216 
217  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.Migration", b =>
218  {
219  b.HasOne("KlusterKite.NodeManager.Client.ORM.Configuration", "FromConfiguration")
220  .WithMany()
221  .HasForeignKey("FromConfigurationId")
222  .OnDelete(DeleteBehavior.Cascade);
223 
224  b.HasOne("KlusterKite.NodeManager.Client.ORM.Configuration", "ToConfiguration")
225  .WithMany()
226  .HasForeignKey("ToConfigurationId")
227  .OnDelete(DeleteBehavior.Cascade);
228  });
229 
230  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.MigrationLogRecord", b =>
231  {
232  b.HasOne("KlusterKite.NodeManager.Client.ORM.Configuration", "Configuration")
233  .WithMany("MigrationLogs")
234  .HasForeignKey("ConfigurationId")
235  .OnDelete(DeleteBehavior.Cascade);
236 
237  b.HasOne("KlusterKite.NodeManager.Client.ORM.Migration", "Migration")
238  .WithMany("Logs")
239  .HasForeignKey("MigrationId");
240  });
241 
242  modelBuilder.Entity("KlusterKite.NodeManager.Client.ORM.RoleUser", b =>
243  {
244  b.HasOne("KlusterKite.NodeManager.Client.ORM.Role", "Role")
245  .WithMany("Users")
246  .HasForeignKey("RoleUid")
247  .OnDelete(DeleteBehavior.Cascade);
248 
249  b.HasOne("KlusterKite.NodeManager.Client.ORM.User", "User")
250  .WithMany("Roles")
251  .HasForeignKey("UserUid")
252  .OnDelete(DeleteBehavior.Cascade);
253  });
254  }
255  }
256 }
The history record describing cluster migration
Definition: Migration.cs:26