Welcome to the Tech by Design Polyglot Prime repository! This repository is the central hub for all bespoke code managed by Technology By Design (Tech by Design). Our goal is to maintain a well-organized, scalable, and efficient monorepo that supports our diverse range of projects and technologies.
At Tech by Design, we focus on the following primary languages and frameworks for our enterprise and utility projects:
- Modern Java 21 LTS and above with Spring Boot 3.3 and above for all API and HTTP service-related use cases.
- Maven for project management.
- Thymeleaf for HTML templating and HTMX 2.0 for HATEOS interactions.
- OpenTelemetry (observability) and OpenFeature (feature flags).
- jOOQ with automatic code generation for type-safe SQL-first database interactions.
- PostgreSQL 16 for server-side persistence and SQLite for edge-side persistence.
- JUnit 5 with AssertJ assertions for testing the app server, Playwright for testing the front end, and pgTAP for testing the database.
- Deployment via containers
- Deno and TypeScript for utilities and scripting where Java may be too heavy.
Inspired by the practices at Microsoft, Google, and other large software companies, we have designed our monorepo strategy to facilitate collaboration, maintainability, and scalability. Here are the key aspects of our strategy:
- Modular Structure: Each top-level directory represents a distinct project or service. This allows for clear separation of concerns and easy navigation.
- Consistent Naming Conventions: Follow consistent naming conventions to make it easier to locate and manage code.
- Shared Libraries: Common libraries and utilities will be placed in a shared directory to promote code reuse.
- Version Control: Use Git submodules or subtree for managing third-party dependencies to keep the repository clean and manageable.
- CI/CD Integration: Integrate Continuous Integration and Continuous Deployment (CI/CD) pipelines for automated testing and deployment.
- Documentation: Each project will contain comprehensive documentation to assist developers in understanding and contributing to the codebase.
.
βββ api-automation/ # TypeScript/Playwright API test automation and validation
β βββ sections/ # Request and validation sections
β β βββ request_validate_data.ts
β βββ testdata/ # Test data and fixtures
β β βββ expectedValidationIssues.ts
β β βββ FHIR-Data/
β βββ tests/ # Test cases
β β βββ FHIR-BundleNegative.test.ts
β β βββ FHIR-BundlePositive.test.ts
β βββ utils/ # Testing utilities
β βββ logger-util.ts
β
βββ core-lib/ # Shared Java core library for common utilities and components
β βββ src/
β β βββ main/
β β β βββ java/
β β βββ test/
β β βββ java/
β βββ lib/ # External dependencies
β
βββ csv-service/ # Java service for CSV file processing and transformation
β βββ src/
β β βββ main/
β β β βββ java/
β β β β βββ org/techbd/
β β β βββ resources/
β β βββ test/
β β βββ java/
β βββ lib/ # External dependencies
β
βββ fhir-validation-service/ # Java service for FHIR compliance validation
β βββ src/
β β βββ main/
β β β βββ java/
β β β β βββ org/techbd/
β β β βββ resources/
β β βββ test/
β β βββ java/
β βββ lib/ # External dependencies
β
βββ hub-prime/ # Primary Spring Boot FHIR API hub and UI application
β βββ src/
β β βββ main/
β β β βββ java/
β β β β βββ org/techbd/
β β β β βββ conf/ # Configuration classes
β β β β βββ controller/ # REST controllers
β β β β βββ orchestrate/ # FHIR and SFTP orchestration
β β β β β βββ fhir/
β β β β β βββ sftp/
β β β β βββ service/ # Business logic services
β β β β β βββ http/
β β β β β β βββ filter/ # Security and request filters
β β β β β β βββ hub/ # Hub-specific logic
β β β β β β βββ *.java # Config, constants, security
β β β β β βββ *.java
β β β β βββ util/ # Utility helpers
β β β βββ resources/
β β β βββ META-INF/
β β β βββ public/ # Static web assets
β β β βββ templates/ # Thymeleaf templates
β β β βββ fragments/
β β β βββ layout/
β β β βββ login/
β β β βββ mock/ # Mock data templates
β β β βββ page/ # Page templates
β β βββ site/
β β β βββ markdown/
β β βββ test/
β β βββ java/
β β βββ org/techbd/
β β βββ orchestrate/ # Tests for orchestration
β β βββ service/ # Tests for services
β β βββ util/ # Tests for utilities
β βββ lib/ # External dependencies
β
βββ integration-artifacts/ # Integration configurations, scripts, and templates for various data formats
β βββ aws-queue-listener/ # AWS SQS integration
β βββ ccda/ # CCDA format templates
β βββ custom-lib/ # Custom libraries
β βββ fhir/ # FHIR-specific artifacts
β βββ flatfile/ # Flat file processing templates
β βββ global-scripts/ # Shared integration scripts
β βββ hl7v2/ # HL7v2 format templates
β βββ lookup-manager/ # Lookup table management
β
βββ nexus-core-lib/ # Nexus-specific core library shared across nexus services
β βββ src/
β β βββ main/
β β β βββ java/
β β βββ test/
β β βββ java/
β βββ lib/
β
βββ nexus-ingestion-api/ # Nexus ingestion API service
β βββ src/
β β βββ main/
β β β βββ java/
β β β β βββ org/techbd/
β β β βββ resources/
β β βββ test/
β β βββ java/
β βββ lib/
β
βββ support/ # Supporting tools, documentation, and non-production work products
β βββ bin/ # Utility scripts and binaries
β βββ containers/ # Docker and container configs
β βββ nyec-ig-version/ # NYEC IG versioning tools
β βββ qualityfolio/ # Quality metrics and dashboards
β βββ release-notes/ # Release documentation
β βββ service/ # Service-level tools
β βββ specifications/ # Technical specifications
β βββ testcases/ # Manual test cases
β
βββ test-automation/ # Test automation scripts for smoke testing and QA
β βββ FHIR-Bundle-SmokeTest-Devl/
β βββ FHIR-Bundle-SmokeTest-PHI-QA/
β βββ FHIR-Bundle-SmokeTest-Stage/
β βββ CCDA-Bundle-SmokeTest-PHI-QA/
β βββ CCDA-Bundle-SmokeTest-Stage/
β βββ CSV-Bundle-SmokeTest-PHI-QA/
β βββ CSV-Bundle-SmokeTest-Stage/
β βββ HL7-Bundle-SmokeTest-PHI-QA/
β βββ HL7-Bundle-SmokeTest-Stage/
β
βββ udi-prime/ # UDI ingestion center with PostgreSQL database and jOOQ code generation
βββ src/
β βββ main/
β β βββ postgres/ # PostgreSQL DDL scripts
β β βββ ingestion-center/
β βββ test/
β βββ postgres/
β βββ ingestion-center/
βββ support/
β βββ jooq/ # jOOQ code generation
β βββ lib/
βββ lib/ # External dependencies
Primary Spring Boot 3.3+ FHIR API hub application with Thymeleaf UI and HTMX interactions. Handles FHIR bundle ingestion, validation, and API endpoints.
UDI (Unified Data Intake) ingestion center with PostgreSQL backend. Uses jOOQ for type-safe SQL operations and includes database migrations and code generation.
Nexus-specific ingestion API service for data integration and processing.
Java-based service for CSV file processing, validation, and transformation to standard formats.
Dedicated FHIR compliance validation service that validates data against FHIR specifications.
Shared Java library containing common utilities, models, and components used across multiple services.
Nexus-specific core library with shared functionality for nexus-related services.
TypeScript/Playwright-based API automation framework for testing REST endpoints and validating responses.
Smoke test automation suites for different environments (Development, QA, Stage, Production) across FHIR, HL7, CCDA, and CSV bundles.
Contains integration configurations, global scripts, and templates for various data formats (FHIR, HL7v2, CCDA, Flatfile, etc.)
Supporting work products including documentation, specifications, release notes, testing tools, and non-production utilities.
To set up the Tech by Design Polyglot Prime monorepo, follow these steps:
-
Clone the Repository:
git clone https://github.com/tech-by-design/polyglot-prime.git cd polyglot-prime direnv allow # apply the env vars cp .envrc.example .envrc # assume the use of direnv vi .envrc # make sure to store secrets in ENV or Vault, not in Git
-
Build
hub-primewith all dependenvy modules:mvn clean install
-
Run the Primary Hub Application:
cd hub-prime mvn spring-boot:run -
Access the Application: Open your browser and navigate to
http://localhost:8080.
Each top-level directory is a separate Maven module or project. Here's the recommended workflow:
- Make changes to your specific project
- Run tests:
mvn testin the project directory - Build the project:
mvn clean install - For integration changes, rebuild the entire monorepo:
mvn clean installfrom root