Skip to content
CAI
Software that uses CAICheck a score

dddplus/dddplus-demo

65.4

Adequate · 21 September 2026

1.9k

lines of production code

Java

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This is an order management system built on a Domain-Driven Design framework, designed to handle order submission, cancellation, and stock reservation workflows. It supports multiple business partners (ISV, KA, Fresh) through a pluggable extension architecture that allows for hot-reloading and dynamic loading of partner-specific logic. The system manages complex order data structures, including header and line items, while integrating with external stock services via RPC.

Features

Add RemoteStockRpc implementation for stock occupation

A new RemoteStockRpc component is introduced in the stock infrastructure layer, implementing the IRemoteStockRpc interface to handle stock occupation (doOccupy) by logging an RPC call to the stock center system.

order-center-domain-stock/order-center-stock-infrastructure · high confidence

Add fresh business front-end BP and extension implementations

Introduced the FreshPartner class to identify and resolve orders from the 'fresh' source, and added three extension implementations for the fresh business line: DecideStepsExt to define process steps for order submission and cancellation, PostPersitExt to handle post-persistence logic, and PresortExt for pre-sorting operations.

order-center-bp-fresh · high confidence

Added stock occupation service and RPC facade for order processing

Introduced a new StockService that implements the IStockService interface to handle stock occupation logic for orders. The service iterates through order items and calls the newly added IRemoteStockRpc interface to execute pre-occupation actions via RPC, facilitating interaction with the stock center.

order-center-domain-stock/order-center-stock-domain · high confidence

Introduce OrderItem and OrderMain domain models

The order domain model has been refactored and expanded to support more granular order data. A new OrderItem value object and its corresponding delegate are introduced to represent individual line items within an order. The existing OrderModel class is renamed to OrderMain to better reflect its role as the header-level aggregate, and it now aggregates both Product and OrderItem delegates. The OrderModelCreator is updated to accept lists of OrderItem and Product objects, enabling the construction of orders with multiple items and products.

order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/model · high confidence

Behavioural changes

Added file logging and hot-reload endpoint

The application now writes logs to a file (logs/app.log) in addition to the console, and exposes a /reload endpoint for hot-reloading plugins. The server also logs active plugins on startup.

order-center-cp/cp-oc-main · high confidence

Domain layer interfaces updated to use new OrderMain model

The domain layer's facade interfaces (IMessageProducer, IOrderRepository) have been updated to use the new OrderMain model instead of the previous OrderModel. Additionally, the repository interface now includes a method to retrieve an order by its ID, enabling the domain layer to fetch order data directly.

order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/facade · high confidence

Hot-reload support for ISV, KA, and Fresh plugins

The OrderController now supports hot-reloading partner plugins for ISV, KA, and Fresh scenarios. The \/reload\ endpoint accepts a \plugin\ parameter to specify which plugin jar to load, with a fallback to 'isv' if none is provided. The implementation uses a static map to resolve plugin names to their respective jar paths and leverages \Container.getInstance().loadPartnerPlugin\ to perform the reload, addressing previous issues where the code hardcoded the 'isv' plugin and used \System.getProperty\ for paths.

order-center-cp/cp-oc-controller/src/main/java/org/example/cp/oms/controller · medium confidence

KA partner implementation updated to use new order model and RPC interfaces

The KA (Key Account) partner implementation has been updated to align with the new order model, changing the identity resolver and extension points to use IOrderMain instead of IOrderModel. Additionally, the stock reservation logic now uses the IStockRpc interface instead of the previous IStockService, and a new ReviseStepsExt extension was added to prevent step revision for KA orders.

order-center-bp-ka · medium confidence

Move DTOs to controller layer and enrich order submission model

The CancelOrderRequest and SubmitOrderRequest DTOs have been moved from the client module to the controller module, aligning with the removal of the separate client module. For order submission, the model has been expanded to include a validated list of order items, each containing SKU, quantity, line identifier, and price, enabling more detailed order creation requests.

order-center-cp/cp-oc-controller/src/main/java/org/example/cp/oms/controller/dto · medium confidence

Order domain model unified to IOrderMain

The order domain's core model has been standardized: all domain abilities (PostPersist, AssignOrderNo, CustomModel, DecideSteps, Presort, ReviseSteps, SerializableIsolation) and their extensions now operate on the \IOrderMain\ interface instead of the previous \IOrderModel\/\OrderModel\. This change aligns the domain layer with the updated specification contract, ensuring consistent model usage across order processing steps.

order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/ability · high confidence

Order model refactored from OrderModel to OrderMain

The domain model used across the order submission and cancellation steps has been renamed from OrderModel to OrderMain. This change updates the core data structure passed through the step execution templates and individual step implementations, ensuring that all order-related operations now reference the new model type.

order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/step · high confidence

Order pattern interfaces updated to use IOrderMain instead of IOrderModel

The order-center-pattern module has been refactored to replace the generic IOrderModel interface with the more specific IOrderMain interface across pattern implementations and their extensions. This change affects ColdChainB2BPattern, HairPattern, and HomeAppliancePattern, as well as their associated extension classes (e.g., SerializableIsolationExt, ReviseStepsExt, AssignOrderNoExt, PresortExt). The removal of the Spring XML configuration (plugin.xml) suggests a shift away from XML-based bean definitions for these patterns. Users interacting with these order patterns will now see the system operating on the IOrderMain contract, which likely provides more specific order data access.

order-center-pattern · high confidence

Order retrieval and item handling expanded in the infrastructure layer

The order center's infrastructure layer now supports fetching complete order data, including both header and line items. A new OrderItemDao interface and its mock implementation allow querying order items by order ID. The OrderRepository gains a new getOrder method that retrieves the main order data and its associated items, then uses the new Data2Model mapper to construct an OrderModelCreator for domain model creation. Additionally, the repository's persist method was updated to use the renamed Model2Data translator for converting OrderMain to data objects, and the message producer was updated to handle the new OrderMain model type.

order-center-cp/cp-oc-infrastructure · medium confidence

Order submission and cancellation now use the OrderMain model

The domain services for submitting and cancelling orders have been updated to accept the OrderMain model instead of the previous OrderModel. Additionally, the order submission process now includes a post-persistence step to handle post-save actions, and the concurrency control logic for order submission has been adjusted to log a message when lock usage is skipped.

order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/service · high confidence

Startup logs domain artifacts for debugging

When the application starts, the system now logs the registered domains, specifications, steps, and extensions. This provides visibility into the domain model's structure and configuration at runtime, aiding in debugging and verification of the DDD framework's initialization.

order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain · high confidence

Updated order model interfaces to use IOrderMain

The ISV extension layer now operates on the IOrderMain model instead of the previous IOrderModel interface. This change affects the core extension classes (CustomModelExt, PresortExt, SerializableIsolationExt) and the IsvPartner identity resolver, ensuring that all order-related data passed to and from ISV plugins conforms to the updated contract. Additionally, the Spring configuration for the ISV plugin has been updated to enable lazy initialization by default, which may affect how beans are loaded during application startup.

order-center-bp-isv · high confidence

Test coverage

Added ProductNotEmptySpec domain specification; Added stock domain specification and service interface; Added test coverage for order exception handling; Added test step definitions for presort and stock operations; Introduces OrderItem model and refactors Order model structure; Renamed IStockService interface to IStockRpc; Update extension interfaces to use IOrderMain instead of IOrderModel; Updated test suite to reflect domain model and plugin loading changes.

Dependencies

Project rebranded to DDDplus and restructured with a new Stock domain

The project has been renamed from cp-ddd-framework-demo to dddplus-demo, and the parent artifact ID has been updated to dddplus-demo. The build configuration now includes the OSSRH snapshot repository for DDDplus dependencies. A new 'Stock' domain has been introduced, comprising spec, domain, and infrastructure modules, which are integrated into the main application. The cp-oc-client module has been removed, and the cp-ddd-plugin dependency has been replaced with dddplus-plugin and dddplus-enforce for architecture enforcement.

(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

This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.

Score

  • CAI 65 → 65 (+0.6)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 100 → 99 (-1.3)
  • Architecture 86 (new)
  • Maturity 71 → 71 (+0.0)
  • Readiness 47 → 47 (+0.0)
  • Security 84 → 93 (+9.3)
  • Domain Modelling 100 → 100 (+0.0)

Resolved (9)

  • Coverage not included — suite not readable by the collector
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • No exposed public API
  • Scanner failed to run — not a clean result
  • Test reliability not included
  • change coupling unreadable for .java — no production change history could be paired for this repository's own source
  • dormant codebase — no living knowledge left to concentrate

New (15)

  • Dependency hygiene PARTLY measured — Maven/Gradle declarations read, no dependency graph resolved
  • Documentation: no installation or build instructions (README.md)
  • Documentation: no usage examples (README.md)
  • Duplicated block (19 lines × 2) (order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/step/CancelOrderStepsExec.java)
  • Duplicated block (21 lines × 2) (order-center-pattern/src/main/java/org/example/cp/oms/pattern/HairPattern.java)
  • Duplicated block (7 lines × 2) (order-center-bp-isv/src/main/java/org/example/bp/oms/isv/IsvPartner.java)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • Medium: security finding (details withheld)
  • Medium: security finding (details withheld)
  • No dependency advisory monitoring
  • Scanner failed to run — not a clean result
  • Scanner failed to run — not a clean result
  • TodoComment (order-center-cp/cp-oc-domain/src/main/java/org/example/cp/oms/domain/step/submitorder/PresortStep.java)
  • Workflow token permissions not restricted

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

dddplus/dddplus-demo 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 21 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 879f2359d1d4d656ec8af67ae4b4a723047ea3b3 — 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-fa71c66cabd8.