Enterprise software systems demand structured, maintainable, and scalable design approaches. Object-Oriented Programming (OOP) principlesโencapsulation, inheritance, polymorphism, and abstractionโprovide the foundational framework for achieving these qualities, while GoF (Gang of Four) design patterns offer reusable solutions to recurring architectural challenges. This paper presents the design and implementation of a School Library Management System (SLMS) built with Java and the Spring Boot framework, demonstrating the systematic application of all four OOP principles and five GoF design patterns: Singleton, Builder, Factory, Observer, and Decorator. The SLMS supports role-based user management (Administrator and Student), book inventory control, borrow/return lifecycle tracking, and live reporting through a RESTful API backed by MySQL persistence via Spring Data JPA. For each OOP principle and design pattern, the paper provides architectural justification, code-level demonstration, and a discussion of the specific quality attributes achieved. A layered four-tier architecture (ControllerโServiceโRepositoryโEntity) enforces clean separation of concerns and aligns directly with the SOLID principles. Evaluation against maintainability, scalability, and extensibility criteria demonstrates that the pattern-driven approach substantially reduces coupling, improves module cohesion, and enables extension without modificationโdirectly realising the Open/Closed Principle. The paper contributes a concrete, replicable reference implementation for applying classical software engineering patterns within the modern Spring Boot ecosystem.
This paper has demonstrated the systematic application of four OOP principles and five GoF design patterns within a Spring Boot Library Management System. The layered architecture enforces clean separation of concerns, with each layer realising specific OOP principles: encapsulation at the entity level, abstraction at the service interface boundary, inheritance in the base class hierarchy, and polymorphism through service contracts. The GoF patternsโSingleton, Builder, Factory, Observer, and Decoratorโcollectively produce a system with high maintainability, extensibility, and testability scores, as evaluated against a non-pattern baseline.
A key contribution is the demonstration that Spring Bootโs annotation-driven programming model is itself pattern-aligned, making GoF implementation both natural and low-overhead in this ecosystem. Future work should address password security hardening, explicit factory class formalisation, and asynchronous Observer dispatch for production readiness.
References
[1]B. Dathan and S. Ramnath, Object-Oriented Analysis, Design and Implementation. Cham: Springer, 2015.
[2]M. Mouratidou et al., โAn assessment of design patternsโ influence on a Java-based e-commerce application,โ J. Theor. Appl. Electron. Commer. Res., vol. 5, no. 1, pp. 25โ38, 2010.
[3]V. Serbanescu et al., โA design pattern for optimizations in data intensive applications using ABS and Java 8,โ Concurr. Comput., vol. 28, no. 2, pp. 374โ385, 2016.
[4]J. S. Mtebe and R. Raisamo, โChallenges and instructorsโ intention to adopt open educational resources in higher education in Tanzania,โ Int. Rev. Res. Open Distrib. Learn., vol. 15, no. 1, pp. 249โ271, 2014.
[5]O. D. Bakare, โThe use of social media technologies in the provision of library and information services in academic libraries of south-west Nigeria,โ Doctoral dissertation, 2018.
[6]Y. D. Liang, Introduction to Java Programming. Boston: Pearson, 2015.
[7]N. Padhy, R. Panigrahi, and S. Baboo, โA systematic literature review of an object-oriented metric: reusability,โ in Proc. Int. Conf. Comput. Intell. Netw., 2015, pp. 190โ191.
[8]P. Kuchana, Software Architecture Design Patterns in Java, 1st ed. Boca Raton: Taylor & Francis, 2004.
[9]P. Spath et al., โDiscovering inheritance, polymorphism, and interfaces,โ in Learn Java for Android Development. Apress, 2020, pp. 157โ202.
[10]R. F. Olanrewaju et al., โA frictionless and secure user authentication in web-based premium applications,โ IEEE Access, vol. 9, pp. 129240โ 129255, 2021.
[11]I. S. de Oliveira et al., โQuality of big data systems: A systematic review of practices, methods and tools,โ in Proc. XXIII Brazilian Symp. Softw. Quality, 2024, pp. 22โ31.
J. Langr, Pragmatic Unit Testing in Java with JUnit. Raleigh: Pragmatic Bookshelf, 2024.