From 4123a45942309b109ef140e29dc2dec3daefde40 Mon Sep 17 00:00:00 2001 From: Erik Shafer Date: Wed, 22 May 2024 12:48:31 -0500 Subject: [PATCH 1/5] changed 00 project name/space --- .../Events/Event.cs | 2 +- .../Events/StudentCreated.cs | 2 +- .../Events/StudentEnrolled.cs | 2 +- .../Events/StudentUnEnrolled.cs | 2 +- .../Events/StudentUpdated.cs | 2 +- .../InMemoryDatabase.cs | 4 ++-- .../Program.cs | 4 ++-- .../Student.cs | 4 ++-- .../StudentEnrollment00.InMemory.csproj | 0 StudentEnrollmentConsoleApp.sln | 2 +- 10 files changed, 12 insertions(+), 12 deletions(-) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Events/Event.cs (72%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Events/StudentCreated.cs (86%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Events/StudentEnrolled.cs (80%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Events/StudentUnEnrolled.cs (80%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Events/StudentUpdated.cs (83%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/InMemoryDatabase.cs (91%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Program.cs (88%) rename {StudentEnrollment00 => StudentEnrollment00.InMemory}/Student.cs (94%) rename StudentEnrollment00/StudentEnrollment00.csproj => StudentEnrollment00.InMemory/StudentEnrollment00.InMemory.csproj (100%) diff --git a/StudentEnrollment00/Events/Event.cs b/StudentEnrollment00.InMemory/Events/Event.cs similarity index 72% rename from StudentEnrollment00/Events/Event.cs rename to StudentEnrollment00.InMemory/Events/Event.cs index f98a116..f445ce5 100644 --- a/StudentEnrollment00/Events/Event.cs +++ b/StudentEnrollment00.InMemory/Events/Event.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.Events; +namespace StudentEnrollment00.InMemory.Events; public abstract class Event { diff --git a/StudentEnrollment00/Events/StudentCreated.cs b/StudentEnrollment00.InMemory/Events/StudentCreated.cs similarity index 86% rename from StudentEnrollment00/Events/StudentCreated.cs rename to StudentEnrollment00.InMemory/Events/StudentCreated.cs index 5dd0e21..dccf050 100644 --- a/StudentEnrollment00/Events/StudentCreated.cs +++ b/StudentEnrollment00.InMemory/Events/StudentCreated.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.Events; +namespace StudentEnrollment00.InMemory.Events; public class StudentCreated : Event { diff --git a/StudentEnrollment00/Events/StudentEnrolled.cs b/StudentEnrollment00.InMemory/Events/StudentEnrolled.cs similarity index 80% rename from StudentEnrollment00/Events/StudentEnrolled.cs rename to StudentEnrollment00.InMemory/Events/StudentEnrolled.cs index f75c385..2de6414 100644 --- a/StudentEnrollment00/Events/StudentEnrolled.cs +++ b/StudentEnrollment00.InMemory/Events/StudentEnrolled.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.Events; +namespace StudentEnrollment00.InMemory.Events; public class StudentEnrolled : Event { diff --git a/StudentEnrollment00/Events/StudentUnEnrolled.cs b/StudentEnrollment00.InMemory/Events/StudentUnEnrolled.cs similarity index 80% rename from StudentEnrollment00/Events/StudentUnEnrolled.cs rename to StudentEnrollment00.InMemory/Events/StudentUnEnrolled.cs index be810b7..83850a0 100644 --- a/StudentEnrollment00/Events/StudentUnEnrolled.cs +++ b/StudentEnrollment00.InMemory/Events/StudentUnEnrolled.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.Events; +namespace StudentEnrollment00.InMemory.Events; public class StudentUnEnrolled : Event { diff --git a/StudentEnrollment00/Events/StudentUpdated.cs b/StudentEnrollment00.InMemory/Events/StudentUpdated.cs similarity index 83% rename from StudentEnrollment00/Events/StudentUpdated.cs rename to StudentEnrollment00.InMemory/Events/StudentUpdated.cs index 9c293f9..2aec1f1 100644 --- a/StudentEnrollment00/Events/StudentUpdated.cs +++ b/StudentEnrollment00.InMemory/Events/StudentUpdated.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.Events; +namespace StudentEnrollment00.InMemory.Events; public class StudentUpdated : Event { diff --git a/StudentEnrollment00/InMemoryDatabase.cs b/StudentEnrollment00.InMemory/InMemoryDatabase.cs similarity index 91% rename from StudentEnrollment00/InMemoryDatabase.cs rename to StudentEnrollment00.InMemory/InMemoryDatabase.cs index f0643ee..018e1ca 100644 --- a/StudentEnrollment00/InMemoryDatabase.cs +++ b/StudentEnrollment00.InMemory/InMemoryDatabase.cs @@ -1,6 +1,6 @@ -using StudentEnrollment00.Events; +using StudentEnrollment00.InMemory.Events; -namespace StudentEnrollment00; +namespace StudentEnrollment00.InMemory; public sealed class InMemoryDatabase { diff --git a/StudentEnrollment00/Program.cs b/StudentEnrollment00.InMemory/Program.cs similarity index 88% rename from StudentEnrollment00/Program.cs rename to StudentEnrollment00.InMemory/Program.cs index 8b71044..cd89ad1 100644 --- a/StudentEnrollment00/Program.cs +++ b/StudentEnrollment00.InMemory/Program.cs @@ -1,5 +1,5 @@ -using StudentEnrollment00; -using StudentEnrollment00.Events; +using StudentEnrollment00.InMemory; +using StudentEnrollment00.InMemory.Events; var id = Guid.Parse("a662d446-4920-415e-8c2a-0dd4a6c58908"); var now = DateTime.Now; diff --git a/StudentEnrollment00/Student.cs b/StudentEnrollment00.InMemory/Student.cs similarity index 94% rename from StudentEnrollment00/Student.cs rename to StudentEnrollment00.InMemory/Student.cs index 75c7596..3cb7da7 100644 --- a/StudentEnrollment00/Student.cs +++ b/StudentEnrollment00.InMemory/Student.cs @@ -1,6 +1,6 @@ -using StudentEnrollment00.Events; +using StudentEnrollment00.InMemory.Events; -namespace StudentEnrollment00; +namespace StudentEnrollment00.InMemory; public class Student { diff --git a/StudentEnrollment00/StudentEnrollment00.csproj b/StudentEnrollment00.InMemory/StudentEnrollment00.InMemory.csproj similarity index 100% rename from StudentEnrollment00/StudentEnrollment00.csproj rename to StudentEnrollment00.InMemory/StudentEnrollment00.InMemory.csproj diff --git a/StudentEnrollmentConsoleApp.sln b/StudentEnrollmentConsoleApp.sln index 09543ff..f024198 100644 --- a/StudentEnrollmentConsoleApp.sln +++ b/StudentEnrollmentConsoleApp.sln @@ -10,7 +10,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution README.md = README.md EndProjectSection EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment00", "StudentEnrollment00\StudentEnrollment00.csproj", "{B8D543AF-F986-4E50-AD1D-492B38A58ECF}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment00.InMemory", "StudentEnrollment00.InMemory\StudentEnrollment00.InMemory.csproj", "{B8D543AF-F986-4E50-AD1D-492B38A58ECF}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution From be3a6ef42e22f30d2cd8bbd81b13feb33e685df2 Mon Sep 17 00:00:00 2001 From: Erik Shafer Date: Wed, 22 May 2024 12:50:39 -0500 Subject: [PATCH 2/5] changed project 01 name/space --- .../Events/Event.cs | 2 +- .../Events/EventTypeMapper.cs | 2 +- .../Events/StudentCreated.cs | 2 +- .../Events/StudentEmailChanged.cs | 2 +- .../Events/StudentEnrolled.cs | 2 +- .../Events/StudentWithdrawn.cs | 2 +- {StudentEnrollment01 => StudentEnrollment01.Esdb}/Program.cs | 2 +- {StudentEnrollment01 => StudentEnrollment01.Esdb}/Student.cs | 4 ++-- .../StudentEnrollment01.Esdb.csproj | 0 StudentEnrollmentConsoleApp.sln | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Events/Event.cs (74%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Events/EventTypeMapper.cs (96%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Events/StudentCreated.cs (85%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Events/StudentEmailChanged.cs (76%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Events/StudentEnrolled.cs (77%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Events/StudentWithdrawn.cs (77%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Program.cs (98%) rename {StudentEnrollment01 => StudentEnrollment01.Esdb}/Student.cs (95%) rename StudentEnrollment01/StudentEnrollment01.csproj => StudentEnrollment01.Esdb/StudentEnrollment01.Esdb.csproj (100%) diff --git a/StudentEnrollment01/Events/Event.cs b/StudentEnrollment01.Esdb/Events/Event.cs similarity index 74% rename from StudentEnrollment01/Events/Event.cs rename to StudentEnrollment01.Esdb/Events/Event.cs index 5c343f5..f45fda5 100644 --- a/StudentEnrollment01/Events/Event.cs +++ b/StudentEnrollment01.Esdb/Events/Event.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Events; +namespace StudentEnrollment01.Esdb.Events; public abstract record Event { diff --git a/StudentEnrollment01/Events/EventTypeMapper.cs b/StudentEnrollment01.Esdb/Events/EventTypeMapper.cs similarity index 96% rename from StudentEnrollment01/Events/EventTypeMapper.cs rename to StudentEnrollment01.Esdb/Events/EventTypeMapper.cs index 438d801..f131553 100644 --- a/StudentEnrollment01/Events/EventTypeMapper.cs +++ b/StudentEnrollment01.Esdb/Events/EventTypeMapper.cs @@ -1,6 +1,6 @@ using System.Collections.Concurrent; -namespace StudentEnrollment01.Events; +namespace StudentEnrollment01.Esdb.Events; public class EventTypeMapper { diff --git a/StudentEnrollment01/Events/StudentCreated.cs b/StudentEnrollment01.Esdb/Events/StudentCreated.cs similarity index 85% rename from StudentEnrollment01/Events/StudentCreated.cs rename to StudentEnrollment01.Esdb/Events/StudentCreated.cs index 2c4354d..b57d4b4 100644 --- a/StudentEnrollment01/Events/StudentCreated.cs +++ b/StudentEnrollment01.Esdb/Events/StudentCreated.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Events; +namespace StudentEnrollment01.Esdb.Events; public record StudentCreated : Event { diff --git a/StudentEnrollment01/Events/StudentEmailChanged.cs b/StudentEnrollment01.Esdb/Events/StudentEmailChanged.cs similarity index 76% rename from StudentEnrollment01/Events/StudentEmailChanged.cs rename to StudentEnrollment01.Esdb/Events/StudentEmailChanged.cs index f7aa0b5..cdf51e5 100644 --- a/StudentEnrollment01/Events/StudentEmailChanged.cs +++ b/StudentEnrollment01.Esdb/Events/StudentEmailChanged.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Events; +namespace StudentEnrollment01.Esdb.Events; public record StudentEmailChanged : Event { diff --git a/StudentEnrollment01/Events/StudentEnrolled.cs b/StudentEnrollment01.Esdb/Events/StudentEnrolled.cs similarity index 77% rename from StudentEnrollment01/Events/StudentEnrolled.cs rename to StudentEnrollment01.Esdb/Events/StudentEnrolled.cs index 560e1a7..419afe9 100644 --- a/StudentEnrollment01/Events/StudentEnrolled.cs +++ b/StudentEnrollment01.Esdb/Events/StudentEnrolled.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Events; +namespace StudentEnrollment01.Esdb.Events; public record StudentEnrolled : Event { diff --git a/StudentEnrollment01/Events/StudentWithdrawn.cs b/StudentEnrollment01.Esdb/Events/StudentWithdrawn.cs similarity index 77% rename from StudentEnrollment01/Events/StudentWithdrawn.cs rename to StudentEnrollment01.Esdb/Events/StudentWithdrawn.cs index 1e8944d..eda391f 100644 --- a/StudentEnrollment01/Events/StudentWithdrawn.cs +++ b/StudentEnrollment01.Esdb/Events/StudentWithdrawn.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Events; +namespace StudentEnrollment01.Esdb.Events; public record StudentWithdrawn : Event { diff --git a/StudentEnrollment01/Program.cs b/StudentEnrollment01.Esdb/Program.cs similarity index 98% rename from StudentEnrollment01/Program.cs rename to StudentEnrollment01.Esdb/Program.cs index 4b17950..4a206b0 100644 --- a/StudentEnrollment01/Program.cs +++ b/StudentEnrollment01.Esdb/Program.cs @@ -1,7 +1,7 @@ using System.Text; using System.Text.Json; using EventStore.Client; -using StudentEnrollment01.Events; +using StudentEnrollment01.Esdb.Events; // Register events to a singleton for ease-of-reference EventTypeMapper.Instance.ToName(typeof(StudentCreated)); diff --git a/StudentEnrollment01/Student.cs b/StudentEnrollment01.Esdb/Student.cs similarity index 95% rename from StudentEnrollment01/Student.cs rename to StudentEnrollment01.Esdb/Student.cs index b15c7c4..8d51e83 100644 --- a/StudentEnrollment01/Student.cs +++ b/StudentEnrollment01.Esdb/Student.cs @@ -1,6 +1,6 @@ -using StudentEnrollment01.Events; +using StudentEnrollment01.Esdb.Events; -namespace StudentEnrollment01; +namespace StudentEnrollment01.Esdb; public class Student { diff --git a/StudentEnrollment01/StudentEnrollment01.csproj b/StudentEnrollment01.Esdb/StudentEnrollment01.Esdb.csproj similarity index 100% rename from StudentEnrollment01/StudentEnrollment01.csproj rename to StudentEnrollment01.Esdb/StudentEnrollment01.Esdb.csproj diff --git a/StudentEnrollmentConsoleApp.sln b/StudentEnrollmentConsoleApp.sln index f024198..ef11d04 100644 --- a/StudentEnrollmentConsoleApp.sln +++ b/StudentEnrollmentConsoleApp.sln @@ -1,6 +1,6 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment01", "StudentEnrollment01\StudentEnrollment01.csproj", "{446FF6B7-B58B-4CFB-8E98-C5B3AED9BA4D}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment01.Esdb", "StudentEnrollment01.Esdb\StudentEnrollment01.Esdb.csproj", "{446FF6B7-B58B-4CFB-8E98-C5B3AED9BA4D}" EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{43721FA4-09D5-4B98-9684-8752B40047AD}" ProjectSection(SolutionItems) = preProject From f9a501e110cd5ac2e356faf69ad48d3d8c21a003 Mon Sep 17 00:00:00 2001 From: Erik Shafer Date: Wed, 22 May 2024 12:52:15 -0500 Subject: [PATCH 3/5] for clarity, changed project from 01 -> 02 --- .../Events/Event.cs | 2 +- .../Events/EventTypeMapper.cs | 2 +- .../Events/StudentCreated.cs | 2 +- .../Events/StudentEmailChanged.cs | 2 +- .../Events/StudentEnrolled.cs | 2 +- .../Events/StudentWithdrawn.cs | 2 +- .../Program.cs | 2 +- .../Student.cs | 4 ++-- .../StudentEnrollment02.Esdb.csproj | 0 StudentEnrollmentConsoleApp.sln | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Events/Event.cs (74%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Events/EventTypeMapper.cs (96%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Events/StudentCreated.cs (85%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Events/StudentEmailChanged.cs (76%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Events/StudentEnrolled.cs (77%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Events/StudentWithdrawn.cs (77%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Program.cs (98%) rename {StudentEnrollment01.Esdb => StudentEnrollment02.Esdb}/Student.cs (95%) rename StudentEnrollment01.Esdb/StudentEnrollment01.Esdb.csproj => StudentEnrollment02.Esdb/StudentEnrollment02.Esdb.csproj (100%) diff --git a/StudentEnrollment01.Esdb/Events/Event.cs b/StudentEnrollment02.Esdb/Events/Event.cs similarity index 74% rename from StudentEnrollment01.Esdb/Events/Event.cs rename to StudentEnrollment02.Esdb/Events/Event.cs index f45fda5..ec0fac2 100644 --- a/StudentEnrollment01.Esdb/Events/Event.cs +++ b/StudentEnrollment02.Esdb/Events/Event.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Esdb.Events; +namespace StudentEnrollment02.Esdb.Events; public abstract record Event { diff --git a/StudentEnrollment01.Esdb/Events/EventTypeMapper.cs b/StudentEnrollment02.Esdb/Events/EventTypeMapper.cs similarity index 96% rename from StudentEnrollment01.Esdb/Events/EventTypeMapper.cs rename to StudentEnrollment02.Esdb/Events/EventTypeMapper.cs index f131553..a1f9f95 100644 --- a/StudentEnrollment01.Esdb/Events/EventTypeMapper.cs +++ b/StudentEnrollment02.Esdb/Events/EventTypeMapper.cs @@ -1,6 +1,6 @@ using System.Collections.Concurrent; -namespace StudentEnrollment01.Esdb.Events; +namespace StudentEnrollment02.Esdb.Events; public class EventTypeMapper { diff --git a/StudentEnrollment01.Esdb/Events/StudentCreated.cs b/StudentEnrollment02.Esdb/Events/StudentCreated.cs similarity index 85% rename from StudentEnrollment01.Esdb/Events/StudentCreated.cs rename to StudentEnrollment02.Esdb/Events/StudentCreated.cs index b57d4b4..bd9014a 100644 --- a/StudentEnrollment01.Esdb/Events/StudentCreated.cs +++ b/StudentEnrollment02.Esdb/Events/StudentCreated.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Esdb.Events; +namespace StudentEnrollment02.Esdb.Events; public record StudentCreated : Event { diff --git a/StudentEnrollment01.Esdb/Events/StudentEmailChanged.cs b/StudentEnrollment02.Esdb/Events/StudentEmailChanged.cs similarity index 76% rename from StudentEnrollment01.Esdb/Events/StudentEmailChanged.cs rename to StudentEnrollment02.Esdb/Events/StudentEmailChanged.cs index cdf51e5..3c241b6 100644 --- a/StudentEnrollment01.Esdb/Events/StudentEmailChanged.cs +++ b/StudentEnrollment02.Esdb/Events/StudentEmailChanged.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Esdb.Events; +namespace StudentEnrollment02.Esdb.Events; public record StudentEmailChanged : Event { diff --git a/StudentEnrollment01.Esdb/Events/StudentEnrolled.cs b/StudentEnrollment02.Esdb/Events/StudentEnrolled.cs similarity index 77% rename from StudentEnrollment01.Esdb/Events/StudentEnrolled.cs rename to StudentEnrollment02.Esdb/Events/StudentEnrolled.cs index 419afe9..eef1def 100644 --- a/StudentEnrollment01.Esdb/Events/StudentEnrolled.cs +++ b/StudentEnrollment02.Esdb/Events/StudentEnrolled.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Esdb.Events; +namespace StudentEnrollment02.Esdb.Events; public record StudentEnrolled : Event { diff --git a/StudentEnrollment01.Esdb/Events/StudentWithdrawn.cs b/StudentEnrollment02.Esdb/Events/StudentWithdrawn.cs similarity index 77% rename from StudentEnrollment01.Esdb/Events/StudentWithdrawn.cs rename to StudentEnrollment02.Esdb/Events/StudentWithdrawn.cs index eda391f..6130737 100644 --- a/StudentEnrollment01.Esdb/Events/StudentWithdrawn.cs +++ b/StudentEnrollment02.Esdb/Events/StudentWithdrawn.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment01.Esdb.Events; +namespace StudentEnrollment02.Esdb.Events; public record StudentWithdrawn : Event { diff --git a/StudentEnrollment01.Esdb/Program.cs b/StudentEnrollment02.Esdb/Program.cs similarity index 98% rename from StudentEnrollment01.Esdb/Program.cs rename to StudentEnrollment02.Esdb/Program.cs index 4a206b0..a57f729 100644 --- a/StudentEnrollment01.Esdb/Program.cs +++ b/StudentEnrollment02.Esdb/Program.cs @@ -1,7 +1,7 @@ using System.Text; using System.Text.Json; using EventStore.Client; -using StudentEnrollment01.Esdb.Events; +using StudentEnrollment02.Esdb.Events; // Register events to a singleton for ease-of-reference EventTypeMapper.Instance.ToName(typeof(StudentCreated)); diff --git a/StudentEnrollment01.Esdb/Student.cs b/StudentEnrollment02.Esdb/Student.cs similarity index 95% rename from StudentEnrollment01.Esdb/Student.cs rename to StudentEnrollment02.Esdb/Student.cs index 8d51e83..4db4ae7 100644 --- a/StudentEnrollment01.Esdb/Student.cs +++ b/StudentEnrollment02.Esdb/Student.cs @@ -1,6 +1,6 @@ -using StudentEnrollment01.Esdb.Events; +using StudentEnrollment02.Esdb.Events; -namespace StudentEnrollment01.Esdb; +namespace StudentEnrollment02.Esdb; public class Student { diff --git a/StudentEnrollment01.Esdb/StudentEnrollment01.Esdb.csproj b/StudentEnrollment02.Esdb/StudentEnrollment02.Esdb.csproj similarity index 100% rename from StudentEnrollment01.Esdb/StudentEnrollment01.Esdb.csproj rename to StudentEnrollment02.Esdb/StudentEnrollment02.Esdb.csproj diff --git a/StudentEnrollmentConsoleApp.sln b/StudentEnrollmentConsoleApp.sln index ef11d04..4a2c9f2 100644 --- a/StudentEnrollmentConsoleApp.sln +++ b/StudentEnrollmentConsoleApp.sln @@ -1,6 +1,6 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment01.Esdb", "StudentEnrollment01.Esdb\StudentEnrollment01.Esdb.csproj", "{446FF6B7-B58B-4CFB-8E98-C5B3AED9BA4D}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment02.Esdb", "StudentEnrollment02.Esdb\StudentEnrollment02.Esdb.csproj", "{446FF6B7-B58B-4CFB-8E98-C5B3AED9BA4D}" EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{43721FA4-09D5-4B98-9684-8752B40047AD}" ProjectSection(SolutionItems) = preProject From 6993f02f370a47ec79be26032914a49c14097176 Mon Sep 17 00:00:00 2001 From: Erik Shafer Date: Wed, 22 May 2024 12:52:37 -0500 Subject: [PATCH 4/5] for clarity, changed project from 00 -> 01 --- .../Events/Event.cs | 2 +- .../Events/StudentCreated.cs | 2 +- .../Events/StudentEnrolled.cs | 2 +- .../Events/StudentUnEnrolled.cs | 2 +- .../Events/StudentUpdated.cs | 2 +- .../InMemoryDatabase.cs | 4 ++-- .../Program.cs | 4 ++-- .../Student.cs | 4 ++-- .../StudentEnrollment01.InMemory.csproj | 0 StudentEnrollmentConsoleApp.sln | 2 +- 10 files changed, 12 insertions(+), 12 deletions(-) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Events/Event.cs (72%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Events/StudentCreated.cs (86%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Events/StudentEnrolled.cs (80%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Events/StudentUnEnrolled.cs (80%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Events/StudentUpdated.cs (83%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/InMemoryDatabase.cs (91%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Program.cs (88%) rename {StudentEnrollment00.InMemory => StudentEnrollment01.InMemory}/Student.cs (94%) rename StudentEnrollment00.InMemory/StudentEnrollment00.InMemory.csproj => StudentEnrollment01.InMemory/StudentEnrollment01.InMemory.csproj (100%) diff --git a/StudentEnrollment00.InMemory/Events/Event.cs b/StudentEnrollment01.InMemory/Events/Event.cs similarity index 72% rename from StudentEnrollment00.InMemory/Events/Event.cs rename to StudentEnrollment01.InMemory/Events/Event.cs index f445ce5..d015937 100644 --- a/StudentEnrollment00.InMemory/Events/Event.cs +++ b/StudentEnrollment01.InMemory/Events/Event.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.InMemory.Events; +namespace StudentEnrollment01.InMemory.Events; public abstract class Event { diff --git a/StudentEnrollment00.InMemory/Events/StudentCreated.cs b/StudentEnrollment01.InMemory/Events/StudentCreated.cs similarity index 86% rename from StudentEnrollment00.InMemory/Events/StudentCreated.cs rename to StudentEnrollment01.InMemory/Events/StudentCreated.cs index dccf050..022cdf1 100644 --- a/StudentEnrollment00.InMemory/Events/StudentCreated.cs +++ b/StudentEnrollment01.InMemory/Events/StudentCreated.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.InMemory.Events; +namespace StudentEnrollment01.InMemory.Events; public class StudentCreated : Event { diff --git a/StudentEnrollment00.InMemory/Events/StudentEnrolled.cs b/StudentEnrollment01.InMemory/Events/StudentEnrolled.cs similarity index 80% rename from StudentEnrollment00.InMemory/Events/StudentEnrolled.cs rename to StudentEnrollment01.InMemory/Events/StudentEnrolled.cs index 2de6414..f55a988 100644 --- a/StudentEnrollment00.InMemory/Events/StudentEnrolled.cs +++ b/StudentEnrollment01.InMemory/Events/StudentEnrolled.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.InMemory.Events; +namespace StudentEnrollment01.InMemory.Events; public class StudentEnrolled : Event { diff --git a/StudentEnrollment00.InMemory/Events/StudentUnEnrolled.cs b/StudentEnrollment01.InMemory/Events/StudentUnEnrolled.cs similarity index 80% rename from StudentEnrollment00.InMemory/Events/StudentUnEnrolled.cs rename to StudentEnrollment01.InMemory/Events/StudentUnEnrolled.cs index 83850a0..4490279 100644 --- a/StudentEnrollment00.InMemory/Events/StudentUnEnrolled.cs +++ b/StudentEnrollment01.InMemory/Events/StudentUnEnrolled.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.InMemory.Events; +namespace StudentEnrollment01.InMemory.Events; public class StudentUnEnrolled : Event { diff --git a/StudentEnrollment00.InMemory/Events/StudentUpdated.cs b/StudentEnrollment01.InMemory/Events/StudentUpdated.cs similarity index 83% rename from StudentEnrollment00.InMemory/Events/StudentUpdated.cs rename to StudentEnrollment01.InMemory/Events/StudentUpdated.cs index 2aec1f1..5026e57 100644 --- a/StudentEnrollment00.InMemory/Events/StudentUpdated.cs +++ b/StudentEnrollment01.InMemory/Events/StudentUpdated.cs @@ -1,4 +1,4 @@ -namespace StudentEnrollment00.InMemory.Events; +namespace StudentEnrollment01.InMemory.Events; public class StudentUpdated : Event { diff --git a/StudentEnrollment00.InMemory/InMemoryDatabase.cs b/StudentEnrollment01.InMemory/InMemoryDatabase.cs similarity index 91% rename from StudentEnrollment00.InMemory/InMemoryDatabase.cs rename to StudentEnrollment01.InMemory/InMemoryDatabase.cs index 018e1ca..dbc881e 100644 --- a/StudentEnrollment00.InMemory/InMemoryDatabase.cs +++ b/StudentEnrollment01.InMemory/InMemoryDatabase.cs @@ -1,6 +1,6 @@ -using StudentEnrollment00.InMemory.Events; +using StudentEnrollment01.InMemory.Events; -namespace StudentEnrollment00.InMemory; +namespace StudentEnrollment01.InMemory; public sealed class InMemoryDatabase { diff --git a/StudentEnrollment00.InMemory/Program.cs b/StudentEnrollment01.InMemory/Program.cs similarity index 88% rename from StudentEnrollment00.InMemory/Program.cs rename to StudentEnrollment01.InMemory/Program.cs index cd89ad1..d1f009a 100644 --- a/StudentEnrollment00.InMemory/Program.cs +++ b/StudentEnrollment01.InMemory/Program.cs @@ -1,5 +1,5 @@ -using StudentEnrollment00.InMemory; -using StudentEnrollment00.InMemory.Events; +using StudentEnrollment01.InMemory; +using StudentEnrollment01.InMemory.Events; var id = Guid.Parse("a662d446-4920-415e-8c2a-0dd4a6c58908"); var now = DateTime.Now; diff --git a/StudentEnrollment00.InMemory/Student.cs b/StudentEnrollment01.InMemory/Student.cs similarity index 94% rename from StudentEnrollment00.InMemory/Student.cs rename to StudentEnrollment01.InMemory/Student.cs index 3cb7da7..10b6595 100644 --- a/StudentEnrollment00.InMemory/Student.cs +++ b/StudentEnrollment01.InMemory/Student.cs @@ -1,6 +1,6 @@ -using StudentEnrollment00.InMemory.Events; +using StudentEnrollment01.InMemory.Events; -namespace StudentEnrollment00.InMemory; +namespace StudentEnrollment01.InMemory; public class Student { diff --git a/StudentEnrollment00.InMemory/StudentEnrollment00.InMemory.csproj b/StudentEnrollment01.InMemory/StudentEnrollment01.InMemory.csproj similarity index 100% rename from StudentEnrollment00.InMemory/StudentEnrollment00.InMemory.csproj rename to StudentEnrollment01.InMemory/StudentEnrollment01.InMemory.csproj diff --git a/StudentEnrollmentConsoleApp.sln b/StudentEnrollmentConsoleApp.sln index 4a2c9f2..e610f79 100644 --- a/StudentEnrollmentConsoleApp.sln +++ b/StudentEnrollmentConsoleApp.sln @@ -10,7 +10,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution README.md = README.md EndProjectSection EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment00.InMemory", "StudentEnrollment00.InMemory\StudentEnrollment00.InMemory.csproj", "{B8D543AF-F986-4E50-AD1D-492B38A58ECF}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StudentEnrollment01.InMemory", "StudentEnrollment01.InMemory\StudentEnrollment01.InMemory.csproj", "{B8D543AF-F986-4E50-AD1D-492B38A58ECF}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution From b0186ec78812a023b732df1c41c2f6a480ba823b Mon Sep 17 00:00:00 2001 From: Erik Shafer Date: Wed, 22 May 2024 13:14:14 -0500 Subject: [PATCH 5/5] readme clarity, fixes, collapsing of text --- README.md | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 614013a..8b1bae1 100644 --- a/README.md +++ b/README.md @@ -2,23 +2,36 @@ An application showing the absolute basics of event sourcing with [EventStoreDB (ESDB)](https://www.eventstore.com/). + ## 💡 Inspiration Inspired by Nick Chapsas' video about [getting started with Event Sourcing in .NET](https://www.youtube.com/watch?v=n_o-xuuVtmw). This take however uses EventStoreDB as its, well, store of events! -### 🤔 Mini-Log / Thoughts / Brian Dump -- **2024-May-21**: +### 📄 Mini-Log / 🤔 Thoughts / 🧠 Brain Dump + +This is not an Architectural Decision Records (ADRs) log. [This is just a tribute 🎶🎸](https://www.youtube.com/watch?v=Vdq3BtWDRq8). + +
+ 2024-May-21 + - For clarity, renamed the .NET console application projects. +
+
+ 2024-May-21 - Updated some code, fixed some bugs and typos. - Decided this repository will have multiple versions. - One that works nearly the same as Nick's original in-memory incarnation. - Another using ESDB and some of the most frequently used commands with the ESDB .NET client. - Could have a potential third version if there is some demand from the community. - Would appreciate feedback. That and questions could extend this even further, perhaps. -- **2024-May-20**: +
+
+ 2024-May-20 - Watched Nick's initial video. Awesome. Wait, what if we did the same thing, but with ESDB? - Made this code repository and .NET solution. - Only the bare bones as of this commit. Will update to include some event sourcing best practices without "getting into the weeds" too much. +
+ ## 📺 Companion Video @@ -26,6 +39,7 @@ A video will be posted on my [YouTube channel](https://www.youtube.com/@event-so Ideally on my birthday, May 22nd! + ## 🐋 Requirements 1. [Docker](https://www.docker.com/products/docker-desktop/) @@ -89,6 +103,7 @@ dotnet run --project .\StudentEnrollment01\StudentEnrollment01.csproj Instructions will go here, but will basically be the same as above! + ## 🔗 Resources Erik Shafer (me): @@ -101,6 +116,7 @@ Nick Chapsas: - [youtube.com/@nickchapsas](https://www.youtube.com/@nickchapsas) - YouTube channel - [Dometrain](https://dometrain.com/) - Courses crafted by real engineers for the real world. + ## License To Be Determined.