Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/codelur/mongodb
Spring Boot Application with JPA, MongoDB, and Global Exception Handling
https://github.com/codelur/mongodb
exception-handling java jpa jpa-hibernate microservices mongodb spring springboot
Last synced: 15 days ago
JSON representation
Spring Boot Application with JPA, MongoDB, and Global Exception Handling
- Host: GitHub
- URL: https://github.com/codelur/mongodb
- Owner: codelur
- Created: 2024-09-20T01:41:36.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-10-27T01:41:05.000Z (21 days ago)
- Last Synced: 2024-10-27T02:35:59.201Z (21 days ago)
- Topics: exception-handling, java, jpa, jpa-hibernate, microservices, mongodb, spring, springboot
- Language: Java
- Homepage:
- Size: 17.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spring Boot Application with JPA, MongoDB, and Global Exception Handling
## Description
This project is a **Spring Boot** application that demonstrates how to use **Spring Data JPA** (for relational databases), **Spring Data MongoDB** (for NoSQL databases), and **Global Exception Handling** with `@ControllerAdvice`. The application provides RESTful endpoints for managing entities in both a relational database and MongoDB.
### Key Features
- **Spring Boot**: Simplified development with auto-configuration and embedded active servers.
- **Spring Data JPA**: For working with relational databases (e.g., MySQL, PostgreSQL).
- **Spring Data MongoDB**: For working with MongoDB as a NoSQL database.
- **Global Exception Handling**: Centralized exception management using `@ControllerAdvice`.
- **REST API**: Expose RESTful web services for CRUD operations.## Technologies Used
- **Java 17**
- **Spring Boot 3.x**
- **Spring Data JPA**
- **Spring Data MongoDB**
- **MongoDB**
- **Maven** (for build and dependency management)## Setup and Configuration
### Prerequisites
- **Java 17+**
- **Maven 3.x+**
- **MongoDB** instance running