Skip to content

Commit

Permalink
Merge pull request #1463 from AndersAbel/anders/serversidesessions-long
Browse files Browse the repository at this point in the history
Change ServerSideSession.Id to long
  • Loading branch information
brockallen authored Nov 10, 2023
2 parents 0730403 + 5943d4d commit 4ac7e46
Show file tree
Hide file tree
Showing 9 changed files with 25 additions and 25 deletions.
2 changes: 1 addition & 1 deletion migrations/IdentityServerDb/Migrations/ConfigurationDb.sql
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ CREATE UNIQUE INDEX [IX_IdentityResources_Name] ON [IdentityResources] ([Name]);
GO

INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
VALUES (N'20231006192633_Configuration', N'8.0.0-preview.7.23375.4');
VALUES (N'20231110071401_Configuration', N'8.0.0-rc.2.23480.1');
GO

COMMIT;
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "8.0.0-preview.7.23375.4")
.HasAnnotation("ProductVersion", "8.0.0-rc.2.23480.1")
.HasAnnotation("Relational:MaxIdentifierLength", 128);

SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
Expand Down
6 changes: 3 additions & 3 deletions migrations/IdentityServerDb/Migrations/PersistedGrantDb.sql
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ CREATE TABLE [PersistedGrants] (
GO

CREATE TABLE [PushedAuthorizationRequests] (
[Id] int NOT NULL IDENTITY,
[Id] bigint NOT NULL IDENTITY,
[ReferenceValueHash] nvarchar(64) NOT NULL,
[ExpiresAtUtc] datetime2 NOT NULL,
[Parameters] nvarchar(max) NOT NULL,
Expand All @@ -64,7 +64,7 @@ CREATE TABLE [PushedAuthorizationRequests] (
GO

CREATE TABLE [ServerSideSessions] (
[Id] int NOT NULL IDENTITY,
[Id] bigint NOT NULL IDENTITY,
[Key] nvarchar(100) NOT NULL,
[Scheme] nvarchar(100) NOT NULL,
[SubjectId] nvarchar(100) NOT NULL,
Expand Down Expand Up @@ -121,7 +121,7 @@ CREATE INDEX [IX_ServerSideSessions_SubjectId] ON [ServerSideSessions] ([Subject
GO

INSERT INTO [__EFMigrationsHistory] ([MigrationId], [ProductVersion])
VALUES (N'20231006192628_Grants', N'8.0.0-preview.7.23375.4');
VALUES (N'20231110071347_Grants', N'8.0.0-rc.2.23480.1');
GO

COMMIT;
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ protected override void Up(MigrationBuilder migrationBuilder)
name: "PushedAuthorizationRequests",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
Id = table.Column<long>(type: "bigint", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
ReferenceValueHash = table.Column<string>(type: "nvarchar(64)", maxLength: 64, nullable: false),
ExpiresAtUtc = table.Column<DateTime>(type: "datetime2", nullable: false),
Expand All @@ -89,7 +89,7 @@ protected override void Up(MigrationBuilder migrationBuilder)
name: "ServerSideSessions",
columns: table => new
{
Id = table.Column<int>(type: "int", nullable: false)
Id = table.Column<long>(type: "bigint", nullable: false)
.Annotation("SqlServer:Identity", "1, 1"),
Key = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: false),
Scheme = table.Column<string>(type: "nvarchar(100)", maxLength: 100, nullable: false),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ protected override void BuildModel(ModelBuilder modelBuilder)
{
#pragma warning disable 612, 618
modelBuilder
.HasAnnotation("ProductVersion", "8.0.0-preview.7.23375.4")
.HasAnnotation("ProductVersion", "8.0.0-rc.2.23480.1")
.HasAnnotation("Relational:MaxIdentifierLength", 128);

SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder);
Expand Down Expand Up @@ -175,11 +175,11 @@ protected override void BuildModel(ModelBuilder modelBuilder)

modelBuilder.Entity("Duende.IdentityServer.EntityFramework.Entities.PushedAuthorizationRequest", b =>
{
b.Property<int>("Id")
b.Property<long>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("int");
.HasColumnType("bigint");
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
b.Property<DateTime>("ExpiresAtUtc")
.HasColumnType("datetime2");
Expand All @@ -203,11 +203,11 @@ protected override void BuildModel(ModelBuilder modelBuilder)

modelBuilder.Entity("Duende.IdentityServer.EntityFramework.Entities.ServerSideSession", b =>
{
b.Property<int>("Id")
b.Property<long>("Id")
.ValueGeneratedOnAdd()
.HasColumnType("int");
.HasColumnType("bigint");
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<int>("Id"));
SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property<long>("Id"));
b.Property<DateTime>("Created")
.HasColumnType("datetime2");
Expand Down
2 changes: 1 addition & 1 deletion src/EntityFramework.Storage/Entities/ServerSideSession.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ namespace Duende.IdentityServer.EntityFramework.Entities;

public class ServerSideSession
{
public int Id { get; set; }
public long Id { get; set; }
public string Key { get; set; }
public string Scheme { get; set; }
public string SubjectId { get; set; }
Expand Down

0 comments on commit 4ac7e46

Please sign in to comment.