A robust enterprise document management and archiving system built on the CUBA Platform.
WFM Archive consolidates documents from scattered systems into a single, searchable repository with powerful workflow automation. It provides multi-tenant document storage, configurable retention policies, and seamless integration with enterprise systems including Keycloak, MongoDB, Amazon S3, and IBM i-Series.
Key Business Value:
- Unified Document Management: Reduce document search time by 30-40% with centralized storage
- Regulatory Compliance: Automated retention policies and comprehensive audit trails
- Legacy System Bridge: Modernize document management without disrupting existing workflows
| Feature | Description |
|---|---|
| Document Archiving | Multi-format document storage with metadata, versioning, and full-text search |
| Dynamic Document Types | Create custom document types with configurable fields - no coding required |
| Workflow Automation | BPMN-based workflows using Flowable for approval routing and process automation |
| Multi-tenant Support | Organization-level data isolation with per-tenant configurations |
| External Integrations | Connect to Keycloak (SSO), MongoDB, Amazon S3, IBM i-Series, and custom databases |
| Role-Based Access | Fine-grained permissions at document type and organization levels |
| Advanced Search | Full-text and metadata search with filters (AND, OR, IN operations) |
| Retention Policies | Configurable deletion schedules with soft delete, hard delete, and anonymization |
| REST API | Complete RESTful API for external system integration |
| Audit Trail | Comprehensive logging for all document operations |
| Component | Technology | Version |
|---|---|---|
| Framework | CUBA Platform | 7.2.19 |
| Languages | Java / Groovy | 11 / 2.5.14 |
| Frontend | Vaadin | 8.14.3 |
| Build Tool | Gradle | 5.6.4 |
| Primary Database | Microsoft SQL Server | - |
| Document Store | MongoDB | 4.10+ |
| File Storage | Amazon S3 | - |
| Workflow Engine | Flowable | 6.5.0 |
| Authentication | Keycloak | - |
| Message Queue | Apache Camel | 2.25.0 |
- Java 11 JDK
- Gradle 5.6.4+ (or use included wrapper)
- Microsoft SQL Server (or HSQLDB for development)
- MongoDB 4.10+
- Docker (optional, for containerized deployment)
# Clone the repository
git clone <repository-url>
cd wfmarchive
# Build the application
./gradlew assemble
# Create development database (uses HSQLDB)
./gradlew createDb
# Start the development server
./gradlew restartThe application will be available at http://localhost:8080/app
# Build Docker image
docker build -t wfmarchive .
# Run with Docker Compose
cd docker-image
docker compose upwfmarchive/
├── modules/
│ ├── global/ # Shared entities, services, and configurations
│ ├── core/ # Business logic and service implementations
│ ├── web/ # Web UI screens and REST controllers
│ └── portal/ # External portal for public access
├── docs/ # Detailed documentation
├── docker-image/ # Docker configuration
└── deploy/ # Deployment artifacts
Create a .env file based on .env.example:
| Variable | Description |
|---|---|
DB_HOST |
Production database host |
DB_PORT |
Database port |
DB_NAME |
Database name |
DB_USER |
Database username |
DB_PASSWORD |
Database password |
DEV_DB_* |
Development database settings |
| File | Purpose |
|---|---|
modules/core/src/.../app.properties |
Production configuration |
modules/core/src/.../dev-app.properties |
Development configuration |
modules/core/src/.../docker-app.properties |
Docker configuration |
modules/web/src/.../web-app.properties |
Web tier configuration |
# Build application
./gradlew assemble
# Run tests
./gradlew test
# Build WAR file
./gradlew buildWar
# Build standalone JAR
./gradlew buildUberJar
# Update database schema
./gradlew updateDb
# Build and deploy themes
./gradlew buildScssThemes deployThemes# Run all tests
./gradlew test
# Run tests for specific module
./gradlew :app-core:testFor detailed documentation, see the docs/ directory:
- Getting Started - Installation and configuration
- Architecture - System design and data flow
- API Reference - REST endpoint documentation
- Services - Service layer documentation
- Development - Developer guides
- Deployment - Production deployment
# Authenticate and get token
curl -X POST http://localhost:8080/app/rest/v2/oauth/token \
-H "Content-Type: application/x-www-form-urlencoded" \
-d "grant_type=password&username=admin&password=admin"
# Search documents
curl -X POST http://localhost:8080/app/rest/wfm/v1/archive/search \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"documentType": "INVOICE", "filters": {"status": "PENDING"}}'For technical details and development guidance, see CLAUDE.md