A multi-module Gradle project for building financial data APIs with Spring Boot.
This is a multi-module Gradle project with the following structure:
- Root directory - Shared build configuration and orchestration
stockapi/- Main application module (Spring Boot stock quotes API)
# Run the stock API application
./gradlew.bat :stockapi:bootRunThe application will start on port 8888 (configurable in application.properties).
# Build all modules
./gradlew.bat build
# Run tests
./gradlew.bat test
# Run integration tests
./gradlew.bat :stockapi:integrationTest
# Generate jOOQ classes
./gradlew.bat :stockapi:classes -PgenerateJooq=trueA Spring Boot REST API that fetches stock quote data and exposes HTTP endpoints.
Key Features:
- REST endpoint for stock quotes (
GET /quotes) - Integration with external stock-data providers (StockData.org, AlphaVantage)
- Google Cloud Secret Manager integration for secure credential storage
- PostgreSQL with Flyway migrations and jOOQ code generation
- Testcontainers for integration testing
Documentation:
- 📖 Quick Start Guide - Get started with the stockapi module
- 🔧 Multi-Module Structure - Understanding the project structure
- 🔐 Secret Manager Setup - GCP Secret Manager integration
- 🐛 Troubleshooting Secret Manager - Debug GCP issues
- 📋 Migration Checklist - Multi-module migration details
musicapi/
├── build.gradle # Parent build configuration
├── settings.gradle # Module definitions
├── gradle.properties # Shared properties
├── README.md # This file
└── stockapi/ # Stock API module
├── build.gradle # Module build configuration
├── docs/ # Module documentation
└── src/
├── main/ # Application code
├── test/ # Unit tests
└── integrationTest/ # Integration tests
This is a multi-module Gradle project. You can run tasks at the root level (applies to all modules) or target specific modules:
# Root level - runs on all modules
./gradlew.bat clean build
# Module-specific - prefix with :moduleName:
./gradlew.bat :stockapi:bootRun
./gradlew.bat :stockapi:testSee Multi-Module Structure for detailed information.
To add a new module:
- Create a directory at the root level (e.g.,
newmodule/) - Add
include 'newmodule'tosettings.gradle - Create a
build.gradlein the module directory - Apply necessary plugins and configure dependencies
- Language: Java (Gradle build)
- Framework: Spring Boot
- Database: PostgreSQL with Flyway migrations
- Code Generation: jOOQ for type-safe SQL
- Testing: JUnit 5, Testcontainers
- Cloud Integration: Google Cloud Secret Manager
- Package Management: Gradle with multi-module support
- General questions: See the Quick Start Guide
- Build issues: Check Multi-Module Structure
- Secret Manager errors: See Troubleshooting Guide
- Available tasks: Run
./gradlew.bat :stockapi:tasks
- Follow the Google Java Style Guide
- See
.github/copilot-instructions.mdfor coding conventions - Keep changes focused and include tests
- Update documentation when adding features
Main Package: com.kiran.stockapi
Documentation: See stockapi/docs/ for module-specific guides