using System; using System.Collections.Generic; using Microsoft.EntityFrameworkCore.Migrations; namespace Sample.Kafka.Migrations { public partial class CreateDatabase : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.CreateTable( name: "ReceivedMessages", columns: table => new { Id = table.Column(nullable: false), Added = table.Column(nullable: false), Content = table.Column(nullable: true), KeyName = table.Column(nullable: true), LastRun = table.Column(nullable: false), Retries = table.Column(nullable: false), StateName = table.Column(maxLength: 50, nullable: true) }, constraints: table => { table.PrimaryKey("PK_ReceivedMessages", x => x.Id); }); migrationBuilder.CreateTable( name: "SentMessages", columns: table => new { Id = table.Column(nullable: false), Added = table.Column(nullable: false), Content = table.Column(nullable: true), KeyName = table.Column(nullable: true), LastRun = table.Column(nullable: false), Retries = table.Column(nullable: false), StateName = table.Column(maxLength: 50, nullable: true) }, constraints: table => { table.PrimaryKey("PK_SentMessages", x => x.Id); }); } protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.DropTable( name: "ReceivedMessages"); migrationBuilder.DropTable( name: "SentMessages"); } } }