RedElastic/reactive-stock-trader
38.5
Weak · 22 September 2026
3.9k
lines of production code
Java
with JavaScript
6
measurements over time
What this system is
This system is a stock trading and portfolio management platform built on a microservices architecture. It enables users to manage investment portfolios, execute buy and sell orders, and perform wire transfers between accounts. The backend coordinates these financial operations through distinct services for portfolio, broker, and wire transfers, while a Vue.js frontend provides the user interface for tracking holdings and initiating trades.
How it got here
2018 — Broker and Portfolio service implementation
9 changes.
The project established the core trading infrastructure by implementing the Broker and Portfolio services, including their API contracts, state machines, and Kubernetes deployment configurations. Concurrently, the codebase was restructured by migrating the build system to SBT and removing obsolete Hello and Stream service implementations.
2019 — BFF and wire transfer feature implementation
18 changes.
This period focused on implementing the Backend for Frontend (BFF) layer and the wire transfer service, establishing the core domain models and API specifications. The work included building out the Vue.js UI components for portfolio and transfer management, alongside the backend services and Kubernetes deployment configurations required to support these new features.
Features
Add Kubernetes deployment manifests for the wire-transfer service
New Kubernetes configuration files have been added to the wire-transfer-impl/deploy directory, enabling the wire-transfer service to be deployed on Kubernetes. This includes a Deployment, Service, ConfigMap, ServiceAccount, and RBAC Role/RoleBinding, along with a production secrets configuration file. The deployment exposes ports 9020 (HTTP), 2552 (remoting), and 8557 (management), and configures environment variables for Cassandra, Kafka, and other services.
wire-transfer-impl/deploy · high confidence
Added BFF controllers for portfolio management and wire transfers
New controllers have been introduced in the BFF layer to expose portfolio and transfer functionality. HomeController provides instance and health check endpoints. PortfolioController exposes endpoints to retrieve portfolio summaries (including equity prices and completed order details) and list all portfolios. WireTransferController exposes endpoints to initiate wire transfers, retrieve transfer history, and stream transfer updates via WebSocket. These controllers wire up the underlying services (PortfolioService, BrokerService, WireTransferService) to handle form binding, JSON serialization, and HTTP response codes (e.g., 202 Accepted for transfers).
bff/src/main/java/controllers · high confidence
Added CSHelper utility for enhanced CompletionStage handling
A new CSHelper utility class was added to the utils package, providing convenience methods for working with Java 8's CompletionStage and CompletableFuture. This includes helpers for combining futures (allOf), recovering from specific exceptions (recoverWith, recover), creating failed futures, and adding timeout support to completion stages.
utils · high confidence
Added common model classes for stock trading domain
The common-models module now includes new domain model classes: OrderId, PortfolioId, TradeType, and TransferId. These classes provide the foundational data structures for the stock trading application, including path parameter serializers for the ID types and an enumeration for trade types (BUY/SELL).
common-models · high confidence
Added common modules for portfolio and transfer management
Introduced new shared modules in the UI layer to handle portfolio and transfer operations. The config module exposes environment variables for the backend and IEX API endpoints. The http module initializes an Axios instance for the IEX sandbox API. The portfolio module provides functions to manage the active portfolio state, retrieve portfolio details, and place orders. The transfers module exposes functions to create, deposit, and retrieve transfer history, enabling the UI to interact with the backend's transfer and portfolio APIs.
ui/src/common · high confidence
Added configuration files for the wire transfer service
New configuration files have been added for the wire transfer service: application.conf sets up Akka, Cassandra persistence, and service discovery; application.prod.conf configures production-specific settings including Cassandra contact points, Kafka brokers, and Kubernetes-based service discovery and cluster management; logback.xml defines logging levels for Play, Akka, Lagom, and related libraries.
wire-transfer-impl/src/main/resources · high confidence
Added core UI pages for portfolio management, stock quotes, and navigation
Introduced new Vue components for the application's main navigation (MainNav), footer (MainFooter), and key pages including Home (portfolio creation and switching), Portfolio (displaying account value, returns, and equity holdings), and Quote (fetching and displaying real-time stock data and market metrics). These components establish the primary user interface for interacting with the trading and portfolio tracking features.
ui/src/components/pages · high confidence
Added portfolio and quote chart components with IEX Cloud integration
The UI now includes new Vue components for displaying individual equity holdings and interactive price charts. The EquityRow component renders a card showing stock details, returns, and action links, while the QuoteChart component visualizes historical price data using AmCharts. These components are wired to fetch data from the IEX Cloud API, supporting multiple timeframes (1 day to 5 years) for stock charts.
ui · medium confidence
Added wire transfer API for portfolio-centric transfers
Introduced a new WireTransferService in the wire-transfer-api module, exposing endpoints to initiate fund transfers between a portfolio and a savings account, retrieve transaction summaries, and stream transfer updates. The API is explicitly scoped to portfolio-centric transfers rather than arbitrary account-to-account movements, utilizing new domain models for accounts, transfers, and transaction summaries.
wire-transfer-api · high confidence
BFF API specification and routing configuration introduced
The BFF now exposes a formal OpenAPI 3.0.2 specification (api.yaml) and defines HTTP routes (routes file) for portfolio and wire transfer endpoints, including portfolio management, order placement, and transfer streaming. The application configuration (application.conf) sets up the Play server, service discovery for wire transfer, broker, and portfolio services, and enables CORS and telemetry.
bff/src/main/resources · high confidence
BFF service initialization and error handling
The BFF (Backend for Frontend) service is initialized with custom HTTP error handling that maps 404 Not Found exceptions to appropriate HTTP responses, and registers formatters for TradeType parsing. The service module binds clients for PortfolioService, BrokerService, and WireTransferService, and configures a custom JSON object mapper to handle big decimal values as plain numbers and floats as big decimals.
bff/src/main/java · medium confidence
Broker service deployment and implementation for order processing
The broker-impl module now includes the full implementation for handling stock orders, including the OrderEntity state machine (Pending, Fulfilled, Failed) and the associated commands and events. This enables the system to process orders asynchronously via Kafka, track their status, and return trade details. Additionally, Kubernetes deployment manifests (Deployment, Service, ConfigMap, RBAC) and configuration files (application.conf, production.conf) are added to support running the broker service in a cluster environment.
broker-impl · high confidence
Initial UI application setup with routing and global filters
The UI application entry point (main.js) and root component (App.vue) have been added, establishing the Vue.js application structure. This includes configuring Vue Router with paths for portfolio, quote, trades, transfers, and home pages, as well as integrating Bootstrap-Vue, Rollbar for error tracking, and defining global Vue filters for currency, percentage, date, and UUID formatting.
ui/src · high confidence
Initial project setup and documentation
The repository was initialized with a complete set of project configuration and documentation files. This includes a README.md providing a comprehensive guide for local development, deployment to Kubernetes, and testing via curl and the Vue.js UI. The project also includes a .jvmopts file to configure JVM memory settings, a lombok.config to manage Java annotation processing, and standard license and notice files (Apache 2.0).
(repo-wide) · high confidence
Introduce Broker Service API for stock quotes and order tracking
The broker-api module now exposes a new BrokerService interface that allows clients to retrieve current and detailed stock quotes, as well as check the status of specific orders. The API provides endpoints for fetching a single quote, a batch of detailed quotes including company information, and an order summary that includes the trade type, symbol, and status (pending, fulfilled with price, or failed). Additionally, the service publishes order result events (fulfilled or failed) to a Kafka topic, enabling real-time tracking of order outcomes.
broker-api · high confidence
Introduce Order and OrderDetails models for trade execution
Added new Java classes Order, OrderDetails, and OrderType to the portfolio-api module. The Order class encapsulates an order's identity and associated details, while OrderDetails captures the specific parameters of a trade, including the symbol, number of shares, trade type, and order type. The OrderType class defines a hierarchy for market and limit orders, supporting serialization via Jackson annotations. This change establishes the core data structures for representing and processing stock orders within the portfolio system.
portfolio-api/src/main/java/com/redelastic/stocktrader/portfolio/api/order · high confidence
Introduce portfolio API contracts and data models
The portfolio-api module now defines the core service interface and data models for managing stock portfolios. The new PortfolioService interface exposes endpoints to open, close, and query portfolios, as well as place orders and process fund transfers. Supporting types include PortfolioView (containing funds, holdings, and completed orders), PortfolioSummary, Holding, FundsTransfer (with Deposit, Withdrawl, and Refund variants), and OrderPlaced events. These changes establish the API contract for portfolio operations.
portfolio-api/src/main/java/com/redelastic/stocktrader/portfolio/api · high confidence
Introduce wire transfer service implementation
The wire-transfer-impl module now contains the core implementation for the wire transfer feature. This includes the WireTransferService and its associated command, state, and event models, enabling the system to process fund transfers between accounts. The implementation utilizes a saga pattern to coordinate the withdrawal from the source portfolio, the deposit to the destination, and the necessary refund logic if delivery fails. Additionally, a read-side processor is provided to persist transfer summaries into a Cassandra database for querying transaction history.
wire-transfer-impl/src/main/java · high confidence
Kubernetes deployment and configuration for the Portfolio service
Added Kubernetes deployment manifests (Deployment, Service, ConfigMap, Role, RoleBinding, ServiceAccount) and production configuration files (application.prod.conf, production.conf) to enable the Portfolio service to run on a Kubernetes cluster. The deployment configures the service with specific ports (HTTP, remoting, management), resource limits, health checks, and environment variables for connecting to Cassandra, Kafka, and other microservices.
portfolio-impl · high confidence
New Wire Transfer Page with Live Status Updates
A new 'New Wire Transfer' page has been added, allowing users to initiate wire transfers, view their active portfolio's cash on hand, and see a transaction history table. The component integrates with WebSocket streams to provide real-time status updates for transfers, and the UI disables the submit button while a transfer is being processed.
ui/src/components/pages/transfers · high confidence
New form models for portfolio and transfer operations
Added new Java form classes to support portfolio and transfer features: OpenPortfolioForm for creating portfolios, PlaceOrderForm for executing buy/sell orders, and TransferForm for handling account transfers. These classes define the data structures used by the backend to process these user actions.
bff/src/main/java/controllers/forms · high confidence
New order placement form introduced
A new 'Place New Order' form has been added to the trades page, allowing users to configure buy or sell orders with various parameters including ticker symbol, number of shares, and order types (market, limit, stop, or stop-limit). The form includes a summary section that displays the selected symbol, company name, latest price, and order details, providing a complete interface for initiating new trades.
ui/src/components/pages/trades · high confidence
Removals
Removed Hello and Stream service implementations
The Hello service implementation, including its entity, commands, events, and tests, has been removed from the codebase. Additionally, the Stream service implementation, along with its repository and subscriber components, has also been deleted. These changes eliminate the associated API interfaces, configuration files, and unit tests for both services.
(repo-wide) · high confidence
Behavioural changes
Added production secret configuration for BFF deployment
A new production configuration file (production.conf) has been added to the BFF deploy secrets, defining the HTTP secret key and including application-specific settings, enabling secure deployment of the BFF in production environments.
bff/deploy/secrets · medium confidence
New portfolio summary and order models for enhanced financial data
The BFF layer now exposes richer portfolio data through new Java models. PortfolioSummary includes total stock value, trade costs, and calculated return metrics (both total value and percentage). It also provides boolean flags indicating the presence of transfers and equities. Additionally, new models for CompletedOrder (including price and trade type) and EquityHolding (including detailed quotes) are introduced to support this enhanced data structure.
bff/src/main/java/models · medium confidence
Test coverage
Removed StreamIT integration test and associated test configuration files
The integration test for the stream service (StreamIT) has been removed, along with the associated test configuration files (application.conf and logback-test.xml). This means the automated checks for the stream functionality are no longer part of the test suite.
integration-tests · high confidence
Dependencies
Migrate build system from Maven to SBT and update frontend dependencies
The project's build configuration has been migrated from a multi-module Maven structure to an SBT-based build, introducing new dependencies for the Lagom framework (including Akka and Kubernetes service discovery) and replacing the previous Maven POM files. Additionally, the frontend UI dependencies have been updated, including a version bump for the axios library.
(dependencies) · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 38 → 38 (+0.9)
- Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.
Lenses
- Code Health 46 → 49 (+2.6)
- Architecture 100 → 88 (-12.5)
- Maturity 64 → 64 (+0.0)
- Readiness 16 → 17 (+1.3)
- Security 72 → 72 (-0.2)
- Accessibility 59 → 59 (+0.0)
Resolved (11)
- Coverage not included — suite not readable by the collector
- Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
- Duplicated block (10 lines × 2) (broker-impl/src/main/java/com/redelastic/stocktrader/broker/impl/quote/IexQuoteServiceImpl.java)
- Duplicated block (10 lines × 2) (portfolio-impl/src/main/java/com/redelastic/stocktrader/portfolio/impl/PortfolioEntity.java)
- Medium IaC: CKV_K8S_21 (portfolio-impl/deploy/kubernetes/akka-cluster-member-role.yaml)
- Medium IaC: CKV_K8S_21 (wire-transfer-impl/deploy/kubernetes/akka-cluster-member-role.yaml)
- No exposed public API
- Scanner failed to run — not a clean result
- Secret: generic-api-key (ui/.env)
- Test reliability not included
- dormant codebase — no living knowledge left to concentrate
New (80)
- Boundary-crossing change coupling: BrokerService.java ↔ PortfolioService.java (broker-api/src/main/java/com/redelastic/stocktrader/broker/api/BrokerService.java)
- Boundary-crossing change coupling: TradeServiceImpl.java ↔ PortfolioServiceImpl.java (broker-impl/src/main/java/com/redelastic/stocktrader/broker/impl/trade/TradeServiceImpl.java)
- Change coupling: PortfolioRepositoryImpl.java ↔ PortfolioServiceImpl.java (portfolio-impl/src/main/java/com/redelastic/stocktrader/portfolio/impl/PortfolioRepositoryImpl.java)
- Coverage not measured — no coverage collector is wired up
- Documentation: no installation or build instructions (README.md)
- Documentation: no usage examples (README.md)
- Duplicated block (10 lines × 2) (broker-impl/src/main/java/com/redelastic/stocktrader/broker/impl/quote/IexQuoteServiceImpl.java)
- Duplicated block (63 lines × 2) (portfolio-api/src/main/java/com/redelastic/stocktrader/portfolio/api/FundsTransfer.java)
- Duplicated block (9–10 lines × 2) (portfolio-impl/src/main/java/com/redelastic/stocktrader/portfolio/impl/PortfolioEntity.java)
- FixmeComment (broker-impl/src/main/java/com/redelastic/stocktrader/broker/impl/order/OrderModelImpl.java)
- FixmeComment (broker-impl/src/main/java/com/redelastic/stocktrader/broker/impl/order/OrderRepositoryImpl.java)
- Medium IaC: CKV2_K8S_6 (bff/deploy/kubernetes/bff-deployment.yaml)
- Medium IaC: CKV2_K8S_6 (broker-impl/deploy/kubernetes/broker-deployment.yaml)
- Medium IaC: CKV2_K8S_6 (portfolio-impl/deploy/kubernetes/portfolio-deployment.yaml)
- Medium IaC: CKV2_K8S_6 (wire-transfer-impl/deploy/kubernetes/wiretransfer-deployment.yaml)
- Medium IaC: CKV_K8S_11 (bff/deploy/kubernetes/bff-deployment.yaml)
- Medium IaC: CKV_K8S_11 (broker-impl/deploy/kubernetes/broker-deployment.yaml)
- Medium IaC: CKV_K8S_11 (portfolio-impl/deploy/kubernetes/portfolio-deployment.yaml)
- Medium IaC: CKV_K8S_11 (wire-transfer-impl/deploy/kubernetes/wiretransfer-deployment.yaml)
- Medium IaC: CKV_K8S_15 (bff/deploy/kubernetes/bff-deployment.yaml)
- …and 60 more
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
RedElastic/reactive-stock-trader was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 22 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit e3a6efbca8558ba30a22722527a5ff45cb43ffec — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-90d5d2fe38ee.