Skip to content

senhkenh/springbank

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spring Bank

A comprehensive banking system built with Spring Boot that provides REST API endpoints for account management and money transfers.

Overview

Spring Bank is a modern banking application that demonstrates enterprise-level Java development practices using the Spring ecosystem. The system manages customer accounts and facilitates secure money transfers between accounts with full transaction support.

Architecture

The application follows a layered architecture pattern with clear separation of concerns:

Controller Layer: REST endpoints for handling HTTP requests and responses Service Layer: Business logic implementation with transaction management Repository Layer: Data access layer with custom queries Model Layer: Entity definitions and data structures

Key Features

The system provides comprehensive banking functionality including account management, money transfers with transaction safety, account lookup by customer name, and exception handling for invalid operations. All operations are secured with Spring's transaction management to ensure data consistency.

Technology Stack

Framework: Spring Boot 4.0 Data Access: Spring Data JDBC Web Layer: Spring Web MVC Database: H2 Database (embedded) Build Tool: Maven Java Version: 25

Database Schema

The application uses a simple yet effective database schema with an account table containing customer information and account balances. The database is automatically initialized with 500 sample accounts for testing and demonstration purposes.

API Endpoints

POST /transfer: Execute money transfers between accounts GET /accounts: Retrieve all accounts or filter by customer name

Getting Started

Clone the repository and navigate to the project directory. Run the application using Maven with mvn spring-boot:run. The application will start on the default port and initialize the H2 database with sample data.

Testing

The application includes comprehensive test coverage and can be tested using the H2 console for database inspection or REST clients for API testing.

Project Structure

The codebase is organized following Spring Boot conventions with separate packages for controllers, services, repositories, models, and exception handling. Configuration files and database scripts are located in the resources directory.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages