VSN-2046 : Adding call to fetch multiple establishments by their name.
Merge Request Description
Title
Add establishment search by name feature with full service, repository, and API exposure
Overview
This merge request introduces a new backend feature that enables retrieving establishments by their name.
The implementation follows the existing layered architecture (repository → service → controller) and ensures consistency with current coding standards and API exposure patterns.
The feature is fully integrated, documented, and exposed through a dedicated REST endpoint.
Functional Scope
The main objective of this MR is to allow consumers (front-end or external services) to query establishments using a textual name parameter and receive the corresponding matching results from the database.
This enhancement improves:
- Data accessibility
- Search capabilities
- API completeness for establishment-related operations
Detailed Changes
1. Service Layer
- Added a new method signature in the service interface responsible for establishment operations.
- The method defines the contract for retrieving establishments based on their name.
- Ensures separation of concerns and keeps business logic centralized.
2. Repository Layer
- Introduced a new repository method to query establishments by name.
- The query is designed to be reusable and aligned with existing repository patterns.
- Enables efficient data retrieval directly from the persistence layer.
3. Service Implementation
- Implemented the newly defined service method.
- Delegates data access to the repository while keeping business logic encapsulated.
- Prepares the data to be returned in a clean and consistent manner.
4. API Layer (Controller)
- Added a new REST endpoint dedicated to establishment search by name.
- The endpoint accepts a name parameter and returns the matching establishments.
- Ensures proper routing, request handling, and response exposure.
- Fully aligned with existing API naming and versioning conventions.
5. Documentation
- Updated the changelog markdown file.
- Documented the introduction of the new establishment search feature.
- Ensures traceability and visibility of changes for future releases.
Technical Benefits
- Improves extensibility of the establishment domain.
- Provides a clear and reusable service contract.
- Keeps repository logic isolated and testable.
- Enhances API usability for client-side filtering and search.
- Maintains clean architecture and consistent layering.
Impact & Compatibility
- No breaking changes introduced.
- Existing features remain unaffected.
- The new endpoint is additive and backward-compatible.
- Safe to merge and deploy with current services.
Conclusion
This merge request completes the full lifecycle of an establishment search feature, from persistence to API exposure.
It strengthens the backend capabilities while respecting architectural principles, code clarity, and documentation standards.
Closes VSN-2046