From 3cc375ec0b8b1b2f0ce5c350e8de36bcabe8c250 Mon Sep 17 00:00:00 2001 From: Andrew4Coding <andrewdevitoaryo@gmail.com> Date: Fri, 28 Mar 2025 01:25:33 +0800 Subject: [PATCH] docs: add second reflection --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index ccf544c..13dd3bc 100644 --- a/README.md +++ b/README.md @@ -89,5 +89,16 @@ Using a Dashmap is highly important in this case because it allows us to access Using a static singleton DashMap ensures thread safety throughout the entire process by guaranteeing that only one thread can access the shared resource at a time. The Singleton pattern ensures that all subscribers remain synchronized effectively. #### Reflection Publisher-2 +> In the Model-View Controller (MVC) compound pattern, there is no “Service” and “Repository”. Model in MVC covers both data storage and business logic. Explain based on your understanding of design principles, why we need to separate “Service” and “Repository” from a Model? + +By separating Model, Service, and Repository, we can achieve a cleaner and more organized code structure. This separation allows us to isolate the data access logic (Repository) from the business logic (Service), making it easier to maintain and test each component independently. Additionally, this separation promotes reusability and scalability (SRP Principal), as we can easily modify or replace one component without affecting the others. + +> What happens if we only use the Model? Explain your imagination on how the interactions between each model (Program, Subscriber, Notification) affect the code complexity for each model? + +Without any separation between Service and Repository, all of the workload of the main application logic will be handled by the Model. This will lead to a monolithic structure where all the logic is tightly coupled, making it difficult to maintain and test. The complexity of the code will increase significantly as more features are added, leading to a higher chance of bugs and errors. Additionally, it will be harder to understand the flow of the application, as all the logic is mixed together in one place. + +> Have you explored more about Postman? Tell us how this tool helps you to test your current work. You might want to also list which features in Postman you are interested in or feel like it is helpful to help your Group Project or any of your future software engineering projects. + +Postman is a powerful tool that allows us to test our API endpoints easily. It provides a user-friendly interface to send HTTP requests and view the responses, errors, and status codes. #### Reflection Publisher-3 -- GitLab