From 9e92087a5647600c06db4b9e05eff6fcb5921087 Mon Sep 17 00:00:00 2001 From: JanardhanBS-SyncByte Date: Tue, 29 Sep 2026 20:22:26 +0530 Subject: [PATCH 1/6] [issue-1633] Signed-off-by: JanardhanBS-SyncByte --- .github/AGENTS.md | 17 + .github/workflows/push-trigger.yml | 31 +- .gitignore | 20 +- AGENTS.md | 163 +---- LICENSE | 395 ++++++++++- NOTICE | 126 ++++ README.md | 306 +++++---- cache-provider-hazelcast/AGENTS.md | 12 + cache-provider-hazelcast/README.md | 32 + cache-provider-hazelcast/pom.xml | 559 ++++++++-------- .../config/HazelcastHealthIndicator.java | 94 ++- .../config/HazelcastHealthIndicatorTest.java | 108 +++ cache-provider-redis/AGENTS.md | 12 + cache-provider-redis/README.md | 27 + cache-provider-redis/pom.xml | 567 +++++++++------- .../redis/config/RedisConfigTest.java | 74 +++ directoryAngularFiles | 2 - helm/AGENTS.md | 17 + helm/prereg-booking/AGENTS.md | 14 + helm/prereg-booking/README.md | 13 +- helm/prereg-booking/values.yaml | 6 +- kernel/AGENTS.md | 15 + kernel/README.md | 31 + kernel/kernel-ref-idobjectvalidator/AGENTS.md | 20 + kernel/kernel-ref-idobjectvalidator/README.md | 27 + kernel/kernel-ref-idobjectvalidator/pom.xml | 179 ++--- .../IdObjectReferenceValidatorConstant.java | 38 +- ...jectReferenceValidatorDocumentMapping.java | 12 +- ...jectReferenceValidatorLocationMapping.java | 22 +- .../impl/IdObjectReferenceValidator.java | 32 +- .../kernel-smsserviceprovider-msg91/AGENTS.md | 21 + .../kernel-smsserviceprovider-msg91/README.md | 91 ++- .../kernel-smsserviceprovider-msg91/pom.xml | 199 +----- .../msg91/dto/SmsVendorRequestDto.java | 6 + .../msg91/exception/ApiExceptionHandler.java | 24 + .../msg91/impl/SMSServiceProviderImpl.java | 40 +- .../msg91/test/SmsServiceProviderTest.java | 27 +- kernel/kernel-virusscanner-clamav/AGENTS.md | 21 + kernel/kernel-virusscanner-clamav/README.md | 28 +- kernel/kernel-virusscanner-clamav/pom.xml | 184 +----- .../constant/VirusScannerErrorCodes.java | 8 + .../clamav/impl/VirusScannerImpl.java | 115 ++-- .../test/VirusScannerExceptionTest.java | 21 +- .../clamav/test/VirusScannerServiceTest.java | 23 +- kernel/pom.xml | 614 ++++++++++++------ keycloak/AGENTS.md | 10 + keycloak/README.md | 16 + licenses/0BSD.txt | 5 + licenses/AFL-2.1.txt | 197 ++++++ licenses/Apache-2.0.txt | 202 ++++++ licenses/BSD-2-Clause.txt | 9 + licenses/BSD-3-Clause-No-Nuclear-License.txt | 15 + licenses/BSD-3-Clause.txt | 9 + licenses/BlueOak-1.0.0.txt | 55 ++ licenses/CDDL-1.0.txt | 119 ++++ ...COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt | 11 + licenses/EPL-1.0.txt | 73 +++ licenses/EPL-2.0.txt | 80 +++ licenses/ISC.txt | 7 + licenses/LGPL-3.0.txt | 304 +++++++++ licenses/MIT.txt | 16 + licenses/MOZILLA-2.0.txt | 151 +++++ licenses/MPL-2.0.txt | 374 +++++++++++ licenses/NOTICE | 195 ++++++ licenses/OFL-1.1.txt | 43 ++ licenses/Unicode-DFS-2016.txt | 22 + licenses/Zlib.txt | 11 + pre-registration-booking-service/AGENTS.md | 34 + pre-registration-booking-service/Dockerfile | 56 +- pre-registration-booking-service/README.md | 158 +++-- pre-registration-booking-service/pom.xml | 537 ++++++++------- .../booking/BookingApplication.java | 12 +- .../booking/codes/RequestCodes.java | 30 +- .../booking/config/BookingConfig.java | 29 +- .../booking/config/OpenApiProperties.java | 52 +- .../booking/controller/BookingController.java | 9 +- .../booking/dto/AvailabilityDto.java | 12 +- .../booking/dto/AvailabilityReqDto.java | 7 +- .../booking/dto/BookingDataByRegIdDto.java | 6 +- .../booking/dto/BookingRequestDTO.java | 4 +- .../booking/dto/BookingStatus.java | 8 +- .../booking/dto/BookingStatusDTO.java | 6 +- .../booking/dto/DateTimeDto.java | 7 +- .../dto/DemographicBookingRightJoin.java | 4 + .../booking/dto/HolidayDto.java | 12 +- .../booking/dto/MultiBookingRequest.java | 5 +- .../booking/dto/MultiBookingRequestDTO.java | 4 +- .../booking/dto/RegistrationCenterDto.java | 29 +- .../dto/RegistrationCenterHolidayDto.java | 7 +- .../dto/RegistrationCenterResponseDto.java | 6 +- .../preregistration/booking/dto/SlotDto.java | 10 +- .../booking/dto/SlotTimeDto.java | 16 +- ...ailabilityTableNotAccessableException.java | 4 + .../AvailabilityUpdationFailedException.java | 4 + .../booking/exception/JsonException.java | 4 + .../booking/exception/TimeSpanException.java | 7 + .../BookingAvailabilityRepository.java | 2 +- .../booking/service/BookingServiceIntf.java | 3 + .../service/util/BookingServiceUtil.java | 6 +- .../src/main/resources/bootstrap.properties | 12 +- .../config/BookingConfigOpenApiTest.java | 56 ++ .../booking/test/BookingApplicationTest.java | 11 +- .../controller/BookingControllerTest.java | 513 +++++---------- .../service/BookingServiceCoverageTest.java | 594 +++++++++++++++++ .../test/service/BookingServiceTest.java | 22 +- .../service/util/BookingServiceUtilTest.java | 16 +- .../src/test/resources/bootstrap.properties | 4 +- registration-processor/AGENTS.md | 14 + registration-processor/README.md | 35 + registration-processor/pom.xml | 481 ++++++++++++++ .../AGENTS.md | 21 + .../Dockerfile | 55 +- .../README.md | 128 ++-- .../pom.xml | 337 ++-------- ...ExternalIntegrationServiceApplication.java | 7 +- .../eis/config/OpenApiProperties.java | 52 +- .../eis/config/SwaggerConfig.java | 45 +- .../eis/controller/ExternalController.java | 16 +- .../eis/entity/BaseRestRequestDTO.java | 21 +- .../eis/entity/MessageRequestDTO.java | 13 +- .../src/main/resources/bootstrap.properties | 11 +- .../ExternalIntegrationControllerTest.java | 2 +- .../eis/config/SwaggerConfigTest.java | 56 ++ .../src/test/resources/application.properties | 3 +- .../AGENTS.md | 20 + .../Dockerfile | 59 +- .../README.md | 139 ++-- .../pom.xml | 270 ++------ .../ExternalStageApplication.java | 10 +- .../externalstage/config/Externalconfig.java | 5 +- .../entity/BaseRestRequestDTO.java | 21 +- .../entity/MessageRequestDTO.java | 14 +- .../externalstage/stage/ExternalStage.java | 35 +- .../externalstage/utils/StatusMessage.java | 10 +- .../src/main/resources/bootstrap.properties | 2 + .../stage/ExternalStageTest.java | 6 +- testng-report-failed1.tar.gz | Bin 106106 -> 0 bytes 137 files changed, 7263 insertions(+), 3260 deletions(-) create mode 100644 .github/AGENTS.md create mode 100644 NOTICE create mode 100644 cache-provider-hazelcast/AGENTS.md create mode 100644 cache-provider-hazelcast/README.md create mode 100644 cache-provider-hazelcast/src/test/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicatorTest.java create mode 100644 cache-provider-redis/AGENTS.md create mode 100644 cache-provider-redis/README.md create mode 100644 cache-provider-redis/src/test/java/io/mosip/commons/packet/cache/provider/redis/config/RedisConfigTest.java delete mode 100644 directoryAngularFiles create mode 100644 helm/AGENTS.md create mode 100644 helm/prereg-booking/AGENTS.md create mode 100644 kernel/AGENTS.md create mode 100644 kernel/README.md create mode 100644 kernel/kernel-ref-idobjectvalidator/AGENTS.md create mode 100644 kernel/kernel-ref-idobjectvalidator/README.md create mode 100644 kernel/kernel-smsserviceprovider-msg91/AGENTS.md create mode 100644 kernel/kernel-virusscanner-clamav/AGENTS.md create mode 100644 keycloak/AGENTS.md create mode 100644 keycloak/README.md create mode 100644 licenses/0BSD.txt create mode 100644 licenses/AFL-2.1.txt create mode 100644 licenses/Apache-2.0.txt create mode 100644 licenses/BSD-2-Clause.txt create mode 100644 licenses/BSD-3-Clause-No-Nuclear-License.txt create mode 100644 licenses/BSD-3-Clause.txt create mode 100644 licenses/BlueOak-1.0.0.txt create mode 100644 licenses/CDDL-1.0.txt create mode 100644 licenses/COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt create mode 100644 licenses/EPL-1.0.txt create mode 100644 licenses/EPL-2.0.txt create mode 100644 licenses/ISC.txt create mode 100644 licenses/LGPL-3.0.txt create mode 100644 licenses/MIT.txt create mode 100644 licenses/MOZILLA-2.0.txt create mode 100644 licenses/MPL-2.0.txt create mode 100644 licenses/NOTICE create mode 100644 licenses/OFL-1.1.txt create mode 100644 licenses/Unicode-DFS-2016.txt create mode 100644 licenses/Zlib.txt create mode 100644 pre-registration-booking-service/AGENTS.md create mode 100644 pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/config/BookingConfigOpenApiTest.java create mode 100644 pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceCoverageTest.java create mode 100644 registration-processor/AGENTS.md create mode 100644 registration-processor/README.md create mode 100644 registration-processor/pom.xml create mode 100644 registration-processor/registration-processor-external-integration-service/AGENTS.md create mode 100644 registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/config/SwaggerConfigTest.java create mode 100644 registration-processor/registration-processor-external-stage/AGENTS.md delete mode 100644 testng-report-failed1.tar.gz diff --git a/.github/AGENTS.md b/.github/AGENTS.md new file mode 100644 index 00000000000..2c5925b7bb7 --- /dev/null +++ b/.github/AGENTS.md @@ -0,0 +1,17 @@ +# .github + +Do not glob. Do not read `keys/`. + +``` +.github/ +├── AGENTS.md +├── workflows/ +│ ├── push-trigger.yml # Maven/Docker/OSSRH/Sonar — kattu@master-java21 +│ ├── chart-lint-publish.yml # helm +│ └── use-pr-linker.yml +└── keys/ # GPG — never read/edit/commit + ├── mosipgpgkey_pub.gpg + └── mosipgpgkey_sec.gpg +``` + +`push-trigger.yml`: Maven `SERVICE_LOCATION` = aggregator for `kernel/` + `registration-processor/`. Docker still child paths. OSSRH skip on `master` + PRs. diff --git a/.github/workflows/push-trigger.yml b/.github/workflows/push-trigger.yml index 4c0d5b49fc8..a2a4cd04fd4 100644 --- a/.github/workflows/push-trigger.yml +++ b/.github/workflows/push-trigger.yml @@ -20,6 +20,7 @@ on: - 1.* - develop* - MOSIP* + - issue* jobs: build-maven-kernel: @@ -122,11 +123,16 @@ jobs: GPG_SECRET: ${{ secrets.GPG_SECRET }} SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} - build-maven-registration-processor-external-stage: + # Maven runs at registration-processor/ (registration-processor-ref-parent), same pattern as kernel/. + # kattu xmlstarlet checks licenses/gpg/git-commit-id on that pom. Children inherit them. + # Docker stays on each service dir so image names and Helm/K8s deploy are unchanged. + # No publish_to_nexus here (same as before) — parent POM is not published as a Docker image + # and artifactId is registration-processor-ref-parent (not registration-processor). + build-maven-registration-processor: uses: mosip/kattu/.github/workflows/maven-build.yml@master-java21 with: - SERVICE_LOCATION: registration-processor/registration-processor-external-stage - BUILD_ARTIFACT: registration-processor-external-stage + SERVICE_LOCATION: registration-processor + BUILD_ARTIFACT: registration-processor secrets: OSSRH_USER: ${{ secrets.OSSRH_USER }} OSSRH_SECRET: ${{ secrets.OSSRH_SECRET }} @@ -135,13 +141,13 @@ jobs: SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} build-dockers-registration-processor-external-stage: - needs: build-maven-registration-processor-external-stage + needs: build-maven-registration-processor strategy: matrix: include: - SERVICE_LOCATION: 'registration-processor/registration-processor-external-stage' SERVICE_NAME: 'registration-processor-external-stage' - BUILD_ARTIFACT: 'registration-processor-external-stage' + BUILD_ARTIFACT: 'registration-processor' fail-fast: false name: ${{ matrix.SERVICE_NAME }} uses: mosip/kattu/.github/workflows/docker-build.yml@master-java21 @@ -154,26 +160,15 @@ jobs: ACTOR_DOCKER_HUB: ${{ secrets.ACTOR_DOCKER_HUB }} RELEASE_DOCKER_HUB: ${{ secrets.RELEASE_DOCKER_HUB }} SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} - build-maven-registration-processor-external-integration-service: - uses: mosip/kattu/.github/workflows/maven-build.yml@master-java21 - with: - SERVICE_LOCATION: registration-processor/registration-processor-external-integration-service - BUILD_ARTIFACT: registration-processor-external-integration-service - secrets: - OSSRH_USER: ${{ secrets.OSSRH_USER }} - OSSRH_SECRET: ${{ secrets.OSSRH_SECRET }} - OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }} - GPG_SECRET: ${{ secrets.GPG_SECRET }} - SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} build-dockers-registration-processor-external-integration-service: - needs: build-maven-registration-processor-external-integration-service + needs: build-maven-registration-processor strategy: matrix: include: - SERVICE_LOCATION: 'registration-processor/registration-processor-external-integration-service' SERVICE_NAME: 'registration-processor-external-integration-service' - BUILD_ARTIFACT: 'registration-processor-external-integration-service' + BUILD_ARTIFACT: 'registration-processor' fail-fast: false name: ${{ matrix.SERVICE_NAME }} uses: mosip/kattu/.github/workflows/docker-build.yml@master-java21 diff --git a/.gitignore b/.gitignore index 03df026840a..9134dbe6f44 100644 --- a/.gitignore +++ b/.gitignore @@ -7,9 +7,6 @@ target/ .springBeans .metadata .factorypath -.classpath -.project -.settings/ .vertx/ bin/ tmp/ @@ -22,11 +19,22 @@ local.properties .loadpath .DS_Store test.txt -.idea/ -.settings/ .sonarlint/ .recommenders/ /.recommenders/ **/*.iml .vscode -authentication-demo-ui/keys/ \ No newline at end of file +authentication-demo-ui/keys/ + +# Local / IDE (Eclipse, STS, IntelliJ) +.local/ +.local +.idea/ +.idea +.classpath +.project +.settings/ +*/.classpath +*/.project +*/.settings/ +.sts4-cache/ \ No newline at end of file diff --git a/AGENTS.md b/AGENTS.md index 7a3dc3176c7..afdfb180e75 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,141 +1,50 @@ # AGENTS.md -This file provides guidance to AI agents when working with code in this repository. +MOSIP **ref impls** (not core). Independent Maven modules. No root parent. Each top parents `spring-boot-starter-parent` **4.1.1**. No `kernel-bom`. Pins live in `pom.xml` only. -## Project Overview +## Speed -This is the **MOSIP Reference Implementation** (`mosip-ref-impl`) — a collection of country-deployable, pluggable implementations that extend the core MOSIP (Modular Open Source Identity Platform). It does **not** contain core platform logic; instead it provides concrete, replaceable implementations of interfaces defined upstream (in `mosip/mosip-platform`, `mosip/kernel`, etc.). +1. **Do not glob / find / `ls`.** This tree + **one** nested `AGENTS.md` is the map. +2. Open **named files only**. Never scan `target/`, `.git/`, `.idea/`, `.sts4-cache/`, `node_modules/`, `*.class`, `*.jar`, `.github/keys/`. +3. Grep a known path. Do not repo-search. Do not put MOSIP versions in comments. -Each module in this repo is an independently buildable Maven project published to Maven Central (OSSRH). Downstream deployments wire these JARs in via Spring `spring.factories` auto-configuration or explicit `pom.xml` dependencies. - -## Build Commands - -Each module has its own `pom.xml`. There is **no root parent pom** — build each top-level directory independently: - -```bash -# Build a top-level module (skip GPG and Javadoc for local dev) -mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true - -# Run tests for a specific module -mvn test -pl - -# Run a single test class -mvn test -Dtest=ClassName - -# Run a single test method -mvn test -Dtest=ClassName#methodName - -# Generate coverage report (output: target/site/jacoco/index.html) -mvn clean verify - -# SonarCloud analysis -mvn clean verify -Psonar -``` - -**Prerequisites:** JDK 21.0.3, Maven 3.9.6. Tests use `--add-opens` JVM args (configured in each `pom.xml`) for Java 21 module compatibility. - -## Module Map +## Tree ``` mosip-ref-impl/ -├── kernel/ -│ ├── kernel-ref-idobjectvalidator/ # Reference ID Object Validator (JSON schema + masterdata validation) -│ ├── kernel-smsserviceprovider-msg91/ # SMS via MSG91 API -│ └── kernel-virusscanner-clamav/ # ClamAV virus scanner integration -├── cache-provider-hazelcast/ # Hazelcast cache provider (with health indicator) -├── cache-provider-redis/ # Redis cache provider -├── pre-registration-booking-service/ # Appointment booking service for pre-registration portal -├── registration-processor/ -│ ├── registration-processor-external-stage/ # Custom Vert.x stage: delegates to EIS -│ └── registration-processor-external-integration-service/ # REST stub for the external stage to call -├── keycloak/ # Keycloak theme + SPI customizations -└── helm/prereg-booking/ # Helm chart for pre-registration booking service +├── cache-provider-hazelcast/ PacketCacheProvider + health → AGENTS.md +├── cache-provider-redis/ PacketCacheProvider Redis → AGENTS.md +├── kernel/ kernel-ref-parent (3 SPIs) → AGENTS.md +│ ├── kernel-ref-idobjectvalidator/ IdObjectValidator → AGENTS.md +│ ├── kernel-smsserviceprovider-msg91/ SMS SPI (MSG91) → AGENTS.md +│ └── kernel-virusscanner-clamav/ VirusScanner + ClamAV → AGENTS.md +├── keycloak/ login FTL overlay → AGENTS.md +├── pre-registration-booking-service/ /appointment/** → AGENTS.md +├── registration-processor/ registration-processor-ref-parent → AGENTS.md +│ ├── registration-processor-external-stage/ → AGENTS.md +│ └── registration-processor-external-integration-service/ → AGENTS.md +├── helm/prereg-booking/ k8s; javaOpts → JDK_JAVA_OPTIONS → AGENTS.md +├── licenses/ third-party texts + NOTICE +├── .github/ CI + GPG keys → AGENTS.md +├── deploy.sh LICENSE NOTICE README.md ``` -## Architecture - -### Design Pattern - -Every module implements a **SPI interface** defined in `mosip/kernel` or `mosip/registration-processor-core`. The interface is resolved at runtime via Spring `spring.factories` (for kernel SPIs) or `@Autowired` injection (for Spring Boot services). To replace an implementation, swap the JAR — no core platform changes required. - -### Pre-Registration Booking Service - -A standalone **Spring Boot 3.x** REST service (`BookingApplication`). Key characteristics: - -- Entry point: `io.mosip.preregistration.booking.BookingApplication` -- All REST endpoints are in `BookingController` under `/appointment/**` -- Role-based access uses `@PreAuthorize("hasAnyRole(@authorizedRoles.get...())")` — roles are resolved from a Spring bean, not hardcoded strings -- Depends on upstream pre-registration core library (`io.mosip.preregistration:preregistration-core`) for DTOs and utilities -- Requires `kernel-auth-adapter.jar` on the classpath at runtime to inject MOSIP auth tokens on outbound REST calls -- Requires `kernel-ref-idobjectvalidator.jar` for ID schema validation -- Config files: `application-default.properties` and `pre-registration-default.properties` from `mosip/mosip-config`, served by a running Spring Cloud Config Server - -### Registration Processor External Stage + Integration Service - -These two modules work as a pair to enable **custom business logic hooks** inside the registration packet processing pipeline: - -1. **`registration-processor-external-stage`** — a Vert.x verticle (`ExternalStage extends MosipVerticleAPIManager`) that sits in the packet pipeline. It: - - Consumes from `EXTERNAL_STAGE_BUS_IN` Kafka topic - - Makes a synchronous POST to the `EISERVICE` API endpoint (the External Integration Service below) - - Forwards `true` (success) or `false` (failure) to update registration status - - Produces to `EXTERNAL_STAGE_BUS_OUT` - - Property prefix: `mosip.regproc.external.` +Angular UIs are other repos. No TestNG report archive. -2. **`registration-processor-external-integration-service`** — a Spring Boot REST service that receives the POST from the external stage at `/registration-processor/external-integration-service/v1.0`. The bundled implementation is a **stub** that always returns `true` if the request body is non-null. Implementers replace this service with real country-specific business logic. +## Build (cwd = module; aggregators = `kernel/`, `registration-processor/`) -The stage follows the standard MOSIP stage pattern: extend `MosipVerticleAPIManager`, implement `process(MessageDTO)`, override `getPropertyPrefix()`. - -### Kernel Reference Implementations - -| Module | SPI Implemented | Key Config | -|--------|----------------|------------| -| `kernel-ref-idobjectvalidator` | `IdObjectValidator` | Validates identity JSON against a JSON Schema; fetches masterdata values (document types, locations, languages) from the Masterdata Service; configurable cron-based cache refresh via `mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern` | -| `kernel-smsserviceprovider-msg91` | SMS SPI | Calls MSG91 REST API; loaded via `spring.factories` | -| `kernel-virusscanner-clamav` | `VirusScanner` | Connects to a running ClamAV daemon; configured via `mosip.kernel.virus-scanner.host` and `mosip.kernel.virus-scanner.port`; loaded via `spring.factories` | - -### Cache Providers - -Both `cache-provider-hazelcast` and `cache-provider-redis` implement MOSIP's `PacketCacheProvider` SPI. The Hazelcast provider includes a custom Spring Boot Actuator health indicator (`HazelcastHealthIndicator`), disabled via `packetmanager.hazelcast.disable.health.check=false`. - -## Runtime Configuration - -All runtime properties are externalized to a **Spring Cloud Config Server** (from `mosip/mosip-config`). Each service bootstraps with `spring.cloud.config.uri` pointing to that server. Key property files: - -- `application-default.properties` — platform-wide settings (DB, IAM/Keycloak URLs, service URLs) -- `pre-registration-default.properties` — pre-registration specific overrides -- `registration-processor-default.properties` — registration processor overrides - -The External Stage needs `mosip.regproc.external.message.expiry-time-limit` (seconds) and Vert.x cluster config (`vertx.cluster.configuration`). - -## ID Lifecycle Context - -This repository implements pluggable components for MOSIP's **ID Lifecycle Management** — the full pipeline from identity enrollment to UIN issuance: - -1. **Pre-Registration** — residents book appointments at registration centers; `pre-registration-booking-service` manages slot availability, booking, cancellation, and batch operations -2. **Registration Processor** — packets from Registration Client travel through a SEDA pipeline (Kafka-connected Vert.x stages) for validation, deduplication (ABIS), authentication, and UIN generation; the external stage and EIS allow country-specific hooks between standard stages -3. **ID Repository** — stores finalized identity records (not in this repo — upstream dependency) - -External systems integrated by these modules: ClamAV (virus scanning), MSG91 (SMS notifications), Hazelcast/Redis (packet caching), Keycloak (IAM), ABIS (biometric deduplication via queues). - -## CI/CD - -GitHub Actions (`.github/workflows/push-trigger.yml`) triggers on push to `develop`, `master`, `release*`, and `MOSIP*` branches via the reusable `mosip/kattu@master-java21` workflow: - -1. Maven build (Java 21) -2. Docker image build and push to Docker Hub (for `pre-registration-booking-service`, `registration-processor-external-stage`, `registration-processor-external-integration-service`) -3. Publish to Maven Central (OSSRH) — skipped on `master` and PRs -4. SonarCloud analysis (skipped on PRs) — project key per module (e.g., `mosip_kernel-ref-idobjectvalidator`, `mosip_pre-registration-booking-service`) - -Kubernetes deployment uses Helm chart in `helm/prereg-booking/`. - -## Testing - -- Tests use JUnit 4 (vintage engine), Mockito, and Vert.x unit test utilities -- `--add-opens` JVM flags are required and are already configured in each module's `pom.xml` Surefire configuration -- The `kernel-ref-idobjectvalidator` tests use `--enable-preview`; the property name for the JaCoCo arg line is `jacocoArgLine` (not `argLine`) in that module +```bash +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn test -Dtest=ClassName[#method] +mvn clean verify +``` -## API Documentation +## Facts -- Pre-Registration Booking Service: https://mosip.github.io/documentation/1.2.0/pre-registration-booking-service.html -- Registration Processor External Integration Service: https://mosip.github.io/documentation/1.2.0/registration-processor-external-integration-service.html -- Product docs: https://docs.mosip.io/1.2.0/id-lifecycle-management +- Swap impl = swap JAR. Kernel SPIs: `META-INF/spring.factories`. Services: Boot 4.1.1. No `pre-processor`. Logging = `kernel-core`, not `kernel-logger-logback`. +- Jackson 2 = `spring-boot-jackson2`. Spring Cloud **2025.1.3**. `git-commit-id` → `service-git.properties`. +- Config: `mosip/mosip-config` (`application-default`, `pre-registration-default`, `registration-processor-default`). +- Tests: JUnit 4 vintage + Mockito; `--add-opens` in poms; idobjectvalidator `--enable-preview`. +- Coverage: JaCoCo LINE **0.90** (`jacoco-check` = `sonar.coverage.exclusions`). Report: `target/site/jacoco/index.html`. +- Docker: no glowroot, no `iam_adapter_url` wget. Adapters in JAR. JVM flags from Helm `javaOpts`. +- CI: `.github/workflows/push-trigger.yml` → `mosip/kattu@master-java21`. diff --git a/LICENSE b/LICENSE index ba08bd62e00..ef3e7282283 100644 --- a/LICENSE +++ b/LICENSE @@ -1,21 +1,374 @@ -MIT License - -Copyright (c) 2022 Modular Open Source Identity Platform - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. \ No newline at end of file + +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/NOTICE b/NOTICE new file mode 100644 index 00000000000..1100a24294c --- /dev/null +++ b/NOTICE @@ -0,0 +1,126 @@ +NOTICES + +Copyright (c) MOSIP. +All rights reserved. + +This project is MPL 2.0 (see LICENSE). Third-party versions match each module +pom.xml and Spring Boot 4.1.1 / Java 21 (no kernel-bom; kernel-core 1.4.1-SNAPSHOT). +Full texts, MOSIP comments, and dual-license elections: licenses/. + +MOSIP open-source license matrix (Compatible with MPL 2.0 / Use with MOSIP): + + License Compatible? Use with MOSIP? MOSIP comments + ------------------------------- ------------ ---------------- ---------------- + BSD (2-Clause, 3-Clause) Yes Yes Combine freely + MIT Yes Yes Combine freely + Apache-2.0 Yes Yes Permissive; meet attribution + MPL-2.0 Yes Yes Combine freely + EPL No No Differing requirements vs MPL + LGPLv3 Yes No Terms may apply to combined work + GPLv2 No No No explicit MPL 2.0 compatibility + GPLv3 Yes No Combined work must be GPLv3 + AGPLv3 Yes No Combined work must be AGPLv3 + Creative Commons (general) No No Not designed for software + ISC Yes Yes Keep ISC text + attribution + Python-2.0 Yes Yes Comply with both licenses + AFL-2.0 No No Clauses conflict with MPL 2.0 + AFL-2.1 Yes Yes Keep AFL notice + attribution + ODC-By-1.0 No No Database license; not software + CDDL-1.0 Yes Yes Each file keeps original license + Unicode-DFS-2016 Yes Yes Keep Unicode license + notice + BlueOak-1.0.0 Yes Yes Keep license text or link + OFL-1.1 Yes Yes Fonts; include full OFL text + CC-BY-4.0 — — To be reviewed (not used here) + Zlib Yes Yes Keep zlib license text + 0BSD Yes Yes Permissive; broad reuse + +CDDL-1.1 treated as CDDL-1.0 successor. Unicode-3.0 treated as Unicode-DFS-2016 +successor. Dual-licensed jars: MOSIP elects an allowed option (never EPL, GPL, +AGPL, LGPLv3, or Creative Commons as the product license). + +Compatibility verdict (this repo): +- Project code and MOSIP SNAPSHOT libs: MPL-2.0 — Use = Yes. +- Runtime third-party: MIT / Apache-2.0 / BSD / CDDL (elected) / MPL (H2 elected) + — Use = Yes after dual-license election. No GPLv2/v3, AGPL, AFL-2.0, ODC-By, + or Creative Commons software deps. +- Use = No still on classpath (Boot/test/build; not elected as product license): + JUnit (EPL, test), Logback (EPL-2.0 OR LGPL-2.1, Boot logger), AspectJ (EPL, + Boot AOP), JaCoCo plugin (EPL, build only). + +=========================== +MIT License (licenses/MIT.txt) +=========================== + +- org.projectlombok:lombok 1.18.46 +- org.slf4j:slf4j-api 2.0.18 +- org.mockito:mockito-core 5.23.0 (test) +- redis.clients:jedis 7.4.1 (cache-provider-redis; Boot 4.1.1) +- xyz.capybara:clamav-client 2.1.2 + +=========================== +Apache-2.0 (licenses/Apache-2.0.txt) +=========================== + +- Spring Boot 4.1.1 / Spring Framework 7.0.9 / Spring Cloud 2025.1.3 +- com.fasterxml.jackson.* 2.21.5 (Jackson 2 via spring-boot-jackson2) +- org.hibernate.validator:hibernate-validator 9.1.3.Final +- io.micrometer:micrometer-core 1.17.1 / micrometer-registry-prometheus +- com.hazelcast:hazelcast 5.7.0 +- io.jsonwebtoken:jjwt-api / jjwt-impl / jjwt-jackson 0.13.0 +- org.apache.commons:commons-collections4 4.6.0 +- net.logstash.logback:logstash-logback-encoder 9.0 +- com.jayway.jsonpath:json-path 2.10.0 (kernel) / 3.0.0 (booking) +- net.minidev:json-smart 2.6.0 +- org.javassist:javassist 3.33.0-GA (MPL-1.1 OR LGPL-2.1 OR Apache-2.0; + MOSIP elects Apache-2.0 — not LGPL) +- org.springdoc:springdoc-openapi-* 3.1.1 +- net.bytebuddy:byte-buddy 1.18.11 +- javax.inject:javax.inject 1 +- org.jetbrains.kotlin:kotlin-stdlib (transitive via clamav-client) +- io.vertx 4.5.34 (EPL-2.0 OR Apache-2.0; MOSIP elects Apache-2.0 — not EPL) +- Maven build plugins (Apache-2.0): compiler, surefire, jar, source, javadoc, + gpg, deploy, assembly, git-commit-id, central-publishing + +=========================== +EDL 1.0 / BSD (licenses/BSD-2-Clause.txt) +=========================== + +- javax.xml.bind:jaxb-api 2.3.1 +- org.glassfish.jaxb:jaxb-runtime 2.3.9 + +=========================== +Mozilla Public License 2.0 (LICENSE) +=========================== + +- This repository (mosip-ref-impl modules) +- io.mosip.kernel:kernel-core / kernel-auth-adapter 1.4.1-SNAPSHOT +- io.mosip.preregistration:pre-registration-core 1.4.1-SNAPSHOT +- io.mosip.registrationprocessor:* 1.4.1-SNAPSHOT +- com.h2database:h2 2.4.240 (EPL-1.0 OR MPL-2.0; MOSIP elects MPL-2.0 — not EPL) + +=========================== +CDDL-1.1 (licenses/COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt) +=========================== + +CDDL files keep CDDL; this project's files stay MPL-2.0 (MOSIP CDDL comment). + +- javax.activation (transitive via JAXB; CDDL-1.1 OR GPL-2.0-with-CPE; + MOSIP elects CDDL-1.1 — not GPL) +- javax.servlet:javax.servlet-api (CDDL OR GPL-2.0-with-CPE; MOSIP elects CDDL) + +=========================== +Public Domain / 0BSD-like (licenses/0BSD.txt) +=========================== + +- org.json:json (Public Domain; treated like 0BSD — Use = Yes) + +=========================== +MOSIP matrix: Use = No (classpath exception — not a product election) +=========================== + +- org.junit.jupiter / junit-vintage / junit:junit — EPL, test only +- ch.qos.logback — EPL-2.0 OR LGPL-2.1 (both Use = No); Boot default logger +- org.aspectj:aspectjweaver — EPL-2.0; Boot AOP transitive +- org.jacoco:* — EPL-2.0; Maven plugin / test agent only, not shipped in product + +See licenses/NOTICE for the full MOSIP comments and elections. diff --git a/README.md b/README.md index 7894219997a..f9ddc5aa9a0 100644 --- a/README.md +++ b/README.md @@ -2,183 +2,271 @@ [![Maven Package upon a push](https://github.com/mosip/mosip-ref-impl/actions/workflows/push-trigger.yml/badge.svg?branch=release-1.3.x)](https://github.com/mosip/mosip-ref-impl/actions/workflows/push-trigger.yml) +Country-pluggable **reference implementations** (not MOSIP core). Each Maven module is independent, publishes to OSSRH, and can be swapped by dropping in another JAR that implements the same SPI or REST contract. + +There is **no repo-root POM** and **no `kernel-bom`**. Standalone modules parent `spring-boot-starter-parent` **4.1.1**. Kernel children inherit through `kernel-ref-parent`; registration-processor children inherit through `registration-processor-ref-parent`. MOSIP library versions (`kernel-core`, `kernel-auth-adapter`, `pre-registration-core`, registration-processor jars) are pinned in each module `pom.xml`, not here. + +## Contents + +- [Overview](#overview) +- [Repository layout](#repository-layout) +- [Prerequisites](#prerequisites) +- [Shared facts](#shared-facts) +- [Build](#build) +- [Tests and coverage](#tests-and-coverage) +- [Configuration](#configuration) +- [Swagger UI (Authorize)](#swagger-ui-authorize) +- [Docker](#docker) +- [Kubernetes / Helm](#kubernetes--helm) +- [Documentation](#documentation) +- [Notices and licensing](#notices-and-licensing) +- [Contribution](#contribution--community) + ## Overview -The MOSIP Reference Implementation (Ref Impl) repository contains country-specific customizations and implementations that extend the core MOSIP platform. It serves as a reference for how different countries can adapt and implement MOSIP according to their unique requirements and regulations. -## Services +This repository is the reference for how a country can adapt MOSIP: -The mosip-ref-impl contains the following services: +| Area | What you replace | +|---|---| +| Packet cache | Hazelcast or Redis `PacketCacheProvider` JAR | +| Kernel SPIs | ID-object validator, MSG91 SMS, ClamAV virus scanner (`META-INF/spring.factories`) | +| Pre-registration | Booking REST service (`/appointment/**`) | +| Registration processor | External stage (Vert.x) + External Integration Service stub REST | +| Identity | Keycloak login theme (FTL) | +| Deploy | Helm chart for booking | -1. **[cache-provider-hazelcast](cache-provider-hazelcast)** : Hazelcast based cache provider Reference implementation -2. **[cache-provider-redis](cache-provider-redis)** : Redis based cache provider Reference implementation -3. **[kernel](kernel)** : Reference implementation for core libraries - - **[kernel-ref-idobjectvalidator](kernel/kernel-ref-idobjectvalidator)** : Reference implementation for ID Object Validator - - **[kernel-smsserviceprovider-msg91](kernel/kernel-smsserviceprovider-msg91)** : Reference implementation for msg91 SMS Service Provider - - **[kernel-virusscanner-clamav](kernel/kernel-virusscanner-clamav)** : Reference implementation for clamv Virus Scanner -4. **[keycloak](keycloak)** : Reference implementation for keycloak -5. **[pre-registration-booking-service](pre-registration-booking-service)** : Reference implementation for pre-registration booking service. -6. **[registration-processor](registration-processor)** : Reference implementation for registration processor external integration. - - **[registration-processor-external-integration-service](registration-processor/registration-processor-external-integration-service)** : Reference implementation for external integration service. - - **[registration-processor-external-stage](registration-processor/registration-processor-external-stage)** : Reference implementation for external stage. +Angular UIs (`pre-registration-ui`, `admin-ui`) live in their own MOSIP repositories, not this tree. Coverage is produced at build time (`mvn clean verify` → `target/site/jacoco/index.html`); TestNG report archives are not checked in. -## Local Setup + -The project can be set up in two ways: +## Repository layout -1. [Local Setup (for Development or Contribution)](#local-setup-for-development-or-contribution) -2. [Local Setup with Docker (Easy Setup for Demos)](#local-setup-with-docker-easy-setup-for-demos) +```text +mosip-ref-impl/ +├── cache-provider-hazelcast/ PacketCacheProvider + Actuator health +├── cache-provider-redis/ PacketCacheProvider (Jedis) +├── kernel/ kernel-ref-parent (3 SPI modules) +│ ├── kernel-ref-idobjectvalidator/ IdObjectValidator +│ ├── kernel-smsserviceprovider-msg91/ SMS SPI (MSG91) +│ └── kernel-virusscanner-clamav/ VirusScanner + ClamAV +├── keycloak/theme/base/login/ login FTL theme +├── pre-registration-booking-service/ Spring Boot /appointment/** +├── registration-processor/ registration-processor-ref-parent +│ ├── registration-processor-external-stage/ +│ └── registration-processor-external-integration-service/ +├── helm/prereg-booking/ Kubernetes chart +├── licenses/ third-party texts + NOTICE +├── .github/workflows/ CI (kattu Java 21) +├── deploy.sh LICENSE NOTICE README.md +``` -### Prerequisites +### Modules -Before you begin, ensure you have the following installed: +| Module | Parent | Role | Typical port / notes | +|---|---|---|---| +| [cache-provider-hazelcast](cache-provider-hazelcast) | Boot 4.1.1 | Hazelcast packet cache + `HazelcastHealthIndicator` | library JAR (provided starter/actuator) | +| [cache-provider-redis](cache-provider-redis) | Boot 4.1.1 | Redis/Jedis packet cache (`RedisConfig`) | library JAR | +| [kernel-ref-idobjectvalidator](kernel/kernel-ref-idobjectvalidator) | `kernel-ref-parent` | Identity JSON vs schema + masterdata | library; `--enable-preview` on tests | +| [kernel-smsserviceprovider-msg91](kernel/kernel-smsserviceprovider-msg91) | `kernel-ref-parent` | MSG91 `SMSServiceProvider` | library; `spring.factories` | +| [kernel-virusscanner-clamav](kernel/kernel-virusscanner-clamav) | `kernel-ref-parent` | ClamAV `VirusScanner` | library; host/port properties | +| [pre-registration-booking-service](pre-registration-booking-service) | Boot 4.1.1 | Book / cancel / query appointments | **9095**, context `/preregistration/v1` | +| [registration-processor-external-integration-service](registration-processor/registration-processor-external-integration-service) | `registration-processor-ref-parent` | Country EIS stub REST | **8201**, path `/registrationprocessor/v1/eis` | +| [registration-processor-external-stage](registration-processor/registration-processor-external-stage) | `registration-processor-ref-parent` | Vert.x stage → POST EIS | eventbus **5736**, HTTP **8095** | +| [keycloak](keycloak) | — | Login theme | FTL under `theme/base/login/` | +| [helm/prereg-booking](helm/prereg-booking) | — | Booking Helm chart | namespace `prereg` | -- **JDK**: 21.0.3 -- **Maven**: 3.9.6 -- **Docker**: Latest stable version -- **PostgreSQL**: 16.0 -- **Keycloak**: [Check here](https://github.com/mosip/keycloak/tree/master) +Each module has its own `README.md` with artifact id, build, config, and (where applicable) Swagger. -### Runtime Dependencies +## Prerequisites -Add the below dependencies to the classpath, or include it as a Maven dependency in your `pom.xml`. -- `kernel-auth-adapter.jar` -- `kernel-ref-idobjectvalidator.jar` +| Tool | Version | +|---|---| +| JDK | **21.0.3** | +| Maven | **3.9.6** | +| Spring Boot parent | **4.1.1** | +| Spring Cloud | **2025.1.3** (Oakwood; pinned in module POMs) | +| Docker | latest stable (optional) | +| PostgreSQL | **16.0** (booking / MOSIP stack) | +| Keycloak | [mosip/keycloak](https://github.com/mosip/keycloak/tree/master) | +| Spring Cloud Config | required for services (see [Configuration](#configuration)) | -### Configuration +### Runtime JARs for services -- This module uses the following configuration files that are accessible in this [mosip-config repository](https://github.com/mosip/mosip-config/tree/master). - Please refer to the required released tagged version for configuration: - - [Configuration-registration](https://github.com/mosip/mosip-config/blob/master/registration-default.properties), - [Configuration-pre-registration](https://github.com/mosip/mosip-config/blob/master/pre-registration-default.properties) and - [Configuration-Application](https://github.com/mosip/mosip-config/blob/master/application-default.properties) are defined here. You need to run the config-server along with the files mentioned above. +Add to the classpath or as Maven dependencies (versions from the consuming module `pom.xml`): -#### Required Configuration Properties +- `kernel-auth-adapter` — outbound auth / `@PreAuthorize` on booking +- `kernel-ref-idobjectvalidator` — identity object validation on booking -The following properties must be configured with your environment-specific values before deployment: +Unpublished MOSIP SNAPSHOTs (`pre-registration-core`, `registration-processor-core`, status-service-impl, rest-client) must be installed locally if they are not on Central snapshots. -**Database Configuration:** -- `mosip.registration.processor.database.hostname` - Database hostname (default: postgres-postgresql.postgres) -- `mosip.registration.processor.database.port` - Database port (default: 5432) -- `db.dbuser.password` - Database user password (passed as environment variable) +## Shared facts -**IAM/Keycloak Configuration:** -- `keycloak.internal.url` - Internal Keycloak URL (passed as environment variable) -- `keycloak.external.url` - External Keycloak URL (passed as environment variable) -- `mosip.regproc.client.secret` - Registration processor client secret (passed as environment variable) +- **Swap impl = swap JAR.** Kernel SPIs load via `META-INF/spring.factories`. Services are Spring Boot 4.1.1 apps. +- **No `pre-processor` parent.** Registration-processor uses `registration-processor-ref-parent` → Boot 4.1.1. +- **Jackson 2** via `spring-boot-jackson2` (Boot 4 defaults to Jackson 3; MOSIP APIs still use Jackson 2). +- **Logging** is in `kernel-core` (commons). Do not add `kernel-logger-logback`. +- **`git-commit-id-plugin`** writes `service-git.properties` (not `git.properties`) so it does not collide with `kernel-core`. +- Tests: JUnit 4 vintage + JUnit 5 + Mockito; `--add-opens` is already in POMs. `kernel-ref-idobjectvalidator` uses `--enable-preview`. +- CI: `.github/workflows/push-trigger.yml` uses `mosip/kattu@master-java21` (build, Docker, OSSRH, Sonar). -**Service URLs:** -- `mosip.kernel.authmanager.url` - Auth manager service URL -- `mosip.kernel.keymanager.url` - Key manager service URL -- `mosip.kernel.masterdata.url` - Masterdata service URL -- `mosip.kernel.notification.url` - Notification service URL -- `mosip.idrepo.identity.url` - ID repository identity service URL -- `mosip.api.internal.url` - Internal API base URL +## Build -## Installation +Always run Maven **in the module directory** (or with `-f` / `-pl` as below). Skip Javadoc and GPG for local builds: + +```text +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` -### Local Setup (for Development or Contribution) +| What | Command (from repo root) | +|---|---| +| Kernel (all 3 SPIs) | `mvn -f kernel/pom.xml clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | +| One kernel module | `mvn -f kernel/pom.xml -pl kernel-ref-idobjectvalidator clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | +| Registration-processor (both) | `mvn -f registration-processor/pom.xml clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | +| EIS only | `mvn -f registration-processor/pom.xml -pl registration-processor-external-integration-service clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | +| Booking | `cd pre-registration-booking-service && mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | +| Hazelcast cache | `cd cache-provider-hazelcast && mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | +| Redis cache | `cd cache-provider-redis && mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true` | -1. Make sure the config server is running. For detailed instructions on setting up and running the config server, refer to the [MOSIP Config Server Setup Guide](https://docs.mosip.io/1.2.0/modules/registration-processor/registration-processor-developers-guide#environment-setup). +Run a single test class: -**Note**: Refer to the MOSIP Config Server Setup Guide for setup, and ensure the properties mentioned above in the configuration section are taken care of. Replace the properties with your own configurations (e.g., DB credentials, IAM credentials, URL). +```text +mvn test -Dtest=ClassName[#method] +``` -2. Clone the repository: +Start a Boot service from the IDE (`BookingApplication`, `ExternalIntegrationServiceApplication`) or: ```text -git clone -cd +java -jar target/-1.4.1-SNAPSHOT.jar ``` -3. Build the project: +## Tests and coverage + +`mvn clean verify` runs tests, writes JaCoCo HTML at `target/site/jacoco/index.html`, and enforces **LINE covered ratio 0.90** (`jacoco-check`), using the same package excludes as `sonar.coverage.exclusions`. ```text -mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn clean verify -Psonar ``` -4. Start the application: - - Click the Run button in your IDE, or - - Run via command: `java -jar target/specific-service:<$version>.jar` +`-Psonar` needs `SONAR_TOKEN` and uploads to SonarCloud. Local JaCoCo XML is the coverage input (`sonar.coverage.jacoco.xmlReportPaths`). -5. Verify Swagger is accessible. +## Configuration -### Local Setup with Docker (Easy Setup for Demos) +Services pull properties from Spring Cloud Config ([mosip/mosip-config](https://github.com/mosip/mosip-config/tree/master)). Use the tagged release that matches your platform: -#### Option 1: Pull from Docker Hub +- [application-default.properties](https://github.com/mosip/mosip-config/blob/master/application-default.properties) +- [pre-registration-default.properties](https://github.com/mosip/mosip-config/blob/master/pre-registration-default.properties) +- [registration-processor-default.properties](https://github.com/mosip/mosip-config/blob/master/registration-processor-default.properties) (registration pipeline; some docs also refer to `registration-default.properties`) -Recommended for users who want a quick, ready-to-use setup — testers, students, and external users. +Packaged defaults: each service `src/main/resources/bootstrap.properties`. -Pull the latest pre-built images from Docker Hub using the following commands: +### Environment-specific properties (typical) -```text -docker pull mosipid/pre-registration-booking-service:1.3.0 -``` +**Database** -#### Option 2: Build Docker Images Locally +- `mosip.registration.processor.database.hostname` (default: `postgres-postgresql.postgres`) +- `mosip.registration.processor.database.port` (default: `5432`) +- `db.dbuser.password` (environment) -Recommended for contributors or developers who want to modify or build the services from source. +**IAM / Keycloak** -1. Clone and build the project: +- `keycloak.internal.url`, `keycloak.external.url` +- `mosip.regproc.client.secret` -```text -git clone -cd -mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true -``` +**Service URLs** -2. Navigate to each service directory and build the Docker image: +- `mosip.kernel.authmanager.url` +- `mosip.kernel.keymanager.url` +- `mosip.kernel.masterdata.url` +- `mosip.kernel.notification.url` +- `mosip.idrepo.identity.url` +- `mosip.api.internal.url` -```text -cd / -docker build -t . -``` +Config-server setup: [MOSIP Config Server Setup Guide](https://docs.mosip.io/1.2.0/modules/registration-processor/registration-processor-developers-guide#environment-setup). + +## Swagger UI (Authorize) + +Booking and EIS expose Springdoc OpenAPI 3. Click **Authorize**, scheme **Authorization** (header apiKey), paste the token from authmanager. Try-it-out then sends that header on each request. -#### Running the Services +| Service | UI | +|---|---| +| pre-registration-booking-service | `http://localhost:9095/preregistration/v1/appointment/booking-service/swagger-ui.html` | +| registration-processor-external-integration-service | `http://localhost:8201/registrationprocessor/v1/eis/swagger-ui.html` | -Start each service using Docker: +## Docker + +### Pull (demo) ```text -docker run -d -p : --name +docker pull mosipid/pre-registration-booking-service:1.3.0 ``` -#### Verify Installation - -Check that all containers are running: +### Build locally ```text +cd +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +docker build -t . +docker run -d -p : --name docker ps ``` -Access the services at `http://localhost:` using the port mappings listed above. +Booking `Dockerfile` is in `pre-registration-booking-service/`. EIS and external-stage have Dockerfiles under `registration-processor//`. -## Deployment +## Kubernetes / Helm -### Kubernetes +Sandbox: [Sandbox Deployment Guide](https://docs.mosip.io/1.2.0/deploymentnew/v3-installation). -To deploy mosip ref impl services on a Kubernetes cluster, refer to the [Sandbox Deployment Guide](https://docs.mosip.io/1.2.0/deploymentnew/v3-installation). +Booking chart: + +```text +kubectl create namespace prereg +helm repo add mosip https://mosip.github.io +helm -n prereg install my-release mosip/prereg-booking +``` + +Chart sources: [helm/prereg-booking](helm/prereg-booking). ## Documentation -### API Documentation +**APIs** + +- [Pre-Registration Booking Service](https://mosip.github.io/documentation/1.2.0/pre-registration-booking-service.html) +- [Registration Processor External Integration Service](https://mosip.github.io/documentation/1.2.0/registration-processor-external-integration-service.html) -API endpoints, base URL, and mock server details are available via Stoplight and Swagger documentation for below services: -- **[Registration Processor External Integration Service API Documentation](https://mosip.github.io/documentation/1.2.0/registration-processor-external-integration-service.html)**. -- **[Pre-Registration Booking Service API Documentation](https://mosip.github.io/documentation/1.2.0/pre-registration-booking-service.html)**. +**Product** -### Product Documentation -For more detailed documents check below links: - [Registration Processor](https://docs.mosip.io/1.2.0/id-lifecycle-management/identity-issuance/registration-processor/overview) - [Pre-Registration](https://docs.mosip.io/1.2.0/id-lifecycle-management/identity-issuance/pre-registration) -- [keycloak](https://docs.mosip.io/1.2.0/id-lifecycle-management/supporting-components/keycloak) -- [Common components](https://docs.mosip.io/1.2.0/setup/implementations/reference-implementations#common-components) +- [Keycloak](https://docs.mosip.io/1.2.0/id-lifecycle-management/supporting-components/keycloak) +- [Reference implementations](https://docs.mosip.io/1.2.0/setup/implementations/reference-implementations#common-components) + +Booking SQL: [pre-registration db_scripts](https://github.com/mosip/pre-registration/tree/master/db_scripts). + +External stage design: + +- [External system integration](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_external_system_integration.md) +- [HTTP stage](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_http_integration.md) +- [Adding an external stage](https://github.com/mosip/registration/blob/master/design/registration-processor/External_System_Integration_Guide.md) + +## Notices and licensing -## Contribution & Community +This project is [Mozilla Public License 2.0](LICENSE). -• To learn how you can contribute code to this application, [click here](https://docs.mosip.io/1.2.0/community/code-contributions). +Third-party attributions and the MOSIP matrix (**Compatible with MPL 2.0?** / **Use with MOSIP?**) are in: -• If you have questions or encounter issues, visit the [MOSIP Community](https://community.mosip.io/) for support. +- [NOTICE](NOTICE) — elected licenses and classpath exceptions +- [licenses/NOTICE](licenses/NOTICE) — full comments and dual-license elections +- [licenses/](licenses/) — Apache-2.0, MIT, BSD, CDDL, EPL, MPL, and matrix reference texts -• For any GitHub issues: [Report here](https://github.com/mosip/mosip-ref-impl/issues) +Product runtime elects Use = Yes options (Apache-2.0, MIT, BSD, MPL-2.0, CDDL). Dual-licensed jars never elect EPL, GPL, AGPL, LGPLv3, or Creative Commons as the product license. JUnit / Logback / AspectJ / JaCoCo remain EPL or EPL-or-LGPL on the test, Boot-logger, or build path; see NOTICE. -## License +## Contribution & community -This project is licensed under the [Mozilla Public License 2.0](LICENSE). +- [Code contributions](https://docs.mosip.io/1.2.0/community/code-contributions) +- [MOSIP Community](https://community.mosip.io/) +- [GitHub issues](https://github.com/mosip/mosip-ref-impl/issues) diff --git a/cache-provider-hazelcast/AGENTS.md b/cache-provider-hazelcast/AGENTS.md new file mode 100644 index 00000000000..e9d1fae0081 --- /dev/null +++ b/cache-provider-hazelcast/AGENTS.md @@ -0,0 +1,12 @@ +# cache-provider-hazelcast + +`PacketCacheProvider` + Boot 4 health. Standalone pom. Pins in `pom.xml`. + +``` +cache-provider-hazelcast/ +├── pom.xml README.md AGENTS.md +├── src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/ +│ └── HazelcastHealthIndicator.java # packetmanager.hazelcast.disable.health.check +└── src/test/java/.../config/ + └── HazelcastHealthIndicatorTest.java +``` diff --git a/cache-provider-hazelcast/README.md b/cache-provider-hazelcast/README.md new file mode 100644 index 00000000000..b042dc691e0 --- /dev/null +++ b/cache-provider-hazelcast/README.md @@ -0,0 +1,32 @@ +# cache-provider-hazelcast + +MOSIP `PacketCacheProvider` SPI backed by Hazelcast, plus an Actuator health indicator. + +- **Artifact**: `io.mosip.cacheprovider:cache-provider-hazelcast:1.4.1-SNAPSHOT` +- **Parent**: `spring-boot-starter-parent` **4.1.1** +- **Hazelcast**: 5.7.0 +- **Health**: `HazelcastHealthIndicator` (`org.springframework.boot.health.contributor` — Boot 4) +- **Git info**: `service-git.properties` + +## Build + +```text +cd cache-provider-hazelcast +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +Drop the JAR on the packet-manager classpath (scope of `spring-boot-starter` / actuator is `provided`). + +```text +mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +JaCoCo LINE covered ratio **0.90** (`target/site/jacoco/index.html`). + +## Health + +Property `packetmanager.hazelcast.disable.health.check` (`matchIfMissing = true`) controls whether the indicator is registered. + +## License + +[Mozilla Public License 2.0](../LICENSE) — [NOTICE](../NOTICE) diff --git a/cache-provider-hazelcast/pom.xml b/cache-provider-hazelcast/pom.xml index cb498a3388c..ee13b97cbd2 100644 --- a/cache-provider-hazelcast/pom.xml +++ b/cache-provider-hazelcast/pom.xml @@ -1,263 +1,312 @@ - 4.0.0 + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + 4.0.0 - io.mosip.cacheprovider - cache-provider-hazelcast - 1.4.0-SNAPSHOT - cache-provider-hazelcast - Cache provider hazelcast of MOSIP - https://github.com/mosip/mosip-ref-impl - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - + + org.springframework.boot + spring-boot-starter-parent + 4.1.1 + + - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - Mosip - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip/mosip-ref-impl - - + io.mosip.cacheprovider + cache-provider-hazelcast + 1.4.1-SNAPSHOT + cache-provider-hazelcast + + MOSIP PacketCacheProvider SPI backed by Hazelcast (Spring Boot 4.1.1, Java 21). + No kernel-bom. Module version and third-party pins live in this pom — not in README.md. + + https://github.com/mosip/mosip-ref-impl - - - UTF-8 - 21 - 21 - 3.8.0 - 2.22.0 - 3.0.2 - 3.1.0 - 0.8.1 - 3.7.0.1746 - 3.2.0 - 2.3 - 3.3.0 - 2.2.1 - 1.5 - 3.0.1 - 3.2.0 - 2.8.1 - 0.11.0 - 1.3.1-rc.1 - 3.12.12 - + + 21 + + false + 3.16.0 + 3.6.0 + 0.8.15 + 0.90 + ${project.build.directory}/site/jacoco/jacoco.xml + 5.8.0.7211 + 3.12.0 + 3.4.0 + 3.2.8 + 3.2.0 + 4.9.10 + 0.11.0 + 3.8.0 + + 5.7.0 + - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - - - - - io.mosip.kernel - kernel-bom - ${kerne.bom.version} - pom - import - - - + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + repo + + + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MOSIP + mosip.emailnotifier@gmail.com + io.mosip + https://github.com/mosip + + - - - org.springframework.boot - spring-boot-starter - provided - - - org.springframework.boot - spring-boot-starter-actuator - provided - - - com.hazelcast - hazelcast-all - ${hazelcast.version} - - - - - - - org.apache.maven.plugins - maven-assembly-plugin - ${maven-assembly-plugin.version} - - - jar-with-dependencies - - false - - - - make-assembly - package - - single - - - - - - org.apache.maven.plugins - maven-source-plugin - ${maven-source-plugin.version} - - - attach-sources - - jar-no-fork - - - - - - org.apache.maven.plugins - maven-gpg-plugin - ${maven-gpg-plugin.version} - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - ${git-commit-id-plugin.version} - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - - - org.apache.maven.plugins - maven-javadoc-plugin - ${maven-javadoc-plugin.version} - - - attach-javadocs - - jar - - - - - none - - - - maven-deploy-plugin - ${maven-deploy-plugin.version} - - - default-deploy - deploy - - deploy - - - - - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - - - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - ${skipTests} - false - - ${argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --illegal-access=permit - - - - - - - - sonar - - . - src/main/java/**,src/main/resources/** - ${sonar.coverage.exclusions} - https://sonarcloud.io - - - false - - - - - org.sonarsource.scanner.maven - sonar-maven-plugin - ${maven.sonar.plugin.version} - - - verify - - sonar - - - - - - - - + + + + org.springframework.boot + spring-boot-starter + provided + + + + org.springframework.boot + spring-boot-starter-actuator + provided + + + + com.hazelcast + hazelcast + ${hazelcast.version} + + + org.springframework.boot + spring-boot-starter-test + test + + + + + + ossrh + https://central.sonatype.com/repository/maven-snapshots/ + + + ossrh + https://central.sonatype.com/api/v1/publisher + + + + + + + org.apache.maven.plugins + maven-assembly-plugin + ${maven.assembly.plugin.version} + + + jar-with-dependencies + + false + + + + make-assembly + package + + single + + + + + + org.apache.maven.plugins + maven-compiler-plugin + ${maven.compiler.plugin.version} + + ${java.version} + true + + + + org.apache.maven.plugins + maven-surefire-plugin + ${maven.surefire.plugin.version} + + ${skipTests} + @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED + + + + org.jacoco + jacoco-maven-plugin + ${maven.jacoco.version} + + + + prepare-agent + + + + report + prepare-package + + report + + + + jacoco-check + + check + + + + + BUNDLE + + + LINE + COVEREDRATIO + ${jacoco.minimum.coverage} + + + + + + + + + + org.apache.maven.plugins + maven-source-plugin + ${maven.source.plugin.version} + + + attach-sources + + jar-no-fork + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + ${maven.javadoc.version} + + + attach-javadocs + + jar + + + + + none + false + + + + org.apache.maven.plugins + maven-gpg-plugin + ${maven.gpg.plugin.version} + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + pl.project13.maven + git-commit-id-plugin + ${git.commit.id.plugin.version} + + + get-the-git-infos + + revision + + validate + + + + + true + ${project.build.outputDirectory}/service-git.properties + + ^git.build.(time|version)$ + ^git.commit.id.(abbrev|full)$ + + full + ${project.basedir}/.git + + + + org.apache.maven.plugins + maven-deploy-plugin + ${maven.deploy.plugin.version} + + + org.sonatype.central + central-publishing-maven-plugin + ${central.publishing.maven.plugin.version} + true + + ossrh + false + + + + + + + sonar + + . + src/main/java/**,src/main/resources/** + https://sonarcloud.io + + + false + + + + + org.sonarsource.scanner.maven + sonar-maven-plugin + ${maven.sonar.plugin.version} + + + verify + + sonar + + + + + + + + diff --git a/cache-provider-hazelcast/src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicator.java b/cache-provider-hazelcast/src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicator.java index 86e81142eba..e5b9ce00462 100644 --- a/cache-provider-hazelcast/src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicator.java +++ b/cache-provider-hazelcast/src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicator.java @@ -1,44 +1,72 @@ package io.mosip.commons.packet.cache.provider.hazelcast.config; -import com.hazelcast.core.HazelcastInstance; -import org.springframework.boot.actuate.health.AbstractHealthIndicator; -import org.springframework.boot.actuate.health.Health; +import java.lang.reflect.Method; +import java.util.UUID; + import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; +import org.springframework.boot.health.contributor.AbstractHealthIndicator; +import org.springframework.boot.health.contributor.Health; import org.springframework.stereotype.Component; import org.springframework.util.ReflectionUtils; -import java.lang.reflect.Method; +import com.hazelcast.core.HazelcastInstance; +/** + * Actuator health check for the Hazelcast instance used by packet cache. + *

+ * Registered when {@code packetmanager.hazelcast.disable.health.check} is unset or true + * ({@code matchIfMissing = true}). Reports cluster name, local UUID, and member count. + * Uses Boot 4 {@code org.springframework.boot.health.contributor} types. + *

+ */ @Component @ConditionalOnProperty(value = "packetmanager.hazelcast.disable.health.check", matchIfMissing = true) public class HazelcastHealthIndicator extends AbstractHealthIndicator { - private final HazelcastInstance hazelcast; - - public HazelcastHealthIndicator(HazelcastInstance hazelcast) { - super("Hazelcast health check failed"); - this.hazelcast = hazelcast; - } - - @Override - protected void doHealthCheck(Health.Builder builder) { - this.hazelcast.executeTransaction((context) -> { - builder.up().withDetail("name", this.hazelcast.getName()).withDetail("uuid", extractUuid()) - .withDetail("members", hazelcast.getCluster().getMembers().size()); - return null; - }); - } - - private String extractUuid() { - try { - return this.hazelcast.getLocalEndpoint().getUuid(); - } - catch (NoSuchMethodError ex) { - Method endpointAccessor = ReflectionUtils.findMethod(HazelcastInstance.class, "getLocalEndpoint"); - Object endpoint = ReflectionUtils.invokeMethod(endpointAccessor, this.hazelcast); - Method uuidAccessor = ReflectionUtils.findMethod(endpoint.getClass(), "getUuid"); - return (String) ReflectionUtils.invokeMethod(uuidAccessor, endpoint); - } - } - -} \ No newline at end of file + /** Shared Hazelcast node injected by the host packet-manager application. */ + private final HazelcastInstance hazelcast; + + /** + * @param hazelcast running Hazelcast instance + */ + public HazelcastHealthIndicator(HazelcastInstance hazelcast) { + super("Hazelcast health check failed"); + this.hazelcast = hazelcast; + } + + /** + * Marks the component UP and attaches cluster diagnostics. + * + * @param builder Spring Boot health builder + */ + @Override + protected void doHealthCheck(Health.Builder builder) { + String uuid = extractUuid(); + builder.up() + .withDetail("name", this.hazelcast.getName()) + .withDetail("uuid", uuid == null ? "" : uuid) + .withDetail("members", this.hazelcast.getCluster().getMembers().size()); + } + + /** + * Resolves the local member UUID, including a fallback for older Hazelcast APIs. + * + * @return UUID string, empty-safe {@code null} if the API is missing or nested lookup fails + */ + private String extractUuid() { + try { + UUID uuid = this.hazelcast.getLocalEndpoint().getUuid(); + return uuid == null ? null : uuid.toString(); + } catch (NoSuchMethodError ex) { + try { + Method endpointAccessor = ReflectionUtils.findMethod(HazelcastInstance.class, "getLocalEndpoint"); + Object endpoint = ReflectionUtils.invokeMethod(endpointAccessor, this.hazelcast); + Method uuidAccessor = ReflectionUtils.findMethod(endpoint.getClass(), "getUuid"); + Object uuid = ReflectionUtils.invokeMethod(uuidAccessor, endpoint); + return uuid == null ? null : uuid.toString(); + } catch (RuntimeException | Error nested) { + return null; + } + } + } +} diff --git a/cache-provider-hazelcast/src/test/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicatorTest.java b/cache-provider-hazelcast/src/test/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicatorTest.java new file mode 100644 index 00000000000..6eb40771569 --- /dev/null +++ b/cache-provider-hazelcast/src/test/java/io/mosip/commons/packet/cache/provider/hazelcast/config/HazelcastHealthIndicatorTest.java @@ -0,0 +1,108 @@ +package io.mosip.commons.packet.cache.provider.hazelcast.config; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.mockito.Mockito.when; + +import java.util.Set; +import java.util.UUID; + +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.extension.ExtendWith; +import org.mockito.Mock; +import org.mockito.junit.jupiter.MockitoExtension; +import org.springframework.boot.health.contributor.Health; +import org.springframework.boot.health.contributor.Status; + +import com.hazelcast.cluster.Cluster; +import com.hazelcast.cluster.Endpoint; +import com.hazelcast.core.HazelcastInstance; + +/** + * Unit tests for {@link HazelcastHealthIndicator}. + */ +@ExtendWith(MockitoExtension.class) +class HazelcastHealthIndicatorTest { + + @Mock + private HazelcastInstance hazelcast; + + @Mock + private Cluster cluster; + + @Mock + private Endpoint endpoint; + + @Test + void healthReportsClusterDetails() { + UUID uuid = UUID.fromString("11111111-1111-1111-1111-111111111111"); + when(hazelcast.getName()).thenReturn("packet-cache"); + when(hazelcast.getLocalEndpoint()).thenReturn(endpoint); + when(endpoint.getUuid()).thenReturn(uuid); + when(hazelcast.getCluster()).thenReturn(cluster); + when(cluster.getMembers()).thenReturn(Set.of()); + + Health health = new HazelcastHealthIndicator(hazelcast).health(); + + assertEquals(Status.UP, health.getStatus()); + assertEquals("packet-cache", health.getDetails().get("name")); + assertEquals(uuid.toString(), health.getDetails().get("uuid")); + assertEquals(0, health.getDetails().get("members")); + } + + @Test + void healthUsesEmptyUuidWhenLocalUuidIsNull() { + when(hazelcast.getName()).thenReturn("packet-cache"); + when(hazelcast.getLocalEndpoint()).thenReturn(endpoint); + when(endpoint.getUuid()).thenReturn(null); + when(hazelcast.getCluster()).thenReturn(cluster); + when(cluster.getMembers()).thenReturn(Set.of()); + + Health health = new HazelcastHealthIndicator(hazelcast).health(); + + assertEquals(Status.UP, health.getStatus()); + assertEquals("", health.getDetails().get("uuid")); + } + + @Test + void healthFallsBackWhenUuidApiIsMissing() { + UUID uuid = UUID.fromString("22222222-2222-2222-2222-222222222222"); + when(hazelcast.getName()).thenReturn("packet-cache"); + when(hazelcast.getLocalEndpoint()).thenReturn(endpoint); + when(endpoint.getUuid()).thenThrow(new NoSuchMethodError("getUuid")).thenReturn(uuid); + when(hazelcast.getCluster()).thenReturn(cluster); + when(cluster.getMembers()).thenReturn(Set.of()); + + Health health = new HazelcastHealthIndicator(hazelcast).health(); + + assertEquals(Status.UP, health.getStatus()); + assertEquals(uuid.toString(), health.getDetails().get("uuid")); + } + + @Test + void healthUsesEmptyUuidWhenFallbackLookupReturnsNull() { + when(hazelcast.getName()).thenReturn("packet-cache"); + when(hazelcast.getLocalEndpoint()).thenReturn(endpoint); + when(endpoint.getUuid()).thenThrow(new NoSuchMethodError("getUuid")).thenReturn(null); + when(hazelcast.getCluster()).thenReturn(cluster); + when(cluster.getMembers()).thenReturn(Set.of()); + + Health health = new HazelcastHealthIndicator(hazelcast).health(); + + assertEquals(Status.UP, health.getStatus()); + assertEquals("", health.getDetails().get("uuid")); + } + + @Test + void healthUsesEmptyUuidWhenFallbackLookupAlsoFails() { + when(hazelcast.getName()).thenReturn("packet-cache"); + when(hazelcast.getLocalEndpoint()).thenReturn(endpoint); + when(endpoint.getUuid()).thenThrow(new NoSuchMethodError("getUuid")); + when(hazelcast.getCluster()).thenReturn(cluster); + when(cluster.getMembers()).thenReturn(Set.of()); + + Health health = new HazelcastHealthIndicator(hazelcast).health(); + + assertEquals(Status.UP, health.getStatus()); + assertEquals("", health.getDetails().get("uuid")); + } +} diff --git a/cache-provider-redis/AGENTS.md b/cache-provider-redis/AGENTS.md new file mode 100644 index 00000000000..cfba7606acf --- /dev/null +++ b/cache-provider-redis/AGENTS.md @@ -0,0 +1,12 @@ +# cache-provider-redis + +`PacketCacheProvider` (Jedis). Standalone pom. Pins in `pom.xml`. + +``` +cache-provider-redis/ +├── pom.xml README.md AGENTS.md +├── src/main/java/io/mosip/commons/packet/cache/provider/redis/config/ +│ └── RedisConfig.java # redis.cache.hostname|port|password +└── src/test/java/.../config/ + └── RedisConfigTest.java +``` diff --git a/cache-provider-redis/README.md b/cache-provider-redis/README.md new file mode 100644 index 00000000000..40878de73ee --- /dev/null +++ b/cache-provider-redis/README.md @@ -0,0 +1,27 @@ +# cache-provider-redis + +MOSIP `PacketCacheProvider` SPI backed by Redis (Jedis; Lettuce excluded). + +- **Artifact**: `io.mosip.cacheprovider:cache-provider-redis:1.4.1-SNAPSHOT` +- **Parent**: `spring-boot-starter-parent` **4.1.1** +- **Config**: `RedisConfig` (`redis.cache.hostname`, `port`, `password`, pool timeouts) +- **Git info**: `service-git.properties` + +## Build + +```text +cd cache-provider-redis +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +Drop the JAR on the packet-manager classpath. + +```text +mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +JaCoCo LINE covered ratio **0.90** (`target/site/jacoco/index.html`). Redis: `redis.cache.hostname`, `port`, `password`, pool timeouts (see `RedisConfig`). Lettuce is excluded in favor of Jedis. + +## License + +[Mozilla Public License 2.0](../LICENSE) — [NOTICE](../NOTICE) diff --git a/cache-provider-redis/pom.xml b/cache-provider-redis/pom.xml index a4cf516776e..466de136e8b 100644 --- a/cache-provider-redis/pom.xml +++ b/cache-provider-redis/pom.xml @@ -1,262 +1,325 @@ - 4.0.0 + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> + 4.0.0 - io.mosip.cacheprovider - cache-provider-redis - 1.4.0-SNAPSHOT - cache-provider-redis - Cache provider redis of MOSIP - https://github.com/mosip/mosip-ref-impl - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - + + org.springframework.boot + spring-boot-starter-parent + 4.1.1 + + - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - Mosip - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip/mosip-ref-impl - - + io.mosip.cacheprovider + cache-provider-redis + 1.4.1-SNAPSHOT + cache-provider-redis + + MOSIP PacketCacheProvider SPI backed by Redis/Jedis (Spring Boot 4.1.1, Java 21). + No kernel-bom. Module version and third-party pins live in this pom — not in README.md. + + https://github.com/mosip/mosip-ref-impl - - - UTF-8 - 21 - 21 - 3.8.0 - 2.22.0 - 3.3.0 - 2.2.1 - 1.5 - 3.0.1 - 3.2.0 - 2.8.1 - 0.11.0 - 1.3.1-rc.1 - + + 21 + + false + 3.16.0 + 3.6.0 + 0.8.15 + 0.90 + ${project.build.directory}/site/jacoco/jacoco.xml + 5.8.0.7211 + 3.12.0 + 3.4.0 + 3.2.8 + 3.2.0 + 4.9.10 + 0.11.0 + 3.8.0 + - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - - - - - io.mosip.kernel - kernel-bom - ${kerne.bom.version} - pom - import - - - + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + repo + + + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MOSIP + mosip.emailnotifier@gmail.com + io.mosip + https://github.com/mosip + + - - - org.springframework.boot - spring-boot-starter - provided - - - org.springframework.boot - spring-boot-starter-actuator - provided - - - org.springframework.boot - spring-boot-starter-data-redis - - - redis.clients - jedis - - - - - - - org.apache.maven.plugins - maven-assembly-plugin - ${maven-assembly-plugin.version} - - - jar-with-dependencies - - false - - - - make-assembly - package - - single - - - - - - org.apache.maven.plugins - maven-source-plugin - ${maven-source-plugin.version} - - - attach-sources - - jar-no-fork - - - - - - org.apache.maven.plugins - maven-gpg-plugin - ${maven-gpg-plugin.version} - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - ${git-commit-id-plugin.version} - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - - - org.apache.maven.plugins - maven-javadoc-plugin - ${maven-javadoc-plugin.version} - - - attach-javadocs - - jar - - - - - none - - - - - maven-deploy-plugin - ${maven-deploy-plugin.version} - - - default-deploy - deploy - - deploy - - - - - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - - - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - ${skipTests} - false - - ${argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --illegal-access=permit - - - - - - - - sonar - - . - src/main/java/**,src/main/resources/** - ${sonar.coverage.exclusions} - https://sonarcloud.io - - - false - - - - - org.sonarsource.scanner.maven - sonar-maven-plugin - ${maven.sonar.plugin.version} - - - verify - - sonar - - - - - - - - + + + + org.springframework.boot + spring-boot-starter + provided + + + + org.springframework.boot + spring-boot-starter-actuator + provided + + + + org.springframework.boot + spring-boot-starter-data-redis + + + io.lettuce + lettuce-core + + + + + + redis.clients + jedis + + + + org.springframework.boot + spring-boot-starter-test + test + + + + + ossrh + https://central.sonatype.com/repository/maven-snapshots/ + + + ossrh + https://central.sonatype.com/api/v1/publisher + + + + + + org.apache.maven.plugins + maven-assembly-plugin + ${maven.assembly.plugin.version} + + + jar-with-dependencies + + false + + + + make-assembly + package + + single + + + + + + org.apache.maven.plugins + maven-compiler-plugin + ${maven.compiler.plugin.version} + + ${java.version} + true + + + + org.apache.maven.plugins + maven-surefire-plugin + ${maven.surefire.plugin.version} + + ${skipTests} + @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED + + + + org.jacoco + jacoco-maven-plugin + ${maven.jacoco.version} + + + + prepare-agent + + + + report + prepare-package + + report + + + + jacoco-check + + check + + + + + BUNDLE + + + LINE + COVEREDRATIO + ${jacoco.minimum.coverage} + + + + + + + + + + org.apache.maven.plugins + maven-source-plugin + ${maven.source.plugin.version} + + + attach-sources + + jar-no-fork + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + ${maven.javadoc.version} + + + attach-javadocs + + jar + + + + + none + false + + + + org.apache.maven.plugins + maven-gpg-plugin + ${maven.gpg.plugin.version} + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + pl.project13.maven + git-commit-id-plugin + ${git.commit.id.plugin.version} + + + get-the-git-infos + + revision + + validate + + + + + true + ${project.build.outputDirectory}/service-git.properties + + ^git.build.(time|version)$ + ^git.commit.id.(abbrev|full)$ + + full + ${project.basedir}/.git + + + + org.apache.maven.plugins + maven-deploy-plugin + ${maven.deploy.plugin.version} + + + org.sonatype.central + central-publishing-maven-plugin + ${central.publishing.maven.plugin.version} + true + + ossrh + false + + + + + + + sonar + + . + src/main/java/**,src/main/resources/** + https://sonarcloud.io + + + false + + + + + org.sonarsource.scanner.maven + sonar-maven-plugin + ${maven.sonar.plugin.version} + + + verify + + sonar + + + + + + + + diff --git a/cache-provider-redis/src/test/java/io/mosip/commons/packet/cache/provider/redis/config/RedisConfigTest.java b/cache-provider-redis/src/test/java/io/mosip/commons/packet/cache/provider/redis/config/RedisConfigTest.java new file mode 100644 index 00000000000..8170878c184 --- /dev/null +++ b/cache-provider-redis/src/test/java/io/mosip/commons/packet/cache/provider/redis/config/RedisConfigTest.java @@ -0,0 +1,74 @@ +package io.mosip.commons.packet.cache.provider.redis.config; + +import static org.junit.jupiter.api.Assertions.assertEquals; +import static org.junit.jupiter.api.Assertions.assertFalse; +import static org.junit.jupiter.api.Assertions.assertNotNull; +import static org.junit.jupiter.api.Assertions.assertTrue; + +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; +import org.springframework.data.redis.connection.jedis.JedisConnectionFactory; +import org.springframework.data.redis.core.RedisTemplate; +import org.springframework.test.util.ReflectionTestUtils; + +import redis.clients.jedis.JedisPoolConfig; + +/** + * Unit tests for {@link RedisConfig} bean wiring (no live Redis). + */ +class RedisConfigTest { + + private RedisConfig redisConfig; + + @BeforeEach + void setUp() { + redisConfig = new RedisConfig(); + ReflectionTestUtils.setField(redisConfig, "hostname", "127.0.0.1"); + ReflectionTestUtils.setField(redisConfig, "password", "secret"); + ReflectionTestUtils.setField(redisConfig, "port", 6379); + ReflectionTestUtils.setField(redisConfig, "database", 0); + ReflectionTestUtils.setField(redisConfig, "sslEnabled", false); + ReflectionTestUtils.setField(redisConfig, "maxTotal", 50); + ReflectionTestUtils.setField(redisConfig, "maxIdle", 10); + ReflectionTestUtils.setField(redisConfig, "minIdle", 2); + ReflectionTestUtils.setField(redisConfig, "connectTimeout", 2000); + ReflectionTestUtils.setField(redisConfig, "readTimeout", 3500); + ReflectionTestUtils.setField(redisConfig, "maxWaitMs", 2000L); + ReflectionTestUtils.setField(redisConfig, "testWhileIdle", true); + ReflectionTestUtils.setField(redisConfig, "evictionRunIntervalMs", 60000L); + ReflectionTestUtils.setField(redisConfig, "minEvictableIdleTimeMs", 300000L); + ReflectionTestUtils.setField(redisConfig, "numTestsPerEvictionRun", 20); + ReflectionTestUtils.setField(redisConfig, "testOnBorrow", false); + ReflectionTestUtils.setField(redisConfig, "testOnCreate", false); + ReflectionTestUtils.setField(redisConfig, "testOnReturn", false); + ReflectionTestUtils.setField(redisConfig, "blockWhenExhausted", true); + ReflectionTestUtils.setField(redisConfig, "jmxEnabled", false); + } + + @Test + void jedisPoolConfigAppliesThroughputSettings() { + JedisPoolConfig pool = redisConfig.jedisPoolConfig(); + assertEquals(50, pool.getMaxTotal()); + assertEquals(10, pool.getMaxIdle()); + assertEquals(2, pool.getMinIdle()); + assertFalse(pool.getTestOnBorrow()); + assertTrue(pool.getTestWhileIdle()); + assertFalse(pool.getJmxEnabled()); + } + + @Test + void jedisConnectionFactoryAndTemplateAreCreated() { + JedisConnectionFactory factory = redisConfig.jedisConnectionFactory(); + assertNotNull(factory); + RedisTemplate template = redisConfig.redisTemplate(); + assertNotNull(template); + } + + @Test + void jedisConnectionFactoryEnablesSslWhenConfigured() { + ReflectionTestUtils.setField(redisConfig, "sslEnabled", true); + JedisConnectionFactory factory = redisConfig.jedisConnectionFactory(); + assertNotNull(factory); + assertTrue(factory.isUseSsl()); + } +} diff --git a/directoryAngularFiles b/directoryAngularFiles deleted file mode 100644 index 00ef13f1164..00000000000 --- a/directoryAngularFiles +++ /dev/null @@ -1,2 +0,0 @@ -./pre-registration-ui/angular.json -./admin-ui/angular.json diff --git a/helm/AGENTS.md b/helm/AGENTS.md new file mode 100644 index 00000000000..0d3665a88b1 --- /dev/null +++ b/helm/AGENTS.md @@ -0,0 +1,17 @@ +# helm + +Chart for pre-registration booking. + +``` +helm/prereg-booking/ +├── Chart.yaml values.yaml README.md .helmignore .gitignore +└── templates/ + ├── _helpers.tpl + ├── deployment.yaml + ├── service.yaml + ├── service-account.yaml + ├── servicemonitor.yaml + ├── virtualservice.yaml + ├── extra-list.yaml + └── NOTES.txt +``` diff --git a/helm/prereg-booking/AGENTS.md b/helm/prereg-booking/AGENTS.md new file mode 100644 index 00000000000..8f29a49195e --- /dev/null +++ b/helm/prereg-booking/AGENTS.md @@ -0,0 +1,14 @@ +# helm/prereg-booking + +Chart for booking image. GC/encoding flags = `values.yaml` `additionalResources.javaOpts` → `JDK_JAVA_OPTIONS` (not Dockerfile). + +``` +helm/prereg-booking/ +├── Chart.yaml values.yaml README.md AGENTS.md +└── templates/ + ├── deployment.yaml # JDK_JAVA_OPTIONS from javaOpts + ├── service.yaml + ├── serviceaccount.yaml + ├── servicemonitor.yaml + └── virtualservice.yaml +``` diff --git a/helm/prereg-booking/README.md b/helm/prereg-booking/README.md index c767333e588..dc4035891e8 100644 --- a/helm/prereg-booking/README.md +++ b/helm/prereg-booking/README.md @@ -1,11 +1,16 @@ # PreReg Booking -Helm chart for installing Pre-Registration Booking service. +Helm chart for the **pre-registration-booking-service** (Spring Boot 4.1.1 image). Chart sources: `Chart.yaml`, `values.yaml`, `templates/` (Deployment, Service, ServiceAccount, ServiceMonitor, VirtualService). + +Sandbox cluster: [Sandbox Deployment Guide](https://docs.mosip.io/1.2.0/deploymentnew/v3-installation). ## Install + ```console -$ kubectl create namespace prereg -$ helm repo add mosip https://mosip.github.io -$ helm -n prereg install my-release mosip/prereg-booking +kubectl create namespace prereg +helm repo add mosip https://mosip.github.io +helm -n prereg install my-release mosip/prereg-booking ``` +Override image tag and config-server settings in `values.yaml` for your environment. Service README: [pre-registration-booking-service](../../pre-registration-booking-service/README.md). + diff --git a/helm/prereg-booking/values.yaml b/helm/prereg-booking/values.yaml index c4fe40dc2ed..cfb0504f692 100644 --- a/helm/prereg-booking/values.yaml +++ b/helm/prereg-booking/values.yaml @@ -119,9 +119,9 @@ resources: cpu: 250m memory: 1250Mi additionalResources: - ## Specify any JAVA_OPTS string here. These typically will be specified in conjunction with above resources - ## Example: java_opts: "-Xms500M -Xmx500M" - javaOpts: "-Xms1125M -Xmx1875M" + ## Passed to the container as JDK_JAVA_OPTIONS (see templates/deployment.yaml). + ## Heap plus GC/encoding flags — not hardcoded in the Dockerfile. + javaOpts: "-Xms1125M -Xmx1875M -XX:-UseG1GC -XX:+ExplicitGCInvokesConcurrent -XX:-UseParallelGC -XX:+UseZGC -XX:+ZGenerational -XX:-UseShenandoahGC -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+UseStringDeduplication -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 -XX:+UseCompressedOops" ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-container ## Clamav container already runs as 'mosip' user, so we may not need to enable this containerSecurityContext: diff --git a/kernel/AGENTS.md b/kernel/AGENTS.md new file mode 100644 index 00000000000..c9607af04ba --- /dev/null +++ b/kernel/AGENTS.md @@ -0,0 +1,15 @@ +# kernel + +`kernel-ref-parent` (`packaging=pom`). Boot 4.1.1. No `kernel-bom`. Child → that folder’s `AGENTS.md`. + +``` +kernel/ +├── pom.xml AGENTS.md +├── kernel-ref-idobjectvalidator/ IdObjectValidator → AGENTS.md +├── kernel-smsserviceprovider-msg91/ SMS SPI (MSG91) → AGENTS.md +└── kernel-virusscanner-clamav/ VirusScanner + ClamAV → AGENTS.md +``` + +```bash +mvn -f kernel/pom.xml -pl clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` diff --git a/kernel/README.md b/kernel/README.md new file mode 100644 index 00000000000..39152f4455d --- /dev/null +++ b/kernel/README.md @@ -0,0 +1,31 @@ +# kernel + +Parent **`kernel-ref-parent`** (`packaging=pom`). Spring Boot **4.1.1**, Java 21, no `kernel-bom`. Logging comes from `kernel-core` (commons); do not add `kernel-logger-logback`. MOSIP versions are in `kernel/pom.xml`. + +## Modules + +| Module | SPI / role | README | +|---|---|---| +| [kernel-ref-idobjectvalidator](kernel-ref-idobjectvalidator) | `IdObjectValidator` — identity JSON vs schema + masterdata | [README](kernel-ref-idobjectvalidator/README.md) | +| [kernel-smsserviceprovider-msg91](kernel-smsserviceprovider-msg91) | `SMSServiceProvider` — MSG91 HTTP | [README](kernel-smsserviceprovider-msg91/README.md) | +| [kernel-virusscanner-clamav](kernel-virusscanner-clamav) | `VirusScanner` — ClamAV | [README](kernel-virusscanner-clamav/README.md) | + +Swap implementation = swap the JAR. SPIs auto-load from `META-INF/spring.factories`. + +## Build + +From this directory: + +```text +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn -pl kernel-ref-idobjectvalidator clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +JaCoCo LINE covered ratio **0.90** on `verify` (`target/site/jacoco/index.html` per child). `kernel-ref-idobjectvalidator` tests use `--enable-preview`. + +Git commit plugin writes `service-git.properties` (not `git.properties`). + +## License + +[Mozilla Public License 2.0](../LICENSE) — [NOTICE](../NOTICE) diff --git a/kernel/kernel-ref-idobjectvalidator/AGENTS.md b/kernel/kernel-ref-idobjectvalidator/AGENTS.md new file mode 100644 index 00000000000..89b253fbb41 --- /dev/null +++ b/kernel/kernel-ref-idobjectvalidator/AGENTS.md @@ -0,0 +1,20 @@ +# kernel-ref-idobjectvalidator + +`IdObjectValidator` SPI. Tests: `--enable-preview`. Pins in parent `kernel/pom.xml`. + +``` +kernel-ref-idobjectvalidator/ +├── pom.xml README.md AGENTS.md +└── src/ + ├── main/java/io/mosip/kernel/idobjectvalidator/ + │ ├── impl/IdObjectReferenceValidator.java + │ └── constant/ + │ ├── IdObjectReferenceValidatorConstant.java + │ ├── IdObjectReferenceValidatorDocumentMapping.java + │ └── IdObjectReferenceValidatorLocationMapping.java + └── test/ + ├── java/.../idobjectvalidator/test/ + │ ├── IdObjectReferenceValidatorTest.java + │ └── TestConfig.java + └── resources/ application-test.properties schema.json +``` diff --git a/kernel/kernel-ref-idobjectvalidator/README.md b/kernel/kernel-ref-idobjectvalidator/README.md new file mode 100644 index 00000000000..f07995854fc --- /dev/null +++ b/kernel/kernel-ref-idobjectvalidator/README.md @@ -0,0 +1,27 @@ +# kernel-ref-idobjectvalidator + +Reference `IdObjectValidator` that checks identity JSON against schema and masterdata (documents, locations, gender, etc.). + +- **Artifact**: `io.mosip.kernel:kernel-ref-idobjectvalidator:1.4.1-SNAPSHOT` +- **Parent**: `kernel-ref-parent` (Boot **4.1.1**, `kernel-core` supplies logging) +- **Preview**: tests use `--enable-preview` +- **Config**: `mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern` and masterdata URI properties + +## Build + +```text +cd kernel +mvn -pl kernel-ref-idobjectvalidator clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +Runtime consumers (booking, registration client) add this JAR plus `kernel-auth-adapter` as needed. + +```text +mvn -pl kernel-ref-idobjectvalidator clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +JaCoCo LINE covered ratio **0.90**. `json-path` / `json-smart` are compile dependencies (identity JSON queries). + +## License + +[Mozilla Public License 2.0](../../LICENSE) — [NOTICE](../../NOTICE) diff --git a/kernel/kernel-ref-idobjectvalidator/pom.xml b/kernel/kernel-ref-idobjectvalidator/pom.xml index 9c0a1233626..91a2577c6c1 100644 --- a/kernel/kernel-ref-idobjectvalidator/pom.xml +++ b/kernel/kernel-ref-idobjectvalidator/pom.xml @@ -1,162 +1,97 @@ - + 4.0.0 io.mosip.kernel kernel-ref-parent - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT - kernel-ref-idobjectvalidator kernel-ref-idobjectvalidator - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT + kernel-ref-idobjectvalidator + + Reference IdObjectValidator: JSON schema + masterdata validation. + kernel-core (commons) supplies logging; do not add kernel-logger-logback. + - - 1.3.1-rc.1 - 1.3.1-rc.1 - 0.11.0 - - - - - io.mosip.kernel - kernel-bom - ${kerne.bom.version} - pom - import - - - - - - org.mockito - mockito-core - test - - - net.bytebuddy - byte-buddy - + + io.mosip.kernel kernel-core - ${kernel-core.version} + org.apache.commons commons-collections4 + - com.fasterxml.jackson.datatype - jackson-datatype-jdk8 - - - org.springframework.boot - spring-boot-starter-web + com.jayway.jsonpath + json-path + - io.mosip.kernel - kernel-logger-logback - ${kernel-logger-logback.version} + net.minidev + json-smart + - com.fasterxml.jackson.core - jackson-databind + org.springframework.boot + spring-boot-starter-web + - com.fasterxml.jackson.core - jackson-annotations + org.springframework.cloud + spring-cloud-starter-config - com.fasterxml.jackson.core - jackson-core + org.springframework.cloud + spring-cloud-starter-bootstrap + - com.fasterxml.jackson.datatype - jackson-datatype-jsr310 + org.mockito + mockito-core + test + - org.junit.vintage - junit-vintage-engine + net.bytebuddy + byte-buddy - - org.springframework.cloud - spring-cloud-starter-config - - - org.springframework.cloud - spring-cloud-starter-bootstrap - - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - + + - - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - false - false - - ${jacocoArgLine} - --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED - --add-opens java.base/java.lang=ALL-UNNAMED - --add-opens java.base/java.util=ALL-UNNAMED - --add-opens java.base/java.io=ALL-UNNAMED - --enable-preview - - - - - org.jacoco - jacoco-maven-plugin - ${maven.jacoco.plugin.version} - - - prepare-agent - - prepare-agent - - - jacocoArgLine - - - - report - verify - - report - - - - - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - org.apache.maven.plugins - maven-compiler-plugin - ${maven.compiler.version} + maven-surefire-plugin - ${maven.compiler.source} - ${maven.compiler.target} + @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED --enable-preview diff --git a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorConstant.java b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorConstant.java index 71fb805410a..c878e3894ea 100644 --- a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorConstant.java +++ b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorConstant.java @@ -1,51 +1,73 @@ package io.mosip.kernel.idobjectvalidator.constant; /** - * The Class IdObjectReferenceValidatorConstant. + * JSON-path keys, identity field types, and configuration property names used by + * {@link io.mosip.kernel.idobjectvalidator.impl.IdObjectReferenceValidator}. * * @author Manoj SP */ public class IdObjectReferenceValidatorConstant { + /** JSON property name {@code type}. */ public static final String TYPE = "type"; + /** JSON property name {@code value}. */ public static final String VALUE = "value"; + /** JSON property name {@code code}. */ public static final String CODE = "code"; + /** JSON property name {@code language}. */ public static final String LANGUAGE = "language"; + /** Identity schema type name for biometric attributes. */ public static final String BIOMETRICS_TYPE = "biometricsType"; + /** Identity schema type name for document attributes. */ public static final String DOCUMENT_TYPE = "documentType"; + /** Identity schema type name for language-tagged simple values. */ public static final String SIMPLE_TYPE = "simpleType"; + /** Identity schema type name for plain strings. */ public static final String STRING = "String"; + /** Path separator used when building JSON Pointer-like paths. */ public static final String SLASH = "/"; + /** JsonPath to each identity field {@code $ref} in the ID schema. */ public static final String SCHEMA_FIELD_DEF_PATH = "$.properties.identity.properties.*.$ref"; + /** JsonPath to each identity field {@code subType} in the ID schema. */ public static final String SCHEMA_SUB_TYPE_PATH = "$.properties.identity.properties.*.subType"; - + + /** Config key for MOSIP mandatory UI languages. */ public static final String MOSIP_MANDATORY_LANG = "mosip.mandatory-languages"; - + + /** Config key for MOSIP optional UI languages. */ public static final String MOSIP_OPTIONAL_LANG = "mosip.optional-languages"; - + + /** Config key for the identity JSON path of ID schema version. */ public static final String IDENTITY_ID_SCHEMA_VERSION_PATH = "mosip.kernel.idobjectvalidator.identity.id-schema-version-path"; - + + /** Config key for the identity JSON path of date of birth. */ public static final String IDENTITY_DOB_PATH = "mosip.kernel.idobjectvalidator.identity.dob-path"; - + + /** Config key for accepted DOB date format. */ public static final String DOB_FORMAT = "mosip.kernel.idobjectvalidator.date-format"; - + + /** Config key for the masterdata "value not available" sentinel. */ public static final String VALUE_NA = "mosip.kernel.idobjectvalidator.masterdata.value-not-available"; - + + /** JsonPath matching language tags under identity. */ public static final String IDENTITY_LANGUAGE_PATH = "identity.*.*.language"; + /** Config key for the masterdata REST URI template. */ public static final String MASTER_DATA_URI = "mosip.idobjectvalidator.masterdata.rest.uri"; + /** Config key: refresh masterdata cache when an unknown code is seen. */ public static final String IS_CACHE_RESET_ENABLED = "mosip.idobjectvalidator.refresh-cache-on-unknown-value"; + /** Config key: cron expression that clears the masterdata cache. */ public static final String CACHE_RESET_CRON_PATTERN = "mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern"; } diff --git a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorDocumentMapping.java b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorDocumentMapping.java index e5c9cd7e0ca..66524b79c4f 100644 --- a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorDocumentMapping.java +++ b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorDocumentMapping.java @@ -11,16 +11,22 @@ */ public enum IdObjectReferenceValidatorDocumentMapping { + /** Proof of address document. */ POA("proofOfAddress", "POA"), - + + /** Proof of identity document. */ POI("proofOfIdentity", "POI"), + /** Proof of relationship document. */ POR("proofOfRelationship", "POR"), - + + /** Proof of exception document. */ POE("proofOfException", "POE"); + /** Identity JSON attribute name. */ private final String attributeName; - + + /** MOSIP document category code. */ private final String code; /** diff --git a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorLocationMapping.java b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorLocationMapping.java index fcd1f475e77..402865fb2d8 100644 --- a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorLocationMapping.java +++ b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/constant/IdObjectReferenceValidatorLocationMapping.java @@ -11,21 +11,29 @@ */ public enum IdObjectReferenceValidatorLocationMapping { + /** Country hierarchy level. */ COUNTRY("Country", "0"), - + + /** Region hierarchy level. */ REGION("Region", "1"), - + + /** Province hierarchy level. */ PROVINCE("Province", "2"), - + + /** City hierarchy level. */ CITY("City", "3"), - + + /** Zone hierarchy level. */ ZONE("Zone", "4"), - + + /** Postal-code hierarchy level. */ POSTAL_CODE("Postal Code", "5"); - + + /** Location hierarchy display name. */ private final String hierarchyName; - + + /** Numeric hierarchy level as used in masterdata. */ private final String level; /** diff --git a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/impl/IdObjectReferenceValidator.java b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/impl/IdObjectReferenceValidator.java index 0ee4841e074..3a6a07d4151 100644 --- a/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/impl/IdObjectReferenceValidator.java +++ b/kernel/kernel-ref-idobjectvalidator/src/main/java/io/mosip/kernel/idobjectvalidator/impl/IdObjectReferenceValidator.java @@ -82,6 +82,12 @@ /** * The Class IdObjectReferenceValidator. + *

+ * Reference {@link IdObjectValidator}: validates identity JSON types, languages, + * DOB, documents, and masterdata codes. Caches masterdata; optional cron reset + * via {@code mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern}. + * Logging is obtained from kernel-core. + *

* * @author Manoj SP */ @@ -89,24 +95,32 @@ @RefreshScope public class IdObjectReferenceValidator implements IdObjectValidator { + /** SLF4J logger supplied by kernel-core. */ private final static Logger logger = Logfactory.getSlf4jLogger(IdObjectReferenceValidator.class); + /** Comma-separated mandatory languages ({@code mosip.mandatory-languages}). */ @Value("${" + MOSIP_MANDATORY_LANG + ":}") private String mandatoryLanguages; + /** Comma-separated optional languages ({@code mosip.optional-languages}). */ @Value("${" + MOSIP_OPTIONAL_LANG + ":}") private String optionalLanguages; + /** Masterdata REST URI template. */ @Value("${" + MASTER_DATA_URI + "}") private String masterDataUri; + /** JsonPath to the identity schema version field. */ @Value("${" + IDENTITY_ID_SCHEMA_VERSION_PATH + "}") private String idSchemaVersionPath; + /** Identity field name → masterdata subType. */ private Map fieldToSubTypeMapping; + /** Identity field name → schema type (simpleType, documentType, …). */ private Map fieldToFieldDefMapping; + /** Schema versions already parsed in this JVM. */ private Set processedSchemaVersions = new HashSet<>(); /** The env. */ @@ -136,7 +150,7 @@ public class IdObjectReferenceValidator implements IdObjectValidator { private Map> validationDataCache = new HashMap<>(); /** - * Load data. + * Loads languages, optionally schedules cache reset, and registers Jackson time modules. */ @PostConstruct public void loadData() { @@ -149,6 +163,9 @@ public void loadData() { mapper.registerModule(new Jdk8Module()).registerModule(new JavaTimeModule()); } + /** + * Clears language, schema, and masterdata caches then reloads them. + */ public void resetCache() { languageList = Set.of(); fieldToSubTypeMapping = Map.of(); @@ -159,12 +176,13 @@ public void resetCache() { loadLanguages(); } - /* - * (non-Javadoc) - * - * @see - * io.mosip.kernel.core.idobjectvalidator.spi.IdObjectValidator#validateIdObject - * (java.lang.Object) + /** + * Validates identity JSON against schema types, languages, DOB, and masterdata codes. + * + * @param identitySchema ID schema JSON + * @param identityObject identity payload + * @param requiredFields unused by this reference impl (SPI signature) + * @return {@code true} when no {@link ServiceError}s are collected */ @Override public boolean validateIdObject(String identitySchema, Object identityObject, List requiredFields) diff --git a/kernel/kernel-smsserviceprovider-msg91/AGENTS.md b/kernel/kernel-smsserviceprovider-msg91/AGENTS.md new file mode 100644 index 00000000000..ca9c4e7ee4d --- /dev/null +++ b/kernel/kernel-smsserviceprovider-msg91/AGENTS.md @@ -0,0 +1,21 @@ +# kernel-smsserviceprovider-msg91 + +`SMSServiceProvider` SPI (MSG91). Auto-config: `META-INF/spring.factories`. Pins in `kernel/pom.xml`. + +``` +kernel-smsserviceprovider-msg91/ +├── pom.xml README.md AGENTS.md +└── src/ + ├── main/ + │ ├── java/io/mosip/kernel/smsserviceprovider/msg91/ + │ │ ├── impl/SMSServiceProviderImpl.java + │ │ ├── exception/ApiExceptionHandler.java + │ │ ├── dto/SmsVendorRequestDto.java SmsServerResponseDto.java + │ │ └── constant/SmsPropertyConstant.java SmsExceptionConstant.java + │ └── resources/ + │ ├── META-INF/spring.factories + │ └── logback.xml + └── test/ + ├── java/.../msg91/SmsServiceProviderTest.java + └── resources/application.properties +``` diff --git a/kernel/kernel-smsserviceprovider-msg91/README.md b/kernel/kernel-smsserviceprovider-msg91/README.md index 4e3ee20f70b..5a4814e5e80 100644 --- a/kernel/kernel-smsserviceprovider-msg91/README.md +++ b/kernel/kernel-smsserviceprovider-msg91/README.md @@ -1,78 +1,69 @@ -## kernel-smsserviceprovider-msg91 +# kernel-smsserviceprovider-msg91 - [Background & Design]() +Reference implementation of `io.mosip.kernel.core.notification.spi.SMSServiceProvider` using the MSG91 HTTP API. - **Implementation** -This service is provided as a reference implementation so the adopters could change this code to support their respective service provider. +- **Artifact**: `io.mosip.kernel:kernel-smsserviceprovider-msg91:1.4.1-SNAPSHOT` +- **Parent**: `kernel-ref-parent` (Boot **4.1.1**, `kernel-core` for logging) +- **SPI**: `SMSServiceProviderImpl` auto-loaded via `META-INF/spring.factories` +- Do not add `kernel-logger-logback`; logging is in `kernel-core`. -``` -io.mosip.kernel.core.notification.spi.SMSServiceProvider +## Implementation -``` -The above interface is implemented in this service. Adopters are expected to be compliant to the interface and add their implementation in the SMSServiceProviderImpl.java or create equivalent impl. +Keep the SPI contract. Change `SMSServiceProviderImpl` (or an equivalent impl) for another vendor. Do not change the REST contract of consuming services. -Its expected that the adopters do not change the controller and the REST api. +```text +io.mosip.kernel.core.notification.spi.SMSServiceProvider +``` - [API Documentation ] - - ``` - mvn javadoc:javadoc +## API docs (Javadoc) - ``` - -**Properties to be added in Spring application environment using this component** +```text +cd kernel +mvn -pl kernel-smsserviceprovider-msg91 javadoc:javadoc +``` -[application-dev.properties](../../config/application-dev.properties) +## Properties (config server / application environment) - ``` - #-----------------------------VID Properties-------------------------------------- +```text mosip.kernel.sms.enabled=true mosip.kernel.sms.country.code=91 mosip.kernel.sms.number.min.length=10 mosip.kernel.sms.number.max.length=10 - - - -#----------msg91 gateway--------------- mosip.kernel.sms.api=http://api.msg91.com/api/v2/sendsms mosip.kernel.sms.authkey= mosip.kernel.sms.route=4 mosip.kernel.sms.sender=MOSMSG +mosip.id.validation.identity.phone=^([6-9]{1})([0-9]{9})$ +``` -auth.server.admin.validate.url= - - ``` - - **Maven Dependency** - - ``` - - io.mosip.kernel - kernel-smsserviceprovider-msg91 - ${version} - +## Maven - ``` - +```xml + + io.mosip.kernel + kernel-smsserviceprovider-msg91 + 1.4.1-SNAPSHOT + +``` +## Usage +```java +@Autowired +private SMSServiceProvider smsServiceProvider; -**Usage Sample:** +smsServiceProvider.sendSms(contactNumber, contentMessage); +``` -Autowired interface +## Build +```text +cd kernel +mvn -pl kernel-smsserviceprovider-msg91 clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` - @Autowired - private VidValidator vidValidatorImpl; -``` -Call the method -Example: - - ``` - smsServiceProvider.sendSms(contactNumber, contentMessage); +JaCoCo LINE covered ratio **0.90**. Outbound MOSIP tokens: `kernel-auth-adapter` (version in parent `pom.xml`). -``` - +## License - +[Mozilla Public License 2.0](../../LICENSE) — [NOTICE](../../NOTICE) diff --git a/kernel/kernel-smsserviceprovider-msg91/pom.xml b/kernel/kernel-smsserviceprovider-msg91/pom.xml index b2d038f8d8a..0c025dc127f 100644 --- a/kernel/kernel-smsserviceprovider-msg91/pom.xml +++ b/kernel/kernel-smsserviceprovider-msg91/pom.xml @@ -1,191 +1,44 @@ + 4.0.0 -io.mosip.kernel + + io.mosip.kernel + kernel-ref-parent + 1.4.1-SNAPSHOT + + kernel-smsserviceprovider-msg91 + 1.4.1-SNAPSHOT kernel-smsserviceprovider-msg91 - kernel-smsserviceprovider-msg91 - https://github.com/mosip/commons - 1.4.0-SNAPSHOT - - UTF-8 + + Reference SMS SPI using MSG91. kernel-core (commons) supplies logging; + do not add kernel-logger-logback. kernel-auth-adapter injects MOSIP tokens. + + https://github.com/mosip/mosip-ref-impl - - 21 - 21 - 3.8.0 - 3.2.0 - 2.8.1 - 2.2.1 - 1.5 - 0.11.0 - 3.0.1 - 1.3.1-rc.1 - 1.3.1 - 5.10.2 - - + io.mosip.kernel kernel-core - ${kernel.core.version} + io.mosip.kernel kernel-auth-adapter - ${kernel.auth.adaptor.version} - - - org.junit.vintage - junit-vintage-engine - ${junit.vintage.version} - - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - - - - - src/main/resources - - bootstrap.properties - - - - - - maven-deploy-plugin - ${maven.deploy.plugin.version} - - - default-deploy - deploy - - deploy - - - - - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - - - org.apache.maven.plugins - maven-source-plugin - true - ${maven.source.plugin.version} - - - attach-sources - - jar-no-fork - - - - - - - org.apache.maven.plugins - maven-javadoc-plugin - ${maven.javadoc.plugin.version} - - - attach-javadocs - - jar - - - - - none - false - - - - org.apache.maven.plugins - maven-gpg-plugin - ${maven.gpg.plugin.version} - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - ${git.commit.plugin.version} - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - - - - - scm:git:git://github.com/mosip/commons.git - scm:git:ssh://github.com:mosip/commons.git - https://github.com/mosip/commons - HEAD - - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - - - - Mosip - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip/commons - - - - + + + + src/main/resources + + bootstrap.properties + + + + +
diff --git a/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/dto/SmsVendorRequestDto.java b/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/dto/SmsVendorRequestDto.java index a59fbac1759..b347279b22e 100644 --- a/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/dto/SmsVendorRequestDto.java +++ b/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/dto/SmsVendorRequestDto.java @@ -2,9 +2,15 @@ import lombok.Data; +/** + * Payload sent to the MSG91 vendor (from / to / text). + */ @Data public class SmsVendorRequestDto { + /** Sender identity. */ private String from; + /** Destination MSISDN. */ private String to; + /** Message body. */ private String text; } diff --git a/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/exception/ApiExceptionHandler.java b/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/exception/ApiExceptionHandler.java index 7cbdb3647c5..b2078d978ce 100644 --- a/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/exception/ApiExceptionHandler.java +++ b/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/exception/ApiExceptionHandler.java @@ -48,6 +48,7 @@ public class ApiExceptionHandler { @Autowired private ObjectMapper objectMapper; + /** Space inserted between a validation field name and its message. */ private static final String WHITESPACE = " "; /** @@ -134,6 +135,14 @@ public ResponseEntity> smsVendorServiceException( return new ResponseEntity<>(errorResponse, HttpStatus.OK); } + /** + * Maps MSG91 / gateway 5xx bodies into MOSIP {@code KER-NOS-004}. + * + * @param httpServletRequest original request + * @param exception Spring {@link HttpServerErrorException} + * @return HTTP 500 wrapper + * @throws IOException if the vendor body cannot be parsed + */ @ExceptionHandler(HttpServerErrorException.class) public ResponseEntity> httpServerErrorException(HttpServletRequest httpServletRequest, final HttpServerErrorException exception) throws IOException { @@ -151,6 +160,14 @@ public ResponseEntity> httpServerErrorException(Ht return new ResponseEntity<>(errorResponse, HttpStatus.INTERNAL_SERVER_ERROR); } + /** + * Catch-all handler for unmapped exceptions ({@code KER-NOS-500}). + * + * @param httpServletRequest original request + * @param e any remaining exception + * @return HTTP 500 wrapper + * @throws IOException if the cached request body cannot be read + */ @ExceptionHandler(value = { Exception.class, RuntimeException.class }) public ResponseEntity> defaultErrorHandler( final HttpServletRequest httpServletRequest, Exception e) throws IOException { @@ -163,6 +180,13 @@ public ResponseEntity> defaultErrorHandler( return new ResponseEntity<>(responseWrapper, HttpStatus.INTERNAL_SERVER_ERROR); } + /** + * Copies {@code id} / {@code version} from a cached JSON body when present. + * + * @param httpServletRequest possibly a {@link ContentCachingRequestWrapper} + * @return empty wrapper or wrapper with id and version + * @throws IOException if JSON parsing fails + */ private ResponseWrapper setErrors(HttpServletRequest httpServletRequest) throws IOException { ResponseWrapper responseWrapper = new ResponseWrapper<>(); String requestBody = null; diff --git a/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/impl/SMSServiceProviderImpl.java b/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/impl/SMSServiceProviderImpl.java index 6d65aaffe7c..333f0195e6b 100644 --- a/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/impl/SMSServiceProviderImpl.java +++ b/kernel/kernel-smsserviceprovider-msg91/src/main/java/io/mosip/kernel/smsserviceprovider/msg91/impl/SMSServiceProviderImpl.java @@ -1,6 +1,3 @@ -/** - * - */ package io.mosip.kernel.smsserviceprovider.msg91.impl; @@ -22,53 +19,79 @@ import io.mosip.kernel.smsserviceprovider.msg91.constant.SmsPropertyConstant; /** + * MSG91 implementation of {@link SMSServiceProvider}. + *

+ * Validates the destination number against {@code mosip.id.validation.identity.phone}, + * then GET-calls {@code mosip.kernel.sms.api} with auth key, sender, route, unicode, + * and country code. Vendor HTTP errors become {@link RuntimeException}. + *

+ * * @author Ritesh Sinha * @since 1.0.0 */ @Component public class SMSServiceProviderImpl implements SMSServiceProvider { + /** HTTP client used to call the MSG91 gateway. */ @Autowired RestTemplate restTemplate; + /** When false, send still validates the number then hits the vendor (legacy behaviour). */ @Value("${mosip.kernel.sms.enabled:false}") boolean smsEnabled; + /** Country dialling code query param for MSG91. */ @Value("${mosip.kernel.sms.country.code}") String countryCode; + /** Minimum allowed national number length. */ @Value("${mosip.kernel.sms.number.min.length}") int numberMinLength; + /** Maximum allowed national number length. */ @Value("${mosip.kernel.sms.number.max.length}") int numberMaxLength; + /** MSG91 send-SMS endpoint. */ @Value("${mosip.kernel.sms.api}") String api; + /** Registered MSG91 sender id. */ @Value("${mosip.kernel.sms.sender}") String sender; + /** Optional vendor password (unused by current query-param flow). */ @Value("${mosip.kernel.sms.password:null}") private String password; + /** MSG91 route id. */ @Value("${mosip.kernel.sms.route:null}") String route; + /** MSG91 auth key. */ @Value("${mosip.kernel.sms.authkey:null}") String authkey; + /** Unicode flag sent to MSG91 ({@code 1} = unicode). */ @Value("${mosip.kernel.sms.unicode:1}") String unicode; + /** Phone regex from MOSIP identity validation config. */ @Value("${mosip.id.validation.identity.phone}") private String phoneRegex; + /** + * Sends {@code message} to {@code contactNumber} via MSG91. + * + * @param contactNumber destination MSISDN (validated) + * @param message SMS body; {@code #} is encoded for the query string + * @return vendor-agnostic MOSIP {@link SMSResponseDto} + */ @Override public SMSResponseDto sendSms(String contactNumber, String message) { SMSResponseDto smsResponseDTO = new SMSResponseDto(); validateInput(contactNumber); - UriComponentsBuilder sms = UriComponentsBuilder.fromHttpUrl(api) + UriComponentsBuilder sms = UriComponentsBuilder.fromUriString(api) .queryParam(SmsPropertyConstant.AUTH_KEY.getProperty(), authkey) .queryParam(SmsPropertyConstant.SMS_MESSAGE.getProperty(), message.replaceAll("\\#", "%23")) .queryParam(SmsPropertyConstant.ROUTE.getProperty(), route) @@ -88,6 +111,11 @@ public SMSResponseDto sendSms(String contactNumber, String message) { return smsResponseDTO; } + /** + * Rejects numbers that fail {@link #phoneValidator(String)}. + * + * @param contactNumber candidate MSISDN + */ private void validateInput(String contactNumber) { if (!phoneValidator(contactNumber)) { throw new InvalidNumberException(SmsExceptionConstant.SMS_INVALID_CONTACT_NUMBER.getErrorCode(), @@ -95,6 +123,10 @@ private void validateInput(String contactNumber) { } } + /** + * @param phone candidate number + * @return {@code true} if {@code phone} matches {@code mosip.id.validation.identity.phone} + */ public boolean phoneValidator(String phone) { return phone.matches(phoneRegex); } diff --git a/kernel/kernel-smsserviceprovider-msg91/src/test/java/io/mosip/kernel/smsserviceprovider/msg91/test/SmsServiceProviderTest.java b/kernel/kernel-smsserviceprovider-msg91/src/test/java/io/mosip/kernel/smsserviceprovider/msg91/test/SmsServiceProviderTest.java index 38fd7e5fc28..87d3c8a2356 100644 --- a/kernel/kernel-smsserviceprovider-msg91/src/test/java/io/mosip/kernel/smsserviceprovider/msg91/test/SmsServiceProviderTest.java +++ b/kernel/kernel-smsserviceprovider-msg91/src/test/java/io/mosip/kernel/smsserviceprovider/msg91/test/SmsServiceProviderTest.java @@ -8,7 +8,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.boot.test.context.ConfigDataApplicationContextInitializer; -import org.springframework.boot.test.mock.mockito.MockBean; +import org.springframework.test.context.bean.override.mockito.MockitoBean; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.context.support.PropertySourcesPlaceholderConfigurer; @@ -45,7 +45,7 @@ public PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderConfigurer @Autowired SMSServiceProviderImpl service; - @MockBean + @MockitoBean RestTemplate restTemplate; @Value("${mosip.kernel.sms.api}") @@ -72,7 +72,7 @@ public PropertySourcesPlaceholderConfigurer propertySourcesPlaceholderConfigurer @Test public void sendSmsTest() { - UriComponentsBuilder sms = UriComponentsBuilder.fromHttpUrl(api) + UriComponentsBuilder sms = UriComponentsBuilder.fromUriString(api) .queryParam(SmsPropertyConstant.AUTH_KEY.getProperty(), authkey) .queryParam(SmsPropertyConstant.SMS_MESSAGE.getProperty(), "your otp is 4646") .queryParam(SmsPropertyConstant.ROUTE.getProperty(), route) @@ -114,7 +114,26 @@ public void contactNumberMaximumThresholdTest() { @Test public void validGateWayTest() { - service.sendSms(phone, "hello your otp is 45373"); + when(restTemplate.getForEntity(Mockito.anyString(), Mockito.eq(String.class))) + .thenReturn(new ResponseEntity<>("ok", HttpStatus.OK)); + SMSResponseDto dto = service.sendSms(phone, "hello your otp is 45373"); + org.junit.Assert.assertEquals("success", dto.getStatus()); + org.junit.Assert.assertEquals("Sms Request Sent", dto.getMessage()); + } + + @Test + public void sendSmsEncodesHashAndSucceeds() { + when(restTemplate.getForEntity(Mockito.anyString(), Mockito.eq(String.class))) + .thenReturn(new ResponseEntity<>("ok", HttpStatus.OK)); + SMSResponseDto dto = service.sendSms(phone, "otp # 1234"); + org.junit.Assert.assertEquals("success", dto.getStatus()); + } + + @Test(expected = RuntimeException.class) + public void sendSmsPropagatesVendorHttpError() { + when(restTemplate.getForEntity(Mockito.anyString(), Mockito.eq(String.class))) + .thenThrow(new org.springframework.web.client.HttpClientErrorException(HttpStatus.BAD_REQUEST, "bad")); + service.sendSms(phone, "hello"); } } \ No newline at end of file diff --git a/kernel/kernel-virusscanner-clamav/AGENTS.md b/kernel/kernel-virusscanner-clamav/AGENTS.md new file mode 100644 index 00000000000..d56ed822ab1 --- /dev/null +++ b/kernel/kernel-virusscanner-clamav/AGENTS.md @@ -0,0 +1,21 @@ +# kernel-virusscanner-clamav + +`VirusScanner` (`ScanResult.OK` / `VirusFound`). Auto-config: `spring.factories`. Pins in `kernel/pom.xml`. + +``` +kernel-virusscanner-clamav/ +├── pom.xml README.md docs/av.md AGENTS.md +└── src/ + ├── main/ + │ ├── java/io/mosip/kernel/virusscanner/clamav/ + │ │ ├── impl/VirusScannerImpl.java + │ │ └── constant/VirusScannerErrorCodes.java + │ └── resources/ + │ ├── META-INF/spring.factories + │ └── logback.xml + └── test/ + ├── java/.../clamav/test/ + │ ├── VirusScannerServiceTest.java + │ └── VirusScannerExceptionTest.java + └── resources/ application.properties logback.xml files/test1.docx +``` diff --git a/kernel/kernel-virusscanner-clamav/README.md b/kernel/kernel-virusscanner-clamav/README.md index f3448f3b663..242520ab8ed 100644 --- a/kernel/kernel-virusscanner-clamav/README.md +++ b/kernel/kernel-virusscanner-clamav/README.md @@ -1,20 +1,24 @@ -## Kernel Virus Scanner - ClamAV - -## Overview - -By default MOSIP bundles the [ClamAV](https://www.clamav.net/) virus scanner. - -To integrate your virus scanner, see [Integrating Virus Scanner](docs/av.md) - - - - - +# Kernel Virus Scanner — ClamAV +Reference `VirusScanner` using [ClamAV](https://www.clamav.net/) via `xyz.capybara:clamav-client` **2.1.2**. +- **Artifact**: `io.mosip.kernel:kernel-virusscanner-clamav:1.4.1-SNAPSHOT` +- **Parent**: `kernel-ref-parent` (Boot **4.1.1**) +- **Logging**: `kernel-core` (commons) +- **Config**: `mosip.kernel.virus-scanner.host`, `mosip.kernel.virus-scanner.port` +To integrate another scanner, see [Integrating Virus Scanner](docs/av.md). +## Build +```text +cd kernel +mvn -pl kernel-virusscanner-clamav clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn -pl kernel-virusscanner-clamav clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` +JaCoCo LINE covered ratio **0.90**. Scan API: `ScanResult.OK` / `VirusFound` (clamav-client 2.1.2). +## License +[Mozilla Public License 2.0](../../LICENSE) — [NOTICE](../../NOTICE) diff --git a/kernel/kernel-virusscanner-clamav/pom.xml b/kernel/kernel-virusscanner-clamav/pom.xml index 5c7cd35e129..8c337e38b88 100644 --- a/kernel/kernel-virusscanner-clamav/pom.xml +++ b/kernel/kernel-virusscanner-clamav/pom.xml @@ -1,64 +1,41 @@ + 4.0.0 - io.mosip.kernel io.mosip.kernel kernel-ref-parent - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT kernel-virusscanner-clamav - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT kernel-virusscanner-clamav - - 3.3.0 - 1.0.4 - 0.11.0 - + + Reference VirusScanner SPI using ClamAV (clamav-client 2.1.2). + kernel-core (commons) supplies logging; do not add kernel-logger-logback. + + io.mosip.kernel kernel-core - ${kernel-core.version} - - - com.fasterxml.jackson.datatype - jackson-datatype-jsr310 - - - + xyz.capybara clamav-client - ${clamav.client.version} - - - org.junit.vintage - junit-vintage-engine - ${junit.vintage.version} - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - + - org.apache.maven.plugins maven-assembly-plugin - ${maven-assembly-plugin.version} + ${maven.assembly.plugin.version} jar-with-dependencies @@ -75,143 +52,6 @@ - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - - - org.apache.maven.plugins - maven-source-plugin - true - ${maven.source.plugin.version} - - - attach-sources - - jar-no-fork - - - - - - - org.apache.maven.plugins - maven-compiler-plugin - ${maven.compiler.version} - - ${maven.compiler.source} - ${maven.compiler.target} - - - - org.apache.maven.plugins - maven-javadoc-plugin - ${maven.javadoc.plugin.version} - - - attach-javadocs - - jar - - - - - none - src/main/java - - - - org.apache.maven.plugins - maven-gpg-plugin - ${maven.gpg.plugin.version} - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - ${git.commit.plugin.version} - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - - - org.jacoco - jacoco-maven-plugin - ${maven.jacoco.plugin.version} - - - **/constant/** - **/config/** - **/dto/** - io/mosip/authentication/service/*.class - io/mosip/authentication/service/filter/** - - - - - - prepare-agent - - - - report - prepare-package - - report - - - - - - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - ${skipTests} - false - - ${argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --illegal-access=permit - - - - - +
diff --git a/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/constant/VirusScannerErrorCodes.java b/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/constant/VirusScannerErrorCodes.java index 74fad8211e5..45125e16480 100644 --- a/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/constant/VirusScannerErrorCodes.java +++ b/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/constant/VirusScannerErrorCodes.java @@ -4,16 +4,24 @@ * Internal Packet virus scan error codes. * */ +/** + * MOSIP error codes for ClamAV connectivity and missing scan files. + */ public class VirusScannerErrorCodes { + /** Packet virus-scan prefix. */ private static final String IIS_EPP_EPV_PREFIX = "IIS_"; + /** Prevents instantiation. */ private VirusScannerErrorCodes() { throw new IllegalStateException("Utility class"); } + /** Generic module prefix. */ private static final String IIS_EPP_EPV_PREFIX_GEN_MODULE = IIS_EPP_EPV_PREFIX + "GEN_"; + /** ClamAV daemon unreachable. */ public static final String IIS_EPP_EPV_SERVICE_NOT_ACCESSIBLE = IIS_EPP_EPV_PREFIX_GEN_MODULE + "ANTIVIRUS_SERVICE_NOT_ACCESSIBLE"; + /** File path does not exist. */ public static final String IIS_EPP_EPV_FILE_NOT_PRESENT = IIS_EPP_EPV_PREFIX_GEN_MODULE + "FILE_NOT_PRESENT_FOR_SCAN"; } diff --git a/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/impl/VirusScannerImpl.java b/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/impl/VirusScannerImpl.java index 960b675e558..9753f0c973a 100644 --- a/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/impl/VirusScannerImpl.java +++ b/kernel/kernel-virusscanner-clamav/src/main/java/io/mosip/kernel/virusscanner/clamav/impl/VirusScannerImpl.java @@ -18,13 +18,18 @@ import io.mosip.kernel.core.virusscanner.spi.VirusScanner; import io.mosip.kernel.virusscanner.clamav.constant.VirusScannerErrorCodes; import xyz.capybara.clamav.ClamavClient; +import xyz.capybara.clamav.ClamavException; import xyz.capybara.clamav.commands.scan.result.ScanResult; -import xyz.capybara.clamav.commands.scan.result.ScanResult.Status; -import xyz.capybara.clamav.exceptions.ClamavException; -// TODO: Auto-generated Javadoc /** - * The implementation Class for VirusScannerService. + * ClamAV implementation of {@link VirusScanner}{@code }. + *

+ * Connects lazily to {@code mosip.kernel.virus-scanner.host} / + * {@code mosip.kernel.virus-scanner.port}. A scan returns {@link Boolean#TRUE} + * when {@link ScanResult.OK} is received, otherwise {@link Boolean#FALSE} and a + * warning is logged. Unreachable daemon or missing files become + * {@link VirusScannerException}. + *

* * @author Mukul Puspam * @author Pranav Kumar @@ -32,43 +37,42 @@ @Component public class VirusScannerImpl implements VirusScanner { - /** The Constant LOGGER. */ + /** Logger for scan warnings and ClamAV failures. */ private static final Logger LOGGER = LoggerFactory.getLogger(VirusScannerImpl.class); - /** The host. */ + /** ClamAV daemon hostname ({@code mosip.kernel.virus-scanner.host}). */ @Value("${mosip.kernel.virus-scanner.host}") private String host; - /** The port. */ + /** ClamAV daemon port ({@code mosip.kernel.virus-scanner.port}). */ @Value("${mosip.kernel.virus-scanner.port}") private int port; - /** The clamav client. */ + /** Lazily created ClamAV client; tests may assign a mock. */ protected ClamavClient clamavClient; - /** The Constant LOGDISPLAY. */ + /** SLF4J pattern {@code "{} - {}"} for exception messages. */ private static final String LOGDISPLAY = "{} - {}"; - /** The Constant ANTIVIRUS_SERVICE_NOT_ACCESSIBLE. */ + /** User-facing text when the daemon cannot be reached. */ private static final String ANTIVIRUS_SERVICE_NOT_ACCESSIBLE = "The anti virus service is not accessible"; - /** The Constant FILE_NOT_PRESENT. */ + /** User-facing text when the scan path does not exist. */ private static final String FILE_NOT_PRESENT = "The file not found for for scanning"; /** - * Creates the connection to client. + * Creates {@link #clamavClient} if it is still {@code null}. */ public void createConnection() { if (this.clamavClient == null) this.clamavClient = new ClamavClient(host, port); } - /* - * (non-Javadoc) - * - * @see - * org.mosip.idissuance.virus.scanner.service.VirusScannerService#scanFile(java. - * lang.Object) + /** + * Scans a file on disk by path. + * + * @param fileName absolute or relative path + * @return {@code true} if ClamAV reports OK */ @Override public Boolean scanFile(String fileName) { @@ -83,10 +87,10 @@ public Boolean scanFile(String fileName) { } try { ScanResult scanResult = this.clamavClient.scan(is); - if (scanResult.getStatus() == Status.OK) { + if (scanResult instanceof ScanResult.OK) { result = Boolean.TRUE; } else { - Map> listOfVirus = scanResult.getFoundViruses(); + Map> listOfVirus = foundViruses(scanResult); LOGGER.warn("Virus Found in file " + fileName + ": ", listOfVirus); } } catch (ClamavException e) { @@ -97,11 +101,11 @@ public Boolean scanFile(String fileName) { return result; } - /* - * (non-Javadoc) - * - * @see io.mosip.kernel.core.virusscanner.spi.VirusScanner#scanFile(java.io. - * InputStream) + /** + * Scans an already opened stream (caller owns the stream). + * + * @param is document bytes + * @return {@code true} if ClamAV reports OK */ @Override public Boolean scanFile(InputStream is) { @@ -109,10 +113,10 @@ public Boolean scanFile(InputStream is) { createConnection(); try { ScanResult scanResult = this.clamavClient.scan(is); - if (scanResult.getStatus() == Status.OK) { + if (scanResult instanceof ScanResult.OK) { result = Boolean.TRUE; } else { - Map> listOfVirus = scanResult.getFoundViruses(); + Map> listOfVirus = foundViruses(scanResult); LOGGER.warn("Virus Found in file : " + listOfVirus); } } catch (ClamavException e) { @@ -122,12 +126,11 @@ public Boolean scanFile(InputStream is) { return result; } - /* - * (non-Javadoc) - * - * @see - * org.mosip.idissuance.virus.scanner.service.VirusScannerService#scanFolder( - * java.lang.Object) + /** + * Scans every file in a directory (non-recursive {@link File#listFiles()}). + * + * @param folderPath directory path + * @return {@code true} if every file is OK; {@code false} on first infection */ @Override public Boolean scanFolder(String folderPath) { @@ -139,7 +142,7 @@ public Boolean scanFolder(String folderPath) { for (File file : files) { try { ScanResult scanResult = this.clamavClient.scan(new FileInputStream(file)); - if (scanResult.getStatus() != Status.OK) { + if (!(scanResult instanceof ScanResult.OK)) { result = Boolean.FALSE; break; } @@ -155,14 +158,12 @@ public Boolean scanFolder(String folderPath) { } /** - * This Method is used to scan byte array - * - * @param docArray array - * - * @return a true if file is virus free and false if file is infected - * @throws IOException Signals that an I/O exception has occurred. + * Scans an in-memory document. + * + * @param docArray raw bytes + * @return {@code true} if virus-free + * @throws IOException if the byte stream cannot be closed */ - @Override public Boolean scanDocument(byte[] docArray) throws IOException { Boolean result = Boolean.FALSE; @@ -172,10 +173,10 @@ public Boolean scanDocument(byte[] docArray) throws IOException { try { ScanResult scanResult = this.clamavClient.scan(docInputStream); - if (scanResult.getStatus() == Status.OK) { + if (scanResult instanceof ScanResult.OK) { result = Boolean.TRUE; } else { - Map> listOfVirus = scanResult.getFoundViruses(); + Map> listOfVirus = foundViruses(scanResult); LOGGER.warn("Virus Found in file " + docInputStream + ": ", listOfVirus); } } catch (ClamavException e) { @@ -191,12 +192,11 @@ public Boolean scanDocument(byte[] docArray) throws IOException { } /** - * This Method is used to scan File - * - * @param doc object - * - * @return a true if file is virus free and false if file is infected - * @throws IOException Signals that an I/O exception has occurred. + * Scans a {@link File} using a try-with-resources {@link FileInputStream}. + * + * @param doc file on disk + * @return {@code true} if virus-free + * @throws IOException if the file cannot be read */ @Override public Boolean scanDocument(File doc) throws IOException { @@ -206,10 +206,10 @@ public Boolean scanDocument(File doc) throws IOException { try (FileInputStream docInputStream = new FileInputStream(doc)) { ScanResult scanResult = this.clamavClient.scan(docInputStream); - if (scanResult.getStatus() == Status.OK) { + if (scanResult instanceof ScanResult.OK) { result = Boolean.TRUE; } else { - Map> listOfVirus = scanResult.getFoundViruses(); + Map> listOfVirus = foundViruses(scanResult); LOGGER.warn("Virus Found in file " + doc + ": ", listOfVirus); } } catch (ClamavException e) { @@ -221,4 +221,17 @@ public Boolean scanDocument(File doc) throws IOException { return result; } + /** + * Extracts the virus map from a {@link ScanResult.VirusFound} result. + * + * @param scanResult ClamAV scan outcome + * @return found signatures, or an empty map if the result is not VirusFound + */ + private static Map> foundViruses(ScanResult scanResult) { + if (scanResult instanceof ScanResult.VirusFound found) { + return found.getFoundViruses(); + } + return Map.of(); + } + } diff --git a/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerExceptionTest.java b/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerExceptionTest.java index dc5cd2b647f..95ee1a6924f 100644 --- a/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerExceptionTest.java +++ b/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerExceptionTest.java @@ -22,7 +22,7 @@ import io.mosip.kernel.core.virusscanner.spi.VirusScanner; import io.mosip.kernel.virusscanner.clamav.impl.VirusScannerImpl; import xyz.capybara.clamav.ClamavClient; -import xyz.capybara.clamav.exceptions.ClamavException; +import xyz.capybara.clamav.ClamavException; /** * @@ -82,4 +82,23 @@ public void serviceUnavailableForScanDocumentTest() throws ClamavException, IOEx Mockito.doThrow(ClamavException.class).when(clamavClient).scan(any(FileInputStream.class)); virusScannerService.scanDocument(doc); } + + @Test(expected = VirusScannerException.class) + public void serviceUnavailableForScanFileInputStreamTest() throws ClamavException, FileNotFoundException { + Mockito.doThrow(ClamavException.class).when(clamavClient).scan(any(InputStream.class)); + virusScannerService.scanFile(new FileInputStream(file)); + } + + @Test(expected = VirusScannerException.class) + public void missingFileForScanFolderTest() throws IOException { + File tmp = java.nio.file.Files.createTempDirectory("clamav-scan").toFile(); + File nestedDir = new File(tmp, "nested"); + nestedDir.mkdir(); + try { + virusScannerService.scanFolder(tmp.getAbsolutePath()); + } finally { + nestedDir.delete(); + tmp.delete(); + } + } } diff --git a/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerServiceTest.java b/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerServiceTest.java index 117e7adcd15..162d751c5db 100644 --- a/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerServiceTest.java +++ b/kernel/kernel-virusscanner-clamav/src/test/java/io/mosip/kernel/virusscanner/clamav/test/VirusScannerServiceTest.java @@ -22,10 +22,12 @@ import io.mosip.kernel.core.virusscanner.spi.VirusScanner; import io.mosip.kernel.virusscanner.clamav.impl.VirusScannerImpl; +import java.util.List; +import java.util.Map; + import xyz.capybara.clamav.ClamavClient; +import xyz.capybara.clamav.ClamavException; import xyz.capybara.clamav.commands.scan.result.ScanResult; -import xyz.capybara.clamav.commands.scan.result.ScanResult.Status; -import xyz.capybara.clamav.exceptions.ClamavException; /** * @@ -63,8 +65,8 @@ public void setup() throws FileNotFoundException { file = new File(classLoader.getResource("files/0000.zip").getFile()); is = new FileInputStream(file); folder = new File(classLoader.getResource("files").getFile()); - virusNotFound = new ScanResult(Status.OK); - virusFound = new ScanResult(Status.VIRUS_FOUND); + virusNotFound = ScanResult.OK.INSTANCE; + virusFound = new ScanResult.VirusFound(Map.of("eicar", List.of("EICAR-Test-File"))); doc = new File(classLoader.getResource("files/test1.docx").getFile()); byteArray = new byte[(int) doc.length()]; } @@ -140,4 +142,17 @@ public void InfectedDocumentCheck() throws ClamavException, IOException { Boolean result = virusScanner.scanDocument(doc); assertEquals(Boolean.FALSE, result); } + + @Test + public void createConnectionIsIdempotent() { + VirusScannerImpl impl = new VirusScannerImpl(); + org.springframework.test.util.ReflectionTestUtils.setField(impl, "host", "127.0.0.1"); + org.springframework.test.util.ReflectionTestUtils.setField(impl, "port", 3310); + impl.createConnection(); + Object first = org.springframework.test.util.ReflectionTestUtils.getField(impl, "clamavClient"); + impl.createConnection(); + Object second = org.springframework.test.util.ReflectionTestUtils.getField(impl, "clamavClient"); + org.junit.Assert.assertNotNull(first); + org.junit.Assert.assertSame(first, second); + } } diff --git a/kernel/pom.xml b/kernel/pom.xml index 7e44580e6de..1e3322b6d71 100644 --- a/kernel/pom.xml +++ b/kernel/pom.xml @@ -3,254 +3,413 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + + + org.springframework.boot + spring-boot-starter-parent + 4.1.1 + + + io.mosip.kernel kernel-ref-parent - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT pom kernel - Parent project of MOSIP Kernel Referernce Implementation components + + Parent of MOSIP kernel reference implementations (id object validator, MSG91 SMS, ClamAV). + Boot 4.1.1, Java 21, no kernel-bom. MOSIP kernel jars pinned here. + https://github.com/mosip/mosip-ref-impl - - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - - - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - Mosip - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip/mosip-ref-impl - - - - - - ossrh-central - MavenCentralRepository - https://central.sonatype.com/repository/maven-snapshots - default - - true - - - - central - MavenCentral - default - https://repo1.maven.org/maven2 - - false - - - - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - - - - UTF-8 - + + kernel-ref-idobjectvalidator + kernel-virusscanner-clamav + kernel-smsserviceprovider-msg91 + + + + 21 21 21 - 3.8.0 - 3.0.2 - 3.1.0 - 2.22.0 - 0.8.11 - 3.7.0.1746 - 3.2.0 - 2.3 - 2.8.1 - 2.2.1 - 1.5 + + false + + 3.16.0 + 3.5.1 + 3.5.1 + 3.6.0 + 0.8.15 + 5.8.0.7211 + 3.12.0 + 3.2.0 + 3.4.0 + 3.2.8 + 4.9.10 0.11.0 - 3.0.1 + 3.8.0 + + + + + 1.4.1-SNAPSHOT + 1.4.1-SNAPSHOT + 2025.1.3 + + 4.6.0 + 2.1.2 + 2.10.0 + 2.6.0 + 2.3.9 + 2.3.1 - - 1.7.25 - - 1.3.1-rc.1 - - 5.10.2 - **/constant/**,**/config/**,**/httpfilter/**,**/cache/**,**/dto/**,**/entity/**,**/model/**,**/exception/**,**/repository/**,**/security/**,**/*Config.java,**/*BootApplication.java,**/*VertxApplication.java,**/cbeffutil/** **/dto/**,**/entity/**,**/config/** + ${project.build.directory}/site/jacoco/jacoco.xml + + 0.90 - - kernel-ref-idobjectvalidator - kernel-virusscanner-clamav - kernel-smsserviceprovider-msg91 - + + + + + org.springframework.cloud + spring-cloud-dependencies + ${spring-cloud.version} + pom + import + + + + io.mosip.kernel + kernel-core + ${kernel.core.version} + + + + io.mosip.kernel + kernel-auth-adapter + ${kernel.auth.adapter.version} + + + + org.apache.commons + commons-collections4 + ${commons-collections4.version} + + + + com.jayway.jsonpath + json-path + ${json-path.version} + + + + net.minidev + json-smart + ${json-smart.version} + + + + xyz.capybara + clamav-client + ${clamav.client.version} + + + + javax.xml.bind + jaxb-api + ${jaxb-api-version} + + + + org.glassfish.jaxb + jaxb-runtime + ${jaxb.runtime.version} + + + + + + org.springframework.boot + spring-boot-jackson2 + + - org.slf4j - jul-to-slf4j - ${jcl.to.slf4j.version} + org.springframework.boot + spring-boot-starter-test + test + - org.slf4j - jcl-over-slf4j - ${jcl.to.slf4j.version} + org.junit.vintage + junit-vintage-engine + test + + + + org.projectlombok + lombok + provided + + + ossrh + https://central.sonatype.com/repository/maven-snapshots/ + + + ossrh + https://central.sonatype.com/api/v1/publisher + + + + - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - ${skipTests} - false - - ${argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --illegal-access=permit - - - - - org.jacoco - jacoco-maven-plugin - ${maven.jacoco.plugin.version} - - - - prepare-agent - - - - report - prepare-package - - report - - - - - - org.apache.maven.plugins - maven-compiler-plugin - ${maven.compiler.version} - - ${maven.compiler.source} - ${maven.compiler.target} - - - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - + org.sonarsource.scanner.maven + sonar-maven-plugin + ${maven.sonar.plugin.version} - - org.apache.maven.plugins - maven-source-plugin - ${maven.source.plugin.version} - - - attach-sources - - jar-no-fork - - - - + + + + + org.sonatype.central + central-publishing-maven-plugin + ${central.publishing.maven.plugin.version} + true + + ossrh + false + + + + org.apache.maven.plugins + maven-surefire-plugin + ${maven.surefire.plugin.version} + + ${skipTests} + false + @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.lang.reflect=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.util.concurrent=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED + + + + org.jacoco + jacoco-maven-plugin + ${maven.jacoco.version} + + + **/constant/** + **/config/** + **/httpfilter/** + **/cache/** + **/dto/** + **/entity/** + **/model/** + **/exception/** + **/repository/** + **/security/** + **/*Config.class + **/*BootApplication.class + **/*VertxApplication.class + **/cbeffutil/** + + + + + + prepare-agent + + + + report + prepare-package + + report + + + + jacoco-check + + check + + + + + BUNDLE + + + LINE + COVEREDRATIO + ${jacoco.minimum.coverage} + + + + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + ${maven.compiler.plugin.version} + + ${java.version} + true + + + org.projectlombok + lombok + ${lombok.version} + + + + + + org.apache.maven.plugins + maven-source-plugin + ${maven.source.plugin.version} + + + attach-sources + + jar-no-fork + + + + org.apache.maven.plugins maven-javadoc-plugin - ${maven.javadoc.plugin.version} + ${maven.javadoc.version} - - attach-javadocs - - jar - - - + + attach-javadocs + + jar + + + - true none + false + false - - - org.apache.maven.plugins - maven-gpg-plugin - ${maven.gpg.plugin.version} - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - ${git.commit.plugin.version} - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - - + true + ${project.build.outputDirectory}/service-git.properties + + ^git.build.(time|version)$ + ^git.commit.id.(abbrev|full)$ + + full + ${project.basedir}/.git + + + + org.apache.maven.plugins + maven-jar-plugin + ${maven.jar.plugin.version} - true + + + true + true + + + ${project.name} + ${project.version} + + ---> + + org.apache.maven.plugins + maven-deploy-plugin + ${maven.deploy.plugin.version} + + + sonar @@ -268,7 +427,6 @@ org.sonarsource.scanner.maven sonar-maven-plugin - ${maven.sonar.plugin.version} verify @@ -282,4 +440,40 @@ + + + + ossrh + Central Snapshots + https://central.sonatype.com/repository/maven-snapshots/ + + false + + + true + + + + + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + repo + + + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MOSIP + mosip.emailnotifier@gmail.com + io.mosip + https://github.com/mosip + + diff --git a/keycloak/AGENTS.md b/keycloak/AGENTS.md new file mode 100644 index 00000000000..dfe743c9846 --- /dev/null +++ b/keycloak/AGENTS.md @@ -0,0 +1,10 @@ +# keycloak + +Theme overlay only. Empty `standalone/deployments/`. + +``` +keycloak/ +├── AGENTS.md +├── standalone/deployments/ +└── theme/base/login/register.ftl +``` diff --git a/keycloak/README.md b/keycloak/README.md new file mode 100644 index 00000000000..a2983dbd254 --- /dev/null +++ b/keycloak/README.md @@ -0,0 +1,16 @@ +# Keycloak theme (reference) + +Reference Keycloak **login** theme for MOSIP (FreeMarker under `theme/base/login/`). + +This is not a Maven module. Overlay or copy the `theme/` tree into your Keycloak distribution as documented for [MOSIP Keycloak](https://docs.mosip.io/1.2.0/id-lifecycle-management/supporting-components/keycloak). + +```text +keycloak/ +└── theme/base/login/ login FTL, messages, resources +``` + +Upstream Keycloak images and MOSIP customizations: [github.com/mosip/keycloak](https://github.com/mosip/keycloak/tree/master). + +## License + +[Mozilla Public License 2.0](../LICENSE) diff --git a/licenses/0BSD.txt b/licenses/0BSD.txt new file mode 100644 index 00000000000..0b8ae762b24 --- /dev/null +++ b/licenses/0BSD.txt @@ -0,0 +1,5 @@ +Copyright (C) YEAR by AUTHOR EMAIL + +Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/licenses/AFL-2.1.txt b/licenses/AFL-2.1.txt new file mode 100644 index 00000000000..bb97914cfc2 --- /dev/null +++ b/licenses/AFL-2.1.txt @@ -0,0 +1,197 @@ +The Academic Free License +v. 2.1 + +This Academic Free License (the "License") applies to any original work of authorship (the "Original Work") whose owner (the "Licensor") has placed the following notice immediately following the copyright notice for the Original Work: + +Licensed under the Academic Free License version 2.1 + +1) Grant of Copyright License. Licensor hereby grants You a +world-wide, royalty-free, non-exclusive, perpetual, sublicenseable +license to do the following: + +a) to reproduce the Original Work in copies; + +b) to prepare derivative works ("Derivative Works") based upon the Original Work; + +c) to distribute copies of the Original Work and Derivative Works to the public; + +d) to perform the Original Work publicly; and + +e) to display the Original Work publicly. + +2) Grant of Patent License. Licensor hereby grants You a world-wide, +royalty-free, non-exclusive, perpetual, sublicenseable license, under +patent claims owned or controlled by the Licensor that are embodied in +the Original Work as furnished by the Licensor, to make, use, sell and +offer for sale the Original Work and Derivative Works. + +3) Grant of Source Code License. The term "Source Code" means the +preferred form of the Original Work for making modifications to it and +all available documentation describing how to modify the Original +Work. Licensor hereby agrees to provide a machine-readable copy of the +Source Code of the Original Work along with each copy of the Original +Work that Licensor distributes. Licensor reserves the right to satisfy +this obligation by placing a machine-readable copy of the Source Code +in an information repository reasonably calculated to permit +inexpensive and convenient access by You for as long as Licensor +continues to distribute the Original Work, and by publishing the +address of that information repository in a notice immediately +following the copyright notice that applies to the Original Work. + +4) Exclusions From License Grant. Neither the names of Licensor, nor +the names of any contributors to the Original Work, nor any of their +trademarks or service marks, may be used to endorse or promote +products derived from this Original Work without express prior written +permission of the Licensor. Nothing in this License shall be deemed to +grant any rights to trademarks, copyrights, patents, trade secrets or +any other intellectual property of Licensor except as expressly stated +herein. No patent license is granted to make, use, sell or offer to +sell embodiments of any patent claims other than the licensed claims +defined in Section 2. No right is granted to the trademarks of +Licensor even if such marks are included in the Original Work. Nothing +in this License shall be interpreted to prohibit Licensor from +licensing under different terms from this License any Original Work +that Licensor otherwise would have a right to license. + +5) This section intentionally omitted. + +6) Attribution Rights. You must retain, in the Source Code of any +Derivative Works that You create, all copyright, patent or trademark +notices from the Source Code of the Original Work, as well as any +notices of licensing and any descriptive text identified therein as an +"Attribution Notice." You must cause the Source Code for any +Derivative Works that You create to carry a prominent Attribution +Notice reasonably calculated to inform recipients that You have +modified the Original Work. + +7) Warranty of Provenance and Disclaimer of Warranty. Licensor +warrants that the copyright in and to the Original Work and the patent +rights granted herein by Licensor are owned by the Licensor or are +sublicensed to You under the terms of this License with the permission +of the contributor(s) of those copyrights and patent rights. Except as +expressly stated in the immediately proceeding sentence, the Original +Work is provided under this License on an "AS IS" BASIS and WITHOUT +WARRANTY, either express or implied, including, without limitation, +the warranties of NON-INFRINGEMENT, MERCHANTABILITY or FITNESS FOR A +PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY OF THE ORIGINAL +WORK IS WITH YOU. This DISCLAIMER OF WARRANTY constitutes an essential +part of this License. No license to Original Work is granted hereunder +except under this disclaimer. + +8) Limitation of Liability. Under no circumstances and under no legal +theory, whether in tort (including negligence), contract, or +otherwise, shall the Licensor be liable to any person for any direct, +indirect, special, incidental, or consequential damages of any +character arising as a result of this License or the use of the +Original Work including, without limitation, damages for loss of +goodwill, work stoppage, computer failure or malfunction, or any and +all other commercial damages or losses. This limitation of liability +shall not apply to liability for death or personal injury resulting +from Licensor's negligence to the extent applicable law prohibits such +limitation. Some jurisdictions do not allow the exclusion or +limitation of incidental or consequential damages, so this exclusion +and limitation may not apply to You. + +9) Acceptance and Termination. If You distribute copies of the +Original Work or a Derivative Work, You must make a reasonable effort +under the circumstances to obtain the express assent of recipients to +the terms of this License. Nothing else but this License (or another +written agreement between Licensor and You) grants You permission to +create Derivative Works based upon the Original Work or to exercise +any of the rights granted in Section 1 herein, and any attempt to do +so except under the terms of this License (or another written +agreement between Licensor and You) is expressly prohibited by +U.S. copyright law, the equivalent laws of other countries, and by +international treaty. Therefore, by exercising any of the rights +granted to You in Section 1 herein, You indicate Your acceptance of +this License and all of its terms and conditions. + +10) Termination for Patent Action. This License shall terminate +automatically and You may no longer exercise any of the rights granted +to You by this License as of the date You commence an action, +including a cross-claim or counterclaim, against Licensor or any +licensee alleging that the Original Work infringes a patent. This +termination provision shall not apply for an action alleging patent +infringement by combinations of the Original Work with other software +or hardware. + +11) Jurisdiction, Venue and Governing Law. Any action or suit relating +to this License may be brought only in the courts of a jurisdiction +wherein the Licensor resides or in which Licensor conducts its primary +business, and under the laws of that jurisdiction excluding its +conflict-of-law provisions. The application of the United Nations +Convention on Contracts for the International Sale of Goods is +expressly excluded. Any use of the Original Work outside the scope of +this License or after its termination shall be subject to the +requirements and penalties of the U.S. Copyright Act, 17 U.S.C. § 101 +et seq., the equivalent laws of other countries, and international +treaty. This section shall survive the termination of this License. + +12) Attorneys Fees. In any action to enforce the terms of this License +or seeking damages relating thereto, the prevailing party shall be +entitled to recover its costs and expenses, including, without +limitation, reasonable attorneys' fees and costs incurred in +connection with such action, including any appeal of such action. This +section shall survive the termination of this License. + +13) Miscellaneous. This License represents the complete agreement +concerning the subject matter hereof. If any provision of this License +is held to be unenforceable, such provision shall be reformed only to +the extent necessary to make it enforceable. + +14) Definition of "You" in This License. "You" throughout this +License, whether in upper or lower case, means an individual or a +legal entity exercising rights under, and complying with all of the +terms of, this License. For legal entities, "You" includes any entity +that controls, is controlled by, or is under common control with +you. For purposes of this definition, "control" means (i) the power, +direct or indirect, to cause the direction or management of such +entity, whether by contract or otherwise, or (ii) ownership of fifty +percent (50%) or more of the outstanding shares, or (iii) beneficial +ownership of such entity. + +15) Right to Use. You may use the Original Work in all ways not +otherwise restricted or conditioned by this License or by law, and +Licensor promises not to interfere with or be responsible for such +uses by You. + +This license is Copyright (C) 2003-2004 Lawrence E. Rosen. All rights +reserved. Permission is hereby granted to copy and distribute this +license without modification. This license may not be modified without +the express written permission of its copyright owner. + + +-- +END OF ACADEMIC FREE LICENSE. The following is intended to describe the essential +differences between the Academic Free License (AFL) version 1.0 and other +open source licenses: + +The Academic Free License is similar to the BSD, MIT, UoI/NCSA and Apache +licenses in many respects but it is intended to solve a few problems with +those licenses. + +* The AFL is written so as to make it clear what software is being +licensed (by the inclusion of a statement following the copyright notice +in the software). This way, the license functions better than a template +license. The BSD, MIT and UoI/NCSA licenses apply to unidentified software. + +* The AFL contains a complete copyright grant to the software. The BSD +and Apache licenses are vague and incomplete in that respect. + +* The AFL contains a complete patent grant to the software. The BSD, MIT, +UoI/NCSA and Apache licenses rely on an implied patent license and contain +no explicit patent grant. + +* The AFL makes it clear that no trademark rights are granted to the +licensor's trademarks. The Apache license contains such a provision, but the +BSD, MIT and UoI/NCSA licenses do not. + +* The AFL includes the warranty by the licensor that it either owns the +copyright or that it is distributing the software under a license. None of +the other licenses contain that warranty. All other warranties are disclaimed, +as is the case for the other licenses. + +* The AFL is itself copyrighted (with the right granted to copy and distribute +without modification). This ensures that the owner of the copyright to the +license will control changes. The Apache license contains a copyright notice, +but the BSD, MIT and UoI/NCSA licenses do not. diff --git a/licenses/Apache-2.0.txt b/licenses/Apache-2.0.txt new file mode 100644 index 00000000000..d6456956733 --- /dev/null +++ b/licenses/Apache-2.0.txt @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/licenses/BSD-2-Clause.txt b/licenses/BSD-2-Clause.txt new file mode 100644 index 00000000000..64a0b64f59c --- /dev/null +++ b/licenses/BSD-2-Clause.txt @@ -0,0 +1,9 @@ +Copyright © 1997-present PostgreSQL Global Development Group + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/licenses/BSD-3-Clause-No-Nuclear-License.txt b/licenses/BSD-3-Clause-No-Nuclear-License.txt new file mode 100644 index 00000000000..07786caf7a9 --- /dev/null +++ b/licenses/BSD-3-Clause-No-Nuclear-License.txt @@ -0,0 +1,15 @@ +BSD-3-Clause-No-Nuclear-License +----------------------------------- +Copyright © 2005 Sun Microsystems, Inc. All Rights Reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + + * Redistribution of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + + * Redistribution in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + + * Neither the name of Sun Microsystems, Inc. or the names of contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +This software is provided "AS IS," without a warranty of any kind. ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE HEREBY EXCLUDED. SUN MICROSYSTEMS, INC. ("SUN") AND ITS LICENSORS SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES. IN NO EVENT WILL SUN OR ITS LICENSORS BE LIABLE FOR ANY LOST REVENUE, PROFIT OR DATA, OR FOR DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL OR PUNITIVE DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF THE USE OF OR INABILITY TO USE THIS SOFTWARE, EVEN IF SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +You acknowledge that this software is not designed, licensed or intended for use in the design, construction, operation or maintenance of any nuclear facility. diff --git a/licenses/BSD-3-Clause.txt b/licenses/BSD-3-Clause.txt new file mode 100644 index 00000000000..2f67e633dad --- /dev/null +++ b/licenses/BSD-3-Clause.txt @@ -0,0 +1,9 @@ +BSD-3-Clause +--------------------- +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/licenses/BlueOak-1.0.0.txt b/licenses/BlueOak-1.0.0.txt new file mode 100644 index 00000000000..c5402b9577a --- /dev/null +++ b/licenses/BlueOak-1.0.0.txt @@ -0,0 +1,55 @@ +# Blue Oak Model License + +Version 1.0.0 + +## Purpose + +This license gives everyone as much permission to work with +this software as possible, while protecting contributors +from liability. + +## Acceptance + +In order to receive this license, you must agree to its +rules. The rules of this license are both obligations +under that agreement and conditions to your license. +You must not do anything with this software that triggers +a rule that you cannot or will not follow. + +## Copyright + +Each contributor licenses you to do everything with this +software that would otherwise infringe that contributor's +copyright in it. + +## Notices + +You must ensure that everyone who gets a copy of +any part of this software from you, with or without +changes, also gets the text of this license or a link to +. + +## Excuse + +If anyone notifies you in writing that you have not +complied with [Notices](#notices), you can keep your +license by taking all practical steps to comply within 30 +days after the notice. If you do not do so, your license +ends immediately. + +## Patent + +Each contributor licenses you to do everything with this +software that would otherwise infringe any patent claims +they can license or become able to license. + +## Reliability + +No contributor can revoke this license. + +## No Liability + +***As far as the law allows, this software comes as is, +without any warranty or condition, and no contributor +will be liable to anyone for any damages related to this +software or this license, under any kind of legal claim.*** diff --git a/licenses/CDDL-1.0.txt b/licenses/CDDL-1.0.txt new file mode 100644 index 00000000000..2a5d7f18fca --- /dev/null +++ b/licenses/CDDL-1.0.txt @@ -0,0 +1,119 @@ +COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) +Version 1.0 + +1. Definitions. + +1.1. “Contributor” means each individual or entity that creates or contributes to the creation of Modifications. + +1.2. “Contributor Version” means the combination of the Original Software, prior Modifications used by a Contributor (if any), and the Modifications made by that particular Contributor. + +1.3. “Covered Software” means (a) the Original Software, or (b) Modifications, or (c) the combination of files containing Original Software with files containing Modifications, in each case including portions thereof. + +1.4. “Executable” means the Covered Software in any form other than Source Code. + +1.5. “Initial Developer” means the individual or entity that first makes Original Software available under this License. + +1.6. “Larger Work” means a work which combines Covered Software or portions thereof with code not governed by the terms of this License. + +1.7. “License” means this document. + +1.8. “Licensable” means having the right to grant, to the maximum extent possible, whether at the time of the initial grant or subsequently acquired, any and all of the rights conveyed herein. + +1.9. “Modifications” means the Source Code and Executable form of any of the following: + + A. Any file that results from an addition to, deletion from or modification of the contents of a file containing Original Software or previous Modifications; + + B. Any new file that contains any part of the Original Software or previous Modification; or + + C. Any new file that is contributed or otherwise made available under the terms of this License. + +1.10. “Original Software” means the Source Code and Executable form of computer software code that is originally released under this License. + +1.11. “Patent Claims” means any patent claim(s), now owned or hereafter acquired, including without limitation, method, process, and apparatus claims, in any patent Licensable by grantor. + +1.12. “Source Code” means (a) the common form of computer software code in which modifications are made and (b) associated documentation included in or with such code. + +1.13. “You” (or “Your”) means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License. For legal entities, “You” includes any entity which controls, is controlled by, or is under common control with You. For purposes of this definition, “control” means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of more than fifty percent (50%) of the outstanding shares or beneficial ownership of such entity. + +2. License Grants. + +2.1. The Initial Developer Grant. +Conditioned upon Your compliance with Section 3.1 below and subject to third party intellectual property claims, the Initial Developer hereby grants You a world-wide, royalty-free, non-exclusive license: + + (a) under intellectual property rights (other than patent or trademark) Licensable by Initial Developer, to use, reproduce, modify, display, perform, sublicense and distribute the Original Software (or portions thereof), with or without Modifications, and/or as part of a Larger Work; and + + (b) under Patent Claims infringed by the making, using or selling of Original Software, to make, have made, use, practice, sell, and offer for sale, and/or otherwise dispose of the Original Software (or portions thereof). + + (c) The licenses granted in Sections 2.1(a) and (b) are effective on the date Initial Developer first distributes or otherwise makes the Original Software available to a third party under the terms of this License. + + (d) Notwithstanding Section 2.1(b) above, no patent license is granted: (1) for code that You delete from the Original Software, or (2) for infringements caused by: (i) the modification of the Original Software, or (ii) the combination of the Original Software with other software or devices. + +2.2. Contributor Grant. +Conditioned upon Your compliance with Section 3.1 below and subject to third party intellectual property claims, each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license: + + (a) under intellectual property rights (other than patent or trademark) Licensable by Contributor to use, reproduce, modify, display, perform, sublicense and distribute the Modifications created by such Contributor (or portions thereof), either on an unmodified basis, with other Modifications, as Covered Software and/or as part of a Larger Work; and + + (b) under Patent Claims infringed by the making, using, or selling of Modifications made by that Contributor either alone and/or in combination with its Contributor Version (or portions of such combination), to make, use, sell, offer for sale, have made, and/or otherwise dispose of: (1) Modifications made by that Contributor (or portions thereof); and (2) the combination of Modifications made by that Contributor with its Contributor Version (or portions of such combination). + + (c) The licenses granted in Sections 2.2(a) and 2.2(b) are effective on the date Contributor first distributes or otherwise makes the Modifications available to a third party. + + (d) Notwithstanding Section 2.2(b) above, no patent license is granted: (1) for any code that Contributor has deleted from the Contributor Version; (2) for infringements caused by: (i) third party modifications of Contributor Version, or (ii) the combination of Modifications made by that Contributor with other software (except as part of the Contributor Version) or other devices; or (3) under Patent Claims infringed by Covered Software in the absence of Modifications made by that Contributor. + +3. Distribution Obligations. + +3.1. Availability of Source Code. +Any Covered Software that You distribute or otherwise make available in Executable form must also be made available in Source Code form and that Source Code form must be distributed only under the terms of this License. You must include a copy of this License with every copy of the Source Code form of the Covered Software You distribute or otherwise make available. You must inform recipients of any such Covered Software in Executable form as to how they can obtain such Covered Software in Source Code form in a reasonable manner on or through a medium customarily used for software exchange. + +3.2. Modifications. +The Modifications that You create or to which You contribute are governed by the terms of this License. You represent that You believe Your Modifications are Your original creation(s) and/or You have sufficient rights to grant the rights conveyed by this License. + +3.3. Required Notices. +You must include a notice in each of Your Modifications that identifies You as the Contributor of the Modification. You may not remove or alter any copyright, patent or trademark notices contained within the Covered Software, or any notices of licensing or any descriptive text giving attribution to any Contributor or the Initial Developer. + +3.4. Application of Additional Terms. +You may not offer or impose any terms on any Covered Software in Source Code form that alters or restricts the applicable version of this License or the recipients’ rights hereunder. You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Software. However, you may do so only on Your own behalf, and not on behalf of the Initial Developer or any Contributor. You must make it absolutely clear that any such warranty, support, indemnity or liability obligation is offered by You alone, and You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of warranty, support, indemnity or liability terms You offer. + +3.5. Distribution of Executable Versions. +You may distribute the Executable form of the Covered Software under the terms of this License or under the terms of a license of Your choice, which may contain terms different from this License, provided that You are in compliance with the terms of this License and that the license for the Executable form does not attempt to limit or alter the recipient’s rights in the Source Code form from the rights set forth in this License. If You distribute the Covered Software in Executable form under a different license, You must make it absolutely clear that any terms which differ from this License are offered by You alone, not by the Initial Developer or Contributor. You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of any such terms You offer. + +3.6. Larger Works. +You may create a Larger Work by combining Covered Software with other code not governed by the terms of this License and distribute the Larger Work as a single product. In such a case, You must make sure the requirements of this License are fulfilled for the Covered Software. + +4. Versions of the License. + +4.1. New Versions. +Sun Microsystems, Inc. is the initial license steward and may publish revised and/or new versions of this License from time to time. Each version will be given a distinguishing version number. Except as provided in Section 4.3, no one other than the license steward has the right to modify this License. + +4.2. Effect of New Versions. +You may always continue to use, distribute or otherwise make the Covered Software available under the terms of the version of the License under which You originally received the Covered Software. If the Initial Developer includes a notice in the Original Software prohibiting it from being distributed or otherwise made available under any subsequent version of the License, You must distribute and make the Covered Software available under the terms of the version of the License under which You originally received the Covered Software. Otherwise, You may also choose to use, distribute or otherwise make the Covered Software available under the terms of any subsequent version of the License published by the license steward. + +4.3. Modified Versions. +When You are an Initial Developer and You want to create a new license for Your Original Software, You may create and use a modified version of this License if You: (a) rename the license and remove any references to the name of the license steward (except to note that the license differs from this License); and (b) otherwise make it clear that the license contains terms which differ from this License. + +5. DISCLAIMER OF WARRANTY. + +COVERED SOFTWARE IS PROVIDED UNDER THIS LICENSE ON AN “AS IS” BASIS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED SOFTWARE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED SOFTWARE IS WITH YOU. SHOULD ANY COVERED SOFTWARE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED SOFTWARE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. + +6. TERMINATION. + +6.1. This License and the rights granted hereunder will terminate automatically if You fail to comply with terms herein and fail to cure such breach within 30 days of becoming aware of the breach. Provisions which, by their nature, must remain in effect beyond the termination of this License shall survive. + +6.2. If You assert a patent infringement claim (excluding declaratory judgment actions) against Initial Developer or a Contributor (the Initial Developer or Contributor against whom You assert such claim is referred to as “Participant”) alleging that the Participant Software (meaning the Contributor Version where the Participant is a Contributor or the Original Software where the Participant is the Initial Developer) directly or indirectly infringes any patent, then any and all rights granted directly or indirectly to You by such Participant, the Initial Developer (if the Initial Developer is not the Participant) and all Contributors under Sections 2.1 and/or 2.2 of this License shall, upon 60 days notice from Participant terminate prospectively and automatically at the expiration of such 60 day notice period, unless if within such 60 day period You withdraw Your claim with respect to the Participant Software against such Participant either unilaterally or pursuant to a written agreement with Participant. + +6.3. In the event of termination under Sections 6.1 or 6.2 above, all end user licenses that have been validly granted by You or any distributor hereunder prior to termination (excluding licenses granted to You by any distributor) shall survive termination. + +7. LIMITATION OF LIABILITY. + +UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED SOFTWARE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOST PROFITS, LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTY’S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. + +8. U.S. GOVERNMENT END USERS. + +The Covered Software is a “commercial item,” as that term is defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of “commercial computer software” (as that term is defined at 48 C.F.R. § 252.227-7014(a)(1)) and “commercial computer software documentation” as such terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995), all U.S. Government End Users acquire Covered Software with only those rights set forth herein. This U.S. Government Rights clause is in lieu of, and supersedes, any other FAR, DFAR, or other clause or provision that addresses Government rights in computer software under this License. + +9. MISCELLANEOUS. + +This License represents the complete agreement concerning subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. This License shall be governed by the law of the jurisdiction specified in a notice contained within the Original Software (except to the extent applicable law, if any, provides otherwise), excluding such jurisdiction’s conflict-of-law provisions. Any litigation relating to this License shall be subject to the jurisdiction of the courts located in the jurisdiction and venue specified in a notice contained within the Original Software, with the losing party responsible for costs, including, without limitation, court costs and reasonable attorneys’ fees and expenses. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not apply to this License. You agree that You alone are responsible for compliance with the United States export administration regulations (and the export control laws and regulation of any other countries) when You use, distribute or otherwise make available any Covered Software. + +10. RESPONSIBILITY FOR CLAIMS. + +As between Initial Developer and the Contributors, each party is responsible for claims and damages arising, directly or indirectly, out of its utilization of rights under this License and You agree to work with Initial Developer and Contributors to distribute such responsibility on an equitable basis. Nothing herein is intended or shall be deemed to constitute any admission of liability. diff --git a/licenses/COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt b/licenses/COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt new file mode 100644 index 00000000000..00cb82542d7 --- /dev/null +++ b/licenses/COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt @@ -0,0 +1,11 @@ +Common Development and Distribution License 1.1 + +Copyright © 1997-2010 Oracle Corporation (formerly Sun Microsystems, Inc.) + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS “AS IS” AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/licenses/EPL-1.0.txt b/licenses/EPL-1.0.txt new file mode 100644 index 00000000000..70ed0f38391 --- /dev/null +++ b/licenses/EPL-1.0.txt @@ -0,0 +1,73 @@ +Eclipse Public License - v 1.0 + +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS + +"Contribution" means: + a) in the case of the initial Contributor, the initial code and documentation distributed under this Agreement, and + b) in the case of each subsequent Contributor: + i) changes to the Program, and + ii) additions to the Program; + +where such changes and/or additions to the Program originate from and are distributed by that particular Contributor. A Contribution 'originates' from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include additions to the Program which: (i) are separate modules of software distributed in conjunction with the Program under their own license agreement, and (ii) are not derivative works of the Program. +"Contributor" means any person or entity that distributes the Program. + +"Licensed Patents" mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. + +"Program" means the Contributions distributed in accordance with this Agreement. + +"Recipient" means anyone who receives the Program under this Agreement, including all Contributors. + +2. GRANT OF RIGHTS + + a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, distribute and sublicense the Contribution of such Contributor, if any, and such derivative works, in source code and object code form. + + b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in source code and object code form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. + + c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. + + d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. + +3. REQUIREMENTS +A Contributor may choose to distribute the Program in object code form under its own license agreement, provided that: + + a) it complies with the terms and conditions of this Agreement; and + + b) its license agreement: + i) effectively disclaims on behalf of all Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; + ii) effectively excludes on behalf of all Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; + iii) states that any provisions which differ from this Agreement are offered by that Contributor alone and not by any other party; and + iv) states that source code for the Program is available from such Contributor, and informs licensees how to obtain it in a reasonable manner on or through a medium customarily used for software exchange. + +When the Program is made available in source code form: + + a) it must be made available under this Agreement; and + + b) a copy of this Agreement must be included with each copy of the Program. +Contributors may not remove or alter any copyright notices contained within the Program. + +Each Contributor must identify itself as the originator of its Contribution, if any, in a manner that reasonably allows subsequent Recipients to identify the originator of the Contribution. + +4. COMMERCIAL DISTRIBUTION +Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor ("Commercial Contributor") hereby agrees to defend and indemnify every other Contributor ("Indemnified Contributor") against any losses, damages and costs (collectively "Losses") arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. + +5. NO WARRANTY +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, THE PROGRAM IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement , including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL + +If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. + +If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. + +Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to distribute the Program (including its Contributions) under the new version. Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. + +This Agreement is governed by the laws of the State of New York and the intellectual property laws of the United States of America. No party to this Agreement will bring a legal action under this Agreement more than one year after the cause of action arose. Each party waives its rights to a jury trial in any resulting litigation. diff --git a/licenses/EPL-2.0.txt b/licenses/EPL-2.0.txt new file mode 100644 index 00000000000..78756b5e9ab --- /dev/null +++ b/licenses/EPL-2.0.txt @@ -0,0 +1,80 @@ +Eclipse Public License - v 2.0 +THE ACCOMPANYING PROGRAM IS PROVIDED UNDER THE TERMS OF THIS ECLIPSE PUBLIC LICENSE (“AGREEMENT”). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT. + +1. DEFINITIONS +“Contribution” means: + +a) in the case of the initial Contributor, the initial content Distributed under this Agreement, and +b) in the case of each subsequent Contributor: +i) changes to the Program, and +ii) additions to the Program; +where such changes and/or additions to the Program originate from and are Distributed by that particular Contributor. A Contribution “originates” from a Contributor if it was added to the Program by such Contributor itself or anyone acting on such Contributor's behalf. Contributions do not include changes or additions to the Program that are not Modified Works. +“Contributor” means any person or entity that Distributes the Program. + +“Licensed Patents” mean patent claims licensable by a Contributor which are necessarily infringed by the use or sale of its Contribution alone or when combined with the Program. + +“Program” means the Contributions Distributed in accordance with this Agreement. + +“Recipient” means anyone who receives the Program under this Agreement or any Secondary License (as applicable), including Contributors. + +“Derivative Works” shall mean any work, whether in Source Code or other form, that is based on (or derived from) the Program and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. + +“Modified Works” shall mean any work in Source Code or other form that results from an addition to, deletion from, or modification of the contents of the Program, including, for purposes of clarity any new file in Source Code form that contains any contents of the Program. Modified Works shall not include works that contain only declarations, interfaces, types, classes, structures, or files of the Program solely in each case in order to link to, bind by name, or subclass the Program or Modified Works thereof. + +“Distribute” means the acts of a) distributing or b) making available in any manner that enables the transfer of a copy. + +“Source Code” means the form of a Program preferred for making modifications, including but not limited to software source code, documentation source, and configuration files. + +“Secondary License” means either the GNU General Public License, Version 2.0, or any later versions of that license, including any exceptions or additional permissions as identified by the initial Contributor. + +2. GRANT OF RIGHTS +a) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, Distribute and sublicense the Contribution of such Contributor, if any, and such Derivative Works. +b) Subject to the terms of this Agreement, each Contributor hereby grants Recipient a non-exclusive, worldwide, royalty-free patent license under Licensed Patents to make, use, sell, offer to sell, import and otherwise transfer the Contribution of such Contributor, if any, in Source Code or other form. This patent license shall apply to the combination of the Contribution and the Program if, at the time the Contribution is added by the Contributor, such addition of the Contribution causes such combination to be covered by the Licensed Patents. The patent license shall not apply to any other combinations which include the Contribution. No hardware per se is licensed hereunder. +c) Recipient understands that although each Contributor grants the licenses to its Contributions set forth herein, no assurances are provided by any Contributor that the Program does not infringe the patent or other intellectual property rights of any other entity. Each Contributor disclaims any liability to Recipient for claims brought by any other entity based on infringement of intellectual property rights or otherwise. As a condition to exercising the rights and licenses granted hereunder, each Recipient hereby assumes sole responsibility to secure any other intellectual property rights needed, if any. For example, if a third party patent license is required to allow Recipient to Distribute the Program, it is Recipient's responsibility to acquire that license before distributing the Program. +d) Each Contributor represents that to its knowledge it has sufficient copyright rights in its Contribution, if any, to grant the copyright license set forth in this Agreement. +e) Notwithstanding the terms of any Secondary License, no Contributor makes additional grants to any Recipient (other than those set forth in this Agreement) as a result of such Recipient's receipt of the Program under the terms of a Secondary License (if permitted under the terms of Section 3). +3. REQUIREMENTS +3.1 If a Contributor Distributes the Program in any form, then: + +a) the Program must also be made available as Source Code, in accordance with section 3.2, and the Contributor must accompany the Program with a statement that the Source Code for the Program is available under this Agreement, and informs Recipients how to obtain it in a reasonable manner on or through a medium customarily used for software exchange; and +b) the Contributor may Distribute the Program under a license different than this Agreement, provided that such license: +i) effectively disclaims on behalf of all other Contributors all warranties and conditions, express and implied, including warranties or conditions of title and non-infringement, and implied warranties or conditions of merchantability and fitness for a particular purpose; +ii) effectively excludes on behalf of all other Contributors all liability for damages, including direct, indirect, special, incidental and consequential damages, such as lost profits; +iii) does not attempt to limit or alter the recipients' rights in the Source Code under section 3.2; and +iv) requires any subsequent distribution of the Program by any party to be under a license that satisfies the requirements of this section 3. +3.2 When the Program is Distributed as Source Code: + +a) it must be made available under this Agreement, or if the Program (i) is combined with other material in a separate file or files made available under a Secondary License, and (ii) the initial Contributor attached to the Source Code the notice described in Exhibit A of this Agreement, then the Program may be made available under the terms of such Secondary Licenses, and +b) a copy of this Agreement must be included with each copy of the Program. +3.3 Contributors may not remove or alter any copyright, patent, trademark, attribution notices, disclaimers of warranty, or limitations of liability (‘notices’) contained within the Program from any copy of the Program which they Distribute, provided that Contributors may add their own appropriate notices. + +4. COMMERCIAL DISTRIBUTION +Commercial distributors of software may accept certain responsibilities with respect to end users, business partners and the like. While this license is intended to facilitate the commercial use of the Program, the Contributor who includes the Program in a commercial product offering should do so in a manner which does not create potential liability for other Contributors. Therefore, if a Contributor includes the Program in a commercial product offering, such Contributor (“Commercial Contributor”) hereby agrees to defend and indemnify every other Contributor (“Indemnified Contributor”) against any losses, damages and costs (collectively “Losses”) arising from claims, lawsuits and other legal actions brought by a third party against the Indemnified Contributor to the extent caused by the acts or omissions of such Commercial Contributor in connection with its distribution of the Program in a commercial product offering. The obligations in this section do not apply to any claims or Losses relating to any actual or alleged intellectual property infringement. In order to qualify, an Indemnified Contributor must: a) promptly notify the Commercial Contributor in writing of such claim, and b) allow the Commercial Contributor to control, and cooperate with the Commercial Contributor in, the defense and any related settlement negotiations. The Indemnified Contributor may participate in any such claim at its own expense. + +For example, a Contributor might include the Program in a commercial product offering, Product X. That Contributor is then a Commercial Contributor. If that Commercial Contributor then makes performance claims, or offers warranties related to Product X, those performance claims and warranties are such Commercial Contributor's responsibility alone. Under this section, the Commercial Contributor would have to defend claims against the other Contributors related to those performance claims and warranties, and if a court requires any other Contributor to pay any damages as a result, the Commercial Contributor must pay those damages. + +5. NO WARRANTY +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, AND TO THE EXTENT PERMITTED BY APPLICABLE LAW, THE PROGRAM IS PROVIDED ON AN “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Each Recipient is solely responsible for determining the appropriateness of using and distributing the Program and assumes all risks associated with its exercise of rights under this Agreement, including but not limited to the risks and costs of program errors, compliance with applicable laws, damage to or loss of data, programs or equipment, and unavailability or interruption of operations. + +6. DISCLAIMER OF LIABILITY +EXCEPT AS EXPRESSLY SET FORTH IN THIS AGREEMENT, AND TO THE EXTENT PERMITTED BY APPLICABLE LAW, NEITHER RECIPIENT NOR ANY CONTRIBUTORS SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE PROGRAM OR THE EXERCISE OF ANY RIGHTS GRANTED HEREUNDER, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +7. GENERAL +If any provision of this Agreement is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this Agreement, and without further action by the parties hereto, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. + +If Recipient institutes patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Program itself (excluding combinations of the Program with other software or hardware) infringes such Recipient's patent(s), then such Recipient's rights granted under Section 2(b) shall terminate as of the date such litigation is filed. + +All Recipient's rights under this Agreement shall terminate if it fails to comply with any of the material terms or conditions of this Agreement and does not cure such failure in a reasonable period of time after becoming aware of such noncompliance. If all Recipient's rights under this Agreement terminate, Recipient agrees to cease use and distribution of the Program as soon as reasonably practicable. However, Recipient's obligations under this Agreement and any licenses granted by Recipient relating to the Program shall continue and survive. + +Everyone is permitted to copy and distribute copies of this Agreement, but in order to avoid inconsistency the Agreement is copyrighted and may only be modified in the following manner. The Agreement Steward reserves the right to publish new versions (including revisions) of this Agreement from time to time. No one other than the Agreement Steward has the right to modify this Agreement. The Eclipse Foundation is the initial Agreement Steward. The Eclipse Foundation may assign the responsibility to serve as the Agreement Steward to a suitable separate entity. Each new version of the Agreement will be given a distinguishing version number. The Program (including Contributions) may always be Distributed subject to the version of the Agreement under which it was received. In addition, after a new version of the Agreement is published, Contributor may elect to Distribute the Program (including its Contributions) under the new version. + +Except as expressly stated in Sections 2(a) and 2(b) above, Recipient receives no rights or licenses to the intellectual property of any Contributor under this Agreement, whether expressly, by implication, estoppel or otherwise. All rights in the Program not expressly granted under this Agreement are reserved. Nothing in this Agreement is intended to be enforceable by any entity that is not a Contributor or Recipient. No third-party beneficiary rights are created under this Agreement. + +Exhibit A – Form of Secondary Licenses Notice +“This Source Code may also be made available under the following Secondary Licenses when the conditions for such availability set forth in the Eclipse Public License, v. 2.0 are satisfied: {name license(s), version(s), and exceptions or additional permissions here}.” + +Simply including a copy of this Agreement, including this Exhibit A is not sufficient to license the Source Code under Secondary Licenses. + +If it is not possible or desirable to put the notice in a particular file, then You may include the notice in a location (such as a LICENSE file in a relevant directory) where a recipient would be likely to look for such a notice. + +You may add additional accurate notices of copyright ownership. diff --git a/licenses/ISC.txt b/licenses/ISC.txt new file mode 100644 index 00000000000..e80998f0769 --- /dev/null +++ b/licenses/ISC.txt @@ -0,0 +1,7 @@ +ISC License + +Copyright + +Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/licenses/LGPL-3.0.txt b/licenses/LGPL-3.0.txt new file mode 100644 index 00000000000..489e1fce898 --- /dev/null +++ b/licenses/LGPL-3.0.txt @@ -0,0 +1,304 @@ +GNU LESSER GENERAL PUBLIC LICENSE +Version 3, 29 June 2007 + +Copyright (C) 2010 Konrad Malawski + +Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. + +This version of the GNU Lesser General Public License incorporates the terms and conditions of version 3 of the GNU General Public License, supplemented by the additional permissions listed below. + +0. Additional Definitions. + +As used herein, "this License" refers to version 3 of the GNU Lesser General Public License, and the "GNU GPL" refers to version 3 of the GNU General Public License. + +"The Library" refers to a covered work governed by this License, other than an Application or a Combined Work as defined below. + +An "Application" is any work that makes use of an interface provided by the Library, but which is not otherwise based on the Library. Defining a subclass of a class defined by the Library is deemed a mode of using an interface provided by the Library. + +A "Combined Work" is a work produced by combining or linking an Application with the Library. The particular version of the Library with which the Combined Work was made is also called the "Linked Version". + +The "Minimal Corresponding Source" for a Combined Work means the Corresponding Source for the Combined Work, excluding any source code for portions of the Combined Work that, considered in isolation, are based on the Application, and not on the Linked Version. + +The "Corresponding Application Code" for a Combined Work means the object code and/or source code for the Application, including any data and utility programs needed for reproducing the Combined Work from the Application, but excluding the System Libraries of the Combined Work. + +1. Exception to Section 3 of the GNU GPL. +You may convey a covered work under sections 3 and 4 of this License without being bound by section 3 of the GNU GPL. + +2. Conveying Modified Versions. +If you modify a copy of the Library, and, in your modifications, a facility refers to a function or data to be supplied by an Application that uses the facility (other than as an argument passed when the facility is invoked), then you may convey a copy of the modified version: + + a) under this License, provided that you make a good faith effort to ensure that, in the event an Application does not supply the function or data, the facility still operates, and performs whatever part of its purpose remains meaningful, or + + b) under the GNU GPL, with none of the additional permissions of this License applicable to that copy. + +3. Object Code Incorporating Material from Library Header Files. +The object code form of an Application may incorporate material from a header file that is part of the Library. You may convey such object code under terms of your choice, provided that, if the incorporated material is not limited to numerical parameters, data structure layouts and accessors, or small macros, inline functions and templates (ten or fewer lines in length), you do both of the following: + + a) Give prominent notice with each copy of the object code that the Library is used in it and that the Library and its use are covered by this License. + + b) Accompany the object code with a copy of the GNU GPL and this license document. + +4. Combined Works. +You may convey a Combined Work under terms of your choice that, taken together, effectively do not restrict modification of the portions of the Library contained in the Combined Work and reverse engineering for debugging such modifications, if you also do each of the following: + + a) Give prominent notice with each copy of the Combined Work that the Library is used in it and that the Library and its use are covered by this License. + + b) Accompany the Combined Work with a copy of the GNU GPL and this license document. + + c) For a Combined Work that displays copyright notices during execution, include the copyright notice for the Library among these notices, as well as a reference directing the user to the copies of the GNU GPL and this license document. + + d) Do one of the following: + + 0) Convey the Minimal Corresponding Source under the terms of this License, and the Corresponding Application Code in a form suitable for, and under terms that permit, the user to recombine or relink the Application with a modified version of the Linked Version to produce a modified Combined Work, in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source. + + 1) Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (a) uses at run time a copy of the Library already present on the user's computer system, and (b) will operate properly with a modified version of the Library that is interface-compatible with the Linked Version. + + e) Provide Installation Information, but only if you would otherwise be required to provide such information under section 6 of the GNU GPL, and only to the extent that such information is necessary to install and execute a modified version of the Combined Work produced by recombining or relinking the Application with a modified version of the Linked Version. (If you use option 4d0, the Installation Information must accompany the Minimal Corresponding Source and Corresponding Application Code. If you use option 4d1, you must provide the Installation Information in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source.) + +5. Combined Libraries. +You may place library facilities that are a work based on the Library side by side in a single library together with other library facilities that are not Applications and are not covered by this License, and convey such a combined library under terms of your choice, if you do both of the following: + + a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities, conveyed under the terms of this License. + + b) Give prominent notice with the combined library that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. + +6. Revised Versions of the GNU Lesser General Public License. +The Free Software Foundation may publish revised and/or new versions of the GNU Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library as you received it specifies that a certain numbered version of the GNU Lesser General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that published version or of any later version published by the Free Software Foundation. If the Library as you received it does not specify a version number of the GNU Lesser General Public License, you may choose any version of the GNU Lesser General Public License ever published by the Free Software Foundation. + +If the Library as you received it specifies that a proxy can decide whether future versions of the GNU Lesser General Public License shall +apply, that proxy's public statement of acceptance of any version is permanent authorization for you to choose that version for the Library. + +GNU GENERAL PUBLIC LICENSE +Version 3, 29 June 2007 + +Copyright © 2007 Free Software Foundation, Inc. + +Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. + +Preamble + +The GNU General Public License is a free, copyleft license for software and other kinds of works. + +The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. We, the Free Software Foundation, use the GNU General Public License for most of our software; it applies also to any other work released this way by its authors. You can apply it to your programs, too. + +When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. + +To protect your rights, we need to prevent others from denying you these rights or asking you to surrender the rights. Therefore, you have certain responsibilities if you distribute copies of the software, or if you modify it: responsibilities to respect the freedom of others. + +For example, if you distribute copies of such a program, whether gratis or for a fee, you must pass on to the recipients the same freedoms that you received. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. + +Developers that use the GNU GPL protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License giving you legal permission to copy, distribute and/or modify it. + +For the developers' and authors' protection, the GPL clearly explains that there is no warranty for this free software. For both users' and authors' sake, the GPL requires that modified versions be marked as changed, so that their problems will not be attributed erroneously to authors of previous versions. + +Some devices are designed to deny users access to install or run modified versions of the software inside them, although the manufacturer can do so. This is fundamentally incompatible with the aim of protecting users' freedom to change the software. The systematic pattern of such abuse occurs in the area of products for individuals to use, which is precisely where it is most unacceptable. Therefore, we have designed this version of the GPL to prohibit the practice for those products. If such problems arise substantially in other domains, we stand ready to extend this provision to those domains in future versions of the GPL, as needed to protect the freedom of users. + +Finally, every program is threatened constantly by software patents. States should not allow patents to restrict development and use of software on general-purpose computers, but in those that do, we wish to avoid the special danger that patents applied to a free program could make it effectively proprietary. To prevent this, the GPL assures that patents cannot be used to render the program non-free. + +The precise terms and conditions for copying, distribution and modification follow. + +TERMS AND CONDITIONS + +0. Definitions. + +“This License” refers to version 3 of the GNU General Public License. + +“Copyright” also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. + +“The Program” refers to any copyrightable work licensed under this License. Each licensee is addressed as “you”. “Licensees” and “recipients” may be individuals or organizations. + +To “modify” a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a “modified version” of the earlier work or a work “based on” the earlier work. + +A “covered work” means either the unmodified Program or a work based on the Program. + +To “propagate” a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. + +To “convey” a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. + +An interactive user interface displays “Appropriate Legal Notices” to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. + +1. Source Code. +The “source code” for a work means the preferred form of the work for making modifications to it. “Object code” means any non-source form of a work. + +A “Standard Interface” means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. + +The “System Libraries” of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A “Major Component”, in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. + +The “Corresponding Source” for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those subprograms and other parts of the work. + +The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. + +The Corresponding Source for a work in source code form is that same work. + +2. Basic Permissions. +All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. + +You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. + +Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. + +3. Protecting Users' Legal Rights From Anti-Circumvention Law. +No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. + +When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. + +4. Conveying Verbatim Copies. +You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. + +You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. + +5. Conveying Modified Source Versions. +You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to “keep intact all notices”. + + c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. + +A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an “aggregate” if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. + +6. Conveying Non-Source Forms. +You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: + + a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. + + d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. + +A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. + +A “User Product” is either (1) a “consumer product”, which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, “normally used” refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. + +“Installation Information” for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. + +If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). + +The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. + +Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. + +7. Additional Terms. +“Additional permissions” are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. + +When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. + +Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or authors of the material; or + + e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. + +All other non-permissive additional terms are considered “further restrictions” within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. + +If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. + +Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. + +8. Termination. +You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). + +However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. + +Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. + +Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. + +9. Acceptance Not Required for Having Copies. +You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. + +10. Automatic Licensing of Downstream Recipients. +Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. + +An “entity transaction” is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. + +You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. + +11. Patents. +A “contributor” is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's “contributor version”. + +A contributor's “essential patent claims” are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, “control” includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. + +Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. + +In the following three paragraphs, a “patent license” is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To “grant” such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. + +If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent license to downstream recipients. “Knowingly relying” means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. + +If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. + +A patent license is “discriminatory” if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. + +Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. + +12. No Surrender of Others' Freedom. +If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. + +13. Use with the GNU Affero General Public License. +Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU Affero General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the special requirements of the GNU Affero General Public License, section 13, concerning interaction through a network will apply to the combination as such. + +14. Revised Versions of this License. +The Free Software Foundation may publish revised and/or new versions of the GNU General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU General Public License “or any later version” applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU General Public License, you may choose any version ever published by the Free Software Foundation. + +If the Program specifies that a proxy can decide which future versions of the GNU General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. + +Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. + +15. Disclaimer of Warranty. +THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + +16. Limitation of Liability. +IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + +17. Interpretation of Sections 15 and 16. +If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. + +END OF TERMS AND CONDITIONS + +How to Apply These Terms to Your New Programs + +If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. + +To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the “copyright” line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. + + You should have received a copy of the GNU General Public License along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + +If the program does terminal interaction, make it output a short notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, your program's commands might be different; for a GUI interface, you would use an “about box”. + +You should also get your employer (if you work as a programmer) or school, if any, to sign a “copyright disclaimer” for the program, if necessary. For more information on this, and how to apply and follow the GNU GPL, see . + +The GNU General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read . diff --git a/licenses/MIT.txt b/licenses/MIT.txt new file mode 100644 index 00000000000..fca51ed230e --- /dev/null +++ b/licenses/MIT.txt @@ -0,0 +1,16 @@ +The MIT License (MIT) +--------------------------- +Copyright © 2009-2026 The Project Lombok Authors +Copyright © 2004-2026 QOS.ch +Copyright © 2007-2026 Mockito contributors +Copyright © 2015-2026 Auth0, Inc. +Copyright © 2000-2026 Legion of the Bouncy Castle Inc. +Copyright © 2009-2026 Jonathan Hedley +Copyright © 2018-2026 Clément Darras (clamav-client) +Copyright © 2010-2026 Redis / Jedis contributors + +Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/licenses/MOZILLA-2.0.txt b/licenses/MOZILLA-2.0.txt new file mode 100644 index 00000000000..b3b8d93f36c --- /dev/null +++ b/licenses/MOZILLA-2.0.txt @@ -0,0 +1,151 @@ +Mozilla Public License +Version 2.0 +1. Definitions +1.1. “Contributor” +means each individual or legal entity that creates, contributes to the creation of, or owns Covered Software. + +1.2. “Contributor Version” +means the combination of the Contributions of others (if any) used by a Contributor and that particular Contributor’s Contribution. + +1.3. “Contribution” +means Covered Software of a particular Contributor. + +1.4. “Covered Software” +means Source Code Form to which the initial Contributor has attached the notice in Exhibit A, the Executable Form of such Source Code Form, and Modifications of such Source Code Form, in each case including portions thereof. + +1.5. “Incompatible With Secondary Licenses” +means + +that the initial Contributor has attached the notice described in Exhibit B to the Covered Software; or + +that the Covered Software was made available under the terms of version 1.1 or earlier of the License, but not also under the terms of a Secondary License. + +1.6. “Executable Form” +means any form of the work other than Source Code Form. + +1.7. “Larger Work” +means a work that combines Covered Software with other material, in a separate file or files, that is not Covered Software. + +1.8. “License” +means this document. + +1.9. “Licensable” +means having the right to grant, to the maximum extent possible, whether at the time of the initial grant or subsequently, any and all of the rights conveyed by this License. + +1.10. “Modifications” +means any of the following: + +any file in Source Code Form that results from an addition to, deletion from, or modification of the contents of Covered Software; or + +any new file in Source Code Form that contains any Covered Software. + +1.11. “Patent Claims” of a Contributor +means any patent claim(s), including without limitation, method, process, and apparatus claims, in any patent Licensable by such Contributor that would be infringed, but for the grant of the License, by the making, using, selling, offering for sale, having made, import, or transfer of either its Contributions or its Contributor Version. + +1.12. “Secondary License” +means either the GNU General Public License, Version 2.0, the GNU Lesser General Public License, Version 2.1, the GNU Affero General Public License, Version 3.0, or any later versions of those licenses. + +1.13. “Source Code Form” +means the form of the work preferred for making modifications. + +1.14. “You” (or “Your”) +means an individual or a legal entity exercising rights under this License. For legal entities, “You” includes any entity that controls, is controlled by, or is under common control with You. For purposes of this definition, “control” means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of more than fifty percent (50%) of the outstanding shares or beneficial ownership of such entity. + +2. License Grants and Conditions +2.1. Grants +Each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license: + +under intellectual property rights (other than patent or trademark) Licensable by such Contributor to use, reproduce, make available, modify, display, perform, distribute, and otherwise exploit its Contributions, either on an unmodified basis, with Modifications, or as part of a Larger Work; and + +under Patent Claims of such Contributor to make, use, sell, offer for sale, have made, import, and otherwise transfer either its Contributions or its Contributor Version. + +2.2. Effective Date +The licenses granted in Section 2.1 with respect to any Contribution become effective for each Contribution on the date the Contributor first distributes such Contribution. + +2.3. Limitations on Grant Scope +The licenses granted in this Section 2 are the only rights granted under this License. No additional rights or licenses will be implied from the distribution or licensing of Covered Software under this License. Notwithstanding Section 2.1(b) above, no patent license is granted by a Contributor: + +for any code that a Contributor has removed from Covered Software; or + +for infringements caused by: (i) Your and any other third party’s modifications of Covered Software, or (ii) the combination of its Contributions with other software (except as part of its Contributor Version); or + +under Patent Claims infringed by Covered Software in the absence of its Contributions. + +This License does not grant any rights in the trademarks, service marks, or logos of any Contributor (except as may be necessary to comply with the notice requirements in Section 3.4). + +2.4. Subsequent Licenses +No Contributor makes additional grants as a result of Your choice to distribute the Covered Software under a subsequent version of this License (see Section 10.2) or under the terms of a Secondary License (if permitted under the terms of Section 3.3). + +2.5. Representation +Each Contributor represents that the Contributor believes its Contributions are its original creation(s) or it has sufficient rights to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use +This License is not intended to limit any rights You have under applicable copyright doctrines of fair use, fair dealing, or other equivalents. + +2.7. Conditions +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted in Section 2.1. + +3. Responsibilities +3.1. Distribution of Source Form +All distribution of Covered Software in Source Code Form, including any Modifications that You create or to which You contribute, must be under the terms of this License. You must inform recipients that the Source Code Form of the Covered Software is governed by the terms of this License, and how they can obtain a copy of this License. You may not attempt to alter or restrict the recipients’ rights in the Source Code Form. + +3.2. Distribution of Executable Form +If You distribute Covered Software in Executable Form then: + +such Covered Software must also be made available in Source Code Form, as described in Section 3.1, and You must inform recipients of the Executable Form how they can obtain a copy of such Source Code Form by reasonable means in a timely manner, at a charge no more than the cost of distribution to the recipient; and + +You may distribute such Executable Form under the terms of this License, or sublicense it under different terms, provided that the license for the Executable Form does not attempt to limit or alter the recipients’ rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work +You may create and distribute a Larger Work under terms of Your choice, provided that You also comply with the requirements of this License for the Covered Software. If the Larger Work is a combination of Covered Software with a work governed by one or more Secondary Licenses, and the Covered Software is not Incompatible With Secondary Licenses, this License permits You to additionally distribute such Covered Software under the terms of such Secondary License(s), so that the recipient of the Larger Work may, at their option, further distribute the Covered Software under the terms of either this License or such Secondary License(s). + +3.4. Notices +You may not remove or alter the substance of any license notices (including copyright notices, patent notices, disclaimers of warranty, or limitations of liability) contained within the Source Code Form of the Covered Software, except that You may alter any license notices to the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms +You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Software. However, You may do so only on Your own behalf, and not on behalf of any Contributor. You must make it absolutely clear that any such warranty, support, indemnity, or liability obligation is offered by You alone, and You hereby agree to indemnify every Contributor for any liability incurred by such Contributor as a result of warranty, support, indemnity or liability terms You offer. You may include additional disclaimers of warranty and limitations of liability specific to any jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +If it is impossible for You to comply with any of the terms of this License with respect to some or all of the Covered Software due to statute, judicial order, or regulation then You must: (a) comply with the terms of this License to the maximum extent possible; and (b) describe the limitations and the code they affect. Such description must be placed in a text file included with all distributions of the Covered Software under this License. Except to the extent prohibited by statute or regulation, such description must be sufficiently detailed for a recipient of ordinary skill to be able to understand it. + +5. Termination +5.1. The rights granted under this License will terminate automatically if You fail to comply with any of its terms. However, if You become compliant, then the rights granted under this License from a particular Contributor are reinstated (a) provisionally, unless and until such Contributor explicitly and finally terminates Your grants, and (b) on an ongoing basis, if such Contributor fails to notify You of the non-compliance by some reasonable means prior to 60 days after You have come back into compliance. Moreover, Your grants from a particular Contributor are reinstated on an ongoing basis if such Contributor notifies You of the non-compliance by some reasonable means, this is the first time You have received notice of non-compliance with this License from such Contributor, and You become compliant prior to 30 days after Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent infringement claim (excluding declaratory judgment actions, counter-claims, and cross-claims) alleging that a Contributor Version directly or indirectly infringes any patent, then the rights granted to You by any and all Contributors for the Covered Software under Section 2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all end user license agreements (excluding distributors and resellers) which have been validly granted by You or Your distributors under this License prior to termination shall survive termination. + +6. Disclaimer of Warranty +Covered Software is provided under this License on an “as is” basis, without warranty of any kind, either expressed, implied, or statutory, including, without limitation, warranties that the Covered Software is free of defects, merchantable, fit for a particular purpose or non-infringing. The entire risk as to the quality and performance of the Covered Software is with You. Should any Covered Software prove defective in any respect, You (not any Contributor) assume the cost of any necessary servicing, repair, or correction. This disclaimer of warranty constitutes an essential part of this License. No use of any Covered Software is authorized under this License except under this disclaimer. + +7. Limitation of Liability +Under no circumstances and under no legal theory, whether tort (including negligence), contract, or otherwise, shall any Contributor, or anyone who distributes Covered Software as permitted above, be liable to You for any direct, indirect, special, incidental, or consequential damages of any character including, without limitation, damages for lost profits, loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses, even if such party shall have been informed of the possibility of such damages. This limitation of liability shall not apply to liability for death or personal injury resulting from such party’s negligence to the extent applicable law prohibits such limitation. Some jurisdictions do not allow the exclusion or limitation of incidental or consequential damages, so this exclusion and limitation may not apply to You. + +8. Litigation +Any litigation relating to this License may be brought only in the courts of a jurisdiction where the defendant maintains its principal place of business and such litigation shall be governed by laws of that jurisdiction, without reference to its conflict-of-law provisions. Nothing in this Section shall prevent a party’s ability to bring cross-claims or counter-claims. + +9. Miscellaneous +This License represents the complete agreement concerning the subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not be used to construe this License against a Contributor. + +10. Versions of the License +10.1. New Versions +Mozilla Foundation is the license steward. Except as provided in Section 10.3, no one other than the license steward has the right to modify or publish new versions of this License. Each version will be given a distinguishing version number. + +10.2. Effect of New Versions +You may distribute the Covered Software under the terms of the version of the License under which You originally received the Covered Software, or under the terms of any subsequent version published by the license steward. + +10.3. Modified Versions +If you create software not governed by this License, and you want to create a new license for such software, you may create and use a modified version of this License if you rename the license and remove any references to the name of the license steward (except to note that such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary Licenses +If You choose to distribute Source Code Form that is Incompatible With Secondary Licenses under the terms of this version of the License, the notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at https://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular file, then You may include the notice in a location (such as a LICENSE file in a relevant directory) where a recipient would be likely to look for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - “Incompatible With Secondary Licenses” Notice +This Source Code Form is “Incompatible With Secondary Licenses”, as defined by the Mozilla Public License, v. 2.0. diff --git a/licenses/MPL-2.0.txt b/licenses/MPL-2.0.txt new file mode 100644 index 00000000000..ef3e7282283 --- /dev/null +++ b/licenses/MPL-2.0.txt @@ -0,0 +1,374 @@ + +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/licenses/NOTICE b/licenses/NOTICE new file mode 100644 index 00000000000..00a528ada79 --- /dev/null +++ b/licenses/NOTICE @@ -0,0 +1,195 @@ +================================================================================ +COPYRIGHT NOTICES — mosip-ref-impl +================================================================================ + +mosip-ref-impl is MPL 2.0 (see ../LICENSE). Spring Boot 4.1.1 / Java 21. +No kernel-bom — Boot parent is the BOM. kernel-core 1.4.1-SNAPSHOT. +Versions match each module pom.xml (1.4.1-SNAPSHOT). +License texts in this directory. + +This NOTICE applies the MOSIP open-source license matrix +(Compatible with MPL 2.0? / Use with MOSIP? / MOSIP comments). + +-------------------------------------------------------------------------------- +MOSIP open-source license matrix +-------------------------------------------------------------------------------- + +License Compatible with MPL 2.0? Use with MOSIP? +------------------------------- ------------------------- --------------- +BSD (2-Clause, 3-Clause) Yes Yes +MIT Yes Yes +Apache-2.0 Yes Yes +MPL-2.0 Yes Yes +EPL No No +LGPLv3 Yes No +GPLv2 No No +GPLv3 Yes No +AGPLv3 Yes No +Creative Commons (general) No No +ISC Yes Yes +Python-2.0 Yes Yes +AFL-2.0 No No +AFL-2.1 Yes Yes +ODC-By-1.0 No No +CDDL-1.0 Yes Yes +Unicode-DFS-2016 Yes Yes +BlueOak-1.0.0 Yes Yes +OFL-1.1 Yes Yes +CC-BY-4.0 To be reviewed To be reviewed +Zlib Yes Yes +0BSD Yes Yes + +MOSIP comments (authoritative wording): + +- BSD / MIT / MPL-2.0: code can be combined freely. +- Apache-2.0: both licenses are permissive and compatible; meet attribution. +- EPL: generally incompatible with MPL due to differing requirements. +- LGPLv3: compatible, but LGPLv3 terms may apply to the combined work; + MOSIP Use = No. +- GPLv2: lacks explicit compatibility with MPL 2.0. +- GPLv3 / AGPLv3: MPL 2.0 may be included in a larger work, but the combined + work must be GPLv3 / AGPLv3; MOSIP Use = No. +- Creative Commons (general): not designed for software. +- ISC: permissive. ISC code stays ISC; the overall project may be MPL 2.0. + Include the ISC text and attribute authors. +- Python-2.0: may be included and the project distributed as MPL 2.0 if both + licenses are complied with. +- AFL-2.0: clauses conflict with MPL 2.0; incompatible for a unified license. +- AFL-2.1: keep AFL notice and a copy of the license; attribute original + authors; AFL files stay AFL, MPL files stay MPL. +- ODC-By-1.0: database license; incompatible with MPL 2.0 as software. +- CDDL-1.0: weak copyleft coexistence. Each file keeps its original license + (MPL files stay MPL; CDDL files stay CDDL). Include both license texts + and identify which files are which. +- Unicode-DFS-2016: each part keeps its original license. Keep Unicode files + identified, do not strip headers, include the Unicode license and notice. +- BlueOak-1.0.0: permissive; keep the license text or a link with the software. +- OFL-1.1: fonts; include the full OFL-1.1 text when distributing fonts. +- CC-BY-4.0: Creative Commons Attribution 4.0 — to be reviewed. Not used in + this repository. +- Zlib: distributed copies must include the original zlib license text. +- 0BSD: permissive; broad use, modification, and distribution. + +CDDL-1.1 treated as CDDL-1.0 successor. Unicode-3.0 treated as +Unicode-DFS-2016 successor. LGPL-2.1 is not on the matrix; treated like +LGPLv3 (Use = No). + +Dual-licensed jars: MOSIP elects an allowed option (never EPL, GPL, AGPL, +LGPLv3, or Creative Commons as the product license). + +-------------------------------------------------------------------------------- +Compatibility audit (this repository) +-------------------------------------------------------------------------------- + +PASS — Use with MOSIP = Yes (product / runtime after election) + MPL-2.0: this repo; kernel-core; kernel-auth-adapter; pre-registration-core; + registration-processor-*; H2 (elects MPL-2.0, not EPL-1.0) + Apache-2.0: Spring Boot / Framework / Cloud; Jackson 2; Hazelcast; Jedis + stack via Boot; jjwt; json-path; json-smart; springdoc; Micrometer; + Hibernate Validator; byte-buddy; Vert.x (elects Apache-2.0, not EPL); + javassist (elects Apache-2.0, not LGPL-2.1 / MPL-1.1); + kotlin-stdlib (transitive of clamav-client) + MIT: Lombok, SLF4J API, Mockito (test), Jedis, clamav-client + BSD / EDL: JAXB API + jaxb-runtime (javax 2.3.x) + CDDL-1.1 elected (not GPL): javax.activation, javax.servlet-api + CDDL files remain CDDL; project files remain MPL-2.0 + Public Domain (treated as 0BSD): org.json:json + +NONE found: GPLv2, GPLv3, AGPLv3, AFL-2.0, ODC-By-1.0, Creative Commons + software, Python-2.0, ISC, AFL-2.1, Unicode-DFS-2016, BlueOak, OFL, Zlib + product dependencies. Matrix texts for those licenses are kept as reference. + +FAIL matrix Use = No — still present (not elected as product license) + EPL test: JUnit Jupiter / vintage / junit:junit — test scope only + EPL Boot AOP: aspectjweaver — transitive of Spring AOP + EPL OR LGPL-2.1: Logback classic/core — Boot default logger (kernel-core + logging). Both options are Use = No on the MOSIP matrix. + EPL build: JaCoCo Maven plugin / agent — not packaged into product jars + +CC-BY-4.0: to be reviewed; no CC-BY-4.0 files in this tree. + +================================================================================ +ELECTED / ALLOWED (Use with MOSIP = Yes) +================================================================================ + +Apache License 2.0 (Apache-2.0.txt) + Spring Boot 4.1.1 / Spring Framework 7.0.9 / Spring Cloud 2025.1.3 + Jackson 2.21.5 via spring-boot-jackson2 (MOSIP APIs) + Hibernate Validator 9.1.3.Final, Micrometer 1.17.1 + Prometheus registry + Hazelcast 5.7.0 (cache-provider-hazelcast) + spring-boot-starter-data-redis + Jedis 7.4.1 (cache-provider-redis) + io.jsonwebtoken:jjwt-api/impl/jackson 0.13.0 + Apache Commons Collections4 4.6.0, logstash-logback-encoder 9.0 + json-path 2.10.0 (kernel-ref-idobjectvalidator) / 3.0.0 (booking) + json-smart 2.6.0 + org.javassist:javassist 3.33.0-GA (Apache-2.0 elected) + springdoc-openapi 3.1.1, byte-buddy 1.18.11 + javax.inject:javax.inject 1 + Eclipse Vert.x 4.5.34 (EPL-2.0 OR Apache-2.0; MOSIP elects Apache-2.0) + Maven build plugins that are Apache-2.0 (compiler 3.16.0, surefire 3.6.0, + jar 3.5.1, source 3.4.0, javadoc 3.12.0, gpg 3.2.8, deploy 3.2.0, + assembly 3.8.0, git-commit-id 4.9.10, central-publishing 0.11.0) + +MIT License (MIT.txt) + Lombok 1.18.46, SLF4J API 2.0.18, Mockito 5.23.0 (test) + redis.clients:jedis 7.4.1 (Boot-managed; cache-provider-redis) + xyz.capybara:clamav-client 2.1.2 + Keep MIT text and author attribution + +EDL 1.0 / BSD-2-Clause (BSD-2-Clause.txt) + JAXB API 2.3.1 / JAXB Runtime 2.3.9 (javax — not Jakarta 4.x) + +Mozilla Public License 2.0 (project LICENSE / MPL-2.0.txt / MOZILLA-2.0.txt) + MOSIP ref-impl modules (kernel-ref-idobjectvalidator, + kernel-smsserviceprovider-msg91, kernel-virusscanner-clamav, + cache-provider-hazelcast, cache-provider-redis, + pre-registration-booking-service, registration-processor-external-stage, + registration-processor-external-integration-service) + MOSIP kernel-core, kernel-auth-adapter 1.4.1-SNAPSHOT, + pre-registration-core 1.4.1-SNAPSHOT, registration-processor-* 1.4.1-SNAPSHOT + H2 Database 2.4.240 (EPL-1.0 OR MPL-2.0; MOSIP elects MPL-2.0) + +CDDL-1.1 (COMMON-DEVLOPMENT-AND-DISTRIBUTION-1.1.txt) — successor to CDDL-1.0 + JavaBeans Activation Framework (transitive via JAXB; CDDL-1.1 OR + GPL-2.0-with-CPE; MOSIP elects CDDL-1.1) + javax.servlet-api (CDDL OR GPL-2.0-with-CPE; MOSIP elects CDDL) + Files retain CDDL; project code remains MPL-2.0 + Also see CDDL-1.0.txt (matrix reference / predecessor text) + +Public Domain / 0BSD-like (0BSD.txt) + org.json:json — Public Domain; treated as 0BSD (Use = Yes) + +Matrix reference texts (not currently a product-license election): + ISC.txt, Python-2.0 is not vendored (no Python-2.0 dependency), + Zlib.txt, BlueOak-1.0.0.txt, OFL-1.1.txt, Unicode-DFS-2016.txt, + AFL-2.1.txt, BSD-3-Clause.txt, BSD-3-Clause-No-Nuclear-License.txt + +================================================================================ +MOSIP MATRIX: Use = No (still on classpath — exception or replace) +================================================================================ + +EPL is incompatible with MPL 2.0 on the MOSIP matrix. +LGPLv3 is compatible with MPL but MOSIP Use = No. +LGPL-2.1 is not listed on the matrix; treated like LGPLv3 (Use = No). +GPLv2 is incompatible. GPLv3 / AGPLv3: Use = No. + +EPL-2.0 only (test / Boot tooling) + org.junit.jupiter / junit-vintage (test) + org.aspectj:aspectjweaver (Boot AOP transitive) + +EPL-1.0 only (test) + junit:junit 4.x (test; vintage) + +EPL-2.0 OR LGPL-2.1 (both MOSIP Use = No) + ch.qos.logback:logback-classic / logback-core — Boot default logger + (logging is supplied via kernel-core in commons) + +EPL-2.0 (build only — not a product jar) + org.jacoco:jacoco-maven-plugin / org.jacoco.agent + +LGPL-3.0.txt is retained for reference only; not used as a product +dependency license election. + +================================================================================ +END OF NOTICES +================================================================================ diff --git a/licenses/OFL-1.1.txt b/licenses/OFL-1.1.txt new file mode 100644 index 00000000000..6fe84ee21eb --- /dev/null +++ b/licenses/OFL-1.1.txt @@ -0,0 +1,43 @@ +SIL OPEN FONT LICENSE + +Version 1.1 - 26 February 2007 + +PREAMBLE + +The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others. + +The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives. + +DEFINITIONS + +"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the copyright statement(s). + +"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, or substituting — in part or in whole — any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment. + +"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS + +Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission. + +5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software. + +TERMINATION + +This license becomes null and void if any of the above conditions are not met. + +DISCLAIMER + +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/licenses/Unicode-DFS-2016.txt b/licenses/Unicode-DFS-2016.txt new file mode 100644 index 00000000000..71fd6ac5e12 --- /dev/null +++ b/licenses/Unicode-DFS-2016.txt @@ -0,0 +1,22 @@ +UNICODE, INC. LICENSE AGREEMENT - DATA FILES AND SOFTWARE + +Unicode Data Files include all data files under the directories http://www.unicode.org/Public/, http://www.unicode.org/reports/, http://www.unicode.org/cldr/data/, http://source.icu-project.org/repos/icu/, and http://www.unicode.org/utility/trac/browser/. + +Unicode Data Files do not include PDF online code charts under the directory http://www.unicode.org/Public/. + +Software includes any source code published in the Unicode Standard or under the directories http://www.unicode.org/Public/, http://www.unicode.org/reports/, http://www.unicode.org/cldr/data/, http://source.icu-project.org/repos/icu/, and http://www.unicode.org/utility/trac/browser/. + +NOTICE TO USER: Carefully read the following legal agreement. BY DOWNLOADING, INSTALLING, COPYING OR OTHERWISE USING UNICODE INC.'S DATA FILES ("DATA FILES"), AND/OR SOFTWARE ("SOFTWARE"), YOU UNEQUIVOCALLY ACCEPT, AND AGREE TO BE BOUND BY, ALL OF THE TERMS AND CONDITIONS OF THIS AGREEMENT. IF YOU DO NOT AGREE, DO NOT DOWNLOAD, INSTALL, COPY, DISTRIBUTE OR USE THE DATA FILES OR SOFTWARE. + +COPYRIGHT AND PERMISSION NOTICE + +Copyright © 1991-2016 Unicode, Inc. All rights reserved. Distributed under the Terms of Use in http://www.unicode.org/copyright.html. + +Permission is hereby granted, free of charge, to any person obtaining a copy of the Unicode data files and any associated documentation (the "Data Files") or Unicode software and any associated documentation (the "Software") to deal in the Data Files or Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, and/or sell copies of the Data Files or Software, and to permit persons to whom the Data Files or Software are furnished to do so, provided that either + + (a) this copyright and permission notice appear with all copies of the Data Files or Software, or + (b) this copyright and permission notice appear in associated Documentation. + +THE DATA FILES AND SOFTWARE ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THE DATA FILES OR SOFTWARE. + +Except as contained in this notice, the name of a copyright holder shall not be used in advertising or otherwise to promote the sale, use or other dealings in these Data Files or Software without prior written authorization of the copyright holder. diff --git a/licenses/Zlib.txt b/licenses/Zlib.txt new file mode 100644 index 00000000000..e0e3605ba42 --- /dev/null +++ b/licenses/Zlib.txt @@ -0,0 +1,11 @@ +zlib License + +This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. + +Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. + + 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. + + 3. This notice may not be removed or altered from any source distribution. diff --git a/pre-registration-booking-service/AGENTS.md b/pre-registration-booking-service/AGENTS.md new file mode 100644 index 00000000000..b343673d4e4 --- /dev/null +++ b/pre-registration-booking-service/AGENTS.md @@ -0,0 +1,34 @@ +# pre-registration-booking-service + +Boot REST `BookingApplication` → `BookingController` `/appointment/**`. Roles via `@authorizedRoles` bean. Adapters in JAR (no wget). JVM from Helm `javaOpts`. Pins in `pom.xml`. + +``` +pre-registration-booking-service/ +├── pom.xml Dockerfile README.md AGENTS.md +└── src/ + ├── main/ + │ ├── java/io/mosip/preregistration/booking/ + │ │ ├── BookingApplication.java + │ │ ├── controller/BookingController.java + │ │ ├── service/BookingService.java BookingServiceIntf.java + │ │ ├── service/util/BookingServiceUtil.java BookingLock.java + │ │ ├── config/BookingConfig.java OpenApiProperties.java + │ │ ├── repository/BookingAvailabilityRepository.java DemographicRepository.java RegistrationBookingRepository.java + │ │ ├── repository/impl/BookingDAO.java + │ │ ├── entity/AvailabilityPK.java AvailibityEntity.java + │ │ ├── codes/RequestCodes.java + │ │ ├── errorcodes/ErrorCodes.java ErrorMessages.java + │ │ ├── dto/ + │ │ └── exception/ util/BookingExceptionCatcher.java BookingExceptionHandler.java + │ └── resources/ bootstrap.properties logback.xml + └── test/ + ├── java/io/mosip/preregistration/booking/ + │ ├── config/BookingConfigOpenApiTest.java + │ └── test/ + │ ├── BookingApplicationTest.java + │ ├── config/TestConfig.java TestSecurityConfig.java + │ ├── controller/BookingControllerTest.java + │ └── service/BookingServiceTest.java BookingServiceCoverageTest.java BookingServiceIdentityMigrationTest.java + │ └── util/BookingServiceUtilTest.java + └── resources/ application.properties bootstrap.properties booking.json cancelAppointment.json multibooking.json create-schema.sql +``` diff --git a/pre-registration-booking-service/Dockerfile b/pre-registration-booking-service/Dockerfile index 8e925be3adf..63426881a8d 100644 --- a/pre-registration-booking-service/Dockerfile +++ b/pre-registration-booking-service/Dockerfile @@ -9,81 +9,41 @@ LABEL commit_hash=${COMMIT_HASH} LABEL commit_id=${COMMIT_ID} LABEL build_time=${BUILD_TIME} -# can be passed during Docker build as build time environment for github branch to pickup configuration from. +# Build-time config (also overridable at runtime via matching ENV). ARG spring_config_label - -# can be passed during Docker build as build time environment for spring profiles active ARG active_profile - -# can be passed during Docker build as build time environment for config server URL ARG spring_config_url -# can be passed during Docker build as build time environment for glowroot -ARG is_glowroot - -# can be passed during Docker build as build time environment for artifactory URL -ARG artifactory_url - -# environment variable to pass active profile such as DEV, QA etc at docker runtime ENV active_profile_env=${active_profile} - -# environment variable to pass github branch to pickup configuration from, at docker runtime ENV spring_config_label_env=${spring_config_label} - -# environment variable to pass spring configuration url, at docker runtime ENV spring_config_url_env=${spring_config_url} -# environment variable to pass glowroot, at docker runtime -ENV is_glowroot_env=${is_glowroot} - -# environment variable to pass artifactory url, at docker runtime -ENV artifactory_url_env=${artifactory_url} - -# environment variable to pass iam_adapter url, at docker runtime -ENV iam_adapter_url_env=${iam_adapter_url} +# JVM flags (ZGC, heap, encoding, …) come from JDK_JAVA_OPTIONS, set by Helm +# additionalResources.javaOpts — not hardcoded here. +# kernel-auth-adapter and kernel-ref-idobjectvalidator 1.4.1-SNAPSHOT are in the JAR. -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_group=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_uid=1002 - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_gid=1001 -# install packages and create user RUN apk -q update \ -&& apk add -q unzip wget \ && addgroup -g ${container_user_gid} ${container_user_group} \ && adduser -s /bin/sh -u ${container_user_uid} -G ${container_user_group} -h /home/${container_user} --disabled-password ${container_user} -# set working directory for the user WORKDIR /home/${container_user} ENV work_dir=/home/${container_user} -ARG loader_path=${work_dir}/additional_jars/ - -RUN mkdir -p ${loader_path} - -ENV loader_path_env=${loader_path} - ADD ./target/pre-registration-booking-service-*.jar pre-registration-booking-service.jar -#ADD http://13.71.87.138:8040/artifactory/libs-release-local/io/mosip/kernel/kernel-ref-idobjectvalidator/0.9.1/kernel-ref-idobjectvalidator-0.9.1.jar kernel-ref-idobjectvalidator-0.9.1.jar - -# change permissions of file inside working dir RUN chown -R ${container_user}:${container_user} /home/${container_user} -# select container user for all tasks USER ${container_user_uid}:${container_user_gid} EXPOSE 9095 -CMD wget -q --show-progress "${artifactory_url_env}"/artifactory/libs-release-local/io/mosip/kernel/kernel-ref-idobjectvalidator/kernel-ref-idobjectvalidator.jar "${loader_path_env}"/kernel-ref-idobjectvalidator.jar ; \ - wget "${iam_adapter_url_env}" -O "${loader_path_env}"/kernel-auth-adapter.jar; \ - java -XX:-UseG1GC -XX:+ExplicitGCInvokesConcurrent -XX:-UseParallelGC -XX:+UseZGC -XX:+ZGenerational -XX:-UseShenandoahGC -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+UseStringDeduplication -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 -XX:+UseCompressedOops \ - -Dloader.path="${loader_path_env}" -jar -Dspring.cloud.config.label="${spring_config_label_env}" -Dspring.profiles.active="${active_profile_env}" -Dspring.cloud.config.uri="${spring_config_url_env}" pre-registration-booking-service.jar ; \ +CMD java -Dspring.cloud.config.label="${spring_config_label_env}" \ + -Dspring.profiles.active="${active_profile_env}" \ + -Dspring.cloud.config.uri="${spring_config_url_env}" \ + -jar pre-registration-booking-service.jar diff --git a/pre-registration-booking-service/README.md b/pre-registration-booking-service/README.md index c81a9694f82..0daf3bf5bd6 100644 --- a/pre-registration-booking-service/README.md +++ b/pre-registration-booking-service/README.md @@ -1,75 +1,107 @@ # Pre-registration Booking Service +Spring Boot **4.1.1** REST service (`BookingApplication`) used by the Pre-Registration portal to book, cancel, and query appointments. + +- **Artifact**: `io.mosip.preregistration:pre-registration-booking-service:1.4.1-SNAPSHOT` +- **Parent**: `spring-boot-starter-parent` 4.1.1 (no `kernel-bom`) +- **REST**: `BookingController` `/appointment/**` +- **Auth**: `@PreAuthorize("hasAnyRole(@authorizedRoles.get…())")`; runtime JARs `kernel-auth-adapter` and `kernel-ref-idobjectvalidator` +- **Logging**: `kernel-core` (commons) — do not add `kernel-logger-logback` +- **Git info**: `git-commit-id-plugin` writes `service-git.properties` + ## Overview -This service details used by Pre-Registration portal to book an appointment by providing his/her basic appointment details + +This service lets an applicant book an appointment with basic slot details (registration centre, date, time). ## Databases + Refer to the required released tagged version [SQL scripts](https://github.com/mosip/pre-registration/tree/master/db_scripts). +## Prerequisites + +- JDK **21.0.3** +- Maven **3.9.6** +- Spring Cloud Config server (see Configuration) +- PostgreSQL 16 (typical MOSIP stack) + ## Build & run (for developers) -The project requires JDK 21.0.3 -and mvn version - 3.9.6 - -1. Build and install: - ``` - $ cd pre-registration-booking-service - $ mvn install -DskipTests=true -Dmaven.javadoc.skip=true -Dgpg.skip=true - ``` -2. Build Docker for a service: - ``` - $ cd - $ docker build -f Dockerfile - ``` - -### Add auth-adapter in a class-path to run a master-data service - ``` - - io.mosip.kernel - kernel-auth-adapter - ${kernel.auth.adapter.version} - - - io.mosip.kernel - kernel-ref-idobjectvalidator - ${kernel.ref.idobjectvalidator.version} - - ``` - -## Configuration files -Pre-registration Service uses the following configuration files: -[Configuration-Application](https://github.com/mosip/mosip-config/blob/master/application-default.properties) and -[Configuration-Pre-registration](https://github.com/mosip/mosip-config/blob/master/pre-registration-default.properties) defined here. -Refer to the required released tagged version. - -Need to run the config-server along with the files mentioned above in order to run the pre-registration booking service. - -## Default context, path, port -Refer to [bootstrap properties](src/main/resources/bootstrap.properties) - -## Deployment in K8 cluster with other MOSIP services: -### Pre-requisites -* Set KUBECONFIG variable to point to existing K8 cluster kubeconfig file: - ``` - export KUBECONFIG=~/.kube/ - ``` -### Install - ``` - $ cd deploy - $ ./install.sh - ``` -### Delete - ``` - $ cd deploy - $ ./delete.sh - ``` -### Restart - ``` - $ cd deploy - $ ./restart.sh - ``` + +```text +cd pre-registration-booking-service +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +Run `BookingApplication` from the IDE or: + +```text +java -jar target/pre-registration-booking-service-1.4.1-SNAPSHOT.jar +``` + +### Docker + +```text +cd pre-registration-booking-service +docker build -t pre-registration-booking-service . +``` + +### Runtime classpath (auth + ID object validator) + +```xml + + io.mosip.kernel + kernel-auth-adapter + ${kernel.auth.adapter.version} + + + io.mosip.kernel + kernel-ref-idobjectvalidator + ${project.version} + +``` + +MOSIP versions are in this module’s `pom.xml` (`kernel.auth.adapter.version`, `pre.registration.core.version`, `kernel.core.version`). + +```text +mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +JaCoCo LINE covered ratio **0.90** (`target/site/jacoco/index.html`). Jackson 2 via `spring-boot-jackson2`. Spring Cloud **2025.1.3**. Git info: `service-git.properties`. + +## Configuration + +Uses Spring Cloud Config: + +- [application-default.properties](https://github.com/mosip/mosip-config/blob/master/application-default.properties) +- [pre-registration-default.properties](https://github.com/mosip/mosip-config/blob/master/pre-registration-default.properties) + +Default context, path, port: [bootstrap.properties](src/main/resources/bootstrap.properties) + +- Port: `9095` +- Context: `/preregistration/v1` + +## Swagger UI (Authorize) + +| | | +|---|---| +| UI | `http://localhost:9095/preregistration/v1/appointment/booking-service/swagger-ui.html` | +| API docs | `/appointment/booking-service/v3/api-docs` | + +Click **Authorize**. Scheme: **Authorization** header apiKey. Paste the token from authmanager; Try-it-out sends it on every call. + +## Deployment (Kubernetes) + +```text +export KUBECONFIG=~/.kube/ +cd deploy +./install.sh # ./delete.sh ./restart.sh +``` + +See also [Sandbox Deployment Guide](https://docs.mosip.io/1.2.0/deploymentnew/v3-installation). ## APIs -API documentation is available [here](https://mosip.github.io/documentation/). + +[Pre-Registration Booking Service API](https://mosip.github.io/documentation/1.2.0/pre-registration-booking-service.html) ## License -This project is licensed under the terms of [Mozilla Public License 2.0](https://github.com/mosip/mosip-ref-impl/blob/master/LICENSE). \ No newline at end of file + +[Mozilla Public License 2.0](../LICENSE) — [NOTICE](../NOTICE) diff --git a/pre-registration-booking-service/pom.xml b/pre-registration-booking-service/pom.xml index 93165d228b5..32fbfb59a06 100644 --- a/pre-registration-booking-service/pom.xml +++ b/pre-registration-booking-service/pom.xml @@ -1,188 +1,247 @@ + 4.0.0 + + org.springframework.boot + spring-boot-starter-parent + 4.1.1 + + + io.mosip.preregistration pre-registration-booking-service - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT pre-registration-booking-service - Booking service of MOSIP Pre-registration - https://github.com/mosip/mosip-ref-impl + + MOSIP Pre-registration appointment booking REST service (Spring Boot 4.1.1, Java 21). + No kernel-bom. MOSIP versions are pinned here — not in README.md. + + https://github.com/mosip/mosip-ref-impl - UTF-8 - 1.4.2 - 1.4.0-SNAPSHOT - 1.3.1-rc.1 - 1.3.1-rc.1 21 - - 3.2.3 - 2.0.9.RELEASE - 2.0.0.RELEASE - - - 2.0.1.Final - 2.9.5 - - - 2.5.0 - - - 2.5.0 - 5.1.46 - 1.4.197 - 42.2.2 - - - 2.3.0 - 4.5.6 - - - 3.6.1 - 3.7 - 1.9.2 - 2.2 - 4.3 - - - 1.18.30 - 3.4.3 - - 1.1.1 - 3.1.4 - 20080701 - 0.7.4 - 1.2 - 63.1 - **/code/**,**/config/**,**/dao/**,**/dto/**,**/entity/**,**/errorcodes/**,**/exception/**,**/exception/system/**,**/exception/util/**,**/repository/**,**/*Config.java,**/*Application.java,**/batchjob/**,**/util/**,**/stateUtil/** - **/dto/**,**/entity/**,**/config/** - - ${java.version} - ${java.version} - 3.11.0 - 3.0.2 - 3.1.0 - 3.1.2 - 0.8.11 - 3.7.0.1746 - 3.2.0 - 3.3.0 + + false + + + + 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT + 1.4.1-SNAPSHOT + 1.4.1-SNAPSHOT + 2025.1.3 + + 3.1.1 + + 0.13.0 + + 9.0 + + 3.0.0 + 2.6.0 + + 3.33.0-GA + + 2.3.9 + 2.3.1 + 3.16.0 + 3.6.0 + 0.8.15 + 5.8.0.7211 + 3.12.0 + 3.4.0 + 3.2.8 + 4.9.10 0.11.0 - - - 4.12 - 1.1.6 - 1.7.19 - + **/code/**,**/codes/**,**/config/**,**/dao/**,**/dto/**,**/entity/**,**/errorcodes/**,**/exception/**,**/exception/system/**,**/exception/util/**,**/repository/**,**/*Config.java,**/*Application.java,**/batchjob/**,**/util/**,**/stateUtil/** + **/dto/**,**/entity/**,**/config/** + ${project.build.directory}/site/jacoco/jacoco.xml + 0.90 + - io.mosip.kernel - kernel-bom - ${kernel.bom.version} + org.springframework.cloud + spring-cloud-dependencies + ${spring-cloud.version} pom import - - org.projectlombok - lombok - ${lombok.version} - provided - + org.springframework.boot spring-boot-starter-web + + + org.springframework.boot + spring-boot-jackson2 + + org.springframework.boot spring-boot-starter-tomcat provided + + + org.springframework.boot + spring-boot-starter-security + + org.springframework.boot spring-boot-starter-test test - - - org.mockito - mockito-core - - + - org.mockito - mockito-core + org.springframework.security + spring-security-test test + - io.jsonwebtoken - jjwt + org.junit.vintage + junit-vintage-engine + test + - com.h2database - h2 + org.projectlombok + lombok + provided + org.springframework.cloud spring-cloud-starter-config + org.springframework.boot spring-boot-devtools runtime + io.mosip.preregistration pre-registration-core ${pre.registration.core.version} + io.mosip.kernel kernel-core ${kernel.core.version} + - org.springframework.boot - spring-boot-starter-security + io.mosip.kernel + kernel-auth-adapter + ${kernel.auth.adapter.version} - org.springframework.security - spring-security-test - test + io.mosip.kernel + kernel-ref-idobjectvalidator + ${kernel.ref.idobjectvalidator.version} + - net.logstash.logback - logstash-logback-encoder + io.jsonwebtoken + jjwt-api + ${jjwt.version} - ch.qos.logback - logback-classic + io.jsonwebtoken + jjwt-impl + ${jjwt.version} + runtime - ch.qos.logback - logback-core + io.jsonwebtoken + jjwt-jackson + ${jjwt.version} + runtime - - net.minidev - asm - 1.0.2 + + + com.h2database + h2 + + + + net.logstash.logback + logstash-logback-encoder + ${logstash-logback-encoder.version} + com.jayway.jsonpath json-path + ${json-path.version} + net.minidev json-smart + ${json-smart.version} + io.micrometer micrometer-core @@ -191,81 +250,104 @@ io.micrometer micrometer-registry-prometheus + javax.xml.bind jaxb-api + ${jaxb-api-version} - - javax.activation - activation - + org.glassfish.jaxb jaxb-runtime + ${jaxb.runtime.version} + org.javassist javassist + ${javassist.version} + - javax.servlet - javax.servlet-api - provided - - - com.fasterxml.jackson.core - jackson-databind - - - com.fasterxml.jackson.core - jackson-annotations - - - com.fasterxml.jackson.core - jackson-core - - - com.fasterxml.jackson.datatype - jackson-datatype-jsr310 + org.springdoc + springdoc-openapi-starter-webmvc-ui + ${springdoc.version} + - org.junit.vintage - junit-vintage-engine - - - org.springdoc - springdoc-openapi-starter-webmvc-ui - 2.6.0 + org.hibernate.validator + hibernate-validator + - org.hibernate.validator - hibernate-validator + org.mockito + mockito-core + test - + + org.apache.maven.plugins + maven-compiler-plugin + ${maven.compiler.plugin.version} + + ${java.version} + true + + + org.projectlombok + lombok + ${lombok.version} + + + + org.apache.maven.plugins maven-surefire-plugin ${maven.surefire.plugin.version} ${skipTests} - false - - ${argLine} - --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED - --add-opens java.base/java.lang=ALL-UNNAMED - --illegal-access=debug - --enable-preview - + @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --enable-preview org.jacoco jacoco-maven-plugin - ${maven.jacoco.plugin.version} + ${maven.jacoco.version} + + + **/code/** + **/codes/** + **/config/** + **/dao/** + **/dto/** + **/entity/** + **/errorcodes/** + **/exception/** + **/repository/** + **/*Config.class + **/*Application.class + **/batchjob/** + **/util/** + **/stateUtil/** + + @@ -279,15 +361,33 @@ report + + jacoco-check + + check + + + + + BUNDLE + + + LINE + COVEREDRATIO + ${jacoco.minimum.coverage} + + + + + + org.springframework.boot spring-boot-maven-plugin - ${spring.boot.version} - true - ZIP + @@ -304,7 +404,6 @@ org.apache.maven.plugins maven-source-plugin - true ${maven.source.plugin.version} @@ -329,13 +428,13 @@ none - src/main/java + false org.apache.maven.plugins maven-gpg-plugin - 3.2.3 + ${maven.gpg.plugin.version} sign-artifacts @@ -355,7 +454,7 @@ pl.project13.maven git-commit-id-plugin - 3.0.1 + ${git.commit.id.plugin.version} get-the-git-infos @@ -366,15 +465,15 @@ + true - ${project.build.outputDirectory}/git.properties + ${project.build.outputDirectory}/service-git.properties ^git.build.(time|version)$ ^git.commit.id.(abbrev|full)$ full ${project.basedir}/.git - @@ -389,6 +488,7 @@ + sonar @@ -422,121 +522,54 @@ openapi-doc-generate-profile + io.mosip.kernel kernel-auth-adapter - 1.3.1 + ${kernel.auth.adapter.version} - - - - org.springframework.boot - spring-boot-maven-plugin - - true - ZIP - - - - pre-integration-test - - start - - - - src/test/resources - - - openapi-profile - - - - - post-integration-test - - stop - - - - - build-info - repackage - - - - - - org.springdoc - springdoc-openapi-maven-plugin - 0.2 - - - integration-test - - generate - - - - - http://localhost:9095/preregistration/v1/v3/api-docs/Pre-Registration-Booking - ${artifactId}-openapi.json - ${project.build.directory} - false - - - - pl.project13.maven - git-commit-id-plugin - ${git.commit.id.plugin.version} - - - get-the-git-infos - - revision - - validate - - - - true - - ${project.build.outputDirectory}/service-git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - - - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - + + + ossrh + Central Snapshots + https://central.sonatype.com/repository/maven-snapshots/ + + false + + + true + + + - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + + - Mosip + MOSIP mosip.emailnotifier@gmail.com io.mosip https://github.com/mosip/mosip-ref-impl - ossrh diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/BookingApplication.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/BookingApplication.java index e49b4d0ed50..33dcc92df65 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/BookingApplication.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/BookingApplication.java @@ -13,7 +13,11 @@ import io.mosip.preregistration.booking.config.BookingConfig; /** - * This class is used to define the start of the Booking application. + * Starts the Pre-registration booking REST service (Spring Boot 4.1.1). + *

+ * Component scan is {@code io.mosip.*} with kernel crypto/keymanager packages excluded. + * Swagger UI Authorize is wired in {@link BookingConfig}. + *

* * @author Kishan Rathore * @author Jagadishwari @@ -39,9 +43,9 @@ @EnableConfigurationProperties(BookingConfig.class) public class BookingApplication { /** - * Method to start the Booking API service - * - * @param args + * Method to start the Booking API service. + * + * @param args Spring Boot arguments */ public static void main(String[] args) { SpringApplication.run(BookingApplication.class, args); diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/codes/RequestCodes.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/codes/RequestCodes.java index ce1fffba4a4..c78f5a1a616 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/codes/RequestCodes.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/codes/RequestCodes.java @@ -1,41 +1,43 @@ package io.mosip.preregistration.booking.codes; +/** + * JSON / persistence field names used when reading MOSIP booking requests. + */ public enum RequestCodes { - /* id */ + /** Envelope id. */ id("id"), - /* version */ + /** Envelope version. */ version("version"), - /* request date time */ + /** Envelope request timestamp. */ requesttime("requesttime"), - /* request object */ + /** Envelope request object. */ request("request"), - /* preRegistration Id */ + /** Pre-registration identifier. */ PRE_REGISTRAION_ID("preRegistrationId"), - /* Appointment Date */ - REG_DATE("appointment_date"), - - /* From Time Slot */ + /** Appointment date column / JSON key. */ + REG_DATE("appointment_date"), + + /** Slot start time column / JSON key. */ FROM_SLOT_TIME("time_slot_from"); + /** - * @param code + * @param code wire or column name */ private RequestCodes(String code) { this.code = code; } - /** - * Code - */ + /** Canonical code stored with this enum constant. */ private final String code; /** - * @return the code + * @return the wire or column name */ public String getCode() { return code; diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/BookingConfig.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/BookingConfig.java index 1c667cdc540..11d6634ab4a 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/BookingConfig.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/BookingConfig.java @@ -23,12 +23,18 @@ import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.info.Info; import io.swagger.v3.oas.models.info.License; +import io.swagger.v3.oas.models.security.SecurityRequirement; +import io.swagger.v3.oas.models.security.SecurityScheme; import io.swagger.v3.oas.models.servers.Server; /** - * This class is used for Swagger configuration, also to configure Host and - * Port. + * This class is used for Swagger / Springdoc configuration, host and port helpers, + * and MOSIP booking id maps. + *

+ * {@link #openApi()} registers an Authorize apiKey named + * {@code Authorization} (header), same pattern as commons kernel-auth-service. + *

* * @author Kishan Rathore * @author Jagadishwari @@ -106,13 +112,19 @@ private Set protocols() { private static final Logger logger = LoggerFactory.getLogger(BookingConfig.class); + /** + * Scheme name shown by Swagger UI as Authorize (IDA-style Authorization apiKey). + */ + public static final String AUTHORIZATION_SCHEME = "Authorization"; + @Autowired private OpenApiProperties openApiProperties; @Bean public OpenAPI openApi() { OpenAPI api = new OpenAPI() - .components(new Components()) + .components(new Components().addSecuritySchemes(AUTHORIZATION_SCHEME, authorizationApiKey())) + .addSecurityItem(new SecurityRequirement().addList(AUTHORIZATION_SCHEME)) .info(new Info() .title(openApiProperties.getInfo().getTitle()) .version(openApiProperties.getInfo().getVersion()) @@ -128,6 +140,17 @@ public OpenAPI openApi() { return api; } + /** + * Header apiKey named {@code Authorization} so Swagger UI shows Authorize + * with Name / In / Value (same as commons kernel-auth-service). + * + * @return the security scheme + */ + private static SecurityScheme authorizationApiKey() { + return new SecurityScheme().type(SecurityScheme.Type.APIKEY).in(SecurityScheme.In.HEADER) + .name(AUTHORIZATION_SCHEME); + } + @Bean public GroupedOpenApi groupedOpenApi() { return GroupedOpenApi.builder().group(openApiProperties.getGroup().getName()) diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/OpenApiProperties.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/OpenApiProperties.java index bca4b4a5892..963ff70ad5f 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/OpenApiProperties.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/config/OpenApiProperties.java @@ -5,42 +5,64 @@ import org.springframework.context.annotation.Configuration; import java.util.List; +/** + * Binds {@code openapi.*} properties used by {@link BookingConfig} for Springdoc. + */ @Configuration @ConfigurationProperties(prefix = "openapi") @Data public class OpenApiProperties { - private InfoProperty info; - private Service service; - private Group group; + /** API title, description, version, and license. */ + private InfoProperty info; + /** Published server URLs for the OpenAPI document. */ + private Service service; + /** Swagger UI group name and path filters. */ + private Group group; } +/** OpenAPI info block bound from {@code openapi.info.*}. */ @Data class InfoProperty { - private String title; - private String description; - private String version; - private LicenseProperty license; + /** Display title in Swagger UI. */ + private String title; + /** Longer description of the API. */ + private String description; + /** Document version string. */ + private String version; + /** License name and URL. */ + private LicenseProperty license; } +/** License fields bound from {@code openapi.info.license.*}. */ @Data class LicenseProperty { - private String name; - private String url; + /** License display name (for example Mosip). */ + private String name; + /** License document URL. */ + private String url; } +/** Server list bound from {@code openapi.service.*}. */ @Data class Service { - private List servers; + /** OpenAPI servers (Try-it-out base URLs). */ + private List servers; } +/** A single OpenAPI server URL and description. */ @Data class Server { - private String description; - private String url; + /** Human-readable server label. */ + private String description; + /** Absolute or relative base URL. */ + private String url; } +/** Path group bound from {@code openapi.group.*}. */ @Data class Group { - private String name; - private List paths; -} \ No newline at end of file + /** Springdoc group name. */ + private String name; + /** Ant-style paths included in this group. */ + private List paths; +} diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/controller/BookingController.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/controller/BookingController.java index 3d196011046..e3b6b5193db 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/controller/BookingController.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/controller/BookingController.java @@ -48,6 +48,7 @@ import io.swagger.v3.oas.annotations.media.Schema; import io.swagger.v3.oas.annotations.responses.ApiResponse; import io.swagger.v3.oas.annotations.responses.ApiResponses; +import io.swagger.v3.oas.annotations.security.SecurityRequirement; import io.swagger.v3.oas.annotations.tags.Tag; /** @@ -63,16 +64,18 @@ @RestController @RequestMapping("/") @Tag(name = "booking-controller", description = "Booking Controller") +@SecurityRequirement(name = "Authorization") public class BookingController { /** Autowired reference for {@link #bookingService}. */ @Autowired private BookingServiceIntf bookingService; - + + /** Validates MOSIP request ids on POST/PUT bodies. */ @Autowired private RequestValidator requestValidator; - - /** The Constant CREATE application. */ + + /** MOSIP request-id constant for booking APIs. */ private static final String BOOKING = "book"; diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityDto.java index bac0c3b15a5..d0b91e8f9d9 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityDto.java @@ -2,21 +2,23 @@ import java.util.List; -import io.mosip.preregistration.booking.dto.DateTimeDto; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import lombok.ToString; +/** + * Availability calendar for one registration centre. + */ @Getter @Setter @NoArgsConstructor @ToString public class AvailabilityDto { - + + /** Registration centre id. */ private String regCenterId; - - private List centerDetails; - + /** Per-day slots (including holidays). */ + private List centerDetails; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityReqDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityReqDto.java index a5d88777d78..2ef79fefc19 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityReqDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/AvailabilityReqDto.java @@ -5,11 +5,14 @@ import lombok.Setter; import lombok.ToString; +/** + * Request body used to fetch availability for one centre. + */ @Getter @Setter @NoArgsConstructor @ToString public class AvailabilityReqDto { - private String registrationCenterId; - + /** Registration centre whose slots are requested. */ + private String registrationCenterId; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingDataByRegIdDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingDataByRegIdDto.java index a5c2327c7bf..d2f50f803cd 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingDataByRegIdDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingDataByRegIdDto.java @@ -7,13 +7,17 @@ import lombok.Getter; import lombok.Setter; +/** + * Booked pre-ids grouped by appointment date for one registration centre. + */ @Data @Getter @Setter public class BookingDataByRegIdDto { + /** Registration centre id. */ private String registrationCenterId; + /** pre-id → (date → slot). */ private Map> idsWithAppointmentDate; - } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingRequestDTO.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingRequestDTO.java index 845726618cd..5d8c5a76062 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingRequestDTO.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingRequestDTO.java @@ -10,9 +10,10 @@ /** + * Appointment request: centre, date, and from/to slot. + * * @author Kishan Rathore * @since 1.0.0 - * */ @Getter @Setter @@ -20,6 +21,7 @@ public class BookingRequestDTO implements Serializable{ /** * */ + /** Serialization version. */ private static final long serialVersionUID = 3339740008361919496L; /** * registration Center Id diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatus.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatus.java index 083324c3bdb..97b799ececd 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatus.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatus.java @@ -2,14 +2,16 @@ import java.util.List; -import io.mosip.preregistration.booking.dto.BookingStatusDTO; import lombok.Getter; import lombok.Setter; +/** + * Multi-appointment response: one status per requested pre-id. + */ @Getter @Setter public class BookingStatus { - - List bookingStatusResponse; + /** Per-pre-id booking outcomes. */ + List bookingStatusResponse; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatusDTO.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatusDTO.java index 7649c92f2db..be5370dac91 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatusDTO.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/BookingStatusDTO.java @@ -3,9 +3,13 @@ import lombok.Getter; import lombok.Setter; +/** + * Single booking outcome message. + */ @Getter @Setter public class BookingStatusDTO { - + + /** Human-readable booking result. */ private String bookingMessage; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DateTimeDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DateTimeDto.java index 1b2f55f63b4..8c785767d9b 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DateTimeDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DateTimeDto.java @@ -2,21 +2,26 @@ import java.util.List; -import io.mosip.preregistration.booking.dto.SlotDto; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import lombok.ToString; +/** + * One calendar day of slot availability for a centre. + */ @Getter @Setter @NoArgsConstructor @ToString public class DateTimeDto { + /** Calendar date (ISO local date string). */ private String date; + /** {@code true} when the centre is closed for a holiday. */ private boolean isHoliday; + /** Bookable slots on {@link #date}. */ private List timeSlots; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DemographicBookingRightJoin.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DemographicBookingRightJoin.java index dc0a1df3877..42b2d6ded5e 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DemographicBookingRightJoin.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/DemographicBookingRightJoin.java @@ -9,6 +9,9 @@ import lombok.NoArgsConstructor; import lombok.Setter; +/** + * Join projection of demographic status and booked slot. + */ @Getter @Setter @NoArgsConstructor @@ -18,6 +21,7 @@ public class DemographicBookingRightJoin implements Serializable { /** * */ + /** Serialization version. */ private static final long serialVersionUID = -6964396778095509912L; /** Status of the preid */ diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/HolidayDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/HolidayDto.java index 0c438458674..f30fbf37ad5 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/HolidayDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/HolidayDto.java @@ -1,16 +1,23 @@ package io.mosip.preregistration.booking.dto; +import java.util.List; + import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import lombok.ToString; +/** + * Holiday row returned with registration-centre masterdata. + */ @Getter @Setter @NoArgsConstructor @ToString public class HolidayDto { + /** Holiday identifier. */ private String holidayId; + /** Calendar date of the holiday. */ private String holidayDate; /** * Holiday day is day of week as integer value, week start from Monday , Monday is 1 and Sunday is 7 @@ -20,9 +27,12 @@ public class HolidayDto { * Holiday month is month of the year as integer value. */ private String holidayMonth; + /** Four-digit year. */ private String holidayYear; + /** Display name of the holiday. */ private String holidayName; + /** Language of {@link #holidayName}. */ private String languageCode; + /** Whether the holiday is currently active. */ private Boolean isActive; - } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequest.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequest.java index 9e1a9b52ff0..5b7e2e2e46f 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequest.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequest.java @@ -2,18 +2,19 @@ import java.util.List; -import io.mosip.preregistration.booking.dto.MultiBookingRequestDTO; import lombok.Getter; import lombok.Setter; /** + * Wrapper for several appointment requests in one API call. + * * @author Kishan Rathore * @since 1.0.0 - * */ @Getter @Setter public class MultiBookingRequest { + /** Individual booking rows. */ List bookingRequest; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequestDTO.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequestDTO.java index e3ad9864572..1d5e4534e72 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequestDTO.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/MultiBookingRequestDTO.java @@ -10,9 +10,10 @@ import lombok.Setter; /** + * One row of a multi-booking request (pre-id plus slot). + * * @author Kishan Rathore * @since 1.0.0 - * */ @Getter @Setter @@ -21,6 +22,7 @@ public class MultiBookingRequestDTO implements Serializable{ /** * */ + /** Serialization version. */ private static final long serialVersionUID = -4081838636811604986L; /** * pre-Registration Id diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterDto.java index 86ec0c48760..012e16d5ebd 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterDto.java @@ -1,4 +1,5 @@ package io.mosip.preregistration.booking.dto; + import java.time.LocalTime; import lombok.Getter; @@ -6,57 +7,81 @@ import lombok.Setter; import lombok.ToString; - +/** + * Registration-centre masterdata used to generate appointment slots. + */ @Getter @Setter @NoArgsConstructor @ToString public class RegistrationCenterDto { + /** Centre identifier. */ private String id; + /** Display name. */ private String name; + /** Centre type code from masterdata. */ private String centerTypeCode; + /** Address line 1. */ private String addressLine1; + /** Address line 2. */ private String addressLine2; + /** Address line 3. */ private String addressLine3; + /** Latitude. */ private String latitude; + /** Longitude. */ private String longitude; + /** Location hierarchy code. */ private String locationCode; + /** Holiday location code used to load holidays. */ private String holidayLocationCode; + /** Contact phone. */ private String contactPhone; + /** Number of stations at the centre. */ private Short numberOfStations; + /** Working-hours description. */ private String workingHours; + /** Language of textual fields. */ private String langCode; + /** Number of kiosks. */ private Short numberOfKiosks; + /** Processing time per kiosk (slot length). */ private LocalTime perKioskProcessTime; + /** Centre opening time. */ private LocalTime centerStartTime; + /** Centre closing time. */ private LocalTime centerEndTime; + /** IANA or MOSIP time zone id. */ private String timeZone; + /** Contact person name. */ private String contactPerson; + /** Lunch break start. */ private LocalTime lunchStartTime; + /** Lunch break end. */ private LocalTime lunchEndTime; + /** Whether the centre is active. */ private Boolean isActive; - } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterHolidayDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterHolidayDto.java index a02fd6464d6..e7e94762274 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterHolidayDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterHolidayDto.java @@ -2,18 +2,21 @@ import java.util.List; -import io.mosip.preregistration.booking.dto.HolidayDto; -import io.mosip.preregistration.booking.dto.RegistrationCenterDto; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import lombok.ToString; +/** + * Masterdata payload: one centre plus its holidays. + */ @Getter @Setter @NoArgsConstructor @ToString public class RegistrationCenterHolidayDto { + /** Centre metadata used to generate slots. */ private RegistrationCenterDto registrationCenter; + /** Holidays for that centre. */ private List holidays; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterResponseDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterResponseDto.java index 0b3b7aecef5..62d57558746 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterResponseDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/RegistrationCenterResponseDto.java @@ -2,17 +2,19 @@ import java.util.List; -import io.mosip.preregistration.booking.dto.RegistrationCenterDto; import lombok.Getter; import lombok.NoArgsConstructor; import lombok.Setter; import lombok.ToString; - +/** + * Masterdata list wrapper for registration centres. + */ @Getter @Setter @NoArgsConstructor @ToString public class RegistrationCenterResponseDto { + /** Centres returned by masterdata. */ private List registrationCenters; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotDto.java index bdee7f5e19b..38e7489d53d 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotDto.java @@ -7,15 +7,21 @@ import lombok.Setter; import lombok.ToString; +/** + * A bookable time window and remaining capacity. + */ @Getter @Setter @NoArgsConstructor @ToString public class SlotDto { + /** Slot start (inclusive). */ private LocalTime fromTime; - + + /** Slot end (exclusive or inclusive per MOSIP config). */ private LocalTime toTime; - + + /** Remaining appointments that can still be booked in this slot. */ private int availability; } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotTimeDto.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotTimeDto.java index e79cb85ff65..cab008af172 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotTimeDto.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/dto/SlotTimeDto.java @@ -8,20 +8,28 @@ import lombok.Setter; import lombok.ToString; +/** + * Slot start/end used in booked-pre-id query responses. + */ @Data @Getter @Setter @NoArgsConstructor @ToString public class SlotTimeDto { - + + /** Slot start. */ private LocalTime fromTime; - + + /** Slot end. */ private LocalTime toTime; - + + /** + * @param fromTime slot start + * @param toTime slot end + */ public SlotTimeDto(LocalTime fromTime, LocalTime toTime) { this.fromTime = fromTime; this.toTime = toTime; } - } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityTableNotAccessableException.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityTableNotAccessableException.java index 00d3f79043c..ae484c258ba 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityTableNotAccessableException.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityTableNotAccessableException.java @@ -4,6 +4,9 @@ import io.mosip.preregistration.core.common.dto.MainResponseDTO; import lombok.Getter; +/** + * Thrown when the availability table cannot be read. + */ @Getter public class AvailabilityTableNotAccessableException extends BaseUncheckedException { @@ -11,6 +14,7 @@ public class AvailabilityTableNotAccessableException extends BaseUncheckedExcept * */ private static final long serialVersionUID = 5135952690225019228L; + /** MOSIP envelope copied onto the error response. */ private MainResponseDTO mainResponseDTO; public AvailabilityTableNotAccessableException(String msg) { diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityUpdationFailedException.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityUpdationFailedException.java index 8ab62140caa..16c157691a4 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityUpdationFailedException.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/AvailabilityUpdationFailedException.java @@ -4,6 +4,9 @@ import io.mosip.preregistration.core.common.dto.MainResponseDTO; import lombok.Getter; +/** + * Thrown when incrementing/decrementing slot availability fails. + */ @Getter public class AvailabilityUpdationFailedException extends BaseUncheckedException{ @@ -12,6 +15,7 @@ public class AvailabilityUpdationFailedException extends BaseUncheckedException{ * */ private static final long serialVersionUID = -8740121632422570371L; + /** MOSIP envelope copied onto the error response. */ private MainResponseDTO mainResponseDTO; public AvailabilityUpdationFailedException(String msg) { diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/JsonException.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/JsonException.java index 332b9a8dc5d..f62b62af72f 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/JsonException.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/JsonException.java @@ -4,6 +4,9 @@ import io.mosip.preregistration.core.common.dto.MainResponseDTO; import lombok.Getter; +/** + * Thrown when booking JSON cannot be parsed. + */ @Getter public class JsonException extends BaseUncheckedException { @@ -11,6 +14,7 @@ public class JsonException extends BaseUncheckedException { * */ private static final long serialVersionUID = -2782261618399872549L; + /** MOSIP envelope copied onto the error response. */ private MainResponseDTO mainResponseDTO; public JsonException(String msg) { diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/TimeSpanException.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/TimeSpanException.java index c511dc70f6b..9159874c6f3 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/TimeSpanException.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/exception/TimeSpanException.java @@ -4,6 +4,9 @@ import io.mosip.preregistration.core.common.dto.MainResponseDTO; import lombok.Getter; +/** + * Thrown when an appointment is requested outside the allowed time span. + */ @Getter public class TimeSpanException extends BaseUncheckedException{ @@ -11,8 +14,12 @@ public class TimeSpanException extends BaseUncheckedException{ * */ private static final long serialVersionUID = -5676105896729083192L; + /** MOSIP envelope copied onto the error response. */ private MainResponseDTO mainResponseDTO; + /** + * @param msg error text + */ public TimeSpanException(String msg) { super("", msg); } diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/repository/BookingAvailabilityRepository.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/repository/BookingAvailabilityRepository.java index bc26f3f783d..c3227ab9666 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/repository/BookingAvailabilityRepository.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/repository/BookingAvailabilityRepository.java @@ -8,7 +8,7 @@ import java.time.LocalTime; import java.util.List; -import javax.transaction.Transactional; +import jakarta.transaction.Transactional; import jakarta.persistence.LockModeType; import org.springframework.data.jpa.repository.Query; diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/BookingServiceIntf.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/BookingServiceIntf.java index 05ef12be20b..39fadb70e41 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/BookingServiceIntf.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/BookingServiceIntf.java @@ -16,6 +16,9 @@ import io.mosip.preregistration.core.common.dto.MainResponseDTO; import io.mosip.preregistration.core.common.dto.PreRegIdsByRegCenterIdResponseDTO; +/** + * Booking operations: availability, book, multi-book, cancel, delete, and queries by centre/date. + */ @Service public interface BookingServiceIntf { diff --git a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/util/BookingServiceUtil.java b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/util/BookingServiceUtil.java index 493e543784c..d8d690543bc 100644 --- a/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/util/BookingServiceUtil.java +++ b/pre-registration-booking-service/src/main/java/io/mosip/preregistration/booking/service/util/BookingServiceUtil.java @@ -176,9 +176,9 @@ public List getRegCenterMasterData(String regCenterId) { String regCentersDetailsPageNo = new StringBuilder(regCenterUrl).append("/").append(regCenterId) .append("/all").toString(); - UriComponentsBuilder regbuilder = UriComponentsBuilder.fromHttpUrl(regCentersDetailsPageNo); + UriComponentsBuilder regbuilder = UriComponentsBuilder.fromUriString(regCentersDetailsPageNo); HttpHeaders headers = new HttpHeaders(); - headers.setContentType(MediaType.APPLICATION_JSON_UTF8); + headers.setContentType(MediaType.APPLICATION_JSON); HttpEntity> entity = new HttpEntity<>(headers); String uriBuilder = regbuilder.build().encode().toUriString(); log.info("sessionId", "idType", "id", @@ -713,7 +713,7 @@ public MainResponseDTO getApplicationStatus(String applicationId) { MainResponseDTO response = new MainResponseDTO<>(); //String url = preRegResourceUrl + "/applications/status/" + applicationId; UriComponentsBuilder builder = UriComponentsBuilder - .fromHttpUrl(preRegResourceUrl + "/applications/status/" + applicationId); + .fromUriString(preRegResourceUrl + "/applications/status/" + applicationId); String uriBuilder = builder.build().encode().toUriString(); HttpHeaders headers = new HttpHeaders(); HttpEntity entity = new HttpEntity<>(headers); diff --git a/pre-registration-booking-service/src/main/resources/bootstrap.properties b/pre-registration-booking-service/src/main/resources/bootstrap.properties index b3f4460749e..ef802362bd9 100644 --- a/pre-registration-booking-service/src/main/resources/bootstrap.properties +++ b/pre-registration-booking-service/src/main/resources/bootstrap.properties @@ -5,6 +5,8 @@ spring.application.name=pre-registration-booking-service spring.profiles.active=dev management.endpoint.health.show-details=always management.endpoints.web.exposure.include=info,health,refresh +# Actuator /info reads this file. git.properties is reserved for kernel-core. +spring.info.git.location=classpath:service-git.properties server.servlet.context-path=/preregistration/v1 @@ -33,17 +35,19 @@ openapi.info.description=Pre-Registration-Booking Service openapi.info.version=1.0 openapi.info.license.name=Mosip openapi.info.license.url=https://docs.mosip.io/platform/license -mosipbox.public.url=http://localhost:${server.port} -openapi.service.servers[0].url=${mosipbox.public.url}${server.servlet.context-path} +# Relative server URL so Try-it-out uses the browser host (gateway), same as kernel-config-server. +openapi.service.servers[0].url=${server.servlet.context-path} openapi.service.servers[0].description=Pre-Registration-Booking Service openapi.group.name=${openapi.info.title} openapi.group.paths[0]=/** springdoc.swagger-ui.disable-swagger-default-url=true springdoc.swagger-ui.tagsSorter=alpha springdoc.swagger-ui.operationsSorter=alpha - +springdoc.swagger-ui.syntaxHighlight.activated=false +springdoc.swagger-ui.validator-url=none +springdoc.swagger-ui.persistAuthorization=true springdoc.swagger-ui.path=/appointment/booking-service/swagger-ui.html -springdoc.api-docs.path= /appointment/booking-service/v3/api-docs +springdoc.api-docs.path=/appointment/booking-service/v3/api-docs #the custom auth provider component names list #this will be used by default auth adapter diff --git a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/config/BookingConfigOpenApiTest.java b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/config/BookingConfigOpenApiTest.java new file mode 100644 index 00000000000..9050201afe4 --- /dev/null +++ b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/config/BookingConfigOpenApiTest.java @@ -0,0 +1,56 @@ +package io.mosip.preregistration.booking.config; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; + +import java.util.List; + +import org.junit.Test; +import org.springframework.test.util.ReflectionTestUtils; + +import io.swagger.v3.oas.models.OpenAPI; +import io.swagger.v3.oas.models.security.SecurityScheme; + +/** + * Swagger UI Authorize is an OpenAPI header apiKey named Authorization. + */ +public class BookingConfigOpenApiTest { + + @Test + public void openApiRegistersAuthorizationHeaderApiKey() { + BookingConfig config = new BookingConfig(); + ReflectionTestUtils.setField(config, "openApiProperties", sampleProperties()); + + OpenAPI api = config.openApi(); + SecurityScheme scheme = api.getComponents().getSecuritySchemes().get(BookingConfig.AUTHORIZATION_SCHEME); + + assertNotNull(scheme); + assertEquals(SecurityScheme.Type.APIKEY, scheme.getType()); + assertEquals(SecurityScheme.In.HEADER, scheme.getIn()); + assertEquals(BookingConfig.AUTHORIZATION_SCHEME, scheme.getName()); + assertFalse(api.getSecurity().isEmpty()); + assertEquals(BookingConfig.AUTHORIZATION_SCHEME, api.getSecurity().get(0).keySet().iterator().next()); + assertEquals("/preregistration/v1", api.getServers().get(0).getUrl()); + } + + private static OpenApiProperties sampleProperties() { + LicenseProperty license = new LicenseProperty(); + license.setName("Mosip"); + license.setUrl("https://docs.mosip.io/platform/license"); + InfoProperty info = new InfoProperty(); + info.setTitle("Pre-Registration-Booking"); + info.setDescription("Pre-Registration-Booking Service"); + info.setVersion("1.0"); + info.setLicense(license); + Server server = new Server(); + server.setUrl("/preregistration/v1"); + server.setDescription("Pre-Registration-Booking Service"); + Service service = new Service(); + service.setServers(List.of(server)); + OpenApiProperties properties = new OpenApiProperties(); + properties.setInfo(info); + properties.setService(service); + return properties; + } +} diff --git a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/BookingApplicationTest.java b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/BookingApplicationTest.java index b0ba0140f78..6bc237edcbc 100644 --- a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/BookingApplicationTest.java +++ b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/BookingApplicationTest.java @@ -1,13 +1,14 @@ package io.mosip.preregistration.booking.test; import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.EnableAutoConfiguration; import org.springframework.boot.autoconfigure.SpringBootApplication; -import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; -import org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration; -@SpringBootApplication(scanBasePackages= {"io.mosip.preregistration.core.*,io.mosip.preregistration.booking.*"}) -@EnableAutoConfiguration(exclude = { DataSourceAutoConfiguration.class, HibernateJpaAutoConfiguration.class }) +@SpringBootApplication( + scanBasePackages = { "io.mosip.preregistration.core.*", "io.mosip.preregistration.booking.*" }, + excludeName = { + "org.springframework.boot.jdbc.autoconfigure.DataSourceAutoConfiguration", + "org.springframework.boot.hibernate.autoconfigure.HibernateJpaAutoConfiguration" + }) public class BookingApplicationTest { /** diff --git a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/controller/BookingControllerTest.java b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/controller/BookingControllerTest.java index b5daf413552..4e1fb14f956 100644 --- a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/controller/BookingControllerTest.java +++ b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/controller/BookingControllerTest.java @@ -1,338 +1,175 @@ -// package io.mosip.preregistration.booking.test.controller; - -// import static org.junit.Assert.assertEquals; -// import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status; - -// import java.io.File; -// import java.io.FileNotFoundException; -// import java.io.FileReader; -// import java.net.URI; -// import java.net.URISyntaxException; -// import java.sql.Timestamp; -// import java.util.ArrayList; -// import java.util.Date; -// import java.util.List; - -// import org.junit.Before; -// import org.junit.Test; -// import org.junit.runner.RunWith; -// import org.mockito.Mock; -// import org.mockito.Mockito; -// import org.springframework.beans.factory.annotation.Autowired; -// import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc; -// import org.springframework.boot.test.context.SpringBootTest; -// import org.springframework.boot.test.mock.mockito.MockBean; -// import org.springframework.http.HttpStatus; -// import org.springframework.http.MediaType; -// import org.springframework.http.ResponseEntity; -// import org.springframework.security.test.context.support.WithUserDetails; -// import org.springframework.test.context.junit4.SpringRunner; -// import org.springframework.test.web.servlet.MockMvc; -// import org.springframework.test.web.servlet.RequestBuilder; -// import org.springframework.test.web.servlet.request.MockMvcRequestBuilders; -// import org.springframework.validation.BeanPropertyBindingResult; - -// import io.mosip.preregistration.booking.controller.BookingController; -// import io.mosip.preregistration.booking.dto.AvailabilityDto; -// import io.mosip.preregistration.booking.dto.BookingRequestDTO; -// import io.mosip.preregistration.booking.dto.BookingStatus; -// import io.mosip.preregistration.booking.dto.BookingStatusDTO; -// import io.mosip.preregistration.booking.dto.CancelBookingDTO; -// import io.mosip.preregistration.booking.dto.MultiBookingRequest; -// import io.mosip.preregistration.booking.dto.MultiBookingRequestDTO; -// import io.mosip.preregistration.booking.service.BookingServiceIntf; -// import io.mosip.preregistration.booking.service.util.BookingServiceUtil; -// import io.mosip.preregistration.booking.test.BookingApplicationTest; -// import io.mosip.preregistration.core.common.dto.BookingRegistrationDTO; -// import io.mosip.preregistration.core.common.dto.CancelBookingResponseDTO; -// import io.mosip.preregistration.core.common.dto.DeleteBookingDTO; -// import io.mosip.preregistration.core.common.dto.MainRequestDTO; -// import io.mosip.preregistration.core.common.dto.MainResponseDTO; -// import io.mosip.preregistration.core.common.dto.PreRegIdsByRegCenterIdDTO; -// import io.mosip.preregistration.core.common.dto.PreRegIdsByRegCenterIdResponseDTO; -// import io.mosip.preregistration.core.util.RequestValidator; -// import net.minidev.json.parser.JSONParser; -// import net.minidev.json.parser.ParseException; - -// /** -// * Booking Controller Test * -// * -// * @author Kishan Rathore -// * @since 1.0.0 -// **/ - -// @SpringBootTest(classes = { BookingApplicationTest.class }) -// @RunWith(SpringRunner.class) -// @AutoConfigureMockMvc -// public class BookingControllerTest { - -// @Autowired -// private MockMvc mockMvc; - -// @MockBean -// private BookingServiceIntf service; - -// @Mock -// private RequestValidator requestValidator; - -// @Autowired -// private BookingController controller; - -// @MockBean -// private BookingServiceUtil serviceUtil; - -// private AvailabilityDto availabilityDto; - -// MainRequestDTO bookingDTO = new MainRequestDTO(); -// BookingRequestDTO bookingRequestDTO = new BookingRequestDTO(); -// MultiBookingRequestDTO multiBookingRequestDto1 = new MultiBookingRequestDTO(); -// MultiBookingRequestDTO multiBookingRequestDto2 = new MultiBookingRequestDTO(); - -// List multiBookingListDto = new ArrayList<>(); -// List bookingList = new ArrayList<>(); -// BookingRegistrationDTO oldBooking = new BookingRegistrationDTO(); -// BookingRegistrationDTO newBooking = new BookingRegistrationDTO(); -// Timestamp resTime = new Timestamp(System.currentTimeMillis()); -// @SuppressWarnings("rawtypes") -// MainResponseDTO responseDto = new MainResponseDTO(); -// private Object jsonObject = null; -// private Object jsonObjectMulti = null; - -// private Object jsonObject1 = null; -// CancelBookingResponseDTO cancelBookingResponseDTO = new CancelBookingResponseDTO(); -// CancelBookingDTO cancelbookingDto = new CancelBookingDTO(); -// MainRequestDTO dto = new MainRequestDTO<>(); -// MainRequestDTO requestDTO = new MainRequestDTO<>(); -// PreRegIdsByRegCenterIdResponseDTO preRegIdsResponseDTO = new PreRegIdsByRegCenterIdResponseDTO(); -// List respList = new ArrayList<>(); -// PreRegIdsByRegCenterIdDTO preRegIdsByRegCenterIdDTO = new PreRegIdsByRegCenterIdDTO(); - -// String preId = "23587986034785"; - -// @SuppressWarnings({ "deprecation" }) -// @Before -// public void setup() throws FileNotFoundException, ParseException, URISyntaxException { -// availabilityDto = new AvailabilityDto(); -// ClassLoader classLoader = getClass().getClassLoader(); -// JSONParser parser = new JSONParser(); - -// URI dataSyncUri = new URI( -// classLoader.getResource("booking.json").getFile().trim().replaceAll("\\u0020", "%20")); -// File file = new File(dataSyncUri.getPath()); - -// jsonObject = parser.parse(new FileReader(file)); - -// URI multiBookingUrl = new URI( -// classLoader.getResource("multibooking.json").getFile().trim().replaceAll("\\u0020", "%20")); -// File fileMulti = new File(multiBookingUrl.getPath()); -// jsonObjectMulti = parser.parse(new FileReader(fileMulti)); - -// bookingRequestDTO.setRegDate("1"); -// bookingRequestDTO.setSlotFromTime("09:00"); -// bookingRequestDTO.setSlotToTime("09:13"); -// bookingRequestDTO.setRegDate("2018-12-06"); - -// bookingDTO.setRequest(bookingList); - -// responseDto.setErrors(null); - -// URI cancelUri = new URI( -// classLoader.getResource("cancelAppointment.json").getFile().trim().replaceAll("\\u0020", "%20")); -// File file1 = new File(cancelUri.getPath()); // -// jsonObject1 = parser.parse(new FileReader(file1)); - -// cancelbookingDto.setRegistrationCenterId("2"); -// cancelbookingDto.setSlotFromTime("09:00"); -// cancelbookingDto.setSlotToTime("09:20"); -// String restime = "2018-12-04T07:22:57.086+0000"; -// cancelbookingDto.setRegDate(restime); - -// dto.setRequest(cancelbookingDto); -// requestDTO.setRequest(preRegIdsByRegCenterIdDTO); -// List respList = new ArrayList<>(); -// respList.add("Reterived all pre-registration ids successfully"); -// preRegIdsResponseDTO.setRegistrationCenterId("1"); -// preRegIdsResponseDTO.setPreRegistrationIds(respList); -// } - -// @WithUserDetails("INDIVIDUAL") -// @Test -// public void getAvailability() throws Exception { -// MainResponseDTO response = new MainResponseDTO<>(); -// Mockito.when(service.getAvailability(Mockito.any())).thenReturn(response); -// RequestBuilder requestBuilder = MockMvcRequestBuilders -// .get("/appointment/availability/{registrationCenterId}", "1001") -// .contentType(MediaType.APPLICATION_JSON_VALUE).characterEncoding("UTF-8") -// .accept(MediaType.APPLICATION_JSON_VALUE).param("registration_center_id", "1"); -// mockMvc.perform(requestBuilder).andExpect(status().isOk()); -// } - -// @SuppressWarnings("unchecked") -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void successBookingTest() throws Exception { - -// responseDto.setResponsetime(serviceUtil.getCurrentResponseTime()); -// List respList = new ArrayList<>(); -// respList.add("APPOINTMENT_SUCCESSFULLY_BOOKED"); -// responseDto.setResponse(respList); - -// Mockito.when(service.bookAppointment(bookingDTO, preId)).thenReturn(responseDto); - -// bookingDTO.setId("mosip.preregistration.booking.book"); -// bookingDTO.setVersion("1.0"); -// bookingDTO.setRequesttime(new Date()); -// bookingDTO.setRequest(bookingRequestDTO); - -// BeanPropertyBindingResult errors = new BeanPropertyBindingResult(bookingDTO, "MainRequestDTO"); -// ResponseEntity> responseEntity = controller.bookAppoinment(preId, bookingDTO, -// errors); -// assertEquals(HttpStatus.OK, responseEntity.getStatusCode()); -// } - -// @SuppressWarnings("unchecked") -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void successMultiBookingTest() throws Exception { - -// multiBookingListDto.add(multiBookingRequestDto1); -// multiBookingListDto.add(multiBookingRequestDto2); - -// MultiBookingRequest multiBookingRequest = new MultiBookingRequest(); -// multiBookingRequest.setBookingRequest(multiBookingListDto); // -// responseDto.setResponsetime(serviceUtil.getCurrentResponseTime()); - -// BookingStatus bookingStatus = new BookingStatus(); -// BookingStatusDTO bookingStatusDTO1 = new BookingStatusDTO(); -// bookingStatusDTO1.setBookingMessage("Appointment booked successfully"); - -// BookingStatusDTO bookingStatusDTO2 = new BookingStatusDTO(); -// bookingStatusDTO2.setBookingMessage("Appointment booked successfully"); - -// List bookingStatusDTOs = new ArrayList<>(); -// bookingStatusDTOs.add(bookingStatusDTO1); -// bookingStatusDTOs.add(bookingStatusDTO2); - -// bookingStatus.setBookingStatusResponse(bookingStatusDTOs); -// responseDto.setErrors(null); -// responseDto.setResponsetime(serviceUtil.getCurrentResponseTime()); -// responseDto.setResponse(bookingStatus); - -// Mockito.when(service.bookMultiAppointment(bookingDTO)).thenReturn(responseDto); - -// bookingDTO.setId("mosip.preregistration.booking.book"); -// bookingDTO.setVersion("1.0"); -// bookingDTO.setRequesttime(new Date()); -// bookingDTO.setRequest(multiBookingRequestDto1); - -// BeanPropertyBindingResult errors = new BeanPropertyBindingResult(bookingDTO, -// "MainRequestDTO"); -// ResponseEntity> responseEntity = controller.bookMultiAppoinment(bookingDTO, -// errors); // -// assertEquals(HttpStatus.OK, responseEntity.getStatusCode()); -// } - -// @SuppressWarnings("unchecked") -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void failureBookingTest() throws Exception { - -// bookingDTO.setRequest(null); -// Mockito.when(service.bookAppointment(bookingDTO, preId)).thenReturn(responseDto); - -// RequestBuilder requestBuilder = MockMvcRequestBuilders.post("/appointment/{preRegistrationId}", preId) -// .contentType(MediaType.APPLICATION_JSON_VALUE).characterEncoding("UTF-8") -// .accept(MediaType.APPLICATION_JSON_VALUE).content(jsonObject.toString()); - -// mockMvc.perform(requestBuilder).andExpect(status().isOk()); -// } - -// @SuppressWarnings("unchecked") -// @Test -// @WithUserDetails("PRE_REGISTRATION_ADMIN") -// public void cancelAppointmentSuccessTest() throws Exception { - -// responseDto.setErrors(null); -// responseDto.setResponsetime(serviceUtil.getCurrentResponseTime()); -// cancelBookingResponseDTO.setMessage("APPOINTMENT_SUCCESSFULLY_CANCELED"); -// cancelBookingResponseDTO.setTransactionId("375765"); -// responseDto.setResponse(cancelBookingResponseDTO); - -// Mockito.when(service.cancelAppointment(preId)).thenReturn(responseDto); -// ResponseEntity> responseEntity = controller -// .cancelAppointmentBatch(preId); -// assertEquals(HttpStatus.OK, responseEntity.getStatusCode()); -// } - -// @SuppressWarnings("unchecked") -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void cancelAppointmentFailureTest() throws Exception { - -// dto.setRequest(null); -// Mockito.when(service.cancelAppointment(preId)).thenReturn(responseDto); - -// RequestBuilder requestBuilder = MockMvcRequestBuilders.put("/appointment/{preRegistrationId}", preId) -// .contentType(MediaType.APPLICATION_JSON_VALUE).characterEncoding("UTF-8") -// .accept(MediaType.APPLICATION_JSON_VALUE).content(jsonObject1.toString()); - -// mockMvc.perform(requestBuilder).andExpect(status().isOk()); -// } - -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void getAppointmentDetails() throws Exception { -// MainResponseDTO response = new MainResponseDTO<>(); -// Mockito.when(service.getAppointmentDetails("12345")).thenReturn(response); -// RequestBuilder requestBuilder = MockMvcRequestBuilders.get("/appointment/{preRegistrationId}", preId) -// .contentType(MediaType.APPLICATION_JSON_VALUE).characterEncoding("UTF-8") -// .accept(MediaType.APPLICATION_JSON_VALUE).param("pre_registration_id", "12345"); -// mockMvc.perform(requestBuilder).andExpect(status().isOk()); -// } - -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void deleteBookingTest() throws Exception { -// String preId = "3"; -// MainResponseDTO response = new MainResponseDTO<>(); -// List DeleteList = new ArrayList(); -// DeleteBookingDTO deleteDto = new DeleteBookingDTO(); - -// deleteDto.setPreRegistrationId("3"); -// deleteDto.setDeletedBy("9527832358"); -// DeleteList.add(deleteDto); -// response.setResponse(deleteDto); -// Mockito.when(service.deleteBooking(preId)).thenReturn(response); - -// RequestBuilder requestBuilder = MockMvcRequestBuilders.delete("/appointment") -// .contentType(MediaType.APPLICATION_JSON_VALUE).characterEncoding("UTF-8") -// .accept(MediaType.APPLICATION_JSON_VALUE).param("preRegistrationId", preId); -// mockMvc.perform(requestBuilder).andExpect(status().isOk()); -// } - -// @Test -// @WithUserDetails("INDIVIDUAL") -// public void getAllApplicationByDateTest() throws Exception { - -// String fromDate = "2018-12-06"; -// String toDate = "2018-12-06"; -// MainResponseDTO response = new MainResponseDTO<>(); -// List preIds = new ArrayList<>(); -// preIds.add("1234"); -// PreRegIdsByRegCenterIdResponseDTO byRegCenterIdResponseDTO = new PreRegIdsByRegCenterIdResponseDTO(); -// byRegCenterIdResponseDTO.setPreRegistrationIds(preIds); -// byRegCenterIdResponseDTO.setRegistrationCenterId("10001"); -// response.setResponse(byRegCenterIdResponseDTO); -// Mockito.when(service.getBookedPreRegistrationByDate(Mockito.any(), Mockito.any(), Mockito.anyString())) -// .thenReturn(response); - -// RequestBuilder requestBuilder = MockMvcRequestBuilders -// .get("/appointment/preRegistrationId/{registrationCenterId}", "1001") -// .contentType(MediaType.APPLICATION_JSON_VALUE).characterEncoding("UTF-8") -// .accept(MediaType.APPLICATION_JSON_VALUE).param("from_date", fromDate) -// .accept(MediaType.APPLICATION_JSON_VALUE).param("to_date", toDate); - -// mockMvc.perform(requestBuilder).andExpect(status().isOk()); - -// } -// } +package io.mosip.preregistration.booking.test.controller; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertSame; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.eq; +import static org.mockito.Mockito.verify; +import static org.mockito.Mockito.when; + +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.InjectMocks; +import org.mockito.Mock; +import org.mockito.junit.MockitoJUnitRunner; +import org.springframework.http.HttpStatus; +import org.springframework.http.ResponseEntity; +import org.springframework.validation.BeanPropertyBindingResult; +import org.springframework.validation.Errors; +import org.springframework.web.bind.WebDataBinder; + +import io.mosip.preregistration.booking.controller.BookingController; +import io.mosip.preregistration.booking.dto.AvailabilityDto; +import io.mosip.preregistration.booking.dto.BookingDataByRegIdDto; +import io.mosip.preregistration.booking.dto.BookingRequestDTO; +import io.mosip.preregistration.booking.dto.BookingStatus; +import io.mosip.preregistration.booking.dto.BookingStatusDTO; +import io.mosip.preregistration.booking.dto.MultiBookingRequest; +import io.mosip.preregistration.booking.service.BookingServiceIntf; +import io.mosip.preregistration.core.common.dto.BookingRegistrationDTO; +import io.mosip.preregistration.core.common.dto.CancelBookingResponseDTO; +import io.mosip.preregistration.core.common.dto.DeleteBookingDTO; +import io.mosip.preregistration.core.common.dto.MainRequestDTO; +import io.mosip.preregistration.core.common.dto.MainResponseDTO; +import io.mosip.preregistration.core.common.dto.PreRegIdsByRegCenterIdResponseDTO; +import io.mosip.preregistration.core.util.RequestValidator; + +@RunWith(MockitoJUnitRunner.class) +public class BookingControllerTest { + + private static final String PRE_ID = "98765432101234"; + private static final String CENTER_ID = "10001"; + private static final String FROM = "2026-12-01"; + private static final String TO = "2026-12-10"; + + @Mock + private BookingServiceIntf bookingService; + + @Mock + private RequestValidator requestValidator; + + @InjectMocks + private BookingController controller; + + private Errors errors; + + @Before + public void setUp() { + errors = new BeanPropertyBindingResult(new MainRequestDTO<>(), "request"); + } + + @Test + public void initBinderRegistersRequestValidator() { + WebDataBinder binder = org.mockito.Mockito.mock(WebDataBinder.class); + controller.initBinder(binder); + verify(binder).addValidators(requestValidator); + } + + @Test + public void getAvailabilityDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.getAvailability(CENTER_ID)).thenReturn(body); + + ResponseEntity> response = controller.getAvailability(CENTER_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void bookAppointmentValidatesIdThenDelegates() { + MainRequestDTO request = new MainRequestDTO<>(); + request.setId("book"); + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.bookAppointment(request, PRE_ID)).thenReturn(body); + + ResponseEntity> response = controller.bookAppoinment(PRE_ID, request, errors); + + verify(requestValidator).validateId(eq("book"), eq("book"), any(Errors.class)); + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void bookMultiAppointmentValidatesIdThenDelegates() { + MainRequestDTO request = new MainRequestDTO<>(); + request.setId("book"); + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.bookMultiAppointment(request)).thenReturn(body); + + ResponseEntity> response = controller.bookMultiAppoinment(request, errors); + + verify(requestValidator).validateId(eq("book"), eq("book"), any(Errors.class)); + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void getAppointmentsDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.getAppointmentDetails(PRE_ID)).thenReturn(body); + + ResponseEntity> response = controller.getAppointments(PRE_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void cancelBookDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.cancelAppointment(PRE_ID)).thenReturn(body); + + ResponseEntity> response = controller.cancelBook(PRE_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void cancelAppointmentBatchDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.cancelAppointmentBatch(PRE_ID)).thenReturn(body); + + ResponseEntity> response = controller.cancelAppointmentBatch(PRE_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void discardIndividualDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.deleteBooking(PRE_ID)).thenReturn(body); + + ResponseEntity> response = controller.discardIndividual(PRE_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void getBookedDataByDateDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.getBookedPreRegistrationByDate(FROM, TO, CENTER_ID)).thenReturn(body); + + ResponseEntity> response = controller.getBookedDataByDate( + FROM, TO, CENTER_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } + + @Test + public void getBookedDataByRegIdDelegatesToService() { + MainResponseDTO body = new MainResponseDTO<>(); + when(bookingService.getBookedPreRegistrations(FROM, TO, CENTER_ID)).thenReturn(body); + + ResponseEntity> response = controller.getBookedDataByRegId(FROM, TO, + CENTER_ID); + + assertEquals(HttpStatus.OK, response.getStatusCode()); + assertSame(body, response.getBody()); + } +} diff --git a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceCoverageTest.java b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceCoverageTest.java new file mode 100644 index 00000000000..68ca591f5f7 --- /dev/null +++ b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceCoverageTest.java @@ -0,0 +1,594 @@ +package io.mosip.preregistration.booking.test.service; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertTrue; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.anyMap; +import static org.mockito.ArgumentMatchers.anyString; +import static org.mockito.ArgumentMatchers.eq; +import static org.mockito.Mockito.never; +import static org.mockito.Mockito.verify; +import static org.mockito.Mockito.when; + +import java.time.LocalDate; +import java.time.LocalTime; +import java.util.ArrayList; +import java.util.Collections; +import java.util.Date; +import java.util.List; + +import org.junit.After; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mockito.InjectMocks; +import org.mockito.Mock; +import org.mockito.Spy; +import org.mockito.junit.MockitoJUnitRunner; +import org.springframework.security.authentication.UsernamePasswordAuthenticationToken; +import org.springframework.security.core.context.SecurityContextHolder; +import org.springframework.test.util.ReflectionTestUtils; + +import io.mosip.kernel.core.authmanager.authadapter.model.AuthUserDetails; +import io.mosip.preregistration.booking.dto.AvailabilityDto; +import io.mosip.preregistration.booking.dto.BookingDataByRegIdDto; +import io.mosip.preregistration.booking.dto.BookingRequestDTO; +import io.mosip.preregistration.booking.dto.BookingStatus; +import io.mosip.preregistration.booking.dto.BookingStatusDTO; +import io.mosip.preregistration.booking.dto.MultiBookingRequest; +import io.mosip.preregistration.booking.dto.MultiBookingRequestDTO; +import io.mosip.preregistration.booking.dto.RegistrationCenterDto; +import io.mosip.preregistration.booking.entity.AvailibityEntity; +import io.mosip.preregistration.booking.errorcodes.ErrorCodes; +import io.mosip.preregistration.booking.errorcodes.ErrorMessages; +import io.mosip.preregistration.booking.exception.AvailablityNotFoundException; +import io.mosip.preregistration.booking.exception.DemographicGetStatusException; +import io.mosip.preregistration.booking.exception.RecordNotFoundException; +import io.mosip.preregistration.booking.repository.impl.BookingDAO; +import io.mosip.preregistration.booking.service.BookingService; +import io.mosip.preregistration.booking.service.util.BookingLock; +import io.mosip.preregistration.booking.service.util.BookingServiceUtil; +import io.mosip.preregistration.core.code.StatusCodes; +import io.mosip.preregistration.core.common.dto.BookingRegistrationDTO; +import io.mosip.preregistration.core.common.dto.CancelBookingResponseDTO; +import io.mosip.preregistration.core.common.dto.MainRequestDTO; +import io.mosip.preregistration.core.common.dto.MainResponseDTO; +import io.mosip.preregistration.core.common.dto.PreRegIdsByRegCenterIdResponseDTO; +import io.mosip.preregistration.core.common.entity.RegistrationBookingEntity; +import io.mosip.preregistration.core.common.service.ApplicationIdentityMigrationService; +import io.mosip.preregistration.core.exception.PreRegistrationException; +import io.mosip.preregistration.core.util.AuditLogUtil; +import io.mosip.preregistration.core.util.ValidationUtil; + +@RunWith(MockitoJUnitRunner.Silent.class) +public class BookingServiceCoverageTest { + + private static final String PRE_ID = "98765432101234"; + private static final String CENTER_ID = "10001"; + private static final String REG_DATE = "2026-12-10"; + private static final String FROM = "09:00"; + private static final String TO = "09:15"; + + @Mock + private BookingDAO bookingDAO; + + @Mock + private BookingServiceUtil serviceUtil; + + @Mock + private ApplicationIdentityMigrationService applicationIdentityMigrationService; + + @Mock + private ValidationUtil validationUtil; + + @Mock + private AuditLogUtil auditLogUtil; + + @Spy + private BookingLock bookingLock = new BookingLock(); + + @InjectMocks + private BookingService bookingService; + + private BookingRequestDTO bookingRequestDTO; + private AvailibityEntity availabilityEntity; + private RegistrationBookingEntity bookingEntity; + private AuthUserDetails principal; + + @Before + public void setUp() { + ReflectionTestUtils.setField(bookingService, "syncDays", 7); + ReflectionTestUtils.setField(bookingService, "displayDays", 7L); + ReflectionTestUtils.setField(bookingService, "availabilityOffset", 2); + ReflectionTestUtils.setField(bookingService, "versionUrl", "1.0"); + ReflectionTestUtils.setField(bookingService, "idUrlSync", "sync"); + ReflectionTestUtils.setField(bookingService, "idUrlBookAppointment", "book"); + ReflectionTestUtils.setField(bookingService, "idUrlFetch", "fetch"); + ReflectionTestUtils.setField(bookingService, "idUrlCancel", "cancel"); + ReflectionTestUtils.setField(bookingService, "idUrlDelete", "delete"); + ReflectionTestUtils.setField(bookingService, "idUrlAvailability", "availability"); + ReflectionTestUtils.setField(bookingService, "idUrlBookingByDate", "booking-by-date"); + ReflectionTestUtils.setField(bookingService, "idUrlIncreaseAvailability", "increase"); + ReflectionTestUtils.setField(bookingService, "idUrlCheckSlotAvailability", "check-slot"); + ReflectionTestUtils.setField(bookingService, "idUrlDeleteOld", "delete-old"); + + principal = org.mockito.Mockito.mock(AuthUserDetails.class); + when(principal.getUserId()).thenReturn("user-1"); + when(principal.getUsername()).thenReturn("user-1"); + SecurityContextHolder.getContext() + .setAuthentication(new UsernamePasswordAuthenticationToken(principal, null)); + + when(serviceUtil.getCurrentResponseTime()).thenReturn("2026-09-29T00:00:00.000Z"); + + bookingRequestDTO = new BookingRequestDTO(); + bookingRequestDTO.setRegistrationCenterId(CENTER_ID); + bookingRequestDTO.setRegDate(REG_DATE); + bookingRequestDTO.setSlotFromTime(FROM); + bookingRequestDTO.setSlotToTime(TO); + + availabilityEntity = new AvailibityEntity(); + availabilityEntity.setRegcntrId(CENTER_ID); + availabilityEntity.setRegDate(LocalDate.parse(REG_DATE)); + availabilityEntity.setFromTime(LocalTime.parse(FROM)); + availabilityEntity.setToTime(LocalTime.parse(TO)); + availabilityEntity.setAvailableKiosks(5); + + bookingEntity = new RegistrationBookingEntity(); + bookingEntity.setCrBy("creator"); + bookingEntity.setPreregistrationId(PRE_ID); + bookingEntity.setRegistrationCenterId(CENTER_ID); + bookingEntity.setRegDate(LocalDate.parse(REG_DATE)); + bookingEntity.setSlotFromTime(LocalTime.parse(FROM)); + bookingEntity.setSlotToTime(LocalTime.parse(TO)); + } + + @After + public void tearDown() { + SecurityContextHolder.clearContext(); + } + + @Test + public void setupBookingServiceIsNoOp() { + bookingService.setupBookingService(); + } + + @Test + public void authUserDetailsReturnsPrincipal() { + assertEquals(principal, bookingService.authUserDetails()); + } + + @Test + public void getAvailabilityReturnsSlots() { + when(serviceUtil.isValidRegCenter(CENTER_ID)).thenReturn(true); + when(bookingDAO.findAvailability(eq(CENTER_ID), any(LocalDate.class), any(LocalDate.class))) + .thenReturn(List.of(availabilityEntity)); + when(serviceUtil.slotSetter(any(), any(), any(), any())).thenReturn(0); + + MainResponseDTO response = bookingService.getAvailability(CENTER_ID); + + assertEquals(CENTER_ID, response.getResponse().getRegCenterId()); + assertEquals("availability", response.getId()); + verify(auditLogUtil).saveAuditDetails(any()); + } + + @Test + public void getAvailabilityHolidayLookaheadThenEmpty() { + when(serviceUtil.isValidRegCenter(CENTER_ID)).thenReturn(true); + when(bookingDAO.findAvailability(eq(CENTER_ID), any(LocalDate.class), any(LocalDate.class))) + .thenReturn(List.of(availabilityEntity)).thenReturn(null); + when(serviceUtil.slotSetter(any(), any(), any(), any())).thenReturn(2); + + MainResponseDTO response = bookingService.getAvailability(CENTER_ID); + + assertEquals(CENTER_ID, response.getResponse().getRegCenterId()); + verify(bookingDAO, org.mockito.Mockito.times(2)).findAvailability(eq(CENTER_ID), any(LocalDate.class), + any(LocalDate.class)); + } + + @Test + public void getAvailabilityHolidayLookaheadFindsMoreSlots() { + AvailibityEntity nextDay = new AvailibityEntity(); + nextDay.setRegcntrId(CENTER_ID); + nextDay.setRegDate(LocalDate.parse("2026-12-11")); + nextDay.setFromTime(LocalTime.parse(FROM)); + nextDay.setToTime(LocalTime.parse(TO)); + nextDay.setAvailableKiosks(3); + + when(serviceUtil.isValidRegCenter(CENTER_ID)).thenReturn(true); + when(bookingDAO.findAvailability(eq(CENTER_ID), any(LocalDate.class), any(LocalDate.class))) + .thenReturn(List.of(availabilityEntity)).thenReturn(List.of(nextDay)); + when(serviceUtil.slotSetter(any(), any(), any(), any())).thenReturn(1).thenReturn(0); + + MainResponseDTO response = bookingService.getAvailability(CENTER_ID); + + assertNotNull(response.getResponse().getCenterDetails()); + } + + @Test(expected = RecordNotFoundException.class) + public void getAvailabilityThrowsWhenNoSlots() { + when(serviceUtil.isValidRegCenter(CENTER_ID)).thenReturn(true); + when(bookingDAO.findAvailability(eq(CENTER_ID), any(LocalDate.class), any(LocalDate.class))).thenReturn(null); + + bookingService.getAvailability(CENTER_ID); + } + + @Test + public void bookAppointmentPendingAppointmentCreatesBooking() { + stubSuccessfulBookPath(StatusCodes.PENDING_APPOINTMENT.getCode()); + + MainResponseDTO response = bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + + assertEquals("Appointment booked successfully", response.getResponse().getBookingMessage()); + verify(bookingDAO).saveRegistrationEntityForBooking(any()); + } + + @Test + public void bookAppointmentCancelledCreatesBooking() { + stubSuccessfulBookPath(StatusCodes.CANCELLED.getCode()); + + MainResponseDTO response = bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + + assertEquals("Appointment booked successfully", response.getResponse().getBookingMessage()); + } + + @Test + public void bookAppointmentBookedRebooks() { + stubSuccessfulBookPath(StatusCodes.BOOKED.getCode()); + when(bookingDAO.findByPreRegistrationId(PRE_ID)).thenReturn(bookingEntity); + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)).thenReturn(1); + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + when(serviceUtil.timeSpanCheckForRebook(any(), any())).thenReturn(true); + + MainResponseDTO response = bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + + assertEquals("Appointment booked successfully", response.getResponse().getBookingMessage()); + verify(bookingDAO, org.mockito.Mockito.atLeastOnce()).deleteByPreRegistrationId(PRE_ID); + } + + @Test + public void bookAppointmentExpiredDeletesThenBooks() { + stubSuccessfulBookPath(StatusCodes.EXPIRED.getCode()); + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)).thenReturn(1); + + MainResponseDTO response = bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + + assertEquals("Appointment booked successfully", response.getResponse().getBookingMessage()); + } + + @Test(expected = DemographicGetStatusException.class) + public void bookAppointmentRejectsIncompleteApplication() { + when(serviceUtil.validateAppointmentDate(anyMap())).thenReturn(true); + when(serviceUtil.getApplicationBookingStatus(PRE_ID)) + .thenReturn(StatusCodes.APPLICATION_INCOMPLETE.getCode()); + + bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + } + + @Test(expected = DemographicGetStatusException.class) + public void bookAppointmentRejectsPrefetchedApplication() { + when(serviceUtil.validateAppointmentDate(anyMap())).thenReturn(true); + when(serviceUtil.getApplicationBookingStatus(PRE_ID)).thenReturn(StatusCodes.PREFETCHED.getCode()); + + bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + } + + @Test + public void bookAppointmentSkipsWhenDateInvalid() { + when(serviceUtil.validateAppointmentDate(anyMap())).thenReturn(false); + + MainResponseDTO response = bookingService.bookAppointment(mainBookingRequest(), PRE_ID); + + verify(bookingDAO, never()).saveRegistrationEntityForBooking(any()); + assertNotNull(response); + } + + @Test + public void bookMultiAppointmentPendingAppointment() { + stubSuccessfulBookPath(StatusCodes.PENDING_APPOINTMENT.getCode()); + + MainResponseDTO response = bookingService.bookMultiAppointment(multiBookingRequest()); + + assertEquals(1, response.getResponse().getBookingStatusResponse().size()); + } + + @Test + public void bookMultiAppointmentBookedRebooks() { + stubSuccessfulBookPath(StatusCodes.BOOKED.getCode()); + when(bookingDAO.findByPreRegistrationId(PRE_ID)).thenReturn(bookingEntity); + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)).thenReturn(1); + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + when(serviceUtil.timeSpanCheckForRebook(any(), any())).thenReturn(true); + + MainResponseDTO response = bookingService.bookMultiAppointment(multiBookingRequest()); + + assertEquals(1, response.getResponse().getBookingStatusResponse().size()); + } + + @Test + public void bookMultiAppointmentExpiredDeletesThenBooks() { + stubSuccessfulBookPath(StatusCodes.EXPIRED.getCode()); + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)).thenReturn(1); + + MainResponseDTO response = bookingService.bookMultiAppointment(multiBookingRequest()); + + assertEquals(1, response.getResponse().getBookingStatusResponse().size()); + } + + @Test + public void bookMultiAppointmentCancelledCreatesBooking() { + stubSuccessfulBookPath(StatusCodes.CANCELLED.getCode()); + + MainResponseDTO response = bookingService.bookMultiAppointment(multiBookingRequest()); + + assertEquals(1, response.getResponse().getBookingStatusResponse().size()); + } + + @Test(expected = DemographicGetStatusException.class) + public void bookMultiAppointmentRejectsIncomplete() { + when(serviceUtil.validateAppointmentDate(anyMap())).thenReturn(true); + when(serviceUtil.getApplicationBookingStatus(PRE_ID)) + .thenReturn(StatusCodes.APPLICATION_INCOMPLETE.getCode()); + + bookingService.bookMultiAppointment(multiBookingRequest()); + } + + @Test(expected = DemographicGetStatusException.class) + public void bookMultiAppointmentRejectsPrefetched() { + when(serviceUtil.validateAppointmentDate(anyMap())).thenReturn(true); + when(serviceUtil.getApplicationBookingStatus(PRE_ID)).thenReturn(StatusCodes.PREFETCHED.getCode()); + + bookingService.bookMultiAppointment(multiBookingRequest()); + } + + @Test + public void getAppointmentDetailsReturnsSlot() { + when(serviceUtil.checkApplicationStatus(PRE_ID)).thenReturn(true); + when(bookingDAO.findByPreRegistrationId(PRE_ID)).thenReturn(bookingEntity); + + MainResponseDTO response = bookingService.getAppointmentDetails(PRE_ID); + + assertEquals(CENTER_ID, response.getResponse().getRegistrationCenterId()); + assertEquals(REG_DATE, response.getResponse().getRegDate()); + } + + @Test(expected = PreRegistrationException.class) + public void getAppointmentDetailsRejectsBlankId() { + bookingService.getAppointmentDetails(" "); + } + + @Test(expected = PreRegistrationException.class) + public void getAppointmentDetailsRejectsNullId() { + bookingService.getAppointmentDetails(null); + } + + @Test + public void cancelAppointmentWrapsCancelBooking() { + stubCancelSuccess(false); + + MainResponseDTO response = bookingService.cancelAppointment(PRE_ID); + + assertTrue(response.getResponse().getMessage().contains("cancelled")); + assertEquals("cancel", response.getId()); + } + + @Test + public void cancelAppointmentBatchSkipsTimeSpanCheck() { + stubCancelSuccess(true); + + MainResponseDTO response = bookingService.cancelAppointmentBatch(PRE_ID); + + assertTrue(response.getResponse().getMessage().contains("cancelled")); + verify(serviceUtil, never()).timeSpanCheckForCancle(any()); + } + + @Test + public void checkSlotAvailabilitySucceedsWhenKioskOpen() { + RegistrationCenterDto center = new RegistrationCenterDto(); + center.setId(CENTER_ID); + when(serviceUtil.getRegCenterMasterData(CENTER_ID)).thenReturn(List.of(center)); + when(bookingDAO.findRegistrationCenterId(CENTER_ID)).thenReturn(true); + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + + bookingService.checkSlotAvailability(bookingRequestDTO); + + verify(bookingDAO).findRegistrationCenterId(CENTER_ID); + } + + @Test(expected = RecordNotFoundException.class) + public void checkSlotAvailabilityRejectsUnknownCenter() { + RegistrationCenterDto other = new RegistrationCenterDto(); + other.setId("99999"); + when(serviceUtil.getRegCenterMasterData(CENTER_ID)).thenReturn(List.of(other)); + + bookingService.checkSlotAvailability(bookingRequestDTO); + } + + @Test(expected = AvailablityNotFoundException.class) + public void checkSlotAvailabilityRejectsEmptySlot() { + RegistrationCenterDto center = new RegistrationCenterDto(); + center.setId(CENTER_ID); + availabilityEntity.setAvailableKiosks(0); + when(serviceUtil.getRegCenterMasterData(CENTER_ID)).thenReturn(List.of(center)); + when(bookingDAO.findRegistrationCenterId(CENTER_ID)).thenReturn(true); + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + + bookingService.checkSlotAvailability(bookingRequestDTO); + } + + @Test + public void deleteOldBookingReturnsTrueWhenRowsDeleted() { + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)).thenReturn(2); + + assertTrue(bookingService.deleteOldBooking(PRE_ID)); + } + + @Test + public void deleteOldBookingReturnsFalseWhenNothingDeleted() { + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)).thenReturn(0); + + assertFalse(bookingService.deleteOldBooking(PRE_ID)); + } + + @Test(expected = RecordNotFoundException.class) + public void deleteOldBookingRethrowsMappedException() { + when(bookingDAO.deleteByPreRegistrationId(PRE_ID)) + .thenThrow(new RecordNotFoundException(ErrorCodes.PRG_BOOK_RCI_015.getCode(), + ErrorMessages.NO_TIME_SLOTS_ASSIGNED_TO_THAT_REG_CENTER.getMessage())); + + bookingService.deleteOldBooking(PRE_ID); + } + + @Test + public void increaseAvailabilityIncrementsKioskCount() { + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + when(bookingDAO.updateAvailibityEntity(any())).thenReturn(availabilityEntity); + + assertTrue(bookingService.increaseAvailability(bookingRequestDTO)); + assertEquals(6, availabilityEntity.getAvailableKiosks()); + } + + @Test(expected = RecordNotFoundException.class) + public void increaseAvailabilityRethrowsMappedException() { + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenThrow(new RecordNotFoundException(ErrorCodes.PRG_BOOK_RCI_015.getCode(), + ErrorMessages.NO_TIME_SLOTS_ASSIGNED_TO_THAT_REG_CENTER.getMessage())); + + bookingService.increaseAvailability(bookingRequestDTO); + } + + @Test + public void setAuditValuesPersistsAudit() { + bookingService.setAuditValues("PRE_401", "RETRIEVE", "BUSINESS", "ok", "id-type", "user-1", "user-1", + CENTER_ID); + + verify(auditLogUtil).saveAuditDetails(any()); + } + + @Test + public void getBookedPreRegistrationByDateReturnsIds() { + when(serviceUtil.validateFromDateAndToDate(anyString(), anyString(), anyString())).thenReturn(true); + when(bookingDAO.findByBookingDateBetweenAndRegCenterId(any(), any(), eq(CENTER_ID), any())) + .thenReturn(List.of(PRE_ID)); + + MainResponseDTO response = bookingService + .getBookedPreRegistrationByDate("2026-12-01", "2026-12-10", CENTER_ID); + + assertEquals(List.of(PRE_ID), response.getResponse().getPreRegistrationIds()); + assertEquals(CENTER_ID, response.getResponse().getRegistrationCenterId()); + } + + @Test + public void getBookedPreRegistrationByDateDefaultsEmptyToDate() { + when(serviceUtil.validateFromDateAndToDate(eq("2026-12-01"), eq("2026-12-01"), anyString())).thenReturn(true); + when(bookingDAO.findByBookingDateBetweenAndRegCenterId(any(), any(), eq(CENTER_ID), any())) + .thenReturn(new ArrayList<>()); + + MainResponseDTO response = bookingService + .getBookedPreRegistrationByDate("2026-12-01", "", CENTER_ID); + + assertNotNull(response.getResponse()); + } + + @Test(expected = RecordNotFoundException.class) + public void getBookedPreRegistrationByDateRethrowsMappedException() { + when(serviceUtil.validateFromDateAndToDate(anyString(), anyString(), anyString())) + .thenThrow(new RecordNotFoundException(ErrorCodes.PRG_BOOK_RCI_015.getCode(), + ErrorMessages.NO_TIME_SLOTS_ASSIGNED_TO_THAT_REG_CENTER.getMessage())); + + bookingService.getBookedPreRegistrationByDate("2026-12-01", "2026-12-10", CENTER_ID); + } + + @Test + public void getBookedPreRegistrationsReturnsSlotsById() { + when(serviceUtil.validateFromDateAndToDate(anyString(), anyString(), anyString())).thenReturn(true); + when(bookingDAO.findByBookingDateBetweenAndRegCenterId(any(), any(), eq(CENTER_ID), any())) + .thenReturn(List.of(PRE_ID)); + + MainResponseDTO response = bookingService.getBookedPreRegistrations("2026-12-01", + "2026-12-10", CENTER_ID); + + assertEquals(CENTER_ID, response.getResponse().getRegistrationCenterId()); + assertNotNull(response.getResponse().getIdsWithAppointmentDate()); + } + + @Test + public void getBookedPreRegistrationsDefaultsNullToDate() { + when(serviceUtil.validateFromDateAndToDate(eq("2026-12-01"), eq("2026-12-01"), anyString())).thenReturn(true); + when(bookingDAO.findByBookingDateBetweenAndRegCenterId(any(), any(), eq(CENTER_ID), any())) + .thenReturn(Collections.emptyList()); + + MainResponseDTO response = bookingService.getBookedPreRegistrations("2026-12-01", null, + CENTER_ID); + + assertEquals(CENTER_ID, response.getResponse().getRegistrationCenterId()); + } + + @Test(expected = RecordNotFoundException.class) + public void getBookedPreRegistrationsRethrowsMappedException() { + when(serviceUtil.validateFromDateAndToDate(anyString(), anyString(), anyString())) + .thenThrow(new RecordNotFoundException(ErrorCodes.PRG_BOOK_RCI_015.getCode(), + ErrorMessages.NO_TIME_SLOTS_ASSIGNED_TO_THAT_REG_CENTER.getMessage())); + + bookingService.getBookedPreRegistrations("2026-12-01", "2026-12-10", CENTER_ID); + } + + private void stubSuccessfulBookPath(String statusCode) { + when(serviceUtil.validateAppointmentDate(anyMap())).thenReturn(true); + when(serviceUtil.getApplicationBookingStatus(PRE_ID)).thenReturn(statusCode); + when(serviceUtil.mandatoryParameterCheck(eq(PRE_ID), any())).thenReturn(true); + when(serviceUtil.slotTimeValidCheck(eq(PRE_ID), any())).thenReturn(true); + RegistrationCenterDto center = new RegistrationCenterDto(); + center.setId(CENTER_ID); + when(serviceUtil.getRegCenterMasterData(CENTER_ID)).thenReturn(List.of(center)); + when(bookingDAO.findRegistrationCenterId(CENTER_ID)).thenReturn(true); + when(bookingDAO.findByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + when(bookingDAO.findFirstByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + when(serviceUtil.isKiosksAvailable(any())).thenReturn(true); + when(serviceUtil.bookingEntitySetter(anyString(), any())).thenReturn(bookingEntity); + when(bookingDAO.saveRegistrationEntityForBooking(any())).thenReturn(bookingEntity); + when(bookingDAO.updateAvailibityEntity(any())).thenReturn(availabilityEntity); + } + + private void stubCancelSuccess(boolean batch) { + when(serviceUtil.mandatoryParameterCheckforCancel(PRE_ID)).thenReturn(true); + when(serviceUtil.getDemographicStatusForCancel(PRE_ID)).thenReturn(true); + when(bookingDAO.findByPreRegistrationId(PRE_ID)).thenReturn(bookingEntity); + when(bookingDAO.findFirstByRegDateAndRegcntrIdAndFromTimeAndToTime(any(), anyString(), any(), any())) + .thenReturn(availabilityEntity); + when(bookingDAO.updateAvailibityEntity(any())).thenReturn(availabilityEntity); + if (!batch) { + when(serviceUtil.timeSpanCheckForCancle(any())).thenReturn(true); + } + } + + private MainRequestDTO mainBookingRequest() { + MainRequestDTO request = new MainRequestDTO<>(); + request.setRequest(bookingRequestDTO); + request.setRequesttime(new Date()); + return request; + } + + private MainRequestDTO multiBookingRequest() { + MultiBookingRequestDTO row = new MultiBookingRequestDTO(); + row.setPreRegistrationId(PRE_ID); + row.setRegistrationCenterId(CENTER_ID); + row.setRegDate(REG_DATE); + row.setSlotFromTime(FROM); + row.setSlotToTime(TO); + MultiBookingRequest multi = new MultiBookingRequest(); + multi.setBookingRequest(List.of(row)); + MainRequestDTO request = new MainRequestDTO<>(); + request.setRequest(multi); + request.setRequesttime(new Date()); + return request; + } +} diff --git a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceTest.java b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceTest.java index bc1be9d3ce5..a07b8e7160d 100644 --- a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceTest.java +++ b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/BookingServiceTest.java @@ -34,7 +34,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.boot.test.mock.mockito.MockBean; +import org.springframework.test.context.bean.override.mockito.MockitoBean; import org.springframework.core.ParameterizedTypeReference; import org.springframework.http.HttpMethod; import org.springframework.http.HttpStatus; @@ -116,26 +116,26 @@ @Ignore public class BookingServiceTest { - @MockBean + @MockitoBean private BookingAvailabilityRepository bookingAvailabilityRepository; - @MockBean + @MockitoBean private RegistrationBookingRepository registrationBookingRepository; /** * Mocking the RestTemplateBuilder bean */ - @MockBean(name = "selfTokenRestTemplate") + @MockitoBean(name = "selfTokenRestTemplate") RestTemplate restTemplate; - @MockBean + @MockitoBean private SecurityContextHolder context; - @MockBean + @MockitoBean private RequestValidator requestValidator; - @MockBean + @MockitoBean private AuditLogUtil auditLogUtil; private final Logger logger = LoggerFactory.getLogger(this.getClass()); @@ -144,7 +144,7 @@ public class BookingServiceTest { @InjectMocks private BookingService service; - @MockBean + @MockitoBean private BookingServiceUtil serviceUtil; private DemographicEntity preRegistrationEntity; @@ -152,16 +152,16 @@ public class BookingServiceTest { /** * Mocking the JsonValidatorImpl bean */ - @MockBean(name = "idObjectValidator") + @MockitoBean(name = "idObjectValidator") private IdObjectValidator jsonValidator; @Autowired private ValidationUtil validationUtil; - @MockBean + @MockitoBean ObjectMapper mapper; - @MockBean + @MockitoBean private BookingDAO bookingDAO; AuditRequestDto auditRequestDto = new AuditRequestDto(); diff --git a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/util/BookingServiceUtilTest.java b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/util/BookingServiceUtilTest.java index 831975c9c03..af64ed332f8 100644 --- a/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/util/BookingServiceUtilTest.java +++ b/pre-registration-booking-service/src/test/java/io/mosip/preregistration/booking/test/service/util/BookingServiceUtilTest.java @@ -23,7 +23,7 @@ import org.mockito.Mockito; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.boot.test.mock.mockito.MockBean; +import org.springframework.test.context.bean.override.mockito.MockitoBean; import org.springframework.core.ParameterizedTypeReference; import org.springframework.http.HttpEntity; import org.springframework.http.HttpHeaders; @@ -70,28 +70,28 @@ @SpringBootTest(classes = { BookingServiceUtil.class }) public class BookingServiceUtilTest { - @MockBean + @MockitoBean private BookingAvailabilityRepository bookingAvailabilityRepository; - @MockBean + @MockitoBean private RegistrationBookingRepository registrationBookingRepository; - @MockBean(name = "selfTokenRestTemplate") + @MockitoBean(name = "selfTokenRestTemplate") RestTemplate restTemplate; - @MockBean + @MockitoBean private RequestValidator requestValidator; - @MockBean + @MockitoBean ObjectMapper mapper; @Autowired private BookingServiceUtil serviceUtil; - @MockBean + @MockitoBean private BookingDAO bookingDAO; - @MockBean + @MockitoBean private UserDetailsService userDetailsService; @Mock diff --git a/pre-registration-booking-service/src/test/resources/bootstrap.properties b/pre-registration-booking-service/src/test/resources/bootstrap.properties index bd3627849d8..29cdedc6f0a 100644 --- a/pre-registration-booking-service/src/test/resources/bootstrap.properties +++ b/pre-registration-booking-service/src/test/resources/bootstrap.properties @@ -4,6 +4,7 @@ spring.cloud.config.name=pre-registration spring.application.name=pre-registration-booking-service spring.profiles.active=test management.endpoints.web.exposure.include=refresh +spring.info.git.location=classpath:service-git.properties server.servlet.context-path=/preregistration/v1 server.port=9095 @@ -13,8 +14,7 @@ openapi.info.description=Pre-Registration-Booking Service openapi.info.version=1.0 openapi.info.license.name=Mosip openapi.info.license.url=https://docs.mosip.io/platform/license -mosipbox.public.url=http://localhost:${server.port} -openapi.service.servers[0].url=${mosipbox.public.url}${server.servlet.context-path} +openapi.service.servers[0].url=${server.servlet.context-path} openapi.service.servers[0].description=Pre-Registration-Booking Service openapi.group.name=${openapi.info.title} openapi.group.paths[0]=/** diff --git a/registration-processor/AGENTS.md b/registration-processor/AGENTS.md new file mode 100644 index 00000000000..bdc88bbb2ef --- /dev/null +++ b/registration-processor/AGENTS.md @@ -0,0 +1,14 @@ +# registration-processor + +`registration-processor-ref-parent` (`packaging=pom`). Boot 4.1.1. No `pre-processor`. Child → that folder’s `AGENTS.md`. Pins in this `pom.xml`. + +``` +registration-processor/ +├── pom.xml AGENTS.md +├── registration-processor-external-stage/ Vert.x → EIS → AGENTS.md +└── registration-processor-external-integration-service/ EIS stub REST → AGENTS.md +``` + +```bash +mvn -f registration-processor/pom.xml -pl clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` diff --git a/registration-processor/README.md b/registration-processor/README.md new file mode 100644 index 00000000000..473dec3196e --- /dev/null +++ b/registration-processor/README.md @@ -0,0 +1,35 @@ +# registration-processor + +Parent **`registration-processor-ref-parent`** (`packaging=pom`). Spring Boot **4.1.1**, Java 21. No MOSIP `pre-processor` parent and no `kernel-bom`. MOSIP registration-processor jars are pinned in `registration-processor/pom.xml`. Logging via `kernel-core` (commons). + +## Modules + +| Module | Role | README | +|---|---|---| +| [registration-processor-external-stage](registration-processor-external-stage) | Vert.x stage: `EXTERNAL_STAGE_BUS_IN` → POST EIS → `EXTERNAL_STAGE_BUS_OUT` | [README](registration-processor-external-stage/README.md) | +| [registration-processor-external-integration-service](registration-processor-external-integration-service) | Country EIS stub REST (`true` if request body non-null) | [README](registration-processor-external-integration-service/README.md) | + +Prefix for stage properties: `mosip.regproc.external.` + +## Build + +From this directory: + +```text +mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn -pl registration-processor-external-integration-service clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +External-stage needs unpublished MOSIP SNAPSHOTs (`registration-processor-core`, status-service-impl, rest-client) installed locally if they are not on Central snapshots. EIS can be built with `-pl` on its own. + +JaCoCo LINE covered ratio **0.90** on `verify`. Git info: `service-git.properties`. + +## Config + +- [application-default.properties](https://github.com/mosip/mosip-config/blob/master/application-default.properties) +- [registration-processor-default.properties](https://github.com/mosip/mosip-config/blob/master/registration-processor-default.properties) + +## License + +[Mozilla Public License 2.0](../LICENSE) — [NOTICE](../NOTICE) diff --git a/registration-processor/pom.xml b/registration-processor/pom.xml new file mode 100644 index 00000000000..18a4d95e68f --- /dev/null +++ b/registration-processor/pom.xml @@ -0,0 +1,481 @@ + + + 4.0.0 + + + + org.springframework.boot + spring-boot-starter-parent + 4.1.1 + + + + io.mosip.registrationprocessor + registration-processor-ref-parent + 1.4.1-SNAPSHOT + pom + registration-processor + + Parent of MOSIP registration-processor reference implementations (external-stage, EIS stub). + Boot 4.1.1, Java 21, no kernel-bom, no pre-processor parent. + MOSIP registration-processor-* jars pinned here. + + https://github.com/mosip/mosip-ref-impl + + + registration-processor-external-stage + registration-processor-external-integration-service + + + + 21 + 21 + 21 + + false + + 3.16.0 + 3.5.1 + 3.6.0 + 0.8.15 + 5.8.0.7211 + 3.12.0 + 3.2.0 + 3.4.0 + 3.2.8 + 4.9.10 + 0.11.0 + + + + + 1.4.0-SNAPSHOT + 1.4.0-SNAPSHOT + 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT + 2025.1.3 + + 3.1.1 + + 4.5.34 + 1 + + **/constant/**,**/config/**,**/httpfilter/**,**/cache/**,**/entity/**,**/model/**,**/exception/**,**/repository/**,**/verticle/**,**/spi/**,**/proxy/**,**/entities/**,**/filter/**,**/util/**,**/verifier/**,**/*Application.java + **/dto/**,**/entity/**,**/config/** + ${project.build.directory}/site/jacoco/jacoco.xml + 0.90 + + + + + + + org.springframework.cloud + spring-cloud-dependencies + ${spring-cloud.version} + pom + import + + + + io.mosip.registrationprocessor + registration-processor-core + ${registration.processor.core.version} + + + + io.mosip.registrationprocessor + registration-processor-registration-status-service-impl + ${registration.status.service.version} + + + + io.mosip.registrationprocessor + registration-processor-rest-client + ${registration.processor.rest.client.version} + + + + io.mosip.kernel + kernel-auth-adapter + ${kernel.auth.adapter.version} + + + + org.springdoc + springdoc-openapi-starter-webmvc-ui + ${springdoc.version} + + + + io.vertx + vertx-unit + ${vertx.version} + + + + javax.inject + javax.inject + ${javax.inject.version} + + + + + + + + org.springframework.boot + spring-boot-jackson2 + + + + org.springframework.boot + spring-boot-starter-test + test + + + + org.junit.vintage + junit-vintage-engine + test + + + + org.projectlombok + lombok + provided + + + + + + ossrh + https://central.sonatype.com/repository/maven-snapshots/ + + + ossrh + https://central.sonatype.com/api/v1/publisher + + + + + + + + org.sonarsource.scanner.maven + sonar-maven-plugin + ${maven.sonar.plugin.version} + + + org.springframework.boot + spring-boot-maven-plugin + + true + + + + + build-info + repackage + + + false + + + + + + + + + org.sonatype.central + central-publishing-maven-plugin + ${central.publishing.maven.plugin.version} + true + + ossrh + false + + + + org.apache.maven.plugins + maven-surefire-plugin + ${maven.surefire.plugin.version} + + ${skipTests} + false + @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.lang.reflect=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.util.concurrent=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED + + + + org.jacoco + jacoco-maven-plugin + ${maven.jacoco.version} + + + **/constant/** + **/config/** + **/httpfilter/** + **/cache/** + **/entity/** + **/model/** + **/exception/** + **/repository/** + **/verticle/** + **/spi/** + **/proxy/** + **/entities/** + **/filter/** + **/util/** + **/verifier/** + **/*Application.class + + + + + + prepare-agent + + + + report + prepare-package + + report + + + + jacoco-check + + check + + + + + BUNDLE + + + LINE + COVEREDRATIO + ${jacoco.minimum.coverage} + + + + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + ${maven.compiler.plugin.version} + + ${java.version} + true + + + org.projectlombok + lombok + ${lombok.version} + + + + + + org.apache.maven.plugins + maven-source-plugin + ${maven.source.plugin.version} + + + attach-sources + + jar-no-fork + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + ${maven.javadoc.version} + + + attach-javadocs + + jar + + + + + none + false + false + + + + org.apache.maven.plugins + maven-gpg-plugin + ${maven.gpg.plugin.version} + + + sign-artifacts + verify + + sign + + + + --pinentry-mode + loopback + + + + + + + pl.project13.maven + git-commit-id-plugin + ${git.commit.id.plugin.version} + + + get-the-git-infos + + revision + + validate + + + + + true + ${project.build.outputDirectory}/service-git.properties + + ^git.build.(time|version)$ + ^git.commit.id.(abbrev|full)$ + + full + ${project.basedir}/.git + + + + org.apache.maven.plugins + maven-jar-plugin + ${maven.jar.plugin.version} + + + + true + true + + + ${project.name} + ${project.version} + + + + + + org.apache.maven.plugins + maven-deploy-plugin + ${maven.deploy.plugin.version} + + + + + + + sonar + + . + src/main/java/**,src/main/resources/** + ${sonar.coverage.exclusions} + https://sonarcloud.io + + + false + + + + + org.sonarsource.scanner.maven + sonar-maven-plugin + + + verify + + sonar + + + + + + + + + + + + ossrh + Central Snapshots + https://central.sonatype.com/repository/maven-snapshots/ + + false + + + true + + + + + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + repo + + + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MOSIP + mosip.emailnotifier@gmail.com + io.mosip + https://github.com/mosip + + + diff --git a/registration-processor/registration-processor-external-integration-service/AGENTS.md b/registration-processor/registration-processor-external-integration-service/AGENTS.md new file mode 100644 index 00000000000..09d85d7b4af --- /dev/null +++ b/registration-processor/registration-processor-external-integration-service/AGENTS.md @@ -0,0 +1,21 @@ +# registration-processor-external-integration-service + +EIS stub. `POST .../v1.0` → `true` if body non-null. Swagger Authorize = `Authorization` apiKey (`SwaggerConfig`). Pins in parent `pom.xml`. + +``` +registration-processor-external-integration-service/ +├── pom.xml Dockerfile README.md AGENTS.md +└── src/ + ├── main/ + │ ├── java/io/mosip/registrationprocessor/eis/ + │ │ ├── ExternalIntegrationServiceApplication.java + │ │ ├── controller/ExternalController.java + │ │ ├── config/SwaggerConfig.java OpenApiProperties.java + │ │ └── entity/BaseRestRequestDTO.java MessageRequestDTO.java + │ └── resources/bootstrap.properties + └── test/ + ├── java/.../eis/ + │ ├── ExternalIntegrationControllerTest.java + │ └── config/SwaggerConfigTest.java + └── resources/application.properties +``` diff --git a/registration-processor/registration-processor-external-integration-service/Dockerfile b/registration-processor/registration-processor-external-integration-service/Dockerfile index f2cf7b320c5..652cbcd631f 100644 --- a/registration-processor/registration-processor-external-integration-service/Dockerfile +++ b/registration-processor/registration-processor-external-integration-service/Dockerfile @@ -9,49 +9,21 @@ LABEL commit_hash=${COMMIT_HASH} LABEL commit_id=${COMMIT_ID} LABEL build_time=${BUILD_TIME} -#Uncomment below and Comment above line(i.e. FROM openjdk:8) for OS specific (e.g. Alpine OS ) docker base image -#FROM openjdk:8-jdk-alpine - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. +# Build-time config (also overridable at runtime via matching ENV). ARG spring_config_label - -# can be passed during Docker build as build time environment for spring profiles active ARG active_profile - -# can be passed during Docker build as build time environment for config server URL ARG spring_config_url -# can be passed during Docker build as build time environment for glowroot -ARG is_glowroot - -# can be passed during Docker build as build time environment for artifactory URL -ARG artifactory_url - -# environment variable to pass active profile such as DEV, QA etc at docker runtime ENV active_profile_env=${active_profile} - -# environment variable to pass github branch to pickup configuration from, at docker runtime -ENV spring_config_label_env=${spring_config_label} - -# environment variable to pass github branch to pickup configuration from, at docker runtime ENV spring_config_label_env=${spring_config_label} +ENV spring_config_url_env=${spring_config_url} -# environment variable to pass glowroot, at docker runtime -ENV is_glowroot_env=${is_glowroot} +# JVM flags (ZGC, heap, encoding, …) come from JDK_JAVA_OPTIONS, set by Helm +# additionalResources.javaOpts — not hardcoded here. -# environment variable to pass artifactory url, at docker runtime -ENV artifactory_url_env=${artifactory_url} - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_group=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_uid=1002 - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_gid=1001 RUN apk -q update \ @@ -61,23 +33,14 @@ RUN apk -q update \ && addgroup sudo \ && adduser ${container_user} sudo -# set working directory for the user WORKDIR /home/${container_user} ENV work_dir=/home/${container_user} -ARG loader_path=${work_dir}/additional_jars/ - -RUN mkdir -p ${loader_path} - -ENV loader_path_env=${loader_path} - -# change volume to whichever storage directory you want to use for this container. VOLUME $work_dir/logs EXPOSE 8201 -# copying shaded jar into docker image ADD ./target/*.jar ./target/ RUN find target/ -regextype posix-extended -regex '.*registration-processor-external-integration-service-[0-9\.]+[-A-Za-z0-9\.]*\.jar' "-print0" | xargs "-0" cp -t ./ \ @@ -85,13 +48,13 @@ RUN find target/ -regextype posix-extended -regex '.*registration-processor-exte && rm -rf original*.jar \ && rm -rf *-sources.jar \ && rm -rf *-javadoc.jar \ - && mv *.jar registration-processor-external-integration-service.jar + && mv *.jar registration-processor-external-integration-service.jar -# change permissions of file inside working dir RUN chown -R ${container_user}:${container_user} /home/${container_user} -# select container user for all tasks USER ${container_user_uid}:${container_user_gid} -CMD java -XX:-UseG1GC -XX:+ExplicitGCInvokesConcurrent -XX:-UseParallelGC -XX:+UseZGC -XX:+ZGenerational -XX:-UseShenandoahGC -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+UseStringDeduplication -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 -XX:+UseCompressedOops \ - -Dspring.cloud.config.label="${spring_config_label_env}" -Dspring.profiles.active="${active_profile_env}" -Dspring.cloud.config.uri="${spring_config_url_env}" -jar registration-processor-external-integration-service.jar ; \ +CMD java -Dspring.cloud.config.label="${spring_config_label_env}" \ + -Dspring.profiles.active="${active_profile_env}" \ + -Dspring.cloud.config.uri="${spring_config_url_env}" \ + -jar registration-processor-external-integration-service.jar diff --git a/registration-processor/registration-processor-external-integration-service/README.md b/registration-processor/registration-processor-external-integration-service/README.md index be1c6086ee0..139a2d17435 100644 --- a/registration-processor/registration-processor-external-integration-service/README.md +++ b/registration-processor/registration-processor-external-integration-service/README.md @@ -1,69 +1,89 @@ # registration-processor-external-integration-service +Country stub REST service that receives POSTs from `registration-processor-external-stage`. Replace the controller body with country-specific integration logic. + +- **Artifact**: `io.mosip.registrationprocessor:registration-processor-external-integration-service:1.4.1-SNAPSHOT` +- **Parent**: `registration-processor-ref-parent` (Boot **4.1.1**) +- **Logging**: `kernel-core` (commons) +- **Git info**: `service-git.properties` + ## Overview -This service details used by Registration service for external integration service. + +Used by registration-processor for external system integration. Default implementation returns `true` when the request body is non-null. ## Design -[Design - Approach for External System Integration](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_external_system_integration.md) -[Design - Approach for Adding HTTP Stage](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_http_integration.md) +- [Approach for External System Integration](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_external_system_integration.md) +- [Approach for Adding HTTP Stage](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_http_integration.md) -## Default Context-path and Port -``` +## Default context and port + +```text server.port=8201 server.servlet.path=/registrationprocessor/v1/eis ``` -## Operations done by the Service -1. It returns boolean value true for every non-null requests - -## Build & run (for developers) -The project requires JDK 21.0.3 -and mvn version - 3.9.6 - -1. Build and install: - ``` - $ cd registration-processor\registration-processor-external-integration-service - $ mvn install -DskipTests=true -Dmaven.javadoc.skip=true -Dgpg.skip=true - ``` -2. Build Docker for a service: - ``` - $ cd - $ docker build -f Dockerfile - ``` - -## Configuration files -Registration processor external integration Service uses the following configuration files: -[Configuration-Application](https://github.com/mosip/mosip-config/blob/master/application-default.properties) and -[Configuration-Registration-processor](https://github.com/mosip/mosip-config/blob/master/registration-processor-default.properties) defined here. -Refer to the required released tagged version. - -Need to run the config-server along with the files mentioned above in order to run the registration processor external integration service. - -## Deployment in K8 cluster with other MOSIP services: -### Pre-requisites -* Set KUBECONFIG variable to point to existing K8 cluster kubeconfig file: - ``` - export KUBECONFIG=~/.kube/ - ``` -### Install - ``` - $ cd deploy - $ ./install.sh - ``` -### Delete - ``` - $ cd deploy - $ ./delete.sh - ``` -### Restart - ``` - $ cd deploy - $ ./restart.sh - ``` +See [bootstrap.properties](src/main/resources/bootstrap.properties). + +## Operations + +1. `POST /registration-processor/external-integration-service/v1.0` — returns `true` for a non-null request payload. + +## Prerequisites + +- JDK **21.0.3** +- Maven **3.9.6** +- Spring Cloud Config + +## Build & run + +```text +cd registration-processor +mvn -pl registration-processor-external-integration-service clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +```text +java -jar target/registration-processor-external-integration-service-1.4.1-SNAPSHOT.jar +``` + +### Docker + +```text +docker build -t registration-processor-external-integration-service . +``` + +## Configuration + +- [application-default.properties](https://github.com/mosip/mosip-config/blob/master/application-default.properties) +- [registration-processor-default.properties](https://github.com/mosip/mosip-config/blob/master/registration-processor-default.properties) + +## Swagger UI (Authorize) + +| | | +|---|---| +| UI | `http://localhost:8201/registrationprocessor/v1/eis/swagger-ui.html` (springdoc default under servlet path) | +| Scheme | **Authorization** header apiKey | + +Click **Authorize**, paste the authmanager token, then Try-it-out. + +```text +mvn -pl registration-processor-external-integration-service clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +JaCoCo LINE covered ratio **0.90**. Boot 4 tests use `org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest`. + +## Deployment (Kubernetes) + +```text +export KUBECONFIG=~/.kube/ +cd deploy +./install.sh +``` ## APIs -API documentation is available [here](https://mosip.github.io/documentation/). + +[External Integration Service API](https://mosip.github.io/documentation/1.2.0/registration-processor-external-integration-service.html) ## License -This project is licensed under the terms of [Mozilla Public License 2.0](https://github.com/mosip/mosip-ref-impl/blob/master/LICENSE). \ No newline at end of file + +[Mozilla Public License 2.0](../../LICENSE) — [NOTICE](../../NOTICE) diff --git a/registration-processor/registration-processor-external-integration-service/pom.xml b/registration-processor/registration-processor-external-integration-service/pom.xml index 24eec2f0272..176dbf29423 100644 --- a/registration-processor/registration-processor-external-integration-service/pom.xml +++ b/registration-processor/registration-processor-external-integration-service/pom.xml @@ -1,72 +1,53 @@ - 4.0.0 - io.mosip.registrationprocessor - pre-processor - 1.3.1-rc.1 - + io.mosip.registrationprocessor + registration-processor-ref-parent + 1.4.1-SNAPSHOT + ../pom.xml + + registration-processor-external-integration-service - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT registration-processor-external-integration-service - Registration processor external integration service + + MOSIP External Integration Service stub. Spring Boot 4.1.1 via parent + registration-processor-ref-parent. No pre-processor parent. Logging via kernel-core (commons). + https://github.com/mosip/mosip-ref-impl - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - - - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - Mosip - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip/mosip-ref-impl - - - - - UTF-8 - UTF-8 - 2.22.0 - 0.8.11 - 3.7.0.1746 - **/constant/**,**/config/**,**/httpfilter/**,**/cache/**,**/entity/**,**/model/**,**/exception/**,**/repository/**,**/verticle/**,**/spi/**,"**/proxy/**","**/entities/**","**/filter/**","**/util/**","**/verifier/**" - 3.2.3 - 0.11.0 - + org.springframework.boot spring-boot-starter-web + org.springframework.boot spring-boot-starter-actuator + org.springframework.cloud spring-cloud-starter-config - org.springframework.boot - spring-boot-starter-test - test - - - org.projectlombok - lombok + org.springframework.cloud + spring-cloud-starter-bootstrap + io.micrometer micrometer-core @@ -75,258 +56,50 @@ io.micrometer micrometer-registry-prometheus + org.springdoc - springdoc-openapi-ui + springdoc-openapi-starter-webmvc-ui + org.springframework.boot spring-boot-configuration-processor true + - org.mockito - mockito-core - ${mockito.version} - test - - - junit - junit - test - - - org.junit.vintage - junit-vintage-engine - - - org.springframework.cloud - spring-cloud-starter-bootstrap + org.springframework.boot + spring-boot-starter-webmvc-test + test + + + + org.mockito + mockito-core + test + + + junit + junit + test - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - + - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - - - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - ${skipTests} - false - - ${argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --illegal-access=permit - - - - - org.jacoco - jacoco-maven-plugin - ${maven.jacoco.plugin.version} - - - - prepare-agent - - - - report - prepare-package - - report - - - - - - org.apache.maven.plugins - maven-gpg-plugin - 1.5 - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - 3.0.1 - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/service-git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - org.springframework.boot spring-boot-maven-plugin - ${spring.boot.version} - - true - - - - - build-info - repackage - - - false - - - - - - sonar - - . - https://sonarcloud.io - - - true - - - - - org.sonarsource.scanner.maven - sonar-maven-plugin - ${maven.sonar.plugin.version} - - - verify - - sonar - - - - - - - - - openapi-doc-generate-profile - - - - org.springframework.boot - spring-boot-maven-plugin - ${spring.boot.version} - - true - ZIP - - - - - build-info-repackage - - build-info - repackage - - - false - - - - - pre-integration-test - pre-integration-test - - start - - - - src/test/resources - - - openapi-profile - - - --server.port=8090 - --server.servlet.path=/app/generic - - - - - - post-integration-test - post-integration-test - - stop - - - - - - org.springdoc - springdoc-openapi-maven-plugin - 0.2 - - - integration-test - - generate - - - - - http://localhost:8090/app/generic/v3/api-docs - ${artifactId}-openapi.json - ${project.build.directory} - false - - - - - - - - \ No newline at end of file +
diff --git a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/ExternalIntegrationServiceApplication.java b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/ExternalIntegrationServiceApplication.java index 3de79c449b1..983fade3f84 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/ExternalIntegrationServiceApplication.java +++ b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/ExternalIntegrationServiceApplication.java @@ -5,15 +5,16 @@ import org.springframework.context.annotation.PropertySource; /** - * external integration service application - * + * Spring Boot entry point for the External Integration Service (EIS) stub. */ @SpringBootApplication @PropertySource("classpath:bootstrap.properties") public class ExternalIntegrationServiceApplication { /** - *load main external integration service + * Starts the EIS servlet on {@code server.port} / {@code server.servlet.path}. + * + * @param args command-line arguments passed to Spring Boot */ public static void main(String[] args) { SpringApplication.run(ExternalIntegrationServiceApplication.class, args); diff --git a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/OpenApiProperties.java b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/OpenApiProperties.java index 6baf23ea1f0..791eea763ee 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/OpenApiProperties.java +++ b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/OpenApiProperties.java @@ -7,42 +7,64 @@ import lombok.Data; +/** + * Binds {@code openapi.*} properties used by {@link SwaggerConfig}. + */ @Configuration @ConfigurationProperties(prefix = "openapi") @Data public class OpenApiProperties { - private InfoProperty info; - private Service service; - private Group group; + /** API title, description, version, and license. */ + private InfoProperty info; + /** Published server URLs for the OpenAPI document. */ + private Service service; + /** Swagger UI group name and path filters. */ + private Group group; } +/** OpenAPI info block bound from {@code openapi.info.*}. */ @Data class InfoProperty { - private String title; - private String description; - private String version; - private LicenseProperty license; + /** Display title in Swagger UI. */ + private String title; + /** Longer description of the API. */ + private String description; + /** Document version string. */ + private String version; + /** License name and URL. */ + private LicenseProperty license; } +/** License fields bound from {@code openapi.info.license.*}. */ @Data class LicenseProperty { - private String name; - private String url; + /** License display name. */ + private String name; + /** License document URL. */ + private String url; } +/** Server list bound from {@code openapi.service.*}. */ @Data class Service { - private List servers; + /** OpenAPI servers (Try-it-out base URLs). */ + private List servers; } +/** A single OpenAPI server URL and description. */ @Data class Server { - private String description; - private String url; + /** Human-readable server label. */ + private String description; + /** Absolute or relative base URL. */ + private String url; } +/** Path group bound from {@code openapi.group.*}. */ @Data class Group { - private String name; - private List paths; -} \ No newline at end of file + /** Springdoc group name. */ + private String name; + /** Ant-style paths included in this group. */ + private List paths; +} diff --git a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/SwaggerConfig.java b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/SwaggerConfig.java index 3c9113f4284..9cc8d5e6748 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/SwaggerConfig.java +++ b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/config/SwaggerConfig.java @@ -2,7 +2,7 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import org.springdoc.core.GroupedOpenApi; +import org.springdoc.core.models.GroupedOpenApi; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; @@ -11,25 +11,44 @@ import io.swagger.v3.oas.models.OpenAPI; import io.swagger.v3.oas.models.info.Info; import io.swagger.v3.oas.models.info.License; +import io.swagger.v3.oas.models.security.SecurityRequirement; +import io.swagger.v3.oas.models.security.SecurityScheme; import io.swagger.v3.oas.models.servers.Server; /** - * Configuration class for swagger config - * @implSpec upgrade the Swagger2.0 to OpenAPI (Swagger3.0) + * Springdoc OpenAPI / Swagger UI configuration for the External Integration Service. + *

+ * Swagger UI shows an Authorize button that sends the + * {@code Authorization} header (IDA-style apiKey), matching commons kernel services. + *

* + * @implSpec OpenAPI 3 / springdoc (not Swagger 2) */ @Configuration public class SwaggerConfig { + /** Logger reserved for this configuration class. */ private static final Logger logger = LoggerFactory.getLogger(SwaggerConfig.class); + /** + * Scheme name shown by Swagger UI as Authorize (IDA-style Authorization apiKey). + */ + public static final String AUTHORIZATION_SCHEME = "Authorization"; + + /** OpenAPI title, description, version, license, group, and server list from {@code openapi.*}. */ @Autowired private OpenApiProperties openApiProperties; + /** + * OpenAPI document used by Springdoc for Swagger UI. + * + * @return configured {@link OpenAPI} with info, servers, and Authorize apiKey + */ @Bean public OpenAPI openApi() { OpenAPI api = new OpenAPI() - .components(new Components()) + .components(new Components().addSecuritySchemes(AUTHORIZATION_SCHEME, authorizationApiKey())) + .addSecurityItem(new SecurityRequirement().addList(AUTHORIZATION_SCHEME)) .info(new Info() .title(openApiProperties.getInfo().getTitle()) .version(openApiProperties.getInfo().getVersion()) @@ -45,10 +64,26 @@ public OpenAPI openApi() { return api; } + /** + * Header apiKey named {@code Authorization} so Swagger UI shows Authorize + * with Name / In / Value. + * + * @return the security scheme + */ + private static SecurityScheme authorizationApiKey() { + return new SecurityScheme().type(SecurityScheme.Type.APIKEY).in(SecurityScheme.In.HEADER) + .name(AUTHORIZATION_SCHEME); + } + + /** + * Groups servlet paths into one Swagger UI document ({@code openapi.group.*}). + * + * @return grouped OpenAPI definition + */ @Bean public GroupedOpenApi groupedOpenApi() { return GroupedOpenApi.builder().group(openApiProperties.getGroup().getName()) .pathsToMatch(openApiProperties.getGroup().getPaths().stream().toArray(String[]::new)) .build(); } -} \ No newline at end of file +} diff --git a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/controller/ExternalController.java b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/controller/ExternalController.java index 1a3ae35c0fd..93e1420d5d0 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/controller/ExternalController.java +++ b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/controller/ExternalController.java @@ -11,22 +11,30 @@ import io.swagger.v3.oas.annotations.Operation; import io.swagger.v3.oas.annotations.responses.ApiResponse; import io.swagger.v3.oas.annotations.responses.ApiResponses; +import io.swagger.v3.oas.annotations.security.SecurityRequirement; import io.swagger.v3.oas.annotations.tags.Tag; import io.swagger.v3.oas.annotations.media.Content; import io.swagger.v3.oas.annotations.media.Schema; /** - * External Controller + * Country stub REST API for external system integration. + *

+ * Default behaviour: HTTP 200 with {@code true} when {@code request} is non-null, + * otherwise {@code false}. Replace this method with country logic. + *

* + * @author MOSIP */ @RestController @RequestMapping("/registration-processor") @Tag(name = "external-integration-service", description = "External Controller") +@SecurityRequirement(name = "Authorization") public class ExternalController { /** - * dummy method to process incoming requests - * @param messageRequestDTO - * @return boolean + * Accepts a packet-id list from registration-processor-external-stage. + * + * @param messageRequestDTO MOSIP envelope plus {@code request} list + * @return {@code true} if {@code request} is not {@code null} */ @PostMapping(path = "/external-integration-service/v1.0", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE) @ApiResponses(value = { diff --git a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/BaseRestRequestDTO.java b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/BaseRestRequestDTO.java index 2bc66a47243..0d8373b4ec2 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/BaseRestRequestDTO.java +++ b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/BaseRestRequestDTO.java @@ -1,26 +1,25 @@ package io.mosip.registrationprocessor.eis.entity; - import java.io.Serializable; import lombok.Data; /** - * base request class - * + * Common MOSIP REST envelope fields shared by EIS request payloads. */ @Data -public class BaseRestRequestDTO implements Serializable{ - +public class BaseRestRequestDTO implements Serializable { + + /** Serialization version. */ private static final long serialVersionUID = 4373201325809902206L; - /** The id. */ + /** MOSIP request id. */ private String id; - - /** The ver. */ + + /** API version (for example {@code 1.0}). */ private String version; - - /** The timestamp. */ + + /** Request timestamp (ISO string as sent by the stage). */ private String requesttime; -} \ No newline at end of file +} diff --git a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/MessageRequestDTO.java b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/MessageRequestDTO.java index c5362682375..4b16a5feccc 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/MessageRequestDTO.java +++ b/registration-processor/registration-processor-external-integration-service/src/main/java/io/mosip/registrationprocessor/eis/entity/MessageRequestDTO.java @@ -3,18 +3,17 @@ import java.util.List; import lombok.Data; import lombok.EqualsAndHashCode; -@Data -/* (non-Javadoc) - * @see io.mosip.registration.processor.core.common.rest.dto.BaseRestRequestDTO#hashCode() +/** + * EIS POST body: MOSIP envelope plus a list of registration ids to process. */ +@Data @EqualsAndHashCode(callSuper = true) public class MessageRequestDTO extends BaseRestRequestDTO { - /** - * - */ + /** Serialization version. */ private static final long serialVersionUID = 7914304502765754692L; - /** The request. */ + + /** Registration ids (or equivalent keys) sent by external-stage. */ private List request; } diff --git a/registration-processor/registration-processor-external-integration-service/src/main/resources/bootstrap.properties b/registration-processor/registration-processor-external-integration-service/src/main/resources/bootstrap.properties index 469dcfeb873..e2167c9da64 100644 --- a/registration-processor/registration-processor-external-integration-service/src/main/resources/bootstrap.properties +++ b/registration-processor/registration-processor-external-integration-service/src/main/resources/bootstrap.properties @@ -13,18 +13,23 @@ health.config.enabled=false management.endpoint.health.show-details=always management.endpoints.web.exposure.include=info,health,refresh +# Actuator /info reads this file. git.properties is reserved for kernel-core. +spring.info.git.location=classpath:service-git.properties openapi.info.title=External Integration Service openapi.info.description=External Integration Service openapi.info.version=1.0 openapi.info.license.name=Mosip openapi.info.license.url=https://docs.mosip.io/platform/license -mosipbox.public.url=http://localhost:${server.port} -openapi.service.servers[0].url=${mosipbox.public.url}${server.servlet.path} +# Relative server URL so Try-it-out uses the browser host (gateway), same as kernel-config-server. +openapi.service.servers[0].url=${server.servlet.path} openapi.service.servers[0].description=External Integration Service openapi.group.name=${openapi.info.title} openapi.group.paths[0]=/** springdoc.swagger-ui.disable-swagger-default-url=true spring.mvc.servlet.path=${server.servlet.path} springdoc.swagger-ui.tagsSorter=alpha -springdoc.swagger-ui.operationsSorter=alpha \ No newline at end of file +springdoc.swagger-ui.operationsSorter=alpha +springdoc.swagger-ui.syntaxHighlight.activated=false +springdoc.swagger-ui.validator-url=none +springdoc.swagger-ui.persistAuthorization=true \ No newline at end of file diff --git a/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/ExternalIntegrationControllerTest.java b/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/ExternalIntegrationControllerTest.java index 025f287cc56..9780470e11d 100644 --- a/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/ExternalIntegrationControllerTest.java +++ b/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/ExternalIntegrationControllerTest.java @@ -11,7 +11,7 @@ import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest; +import org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest; import org.springframework.http.MediaType; import org.springframework.test.context.junit4.SpringRunner; import org.springframework.test.web.servlet.MockMvc; diff --git a/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/config/SwaggerConfigTest.java b/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/config/SwaggerConfigTest.java new file mode 100644 index 00000000000..e0693498b16 --- /dev/null +++ b/registration-processor/registration-processor-external-integration-service/src/test/java/io/mosip/registrationprocessor/eis/config/SwaggerConfigTest.java @@ -0,0 +1,56 @@ +package io.mosip.registrationprocessor.eis.config; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; + +import java.util.List; + +import org.junit.Test; +import org.springframework.test.util.ReflectionTestUtils; + +import io.swagger.v3.oas.models.OpenAPI; +import io.swagger.v3.oas.models.security.SecurityScheme; + +/** + * Swagger UI Authorize is an OpenAPI header apiKey named Authorization. + */ +public class SwaggerConfigTest { + + @Test + public void openApiRegistersAuthorizationHeaderApiKey() { + SwaggerConfig config = new SwaggerConfig(); + ReflectionTestUtils.setField(config, "openApiProperties", sampleProperties()); + + OpenAPI api = config.openApi(); + SecurityScheme scheme = api.getComponents().getSecuritySchemes().get(SwaggerConfig.AUTHORIZATION_SCHEME); + + assertNotNull(scheme); + assertEquals(SecurityScheme.Type.APIKEY, scheme.getType()); + assertEquals(SecurityScheme.In.HEADER, scheme.getIn()); + assertEquals(SwaggerConfig.AUTHORIZATION_SCHEME, scheme.getName()); + assertFalse(api.getSecurity().isEmpty()); + assertEquals(SwaggerConfig.AUTHORIZATION_SCHEME, api.getSecurity().get(0).keySet().iterator().next()); + assertEquals("/registrationprocessor/v1/eis", api.getServers().get(0).getUrl()); + } + + private static OpenApiProperties sampleProperties() { + LicenseProperty license = new LicenseProperty(); + license.setName("Mosip"); + license.setUrl("https://docs.mosip.io/platform/license"); + InfoProperty info = new InfoProperty(); + info.setTitle("External Integration Service"); + info.setDescription("External Integration Service"); + info.setVersion("1.0"); + info.setLicense(license); + Server server = new Server(); + server.setUrl("/registrationprocessor/v1/eis"); + server.setDescription("External Integration Service"); + Service service = new Service(); + service.setServers(List.of(server)); + OpenApiProperties properties = new OpenApiProperties(); + properties.setInfo(info); + properties.setService(service); + return properties; + } +} diff --git a/registration-processor/registration-processor-external-integration-service/src/test/resources/application.properties b/registration-processor/registration-processor-external-integration-service/src/test/resources/application.properties index 63981a47d44..09ed082eb55 100644 --- a/registration-processor/registration-processor-external-integration-service/src/test/resources/application.properties +++ b/registration-processor/registration-processor-external-integration-service/src/test/resources/application.properties @@ -6,8 +6,7 @@ openapi.info.description=External Integration Service openapi.info.version=1.0 openapi.info.license.name=Mosip openapi.info.license.url=https://docs.mosip.io/platform/license -mosipbox.public.url=http://localhost:${server.port} -openapi.service.servers[0].url=${mosipbox.public.url}${server.servlet.path} +openapi.service.servers[0].url=${server.servlet.path} openapi.service.servers[0].description=External Integration Service openapi.group.name=${openapi.info.title} openapi.group.paths[0]=/** diff --git a/registration-processor/registration-processor-external-stage/AGENTS.md b/registration-processor/registration-processor-external-stage/AGENTS.md new file mode 100644 index 00000000000..3b935ae384b --- /dev/null +++ b/registration-processor/registration-processor-external-stage/AGENTS.md @@ -0,0 +1,20 @@ +# registration-processor-external-stage + +Vert.x `ExternalStage`. `EXTERNAL_STAGE_BUS_IN` → POST EIS → `EXTERNAL_STAGE_BUS_OUT`. Adapter in JAR. Pins in parent `pom.xml`. + +``` +registration-processor-external-stage/ +├── pom.xml Dockerfile README.md AGENTS.md +└── src/ + ├── main/ + │ ├── java/io/mosip/registrationprocessor/externalstage/ + │ │ ├── ExternalStageApplication.java + │ │ ├── stage/ExternalStage.java + │ │ ├── config/Externalconfig.java + │ │ ├── entity/BaseRestRequestDTO.java MessageRequestDTO.java + │ │ └── utils/StatusMessage.java + │ └── resources/ bootstrap.properties logback.xml + └── test/java/.../externalstage/ + ├── ExternalStageApplicationTests.java + └── stage/ExternalStageTest.java +``` diff --git a/registration-processor/registration-processor-external-stage/Dockerfile b/registration-processor/registration-processor-external-stage/Dockerfile index 802f249ba2a..c588b6968d2 100644 --- a/registration-processor/registration-processor-external-stage/Dockerfile +++ b/registration-processor/registration-processor-external-stage/Dockerfile @@ -9,52 +9,21 @@ LABEL commit_hash=${COMMIT_HASH} LABEL commit_id=${COMMIT_ID} LABEL build_time=${BUILD_TIME} -#Uncomment below and Comment above line(i.e. FROM openjdk:8) for OS specific (e.g. Alpine OS ) docker base image -#FROM openjdk:8-jdk-alpine - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. +# Build-time config (also overridable at runtime via matching ENV). ARG spring_config_label - -# can be passed during Docker build as build time environment for spring profiles active ARG active_profile - -# can be passed during Docker build as build time environment for config server URL ARG spring_config_url -# can be passed during Docker build as build time environment for glowroot -ARG is_glowroot - -# can be passed during Docker build as build time environment for artifactory URL -ARG artifactory_url - -# environment variable to pass active profile such as DEV, QA etc at docker runtime ENV active_profile_env=${active_profile} - -# environment variable to pass github branch to pickup configuration from, at docker runtime -ENV spring_config_label_env=${spring_config_label} - -# environment variable to pass github branch to pickup configuration from, at docker runtime ENV spring_config_label_env=${spring_config_label} +ENV spring_config_url_env=${spring_config_url} -# environment variable to pass glowroot, at docker runtime -ENV is_glowroot_env=${is_glowroot} +# JVM flags (ZGC, heap, encoding, …) come from JDK_JAVA_OPTIONS, set by Helm +# additionalResources.javaOpts — not hardcoded here. -# environment variable to pass artifactory url, at docker runtime -ENV artifactory_url_env=${artifactory_url} - -# environment variable to pass iam_adapter url, at docker runtime -ENV iam_adapter_url_env=${iam_adapter_url} - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_group=mosip - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_uid=1002 - -# can be passed during Docker build as build time environment for github branch to pickup configuration from. ARG container_user_gid=1001 RUN apk -q update \ @@ -64,21 +33,12 @@ RUN apk -q update \ && addgroup sudo \ && adduser ${container_user} sudo -# set working directory for the user WORKDIR /home/${container_user} ENV work_dir=/home/${container_user} -ARG loader_path=${work_dir}/additional_jars/ - -RUN mkdir -p ${loader_path} - -ENV loader_path_env=${loader_path} - -# change volume to whichever storage directory you want to use for this container. VOLUME ${work_dir}/logs -# copying shaded jar into docker image ADD ./target/*.jar ./target/ RUN find target/ -regextype posix-extended -regex '.*registration-processor-external-stage-[0-9\.]+[-A-Za-z0-9\.]*\.jar' "-print0" | xargs "-0" cp -t ./ \ @@ -86,14 +46,13 @@ RUN find target/ -regextype posix-extended -regex '.*registration-processor-exte && rm -rf original*.jar \ && rm -rf *-sources.jar \ && rm -rf *-javadoc.jar \ - && mv *.jar registration-processor-external-stage.jar + && mv *.jar registration-processor-external-stage.jar -# change permissions of file inside working dir RUN chown -R ${container_user}:${container_user} /home/${container_user} -# select container user for all tasks USER ${container_user_uid}:${container_user_gid} -CMD wget "${iam_adapter_url_env}" -O "${loader_path_env}"/kernel-auth-adapter.jar; \ - java -XX:-UseG1GC -XX:+ExplicitGCInvokesConcurrent -XX:-UseParallelGC -XX:+UseZGC -XX:+ZGenerational -XX:-UseShenandoahGC -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+UseStringDeduplication -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 -XX:+UseCompressedOops \ - -Dspring.cloud.config.label="${spring_config_label_env}" -Dspring.profiles.active="${active_profile_env}" -Dspring.cloud.config.uri="${spring_config_url_env}" -jar registration-processor-external-stage.jar ; \ +CMD java -Dspring.cloud.config.label="${spring_config_label_env}" \ + -Dspring.profiles.active="${active_profile_env}" \ + -Dspring.cloud.config.uri="${spring_config_url_env}" \ + -jar registration-processor-external-stage.jar diff --git a/registration-processor/registration-processor-external-stage/README.md b/registration-processor/registration-processor-external-stage/README.md index 59686ca498e..cb41cf49e4e 100644 --- a/registration-processor/registration-processor-external-stage/README.md +++ b/registration-processor/registration-processor-external-stage/README.md @@ -1,90 +1,95 @@ # registration-processor-external-stage +Vert.x stage that reads `EXTERNAL_STAGE_BUS_IN`, POSTs to the External Integration Service, then emits `EXTERNAL_STAGE_BUS_OUT`. + +- **Artifact**: `io.mosip.registrationprocessor:registration-processor-external-stage:1.4.1-SNAPSHOT` +- **Parent**: `registration-processor-ref-parent` (Boot **4.1.1**) +- **Logging**: `kernel-core` (commons) +- **Git info**: `service-git.properties` + ## Overview -This stage integrates with external system for required external operations + +Integrates the packet SEDA pipeline with an external HTTP system (EIS). ## Design -[Design - Approach for External System Integration](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_external_system_integration.md) -[Design - Approach for Adding HTTP Stage](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_http_integration.md) +- [Approach for External System Integration](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_external_system_integration.md) +- [Approach for Adding HTTP Stage](https://github.com/mosip/registration/blob/master/design/registration-processor/Approach_for_http_integration.md) +- [Guideline for adding an External Stage](https://github.com/mosip/registration/blob/master/design/registration-processor/External_System_Integration_Guide.md) -[Guideline for adding an External Stage](https://github.com/mosip/registration/blob/master/design/registration-processor/External_System_Integration_Guide.md) +## Default ports and path -## Default Context Path and Port -``` +```text eventbus.port=5736 server.port=8095 -server.servlet.path=/registrationprocessor/v1/externaleventbus.port=5736 -``` -## Configurable Properties from Config Server +server.servlet.path=/registrationprocessor/v1/external ``` + +## Configurable properties (config server) + +```text EISERVICE=${mosip.base.url}/registrationprocessor/v1/eis/registration-processor/external-integration-service/v1.0 mosip.regproc.external.eventbus.kafka.commit.type=single mosip.regproc.external.eventbus.kafka.max.poll.records=100 mosip.regproc.external.eventbus.kafka.poll.frequency=100 mosip.regproc.external.eventbus.kafka.group.id=external-stage mosip.regproc.external.message.expiry-time-limit=${mosip.regproc.common.stage.message.expiry-time-limit} - mosip.regproc.external.eventbus.port=5736 mosip.regproc.external.server.port=8095 mosip.regproc.external.server.servlet.path=/registrationprocessor/v1/external ``` -## Operations in External stage -External validation by sending requests to external integration system - -## Build & run (for developers) -The project requires JDK 21.0.3 -and mvn version - 3.9.6 - -1. Build and install: - ``` - $ cd registration-processor\registration-processor-external-stage - $ mvn install -DskipTests=true -Dmaven.javadoc.skip=true -Dgpg.skip=true - ``` -2. Build Docker for a service: - ``` - $ cd - $ docker build -f Dockerfile - ``` - -### Add auth-adapter in a class-path to run a master-data service - ``` - - io.mosip.kernel - kernel-auth-adapter - ${kernel.auth.adapter.version} - - ``` - -## Configuration files -Registration processor external stage uses the following configuration files: -[Configuration-Application](https://github.com/mosip/mosip-config/blob/master/application-default.properties) and -[Configuration-Registration-processor](https://github.com/mosip/mosip-config/blob/master/registration-processor-default.properties) defined here. - Refer to the required released tagged version. - -Need to run the config-server along with the files mentioned above in order to run the registration processor external stage service. - -## Deployment in K8 cluster with other MOSIP services: -### Pre-requisites -* Set KUBECONFIG variable to point to existing K8 cluster kubeconfig file: - ``` - export KUBECONFIG=~/.kube/ - ``` -### Install - ``` - $ cd deploy - $ ./install.sh - ``` -### Delete - ``` - $ cd deploy - $ ./delete.sh - ``` -### Restart - ``` - $ cd deploy - $ ./restart.sh - ``` + +Prefix: `mosip.regproc.external.` + +## Operations + +External validation by sending the packet id list to EIS (`ApiName.EISERVICE`). Status is updated true/false from the HTTP response. + +## Prerequisites + +- JDK **21.0.3** +- Maven **3.9.6** +- Config server + Kafka/Vert.x cluster as in MOSIP registration-processor + +## Build & run + +```text +cd registration-processor +mvn -pl registration-processor-external-stage clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +mvn -pl registration-processor-external-stage clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +### Docker + +```text +docker build -t registration-processor-external-stage . +``` + +### Runtime auth adapter (typical MOSIP stage) + +```xml + + io.mosip.kernel + kernel-auth-adapter + ${kernel.auth.adapter.version} + +``` + +JaCoCo LINE covered ratio **0.90**. Needs MOSIP `registration-processor-core` / status-service-impl / rest-client SNAPSHOTs on the classpath. + +## Configuration + +- [application-default.properties](https://github.com/mosip/mosip-config/blob/master/application-default.properties) +- [registration-processor-default.properties](https://github.com/mosip/mosip-config/blob/master/registration-processor-default.properties) + +## Deployment (Kubernetes) + +```text +export KUBECONFIG=~/.kube/ +cd deploy +./install.sh +``` ## License -This project is licensed under the terms of [Mozilla Public License 2.0](https://github.com/mosip/mosip-ref-impl/blob/master/LICENSE). \ No newline at end of file + +[Mozilla Public License 2.0](../../LICENSE) — [NOTICE](../../NOTICE) diff --git a/registration-processor/registration-processor-external-stage/pom.xml b/registration-processor/registration-processor-external-stage/pom.xml index bc40db78197..15391a1c7ce 100644 --- a/registration-processor/registration-processor-external-stage/pom.xml +++ b/registration-processor/registration-processor-external-stage/pom.xml @@ -1,89 +1,89 @@ - 4.0.0 - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - - - - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - Mosip - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip/mosip-ref-impl - - io.mosip.registrationprocessor - pre-processor - 1.3.1-rc.1 + registration-processor-ref-parent + 1.4.1-SNAPSHOT + ../pom.xml - + registration-processor-external-stage - 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT registration-processor-external-stage - Registration processor external stage + + MOSIP registration-processor Vert.x stage that POSTs to the External Integration Service. + Spring Boot 4.1.1 via parent registration-processor-ref-parent. No pre-processor parent. + Logging via kernel-core (commons); do not add kernel-logger-logback. + https://github.com/mosip/mosip-ref-impl - - UTF-8 - 2.22.0 - 0.8.11 - 3.7.0.1746 - 3.2.3 - 0.11.0 - - + - org.springframework.cloud - spring-cloud-starter-config + org.springframework.boot + spring-boot-starter + - org.mockito - mockito-core - ${mockito.version} - test + org.springframework.cloud + spring-cloud-starter-config - io.vertx - vertx-unit - test + org.springframework.cloud + spring-cloud-starter-bootstrap + org.springframework spring-context + io.mosip.registrationprocessor registration-processor-core - ${registration.processor.core.version} + io.mosip.registrationprocessor registration-processor-registration-status-service-impl - ${registration.status.service.version} + io.mosip.registrationprocessor registration-processor-rest-client - ${registration.processor.rest.client.version} + + + io.mosip.kernel + kernel-auth-adapter + + javax.inject javax.inject - 1 + io.micrometer micrometer-core @@ -92,162 +92,34 @@ io.micrometer micrometer-registry-prometheus + + + com.h2database + h2 + + + + org.mockito + mockito-core + test + + + io.vertx + vertx-unit + test + - - - - com.h2database - h2 - ${h2.version} - - - - - - ossrh - https://central.sonatype.com/repository/maven-snapshots/ - - - ossrh - https://central.sonatype.com/api/v1/publisher - - + - - org.sonatype.central - central-publishing-maven-plugin - ${central.publishing.maven.plugin.version} - true - - ossrh - false - - - - org.apache.maven.plugins - maven-surefire-plugin - ${maven.surefire.plugin.version} - - ${skipTests} - false - - ${argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --illegal-access=permit - - - - - org.jacoco - jacoco-maven-plugin - ${maven.jacoco.plugin.version} - - - - prepare-agent - - - - report - prepare-package - - report - - - - - - org.apache.maven.plugins - maven-gpg-plugin - 1.5 - - - sign-artifacts - verify - - sign - - - - --pinentry-mode - loopback - - - - - - - pl.project13.maven - git-commit-id-plugin - 3.0.1 - - - get-the-git-infos - - revision - - validate - - - - true - ${project.build.outputDirectory}/service-git.properties - - ^git.build.(time|version)$ - ^git.commit.id.(abbrev|full)$ - - full - ${project.basedir}/.git - - - org.springframework.boot spring-boot-maven-plugin - ${spring.boot.version} - - true - - - - - build-info - repackage - - - false - - - - - - sonar - - . - https://sonarcloud.io - - - true - - - - - org.sonarsource.scanner.maven - sonar-maven-plugin - ${maven.sonar.plugin.version} - - - verify - - sonar - - - - - - - - - \ No newline at end of file + diff --git a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/ExternalStageApplication.java b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/ExternalStageApplication.java index 180dce9db63..33e3446d91c 100644 --- a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/ExternalStageApplication.java +++ b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/ExternalStageApplication.java @@ -6,15 +6,15 @@ import io.mosip.registrationprocessor.externalstage.stage.ExternalStage; /** - * External Stage application - * + * Launches the external-stage Vert.x application via an annotation config context + * (scans MOSIP core, status, rest-client, and this stage). */ public class ExternalStageApplication { /** - * main method to launch external stage application - * - * @param args + * Boots Spring, then deploys {@link ExternalStage}. + * + * @param args unused */ public static void main(String[] args) { AnnotationConfigApplicationContext configApplicationContext = new AnnotationConfigApplicationContext(); diff --git a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/config/Externalconfig.java b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/config/Externalconfig.java index bc2e8a412e7..9a0283f9ceb 100644 --- a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/config/Externalconfig.java +++ b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/config/Externalconfig.java @@ -7,14 +7,13 @@ import io.mosip.registrationprocessor.externalstage.stage.ExternalStage; /** - * external stage beans configuration class - * + * Registers Vert.x {@link ExternalStage} as a Spring bean (aspects enabled). */ @Configuration @EnableAspectJAutoProxy public class Externalconfig { /** - * ExternalStage bean + * @return new {@link ExternalStage} instance managed by Spring */ @Bean public ExternalStage externalStage() { diff --git a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/BaseRestRequestDTO.java b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/BaseRestRequestDTO.java index 87a708bd4cb..2fb2b4a2634 100644 --- a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/BaseRestRequestDTO.java +++ b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/BaseRestRequestDTO.java @@ -1,26 +1,25 @@ package io.mosip.registrationprocessor.externalstage.entity; - import java.io.Serializable; import lombok.Data; /** - * base request class - * + * MOSIP REST envelope used when posting to EIS. */ @Data -public class BaseRestRequestDTO implements Serializable{ - +public class BaseRestRequestDTO implements Serializable { + + /** Serialization version. */ private static final long serialVersionUID = 4373201325809902206L; - /** The id. */ + /** MOSIP request id. */ private String id; - - /** The ver. */ + + /** API version. */ private String version; - - /** The timestamp. */ + + /** Request timestamp. */ private String requesttime; -} \ No newline at end of file +} diff --git a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/MessageRequestDTO.java b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/MessageRequestDTO.java index eb1bf780a5d..c78d142e699 100644 --- a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/MessageRequestDTO.java +++ b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/entity/MessageRequestDTO.java @@ -2,21 +2,19 @@ import java.util.List; -import io.mosip.registration.processor.core.abstractverticle.MessageDTO; import lombok.Data; import lombok.EqualsAndHashCode; -@Data -/* (non-Javadoc) - * @see io.mosip.registration.processor.core.common.rest.dto.BaseRestRequestDTO#hashCode() +/** + * Body posted to {@code ApiName.EISERVICE}: envelope plus registration ids. */ +@Data @EqualsAndHashCode(callSuper = true) public class MessageRequestDTO extends BaseRestRequestDTO { - /** - * - */ + /** Serialization version. */ private static final long serialVersionUID = 7914304502765754692L; - /** The request. */ + + /** Registration ids forwarded to the External Integration Service. */ private List request; } diff --git a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStage.java b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStage.java index 7243aee473b..f4be21e9da6 100644 --- a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStage.java +++ b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStage.java @@ -41,8 +41,11 @@ import io.mosip.registrationprocessor.externalstage.entity.MessageRequestDTO; /** - * External stage verticle class + * Vert.x external stage: consumes {@code EXTERNAL_STAGE_BUS_IN}, POSTs registration + * ids to EIS ({@link ApiName#EISERVICE}), updates registration status, then emits + * {@code EXTERNAL_STAGE_BUS_OUT}. * + * @see ExternalStageApplication */ @Service public class ExternalStage extends MosipVerticleAPIManager { @@ -55,7 +58,7 @@ public class ExternalStage extends MosipVerticleAPIManager { private static final String ID = "io.mosip.registrationprocessor"; /** request version */ private static final String VERSION = "1.0"; - /** mosipEventBus */ + /** MOSIP event bus used by {@link #deployVerticle()}. */ private MosipEventBus mosipEventBus; /** vertx Cluster Manager Url. */ @Value("${vertx.cluster.configuration}") @@ -95,11 +98,13 @@ public class ExternalStage extends MosipVerticleAPIManager { /** The Constant USER. */ private static final String USER = "MOSIP_SYSTEM"; + /** Maps exception types to registration transaction status codes. */ @Autowired RegistrationExceptionMapperUtil registrationStatusMapperUtil; /** - * method to deploy external stage verticle + * Deploys this verticle, then consumes {@code EXTERNAL_STAGE_BUS_IN} and sends + * {@code EXTERNAL_STAGE_BUS_OUT}. */ public void deployVerticle() { this.mosipEventBus = this.getEventBus(this, clusterManagerUrl, workerPoolSize); @@ -107,10 +112,8 @@ public void deployVerticle() { MessageBusAddress.EXTERNAL_STAGE_BUS_OUT, messageExpiryTimeLimit); } - /* - * (non-Javadoc) - * - * @see io.vertx.core.AbstractVerticle#start() + /** + * Registers HTTP routes for the stage and starts the Vert.x HTTP server. */ @Override public void start() { @@ -120,12 +123,11 @@ public void start() { this.createServer(router.getRouter(), Integer.parseInt(port)); } - /* - * (non-Javadoc) - * - * @see - * io.mosip.registration.processor.core.spi.eventbus.EventBusManager#process( - * java.lang.Object) + /** + * POSTs the registration id to EIS, updates status, and sets {@code isValid}. + * + * @param object packet message from the SEDA bus + * @return the same message with validity / internal-error flags */ @Override public MessageDTO process(MessageDTO object) { @@ -228,7 +230,12 @@ public MessageDTO process(MessageDTO object) { return object; } - + + /** + * Vert.x property prefix {@code mosip.regproc.external.}. + * + * @return stage property prefix + */ @Override protected String getPropertyPrefix() { return STAGE_PROPERTY_PREFIX; diff --git a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/utils/StatusMessage.java b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/utils/StatusMessage.java index 8ac4de47c9f..53c02e5e5c4 100644 --- a/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/utils/StatusMessage.java +++ b/registration-processor/registration-processor-external-stage/src/main/java/io/mosip/registrationprocessor/externalstage/utils/StatusMessage.java @@ -1,21 +1,19 @@ package io.mosip.registrationprocessor.externalstage.utils; /** - * The Class StatusMessage. + * Human-readable status strings written after EIS success or failure. */ public final class StatusMessage { - /** - * Instantiates a new status message. - */ + /** Utility class; do not instantiate. */ private StatusMessage() { } - /** The Constant PACKET_CHECKSUM_VALIDATION_FAILURE. */ + /** Human-readable text after a failed EIS call. */ public static final String EXTERNAL_STAGE_FAILURE = "external stage failure"; - /** The Constant PACKET_FILES_VALIDATION_FAILURE. */ + /** Human-readable text after a successful EIS call. */ public static final String EXTERNAL_STAGE_SUCCESS = "external stage success"; } diff --git a/registration-processor/registration-processor-external-stage/src/main/resources/bootstrap.properties b/registration-processor/registration-processor-external-stage/src/main/resources/bootstrap.properties index c55caa59d94..bc68ae87bdd 100644 --- a/registration-processor/registration-processor-external-stage/src/main/resources/bootstrap.properties +++ b/registration-processor/registration-processor-external-stage/src/main/resources/bootstrap.properties @@ -5,6 +5,8 @@ spring.profiles.active=dev spring.cloud.config.name=registration-processor config.server.file.storage.uri=${spring.cloud.config.uri}/${packet.info.storage.service}/${spring.profiles.active}/${spring.cloud.config.label}/ management.endpoints.web.exposure.include=refresh +# Actuator /info reads this file. git.properties is reserved for kernel-core. +spring.info.git.location=classpath:service-git.properties registration.processor.zone=secure vertx.cluster.configuration=${spring.cloud.config.uri}/*/${spring.profiles.active}/${spring.cloud.config.label}/hazelcast_${registration.processor.zone}.xml #management.security.enabled=false diff --git a/registration-processor/registration-processor-external-stage/src/test/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStageTest.java b/registration-processor/registration-processor-external-stage/src/test/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStageTest.java index d12edbd68d6..f0c3e23074e 100644 --- a/registration-processor/registration-processor-external-stage/src/test/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStageTest.java +++ b/registration-processor/registration-processor-external-stage/src/test/java/io/mosip/registrationprocessor/externalstage/stage/ExternalStageTest.java @@ -2,8 +2,8 @@ import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; -import static org.mockito.Matchers.any; -import static org.mockito.Matchers.anyString; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.ArgumentMatchers.anyString; import org.junit.Before; import org.junit.Test; @@ -11,6 +11,7 @@ import org.mockito.InjectMocks; import org.mockito.Mock; import org.mockito.Mockito; +import org.mockito.MockitoAnnotations; import org.springframework.test.context.junit4.SpringRunner; import org.springframework.test.util.ReflectionTestUtils; @@ -82,6 +83,7 @@ public void testDeployVerticle() { InternalRegistrationStatusDto registrationStatusDto=new InternalRegistrationStatusDto(); @Before public void setUp() throws Exception { + MockitoAnnotations.openMocks(this); ReflectionTestUtils.setField(externalStage, "workerPoolSize", 10); ReflectionTestUtils.setField(externalStage, "clusterManagerUrl", "/dummyPath"); ReflectionTestUtils.setField(externalStage, "messageExpiryTimeLimit", Long.valueOf(0)); diff --git a/testng-report-failed1.tar.gz b/testng-report-failed1.tar.gz deleted file mode 100644 index ab30135bea73cc1c3e116703fb8736a02cd2f888..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 106106 zcmZU)byQr>6Ss*4cS0E40t6r286?3acz~cmgS#{6K!D&b!JXj2-7UBWcXyYWCExsZ z_q@CR%y~|qxpRANSAD9wx-MlnDjeRZq&^(tQ7eY?+d&QbC7_vgRR4S*@}=NMx$j;j zQpKvRbP4L7Zpy<`?DgDSbu+0Bnr50Ba@q+q8rsW0V@x8n`R9?pV1{@48O=3UhF8t; zHivT9^BR*I#DnbcAPp2KF} zGmY(1nUzhxfc8H3d%X#g0Kwv6n^qAzXXl@6YqXvf7(YwOl-Ct=1s7t|bmTJyi7w>w zRi~!z0Z)p`yJ~%_+|Xa;p9FOW@(P@SKeLg`o2pH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$I&T75 zGktsGUul}YRd1W>`rAiv9P^=v^x_QAC5)( z;Bj$bDTo;LWfzq0_&}C}r$WWc$gAoVv7;Pe88pb}$}!)0>KVK}zi?Tx-?Ke)vmZ&} zK(+L3vb-8^8BFm0i+R80V=7jlN?X&_H>)8PtvE|z7jhfkJy}}5)vuYGj{6nAu@L9S zDWddm585Poyq3mg9vO44H>+sg^!02CrK+{(;Hs-q3Qn7P6~EV`EBU}<@qH+EhhO&k zJ0A;Ef{duu(lozcH2u*LOO^)lR(wa6_Osp|m&cbx)^&z3#=nc(N6NJ4 zw)CtXtU~Uv*L74sx7wLd5q~Qs$L0eWabQdBS0i`Y-oJFvZa%zDP3T=NqKFv6O#T?T zUR@9@WhEiyLQ}MqoD3m^UU=YBCx~_#vJK<&X;7yxjyG34+Z9YwAuHefCYi5c`s;i^ zVTcadkRt+KDa2*LC>%|{MQ7AIHQ;ou%J;PbogbHm%Uj5&IK7C+Ocwa~hAd0zV&g1! zO63@4fo$uk9Rd3G$d6(2ZsXlRA=CCILLUP$LSjSze|&3Eow4P{(KqlIscp)CQ>!9u+fpJ@n_5jxDPj(%1C7tR z-u9xI?M2+Q=Q-O*VbguMA>HH?xFE)^kdle}RzVh1b{sczxO|D`4E8Hdjior&rDoI9Oaph!t=5pqwLkNM{e J

|;e*kO4wmbj; From 094f7b953963f9e523e38310c422e9022087e80a Mon Sep 17 00:00:00 2001 From: JanardhanBS-SyncByte Date: Wed, 30 Sep 2026 11:39:36 +0530 Subject: [PATCH 2/6] [issue-1633] push trigger Signed-off-by: JanardhanBS-SyncByte --- .github/AGENTS.md | 2 +- .github/workflows/push-trigger.yml | 10 ++++++++++ registration-processor/AGENTS.md | 2 +- registration-processor/pom.xml | 3 --- 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/.github/AGENTS.md b/.github/AGENTS.md index 2c5925b7bb7..9f3da917418 100644 --- a/.github/AGENTS.md +++ b/.github/AGENTS.md @@ -14,4 +14,4 @@ Do not glob. Do not read `keys/`. └── mosipgpgkey_sec.gpg ``` -`push-trigger.yml`: Maven `SERVICE_LOCATION` = aggregator for `kernel/` + `registration-processor/`. Docker still child paths. OSSRH skip on `master` + PRs. +`push-trigger.yml`: Maven `SERVICE_LOCATION` = aggregator for `kernel/` + `registration-processor/`. Docker still child paths. OSSRH skip on `master` + PRs. Booking Maven waits for `publish_to_nexus_kernel` (same-repo `kernel-ref-idobjectvalidator`). diff --git a/.github/workflows/push-trigger.yml b/.github/workflows/push-trigger.yml index a2a4cd04fd4..d806904ab66 100644 --- a/.github/workflows/push-trigger.yml +++ b/.github/workflows/push-trigger.yml @@ -62,7 +62,14 @@ jobs: OSSRH_TOKEN: ${{ secrets.OSSRH_TOKEN }} GPG_SECRET: ${{ secrets.GPG_SECRET }} SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK }} + # Booking packages kernel-ref-idobjectvalidator 1.4.1-SNAPSHOT from this repo. + # Wait for kernel publish so Central snapshots has the JAR. On PR/master, publish + # is skipped — still run booking (artifact may already be on snapshots). build-maven-pre-registration-booking-service: + needs: + - build-maven-kernel + - publish_to_nexus_kernel + if: ${{ always() && needs.build-maven-kernel.result == 'success' && (needs.publish_to_nexus_kernel.result == 'success' || needs.publish_to_nexus_kernel.result == 'skipped') }} uses: mosip/kattu/.github/workflows/maven-build.yml@master-java21 with: SERVICE_LOCATION: pre-registration-booking-service @@ -128,11 +135,14 @@ jobs: # Docker stays on each service dir so image names and Helm/K8s deploy are unchanged. # No publish_to_nexus here (same as before) — parent POM is not published as a Docker image # and artifactId is registration-processor-ref-parent (not registration-processor). + # kattu zips +x Boot JARs as artifact "registration-processor". Docker jobs + # download that zip. MAVEN_NON_EXEC_ARTIFACTS covers JARs without the exec bit. build-maven-registration-processor: uses: mosip/kattu/.github/workflows/maven-build.yml@master-java21 with: SERVICE_LOCATION: registration-processor BUILD_ARTIFACT: registration-processor + MAVEN_NON_EXEC_ARTIFACTS: registration-processor-external-stage.jar,registration-processor-external-integration-service.jar secrets: OSSRH_USER: ${{ secrets.OSSRH_USER }} OSSRH_SECRET: ${{ secrets.OSSRH_SECRET }} diff --git a/registration-processor/AGENTS.md b/registration-processor/AGENTS.md index bdc88bbb2ef..f9b491306c3 100644 --- a/registration-processor/AGENTS.md +++ b/registration-processor/AGENTS.md @@ -1,6 +1,6 @@ # registration-processor -`registration-processor-ref-parent` (`packaging=pom`). Boot 4.1.1. No `pre-processor`. Child → that folder’s `AGENTS.md`. Pins in this `pom.xml`. +`registration-processor-ref-parent` (`packaging=pom`). Boot 4.1.1. No `pre-processor`. Child → that folder’s `AGENTS.md`. Pins in this `pom.xml`. CI artifact name: `registration-processor` (both child Boot JARs). ``` registration-processor/ diff --git a/registration-processor/pom.xml b/registration-processor/pom.xml index 18a4d95e68f..4f080ad337c 100644 --- a/registration-processor/pom.xml +++ b/registration-processor/pom.xml @@ -207,9 +207,6 @@ build-info repackage - - false - From a65f048abd2e60178e5aa6897b40c7dfb972be9c Mon Sep 17 00:00:00 2001 From: JanardhanBS-SyncByte Date: Wed, 30 Sep 2026 11:42:28 +0530 Subject: [PATCH 3/6] [issue-1633] agent Signed-off-by: JanardhanBS-SyncByte --- .github/AGENTS.md | 12 ++--- AGENTS.md | 52 +++++++------------ cache-provider-hazelcast/AGENTS.md | 8 ++- cache-provider-redis/AGENTS.md | 8 ++- helm/prereg-booking/AGENTS.md | 4 +- kernel/AGENTS.md | 12 ++--- kernel/kernel-ref-idobjectvalidator/AGENTS.md | 13 ++--- .../kernel-smsserviceprovider-msg91/AGENTS.md | 11 ++-- kernel/kernel-virusscanner-clamav/AGENTS.md | 13 ++--- keycloak/AGENTS.md | 2 +- pre-registration-booking-service/AGENTS.md | 45 ++++++++-------- registration-processor/AGENTS.md | 10 ++-- .../AGENTS.md | 23 ++++---- .../AGENTS.md | 22 ++++---- 14 files changed, 93 insertions(+), 142 deletions(-) diff --git a/.github/AGENTS.md b/.github/AGENTS.md index 9f3da917418..5acfa023eae 100644 --- a/.github/AGENTS.md +++ b/.github/AGENTS.md @@ -1,17 +1,15 @@ # .github -Do not glob. Do not read `keys/`. +Do not glob. Never read `keys/`. ``` .github/ ├── AGENTS.md ├── workflows/ -│ ├── push-trigger.yml # Maven/Docker/OSSRH/Sonar — kattu@master-java21 -│ ├── chart-lint-publish.yml # helm +│ ├── push-trigger.yml # kattu@master-java21 +│ ├── chart-lint-publish.yml │ └── use-pr-linker.yml -└── keys/ # GPG — never read/edit/commit - ├── mosipgpgkey_pub.gpg - └── mosipgpgkey_sec.gpg +└── keys/ # GPG — never read/edit/commit ``` -`push-trigger.yml`: Maven `SERVICE_LOCATION` = aggregator for `kernel/` + `registration-processor/`. Docker still child paths. OSSRH skip on `master` + PRs. Booking Maven waits for `publish_to_nexus_kernel` (same-repo `kernel-ref-idobjectvalidator`). +`push-trigger.yml`: Maven at aggregator (`kernel/`, `registration-processor/`). Docker = child paths. OSSRH skip `master`+PR. Booking Maven `needs` kernel publish. Regproc Docker downloads artifact `registration-processor` (both Boot JARs). diff --git a/AGENTS.md b/AGENTS.md index afdfb180e75..436eff5cf07 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,37 +1,29 @@ # AGENTS.md -MOSIP **ref impls** (not core). Independent Maven modules. No root parent. Each top parents `spring-boot-starter-parent` **4.1.1**. No `kernel-bom`. Pins live in `pom.xml` only. +Ref impls (not core). No root parent. Tops parent Boot **4.1.1**. No `kernel-bom`. Pins in `pom.xml` only. No versions in comments. -## Speed - -1. **Do not glob / find / `ls`.** This tree + **one** nested `AGENTS.md` is the map. -2. Open **named files only**. Never scan `target/`, `.git/`, `.idea/`, `.sts4-cache/`, `node_modules/`, `*.class`, `*.jar`, `.github/keys/`. -3. Grep a known path. Do not repo-search. Do not put MOSIP versions in comments. - -## Tree +**Speed:** do not glob/`ls`. Read this tree + **one** nested `AGENTS.md`. Open named files only. Never scan `target/`, `.git/`, `.idea/`, `.sts4-cache/`, `node_modules/`, `*.class`, `*.jar`, `.github/keys/`. Grep a known path. ``` mosip-ref-impl/ -├── cache-provider-hazelcast/ PacketCacheProvider + health → AGENTS.md -├── cache-provider-redis/ PacketCacheProvider Redis → AGENTS.md -├── kernel/ kernel-ref-parent (3 SPIs) → AGENTS.md -│ ├── kernel-ref-idobjectvalidator/ IdObjectValidator → AGENTS.md -│ ├── kernel-smsserviceprovider-msg91/ SMS SPI (MSG91) → AGENTS.md -│ └── kernel-virusscanner-clamav/ VirusScanner + ClamAV → AGENTS.md -├── keycloak/ login FTL overlay → AGENTS.md -├── pre-registration-booking-service/ /appointment/** → AGENTS.md -├── registration-processor/ registration-processor-ref-parent → AGENTS.md -│ ├── registration-processor-external-stage/ → AGENTS.md -│ └── registration-processor-external-integration-service/ → AGENTS.md -├── helm/prereg-booking/ k8s; javaOpts → JDK_JAVA_OPTIONS → AGENTS.md -├── licenses/ third-party texts + NOTICE -├── .github/ CI + GPG keys → AGENTS.md +├── cache-provider-hazelcast/ PacketCacheProvider + health → AGENTS.md +├── cache-provider-redis/ PacketCacheProvider Redis → AGENTS.md +├── kernel/ kernel-ref-parent (3 SPIs) → AGENTS.md +│ ├── kernel-ref-idobjectvalidator/ IdObjectValidator → AGENTS.md +│ ├── kernel-smsserviceprovider-msg91/ SMS SPI → AGENTS.md +│ └── kernel-virusscanner-clamav/ VirusScanner → AGENTS.md +├── keycloak/ login FTL → AGENTS.md +├── pre-registration-booking-service/ /appointment/** → AGENTS.md +├── registration-processor/ registration-processor-ref-parent → AGENTS.md +│ ├── registration-processor-external-stage/ → AGENTS.md +│ └── registration-processor-external-integration-service/ → AGENTS.md +├── helm/prereg-booking/ javaOpts → JDK_JAVA_OPTIONS → AGENTS.md +├── licenses/ NOTICE texts +├── .github/ CI; never read keys/ → AGENTS.md ├── deploy.sh LICENSE NOTICE README.md ``` -Angular UIs are other repos. No TestNG report archive. - -## Build (cwd = module; aggregators = `kernel/`, `registration-processor/`) +Angular UIs are other repos. Aggregators: `kernel/`, `registration-processor/`. ```bash mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true @@ -39,12 +31,4 @@ mvn test -Dtest=ClassName[#method] mvn clean verify ``` -## Facts - -- Swap impl = swap JAR. Kernel SPIs: `META-INF/spring.factories`. Services: Boot 4.1.1. No `pre-processor`. Logging = `kernel-core`, not `kernel-logger-logback`. -- Jackson 2 = `spring-boot-jackson2`. Spring Cloud **2025.1.3**. `git-commit-id` → `service-git.properties`. -- Config: `mosip/mosip-config` (`application-default`, `pre-registration-default`, `registration-processor-default`). -- Tests: JUnit 4 vintage + Mockito; `--add-opens` in poms; idobjectvalidator `--enable-preview`. -- Coverage: JaCoCo LINE **0.90** (`jacoco-check` = `sonar.coverage.exclusions`). Report: `target/site/jacoco/index.html`. -- Docker: no glowroot, no `iam_adapter_url` wget. Adapters in JAR. JVM flags from Helm `javaOpts`. -- CI: `.github/workflows/push-trigger.yml` → `mosip/kattu@master-java21`. +Swap impl = swap JAR. SPIs: `spring.factories`. No `pre-processor`. Log via `kernel-core` (not `kernel-logger-logback`). Jackson 2 = `spring-boot-jackson2`. Cloud **2025.1.3**. Git → `service-git.properties`. Config: `mosip/mosip-config`. Tests: JUnit 4 + Mockito; idobjectvalidator `--enable-preview`. JaCoCo LINE **0.90**. Docker: no glowroot/wget; adapters in JAR; JVM from Helm. CI: `push-trigger.yml` → `kattu@master-java21`. diff --git a/cache-provider-hazelcast/AGENTS.md b/cache-provider-hazelcast/AGENTS.md index e9d1fae0081..c55d27d4422 100644 --- a/cache-provider-hazelcast/AGENTS.md +++ b/cache-provider-hazelcast/AGENTS.md @@ -1,12 +1,10 @@ # cache-provider-hazelcast -`PacketCacheProvider` + Boot 4 health. Standalone pom. Pins in `pom.xml`. +`PacketCacheProvider` + health. Standalone. Pins in `pom.xml`. ``` cache-provider-hazelcast/ ├── pom.xml README.md AGENTS.md -├── src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/ -│ └── HazelcastHealthIndicator.java # packetmanager.hazelcast.disable.health.check -└── src/test/java/.../config/ - └── HazelcastHealthIndicatorTest.java +├── src/main/java/.../hazelcast/config/HazelcastHealthIndicator.java +└── src/test/java/.../config/HazelcastHealthIndicatorTest.java ``` diff --git a/cache-provider-redis/AGENTS.md b/cache-provider-redis/AGENTS.md index cfba7606acf..7a0af2fff02 100644 --- a/cache-provider-redis/AGENTS.md +++ b/cache-provider-redis/AGENTS.md @@ -1,12 +1,10 @@ # cache-provider-redis -`PacketCacheProvider` (Jedis). Standalone pom. Pins in `pom.xml`. +`PacketCacheProvider` (Jedis). Standalone. Pins in `pom.xml`. ``` cache-provider-redis/ ├── pom.xml README.md AGENTS.md -├── src/main/java/io/mosip/commons/packet/cache/provider/redis/config/ -│ └── RedisConfig.java # redis.cache.hostname|port|password -└── src/test/java/.../config/ - └── RedisConfigTest.java +├── src/main/java/.../redis/config/RedisConfig.java +└── src/test/java/.../config/RedisConfigTest.java ``` diff --git a/helm/prereg-booking/AGENTS.md b/helm/prereg-booking/AGENTS.md index 8f29a49195e..353d2d5cbbe 100644 --- a/helm/prereg-booking/AGENTS.md +++ b/helm/prereg-booking/AGENTS.md @@ -1,12 +1,12 @@ # helm/prereg-booking -Chart for booking image. GC/encoding flags = `values.yaml` `additionalResources.javaOpts` → `JDK_JAVA_OPTIONS` (not Dockerfile). +`values.yaml` `additionalResources.javaOpts` → `JDK_JAVA_OPTIONS`. Not in Dockerfile. ``` helm/prereg-booking/ ├── Chart.yaml values.yaml README.md AGENTS.md └── templates/ - ├── deployment.yaml # JDK_JAVA_OPTIONS from javaOpts + ├── deployment.yaml ├── service.yaml ├── serviceaccount.yaml ├── servicemonitor.yaml diff --git a/kernel/AGENTS.md b/kernel/AGENTS.md index c9607af04ba..69a64bf2cec 100644 --- a/kernel/AGENTS.md +++ b/kernel/AGENTS.md @@ -1,15 +1,11 @@ # kernel -`kernel-ref-parent` (`packaging=pom`). Boot 4.1.1. No `kernel-bom`. Child → that folder’s `AGENTS.md`. +`kernel-ref-parent` (`packaging=pom`). Child → that `AGENTS.md`. Pins in `pom.xml`. ``` kernel/ ├── pom.xml AGENTS.md -├── kernel-ref-idobjectvalidator/ IdObjectValidator → AGENTS.md -├── kernel-smsserviceprovider-msg91/ SMS SPI (MSG91) → AGENTS.md -└── kernel-virusscanner-clamav/ VirusScanner + ClamAV → AGENTS.md -``` - -```bash -mvn -f kernel/pom.xml -pl clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +├── kernel-ref-idobjectvalidator/ → AGENTS.md +├── kernel-smsserviceprovider-msg91/ → AGENTS.md +└── kernel-virusscanner-clamav/ → AGENTS.md ``` diff --git a/kernel/kernel-ref-idobjectvalidator/AGENTS.md b/kernel/kernel-ref-idobjectvalidator/AGENTS.md index 89b253fbb41..b2b03cb3538 100644 --- a/kernel/kernel-ref-idobjectvalidator/AGENTS.md +++ b/kernel/kernel-ref-idobjectvalidator/AGENTS.md @@ -1,6 +1,6 @@ # kernel-ref-idobjectvalidator -`IdObjectValidator` SPI. Tests: `--enable-preview`. Pins in parent `kernel/pom.xml`. +`IdObjectValidator` SPI. Tests `--enable-preview`. Pins in `kernel/pom.xml`. ``` kernel-ref-idobjectvalidator/ @@ -8,13 +8,10 @@ kernel-ref-idobjectvalidator/ └── src/ ├── main/java/io/mosip/kernel/idobjectvalidator/ │ ├── impl/IdObjectReferenceValidator.java - │ └── constant/ - │ ├── IdObjectReferenceValidatorConstant.java - │ ├── IdObjectReferenceValidatorDocumentMapping.java - │ └── IdObjectReferenceValidatorLocationMapping.java + │ └── constant/IdObjectReferenceValidatorConstant.java + │ IdObjectReferenceValidatorDocumentMapping.java + │ IdObjectReferenceValidatorLocationMapping.java └── test/ - ├── java/.../idobjectvalidator/test/ - │ ├── IdObjectReferenceValidatorTest.java - │ └── TestConfig.java + ├── java/.../test/IdObjectReferenceValidatorTest.java TestConfig.java └── resources/ application-test.properties schema.json ``` diff --git a/kernel/kernel-smsserviceprovider-msg91/AGENTS.md b/kernel/kernel-smsserviceprovider-msg91/AGENTS.md index ca9c4e7ee4d..5473a8276f8 100644 --- a/kernel/kernel-smsserviceprovider-msg91/AGENTS.md +++ b/kernel/kernel-smsserviceprovider-msg91/AGENTS.md @@ -1,6 +1,6 @@ # kernel-smsserviceprovider-msg91 -`SMSServiceProvider` SPI (MSG91). Auto-config: `META-INF/spring.factories`. Pins in `kernel/pom.xml`. +`SMSServiceProvider` SPI. `META-INF/spring.factories`. Pins in `kernel/pom.xml`. ``` kernel-smsserviceprovider-msg91/ @@ -12,10 +12,7 @@ kernel-smsserviceprovider-msg91/ │ │ ├── exception/ApiExceptionHandler.java │ │ ├── dto/SmsVendorRequestDto.java SmsServerResponseDto.java │ │ └── constant/SmsPropertyConstant.java SmsExceptionConstant.java - │ └── resources/ - │ ├── META-INF/spring.factories - │ └── logback.xml - └── test/ - ├── java/.../msg91/SmsServiceProviderTest.java - └── resources/application.properties + │ └── resources/META-INF/spring.factories logback.xml + └── test/java/.../SmsServiceProviderTest.java + resources/application.properties ``` diff --git a/kernel/kernel-virusscanner-clamav/AGENTS.md b/kernel/kernel-virusscanner-clamav/AGENTS.md index d56ed822ab1..252cd7103a1 100644 --- a/kernel/kernel-virusscanner-clamav/AGENTS.md +++ b/kernel/kernel-virusscanner-clamav/AGENTS.md @@ -1,6 +1,6 @@ # kernel-virusscanner-clamav -`VirusScanner` (`ScanResult.OK` / `VirusFound`). Auto-config: `spring.factories`. Pins in `kernel/pom.xml`. +`VirusScanner`. `spring.factories`. Pins in `kernel/pom.xml`. ``` kernel-virusscanner-clamav/ @@ -10,12 +10,7 @@ kernel-virusscanner-clamav/ │ ├── java/io/mosip/kernel/virusscanner/clamav/ │ │ ├── impl/VirusScannerImpl.java │ │ └── constant/VirusScannerErrorCodes.java - │ └── resources/ - │ ├── META-INF/spring.factories - │ └── logback.xml - └── test/ - ├── java/.../clamav/test/ - │ ├── VirusScannerServiceTest.java - │ └── VirusScannerExceptionTest.java - └── resources/ application.properties logback.xml files/test1.docx + │ └── resources/META-INF/spring.factories logback.xml + └── test/java/.../test/VirusScannerServiceTest.java VirusScannerExceptionTest.java + resources/ application.properties logback.xml files/test1.docx ``` diff --git a/keycloak/AGENTS.md b/keycloak/AGENTS.md index dfe743c9846..07620026a6d 100644 --- a/keycloak/AGENTS.md +++ b/keycloak/AGENTS.md @@ -1,6 +1,6 @@ # keycloak -Theme overlay only. Empty `standalone/deployments/`. +Theme overlay. Empty `standalone/deployments/`. ``` keycloak/ diff --git a/pre-registration-booking-service/AGENTS.md b/pre-registration-booking-service/AGENTS.md index b343673d4e4..8e7973c9cad 100644 --- a/pre-registration-booking-service/AGENTS.md +++ b/pre-registration-booking-service/AGENTS.md @@ -1,34 +1,31 @@ # pre-registration-booking-service -Boot REST `BookingApplication` → `BookingController` `/appointment/**`. Roles via `@authorizedRoles` bean. Adapters in JAR (no wget). JVM from Helm `javaOpts`. Pins in `pom.xml`. +`BookingController` `/appointment/**`. Adapters in JAR. JVM = Helm `javaOpts`. Pins in `pom.xml`. CI waits for kernel publish. ``` pre-registration-booking-service/ ├── pom.xml Dockerfile README.md AGENTS.md └── src/ - ├── main/ - │ ├── java/io/mosip/preregistration/booking/ - │ │ ├── BookingApplication.java - │ │ ├── controller/BookingController.java - │ │ ├── service/BookingService.java BookingServiceIntf.java - │ │ ├── service/util/BookingServiceUtil.java BookingLock.java - │ │ ├── config/BookingConfig.java OpenApiProperties.java - │ │ ├── repository/BookingAvailabilityRepository.java DemographicRepository.java RegistrationBookingRepository.java - │ │ ├── repository/impl/BookingDAO.java - │ │ ├── entity/AvailabilityPK.java AvailibityEntity.java - │ │ ├── codes/RequestCodes.java - │ │ ├── errorcodes/ErrorCodes.java ErrorMessages.java - │ │ ├── dto/ - │ │ └── exception/ util/BookingExceptionCatcher.java BookingExceptionHandler.java - │ └── resources/ bootstrap.properties logback.xml + ├── main/java/io/mosip/preregistration/booking/ + │ ├── BookingApplication.java + │ ├── controller/BookingController.java + │ ├── service/BookingService.java BookingServiceIntf.java + │ ├── service/util/BookingServiceUtil.java BookingLock.java + │ ├── config/BookingConfig.java OpenApiProperties.java + │ ├── repository/BookingAvailabilityRepository.java DemographicRepository.java RegistrationBookingRepository.java + │ ├── repository/impl/BookingDAO.java + │ ├── entity/AvailabilityPK.java AvailibityEntity.java + │ ├── codes/RequestCodes.java + │ ├── errorcodes/ErrorCodes.java ErrorMessages.java + │ ├── dto/ + │ └── exception/ util/BookingExceptionCatcher.java BookingExceptionHandler.java + ├── main/resources/ bootstrap.properties logback.xml └── test/ - ├── java/io/mosip/preregistration/booking/ - │ ├── config/BookingConfigOpenApiTest.java - │ └── test/ - │ ├── BookingApplicationTest.java - │ ├── config/TestConfig.java TestSecurityConfig.java - │ ├── controller/BookingControllerTest.java - │ └── service/BookingServiceTest.java BookingServiceCoverageTest.java BookingServiceIdentityMigrationTest.java - │ └── util/BookingServiceUtilTest.java + ├── java/.../booking/config/BookingConfigOpenApiTest.java + ├── java/.../booking/test/BookingApplicationTest.java + ├── java/.../test/config/TestConfig.java TestSecurityConfig.java + ├── java/.../test/controller/BookingControllerTest.java + ├── java/.../test/service/BookingServiceTest.java BookingServiceCoverageTest.java BookingServiceIdentityMigrationTest.java + ├── java/.../test/service/util/BookingServiceUtilTest.java └── resources/ application.properties bootstrap.properties booking.json cancelAppointment.json multibooking.json create-schema.sql ``` diff --git a/registration-processor/AGENTS.md b/registration-processor/AGENTS.md index f9b491306c3..3f2f5785924 100644 --- a/registration-processor/AGENTS.md +++ b/registration-processor/AGENTS.md @@ -1,14 +1,10 @@ # registration-processor -`registration-processor-ref-parent` (`packaging=pom`). Boot 4.1.1. No `pre-processor`. Child → that folder’s `AGENTS.md`. Pins in this `pom.xml`. CI artifact name: `registration-processor` (both child Boot JARs). +`registration-processor-ref-parent` (`packaging=pom`). Child → that `AGENTS.md`. Pins in `pom.xml`. CI artifact: `registration-processor` (both Boot JARs). ``` registration-processor/ ├── pom.xml AGENTS.md -├── registration-processor-external-stage/ Vert.x → EIS → AGENTS.md -└── registration-processor-external-integration-service/ EIS stub REST → AGENTS.md -``` - -```bash -mvn -f registration-processor/pom.xml -pl clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +├── registration-processor-external-stage/ → AGENTS.md +└── registration-processor-external-integration-service/ → AGENTS.md ``` diff --git a/registration-processor/registration-processor-external-integration-service/AGENTS.md b/registration-processor/registration-processor-external-integration-service/AGENTS.md index 09d85d7b4af..496b9821d40 100644 --- a/registration-processor/registration-processor-external-integration-service/AGENTS.md +++ b/registration-processor/registration-processor-external-integration-service/AGENTS.md @@ -1,21 +1,18 @@ # registration-processor-external-integration-service -EIS stub. `POST .../v1.0` → `true` if body non-null. Swagger Authorize = `Authorization` apiKey (`SwaggerConfig`). Pins in parent `pom.xml`. +EIS stub REST. Authorize = `Authorization` (`SwaggerConfig`). Pins in parent `pom.xml`. ``` registration-processor-external-integration-service/ ├── pom.xml Dockerfile README.md AGENTS.md └── src/ - ├── main/ - │ ├── java/io/mosip/registrationprocessor/eis/ - │ │ ├── ExternalIntegrationServiceApplication.java - │ │ ├── controller/ExternalController.java - │ │ ├── config/SwaggerConfig.java OpenApiProperties.java - │ │ └── entity/BaseRestRequestDTO.java MessageRequestDTO.java - │ └── resources/bootstrap.properties - └── test/ - ├── java/.../eis/ - │ ├── ExternalIntegrationControllerTest.java - │ └── config/SwaggerConfigTest.java - └── resources/application.properties + ├── main/java/io/mosip/registrationprocessor/eis/ + │ ├── ExternalIntegrationServiceApplication.java + │ ├── controller/ExternalController.java + │ ├── config/SwaggerConfig.java OpenApiProperties.java + │ └── entity/BaseRestRequestDTO.java MessageRequestDTO.java + ├── main/resources/bootstrap.properties + └── test/java/.../ExternalIntegrationControllerTest.java + test/java/.../config/SwaggerConfigTest.java + test/resources/application.properties ``` diff --git a/registration-processor/registration-processor-external-stage/AGENTS.md b/registration-processor/registration-processor-external-stage/AGENTS.md index 3b935ae384b..44f6c073fcc 100644 --- a/registration-processor/registration-processor-external-stage/AGENTS.md +++ b/registration-processor/registration-processor-external-stage/AGENTS.md @@ -1,20 +1,18 @@ # registration-processor-external-stage -Vert.x `ExternalStage`. `EXTERNAL_STAGE_BUS_IN` → POST EIS → `EXTERNAL_STAGE_BUS_OUT`. Adapter in JAR. Pins in parent `pom.xml`. +Vert.x `ExternalStage` → EIS POST. Adapter in JAR. Pins in parent `pom.xml`. ``` registration-processor-external-stage/ ├── pom.xml Dockerfile README.md AGENTS.md └── src/ - ├── main/ - │ ├── java/io/mosip/registrationprocessor/externalstage/ - │ │ ├── ExternalStageApplication.java - │ │ ├── stage/ExternalStage.java - │ │ ├── config/Externalconfig.java - │ │ ├── entity/BaseRestRequestDTO.java MessageRequestDTO.java - │ │ └── utils/StatusMessage.java - │ └── resources/ bootstrap.properties logback.xml - └── test/java/.../externalstage/ - ├── ExternalStageApplicationTests.java - └── stage/ExternalStageTest.java + ├── main/java/io/mosip/registrationprocessor/externalstage/ + │ ├── ExternalStageApplication.java + │ ├── stage/ExternalStage.java + │ ├── config/Externalconfig.java + │ ├── entity/BaseRestRequestDTO.java MessageRequestDTO.java + │ └── utils/StatusMessage.java + ├── main/resources/ bootstrap.properties logback.xml + └── test/java/.../ExternalStageApplicationTests.java + test/java/.../stage/ExternalStageTest.java ``` From 942e90107d2047cabdbfbb0bc2c76e8000df2466 Mon Sep 17 00:00:00 2001 From: JanardhanBS-SyncByte Date: Wed, 30 Sep 2026 12:07:46 +0530 Subject: [PATCH 4/6] [issue-1633] push trigger Signed-off-by: JanardhanBS-SyncByte --- .github/AGENTS.md | 2 +- .github/workflows/push-trigger.yml | 1 + pre-registration-booking-service/pom.xml | 5 +---- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/AGENTS.md b/.github/AGENTS.md index 5acfa023eae..5005e6bfe49 100644 --- a/.github/AGENTS.md +++ b/.github/AGENTS.md @@ -12,4 +12,4 @@ Do not glob. Never read `keys/`. └── keys/ # GPG — never read/edit/commit ``` -`push-trigger.yml`: Maven at aggregator (`kernel/`, `registration-processor/`). Docker = child paths. OSSRH skip `master`+PR. Booking Maven `needs` kernel publish. Regproc Docker downloads artifact `registration-processor` (both Boot JARs). +`push-trigger.yml`: Maven at aggregator (`kernel/`, `registration-processor/`). Docker = child paths. OSSRH skip `master`+PR. Booking Maven `needs` kernel publish; artifact `pre-registration-booking-service` (fat JAR). Regproc Docker artifact `registration-processor`. diff --git a/.github/workflows/push-trigger.yml b/.github/workflows/push-trigger.yml index d806904ab66..7902676f266 100644 --- a/.github/workflows/push-trigger.yml +++ b/.github/workflows/push-trigger.yml @@ -74,6 +74,7 @@ jobs: with: SERVICE_LOCATION: pre-registration-booking-service BUILD_ARTIFACT: pre-registration-booking-service + MAVEN_NON_EXEC_ARTIFACTS: pre-registration-booking-service.jar secrets: OSSRH_USER: ${{ secrets.OSSRH_USER }} OSSRH_SECRET: ${{ secrets.OSSRH_SECRET }} diff --git a/pre-registration-booking-service/pom.xml b/pre-registration-booking-service/pom.xml index 32fbfb59a06..5f5190dc599 100644 --- a/pre-registration-booking-service/pom.xml +++ b/pre-registration-booking-service/pom.xml @@ -387,7 +387,7 @@ org.springframework.boot spring-boot-maven-plugin - + true @@ -395,9 +395,6 @@ build-info repackage - - false - From 114915e22c66fc6d90be980726d9a115f9001181 Mon Sep 17 00:00:00 2001 From: JanardhanBS-SyncByte Date: Wed, 30 Sep 2026 12:58:43 +0530 Subject: [PATCH 5/6] [issue-1633] pom comments Signed-off-by: JanardhanBS-SyncByte --- AGENTS.md | 4 +- cache-provider-hazelcast/AGENTS.md | 8 +- cache-provider-hazelcast/README.md | 8 +- cache-provider-hazelcast/pom.xml | 112 +++++++++++++----- cache-provider-redis/AGENTS.md | 8 +- cache-provider-redis/README.md | 7 +- cache-provider-redis/pom.xml | 111 ++++++++++++----- kernel/AGENTS.md | 14 ++- kernel/README.md | 28 +++-- kernel/kernel-ref-idobjectvalidator/AGENTS.md | 13 +- kernel/kernel-ref-idobjectvalidator/README.md | 14 +-- kernel/kernel-ref-idobjectvalidator/pom.xml | 24 +++- .../kernel-smsserviceprovider-msg91/AGENTS.md | 11 +- .../kernel-smsserviceprovider-msg91/README.md | 50 +++----- .../kernel-smsserviceprovider-msg91/pom.xml | 23 +++- kernel/kernel-virusscanner-clamav/AGENTS.md | 13 +- kernel/kernel-virusscanner-clamav/README.md | 13 +- kernel/kernel-virusscanner-clamav/pom.xml | 21 +++- kernel/pom.xml | 34 ++++-- pre-registration-booking-service/pom.xml | 44 +++++-- registration-processor/AGENTS.md | 12 +- registration-processor/README.md | 11 +- registration-processor/pom.xml | 29 ++++- .../AGENTS.md | 23 ++-- .../README.md | 9 +- .../pom.xml | 21 +++- .../AGENTS.md | 22 ++-- .../README.md | 9 +- .../pom.xml | 24 +++- 29 files changed, 501 insertions(+), 219 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 436eff5cf07..3e94775dc23 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -15,8 +15,8 @@ mosip-ref-impl/ ├── keycloak/ login FTL → AGENTS.md ├── pre-registration-booking-service/ /appointment/** → AGENTS.md ├── registration-processor/ registration-processor-ref-parent → AGENTS.md -│ ├── registration-processor-external-stage/ → AGENTS.md -│ └── registration-processor-external-integration-service/ → AGENTS.md +│ ├── registration-processor-external-stage/ Vert.x → EIS → AGENTS.md +│ └── registration-processor-external-integration-service/ EIS stub REST → AGENTS.md ├── helm/prereg-booking/ javaOpts → JDK_JAVA_OPTIONS → AGENTS.md ├── licenses/ NOTICE texts ├── .github/ CI; never read keys/ → AGENTS.md diff --git a/cache-provider-hazelcast/AGENTS.md b/cache-provider-hazelcast/AGENTS.md index c55d27d4422..e9d1fae0081 100644 --- a/cache-provider-hazelcast/AGENTS.md +++ b/cache-provider-hazelcast/AGENTS.md @@ -1,10 +1,12 @@ # cache-provider-hazelcast -`PacketCacheProvider` + health. Standalone. Pins in `pom.xml`. +`PacketCacheProvider` + Boot 4 health. Standalone pom. Pins in `pom.xml`. ``` cache-provider-hazelcast/ ├── pom.xml README.md AGENTS.md -├── src/main/java/.../hazelcast/config/HazelcastHealthIndicator.java -└── src/test/java/.../config/HazelcastHealthIndicatorTest.java +├── src/main/java/io/mosip/commons/packet/cache/provider/hazelcast/config/ +│ └── HazelcastHealthIndicator.java # packetmanager.hazelcast.disable.health.check +└── src/test/java/.../config/ + └── HazelcastHealthIndicatorTest.java ``` diff --git a/cache-provider-hazelcast/README.md b/cache-provider-hazelcast/README.md index b042dc691e0..ee7e816d9cf 100644 --- a/cache-provider-hazelcast/README.md +++ b/cache-provider-hazelcast/README.md @@ -2,9 +2,9 @@ MOSIP `PacketCacheProvider` SPI backed by Hazelcast, plus an Actuator health indicator. -- **Artifact**: `io.mosip.cacheprovider:cache-provider-hazelcast:1.4.1-SNAPSHOT` -- **Parent**: `spring-boot-starter-parent` **4.1.1** -- **Hazelcast**: 5.7.0 +Pins (Boot parent, Hazelcast, plugins, JaCoCo gate) live in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.cacheprovider:cache-provider-hazelcast` - **Health**: `HazelcastHealthIndicator` (`org.springframework.boot.health.contributor` — Boot 4) - **Git info**: `service-git.properties` @@ -21,7 +21,7 @@ Drop the JAR on the packet-manager classpath (scope of `spring-boot-starter` / a mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -JaCoCo LINE covered ratio **0.90** (`target/site/jacoco/index.html`). +JaCoCo LINE covered ratio is gated in `pom.xml` (`target/site/jacoco/index.html`). ## Health diff --git a/cache-provider-hazelcast/pom.xml b/cache-provider-hazelcast/pom.xml index ee13b97cbd2..d55d0b6d3f2 100644 --- a/cache-provider-hazelcast/pom.xml +++ b/cache-provider-hazelcast/pom.xml @@ -4,6 +4,10 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + org.springframework.boot spring-boot-starter-parent @@ -16,18 +20,27 @@ 1.4.1-SNAPSHOT cache-provider-hazelcast - MOSIP PacketCacheProvider SPI backed by Hazelcast (Spring Boot 4.1.1, Java 21). - No kernel-bom. Module version and third-party pins live in this pom — not in README.md. + MOSIP PacketCacheProvider SPI backed by Hazelcast IMDG, plus Boot 4 Actuator + health (HazelcastHealthIndicator on org.springframework.boot.health.contributor). + Spring Boot 4.1.1 parent, Java 21. Standalone — no kernel-bom and no + kernel-ref-parent. Module, plugin, and third-party pins live in this pom — + not in README.md or AGENTS.md. Fat JAR (assembly jar-with-dependencies, + appendAssemblyId false) is dropped onto the packet-manager classpath; + spring-boot-starter and actuator are provided by that host. https://github.com/mosip/mosip-ref-impl 21 + false + + 3.16.0 3.6.0 0.8.15 + 0.90 ${project.build.directory}/site/jacoco/jacoco.xml 5.8.0.7211 @@ -37,36 +50,18 @@ 3.2.0 4.9.10 0.11.0 + 3.8.0 - + + + 5.7.0 - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - repo - - - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - MOSIP - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip - - - org.springframework.boot @@ -74,8 +69,9 @@ provided org.springframework.boot @@ -83,13 +79,18 @@ provided com.hazelcast hazelcast ${hazelcast.version} + org.springframework.boot spring-boot-starter-test @@ -110,6 +111,11 @@ + org.apache.maven.plugins maven-assembly-plugin @@ -130,6 +136,10 @@ + org.apache.maven.plugins maven-compiler-plugin @@ -139,6 +149,10 @@ true + org.apache.maven.plugins maven-surefire-plugin @@ -148,6 +162,10 @@ @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED + org.jacoco jacoco-maven-plugin @@ -187,6 +205,7 @@ + org.apache.maven.plugins maven-source-plugin @@ -200,6 +219,7 @@ + org.apache.maven.plugins maven-javadoc-plugin @@ -217,6 +237,7 @@ false + org.apache.maven.plugins maven-gpg-plugin @@ -237,6 +258,10 @@ + pl.project13.maven git-commit-id-plugin @@ -251,7 +276,6 @@ - true ${project.build.outputDirectory}/service-git.properties @@ -262,11 +286,16 @@ ${project.basedir}/.git + org.apache.maven.plugins maven-deploy-plugin ${maven.deploy.plugin.version} + org.sonatype.central central-publishing-maven-plugin @@ -280,6 +309,7 @@ + sonar @@ -309,4 +339,26 @@ + + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + repo + + + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MOSIP + mosip.emailnotifier@gmail.com + io.mosip + https://github.com/mosip + + diff --git a/cache-provider-redis/AGENTS.md b/cache-provider-redis/AGENTS.md index 7a0af2fff02..be1878dc30a 100644 --- a/cache-provider-redis/AGENTS.md +++ b/cache-provider-redis/AGENTS.md @@ -1,10 +1,12 @@ # cache-provider-redis -`PacketCacheProvider` (Jedis). Standalone. Pins in `pom.xml`. +`PacketCacheProvider` (Jedis). Standalone pom. Pins and the module description live in `pom.xml`. ``` cache-provider-redis/ ├── pom.xml README.md AGENTS.md -├── src/main/java/.../redis/config/RedisConfig.java -└── src/test/java/.../config/RedisConfigTest.java +├── src/main/java/io/mosip/commons/packet/cache/provider/redis/config/ +│ └── RedisConfig.java # redis.cache.hostname|port|password +└── src/test/java/.../config/ + └── RedisConfigTest.java ``` diff --git a/cache-provider-redis/README.md b/cache-provider-redis/README.md index 40878de73ee..45770a062a0 100644 --- a/cache-provider-redis/README.md +++ b/cache-provider-redis/README.md @@ -2,8 +2,9 @@ MOSIP `PacketCacheProvider` SPI backed by Redis (Jedis; Lettuce excluded). -- **Artifact**: `io.mosip.cacheprovider:cache-provider-redis:1.4.1-SNAPSHOT` -- **Parent**: `spring-boot-starter-parent` **4.1.1** +Pins (Boot parent, plugins, JaCoCo gate) and the module description live in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.cacheprovider:cache-provider-redis` - **Config**: `RedisConfig` (`redis.cache.hostname`, `port`, `password`, pool timeouts) - **Git info**: `service-git.properties` @@ -20,7 +21,7 @@ Drop the JAR on the packet-manager classpath. mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -JaCoCo LINE covered ratio **0.90** (`target/site/jacoco/index.html`). Redis: `redis.cache.hostname`, `port`, `password`, pool timeouts (see `RedisConfig`). Lettuce is excluded in favor of Jedis. +JaCoCo LINE covered ratio is gated in `pom.xml` (`target/site/jacoco/index.html`). Redis: `redis.cache.hostname`, `port`, `password`, pool timeouts (see `RedisConfig`). Lettuce is excluded in favor of Jedis. ## License diff --git a/cache-provider-redis/pom.xml b/cache-provider-redis/pom.xml index 466de136e8b..d74b9f14f07 100644 --- a/cache-provider-redis/pom.xml +++ b/cache-provider-redis/pom.xml @@ -4,6 +4,10 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + org.springframework.boot spring-boot-starter-parent @@ -16,18 +20,29 @@ 1.4.1-SNAPSHOT cache-provider-redis - MOSIP PacketCacheProvider SPI backed by Redis/Jedis (Spring Boot 4.1.1, Java 21). - No kernel-bom. Module version and third-party pins live in this pom — not in README.md. + MOSIP PacketCacheProvider SPI backed by Redis via Jedis. Lettuce is excluded from + spring-boot-starter-data-redis. RedisConfig builds a pooled JedisConnectionFactory + and RedisTemplate from redis.cache.hostname, port, password, database, ssl, and + pool settings (max total/idle, connect and read timeouts, max wait, eviction, + test-on-borrow off, JMX off). Spring Boot 4.1.1 parent, Java 21. Standalone — + no kernel-bom and no kernel-ref-parent. Module and plugin pins live in this pom — + not in README.md or AGENTS.md. Jedis is version-managed by the Boot parent. + Fat JAR (assembly jar-with-dependencies, appendAssemblyId false) is dropped onto + the packet-manager classpath; spring-boot-starter and actuator are provided by that host. https://github.com/mosip/mosip-ref-impl 21 + false + + 3.16.0 3.6.0 0.8.15 + 0.90 ${project.build.directory}/site/jacoco/jacoco.xml 5.8.0.7211 @@ -37,34 +52,14 @@ 3.2.0 4.9.10 0.11.0 + 3.8.0 - - - MPL 2.0 - https://www.mozilla.org/en-US/MPL/2.0/ - repo - - - - scm:git:git://github.com/mosip/mosip-ref-impl.git - scm:git:ssh://github.com:mosip/mosip-ref-impl.git - https://github.com/mosip/mosip-ref-impl - HEAD - - - - MOSIP - mosip.emailnotifier@gmail.com - io.mosip - https://github.com/mosip - - - org.springframework.boot @@ -72,7 +67,9 @@ provided org.springframework.boot @@ -80,8 +77,8 @@ provided org.springframework.boot @@ -94,14 +91,16 @@ redis.clients jedis org.springframework.boot @@ -123,6 +122,11 @@ + org.apache.maven.plugins maven-assembly-plugin @@ -143,6 +147,10 @@ + org.apache.maven.plugins maven-compiler-plugin @@ -152,6 +160,10 @@ true + org.apache.maven.plugins maven-surefire-plugin @@ -161,6 +173,10 @@ @{argLine} --add-opens java.xml/jdk.xml.internal=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED + org.jacoco jacoco-maven-plugin @@ -200,6 +216,7 @@ + org.apache.maven.plugins maven-source-plugin @@ -213,6 +230,7 @@ + org.apache.maven.plugins maven-javadoc-plugin @@ -230,6 +248,7 @@ false + org.apache.maven.plugins maven-gpg-plugin @@ -250,6 +269,10 @@ + pl.project13.maven git-commit-id-plugin @@ -264,7 +287,6 @@ - true ${project.build.outputDirectory}/service-git.properties @@ -275,11 +297,16 @@ ${project.basedir}/.git + org.apache.maven.plugins maven-deploy-plugin ${maven.deploy.plugin.version} + org.sonatype.central central-publishing-maven-plugin @@ -293,6 +320,7 @@ + sonar @@ -322,4 +350,25 @@ + + + MPL 2.0 + https://www.mozilla.org/en-US/MPL/2.0/ + repo + + + + scm:git:git://github.com/mosip/mosip-ref-impl.git + scm:git:ssh://github.com:mosip/mosip-ref-impl.git + https://github.com/mosip/mosip-ref-impl + HEAD + + + + MOSIP + mosip.emailnotifier@gmail.com + io.mosip + https://github.com/mosip + + diff --git a/kernel/AGENTS.md b/kernel/AGENTS.md index 69a64bf2cec..0a842dce8b2 100644 --- a/kernel/AGENTS.md +++ b/kernel/AGENTS.md @@ -1,11 +1,15 @@ # kernel -`kernel-ref-parent` (`packaging=pom`). Child → that `AGENTS.md`. Pins in `pom.xml`. +`kernel-ref-parent` (`packaging=pom`). No `kernel-bom`. Child → that folder’s `AGENTS.md`. Pins in `pom.xml`. ``` kernel/ -├── pom.xml AGENTS.md -├── kernel-ref-idobjectvalidator/ → AGENTS.md -├── kernel-smsserviceprovider-msg91/ → AGENTS.md -└── kernel-virusscanner-clamav/ → AGENTS.md +├── pom.xml README.md AGENTS.md +├── kernel-ref-idobjectvalidator/ IdObjectValidator → AGENTS.md +├── kernel-smsserviceprovider-msg91/ SMS SPI (MSG91) → AGENTS.md +└── kernel-virusscanner-clamav/ VirusScanner + ClamAV → AGENTS.md +``` + +```bash +mvn -f kernel/pom.xml -pl clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` diff --git a/kernel/README.md b/kernel/README.md index 39152f4455d..a36c148a63c 100644 --- a/kernel/README.md +++ b/kernel/README.md @@ -1,30 +1,36 @@ # kernel -Parent **`kernel-ref-parent`** (`packaging=pom`). Spring Boot **4.1.1**, Java 21, no `kernel-bom`. Logging comes from `kernel-core` (commons); do not add `kernel-logger-logback`. MOSIP versions are in `kernel/pom.xml`. +Parent `kernel-ref-parent` (`packaging=pom`) for three MOSIP kernel SPI reference implementations. + +Pins (Boot parent, MOSIP jars, plugins, JaCoCo gate) and the module description live in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.kernel:kernel-ref-parent` +- **Logging**: `kernel-core` (commons) — do not add `kernel-logger-logback` +- **Git info**: `service-git.properties` ## Modules -| Module | SPI / role | README | -|---|---|---| -| [kernel-ref-idobjectvalidator](kernel-ref-idobjectvalidator) | `IdObjectValidator` — identity JSON vs schema + masterdata | [README](kernel-ref-idobjectvalidator/README.md) | -| [kernel-smsserviceprovider-msg91](kernel-smsserviceprovider-msg91) | `SMSServiceProvider` — MSG91 HTTP | [README](kernel-smsserviceprovider-msg91/README.md) | -| [kernel-virusscanner-clamav](kernel-virusscanner-clamav) | `VirusScanner` — ClamAV | [README](kernel-virusscanner-clamav/README.md) | +| Module | SPI / role | +|---|---| +| [kernel-ref-idobjectvalidator](kernel-ref-idobjectvalidator) | `IdObjectValidator` — identity JSON vs schema + masterdata | +| [kernel-smsserviceprovider-msg91](kernel-smsserviceprovider-msg91) | `SMSServiceProvider` — MSG91 HTTP | +| [kernel-virusscanner-clamav](kernel-virusscanner-clamav) | `VirusScanner` — ClamAV | Swap implementation = swap the JAR. SPIs auto-load from `META-INF/spring.factories`. ## Build -From this directory: - ```text +cd kernel mvn clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true +``` + +```text mvn -pl kernel-ref-idobjectvalidator clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -JaCoCo LINE covered ratio **0.90** on `verify` (`target/site/jacoco/index.html` per child). `kernel-ref-idobjectvalidator` tests use `--enable-preview`. - -Git commit plugin writes `service-git.properties` (not `git.properties`). +JaCoCo LINE covered ratio is gated in `pom.xml` (`target/site/jacoco/index.html` per child). `kernel-ref-idobjectvalidator` tests use `--enable-preview`. ## License diff --git a/kernel/kernel-ref-idobjectvalidator/AGENTS.md b/kernel/kernel-ref-idobjectvalidator/AGENTS.md index b2b03cb3538..89b253fbb41 100644 --- a/kernel/kernel-ref-idobjectvalidator/AGENTS.md +++ b/kernel/kernel-ref-idobjectvalidator/AGENTS.md @@ -1,6 +1,6 @@ # kernel-ref-idobjectvalidator -`IdObjectValidator` SPI. Tests `--enable-preview`. Pins in `kernel/pom.xml`. +`IdObjectValidator` SPI. Tests: `--enable-preview`. Pins in parent `kernel/pom.xml`. ``` kernel-ref-idobjectvalidator/ @@ -8,10 +8,13 @@ kernel-ref-idobjectvalidator/ └── src/ ├── main/java/io/mosip/kernel/idobjectvalidator/ │ ├── impl/IdObjectReferenceValidator.java - │ └── constant/IdObjectReferenceValidatorConstant.java - │ IdObjectReferenceValidatorDocumentMapping.java - │ IdObjectReferenceValidatorLocationMapping.java + │ └── constant/ + │ ├── IdObjectReferenceValidatorConstant.java + │ ├── IdObjectReferenceValidatorDocumentMapping.java + │ └── IdObjectReferenceValidatorLocationMapping.java └── test/ - ├── java/.../test/IdObjectReferenceValidatorTest.java TestConfig.java + ├── java/.../idobjectvalidator/test/ + │ ├── IdObjectReferenceValidatorTest.java + │ └── TestConfig.java └── resources/ application-test.properties schema.json ``` diff --git a/kernel/kernel-ref-idobjectvalidator/README.md b/kernel/kernel-ref-idobjectvalidator/README.md index f07995854fc..fe8006638c5 100644 --- a/kernel/kernel-ref-idobjectvalidator/README.md +++ b/kernel/kernel-ref-idobjectvalidator/README.md @@ -1,11 +1,13 @@ # kernel-ref-idobjectvalidator -Reference `IdObjectValidator` that checks identity JSON against schema and masterdata (documents, locations, gender, etc.). +Reference `IdObjectValidator` that checks identity JSON against schema and masterdata (documents, locations, gender, languages). -- **Artifact**: `io.mosip.kernel:kernel-ref-idobjectvalidator:1.4.1-SNAPSHOT` -- **Parent**: `kernel-ref-parent` (Boot **4.1.1**, `kernel-core` supplies logging) +Pins live in parent [`kernel/pom.xml`](../pom.xml). Module description lives in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.kernel:kernel-ref-idobjectvalidator` +- **Impl**: `IdObjectReferenceValidator` - **Preview**: tests use `--enable-preview` -- **Config**: `mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern` and masterdata URI properties +- **Config**: `mosip.idobjectvalidator.masterdata.rest.uri`, `mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern` ## Build @@ -14,13 +16,11 @@ cd kernel mvn -pl kernel-ref-idobjectvalidator clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -Runtime consumers (booking, registration client) add this JAR plus `kernel-auth-adapter` as needed. - ```text mvn -pl kernel-ref-idobjectvalidator clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -JaCoCo LINE covered ratio **0.90**. `json-path` / `json-smart` are compile dependencies (identity JSON queries). +JaCoCo LINE covered ratio is gated in the parent `pom.xml` (`target/site/jacoco/index.html`). Drop the JAR onto booking / registration-client. ## License diff --git a/kernel/kernel-ref-idobjectvalidator/pom.xml b/kernel/kernel-ref-idobjectvalidator/pom.xml index 91a2577c6c1..b32000dbac2 100644 --- a/kernel/kernel-ref-idobjectvalidator/pom.xml +++ b/kernel/kernel-ref-idobjectvalidator/pom.xml @@ -3,6 +3,12 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + + io.mosip.kernel kernel-ref-parent @@ -13,9 +19,23 @@ 1.4.1-SNAPSHOT kernel-ref-idobjectvalidator - Reference IdObjectValidator: JSON schema + masterdata validation. - kernel-core (commons) supplies logging; do not add kernel-logger-logback. + Reference IdObjectValidator: identity JSON vs schema and masterdata + (documents, locations, gender, languages). IdObjectReferenceValidator + queries identity with json-path / json-smart, caches masterdata in + commons-collections4 multi-maps, and refreshes via + mosip.idobjectvalidator.masterdata.rest.uri, + mosip.idobjectvalidator.scheduler.reset-cache.cron-job-pattern, and + mosip.idobjectvalidator.refresh-cache-on-unknown-value. Also uses + mosip.mandatory-languages, mosip.optional-languages, and + mosip.kernel.idobjectvalidator identity path / date-format keys. + Tests require surefire --enable-preview. kernel-core (commons) supplies + logging; do not add kernel-logger-logback. Versions from parent + kernel-ref-parent; module description lives in this pom, not in + README.md or AGENTS.md. spring-boot-starter-web (RestTemplate) and + Spring Cloud config/bootstrap are declared here. Drop the JAR onto + booking / registration-client. + https://github.com/mosip/mosip-ref-impl io.mosip.kernel kernel-ref-parent @@ -13,8 +19,18 @@ 1.4.1-SNAPSHOT kernel-smsserviceprovider-msg91 - Reference SMS SPI using MSG91. kernel-core (commons) supplies logging; - do not add kernel-logger-logback. kernel-auth-adapter injects MOSIP tokens. + Reference SMSServiceProvider SPI using the MSG91 HTTP API. + SMSServiceProviderImpl validates mosip.id.validation.identity.phone then + GET-calls mosip.kernel.sms.api with authkey, sender, route, unicode, and + country code (mosip.kernel.sms.enabled, country.code, number min/max + length, api, sender, password, route, authkey, unicode). Auto-loaded via + META-INF/spring.factories (EnableAutoConfiguration to + SMSServiceProviderImpl and ApiExceptionHandler). kernel-core supplies + logging; do not add kernel-logger-logback. kernel-auth-adapter injects + MOSIP tokens on outbound calls. Versions from parent kernel-ref-parent; + module description lives in this pom, not in README.md or AGENTS.md. + Swap vendor by replacing the impl, not the SPI. bootstrap.properties is + excluded from the packaged resources. https://github.com/mosip/mosip-ref-impl @@ -24,7 +40,7 @@ io.mosip.kernel kernel-core - + io.mosip.kernel kernel-auth-adapter @@ -36,6 +52,7 @@ src/main/resources + bootstrap.properties diff --git a/kernel/kernel-virusscanner-clamav/AGENTS.md b/kernel/kernel-virusscanner-clamav/AGENTS.md index 252cd7103a1..ecec2e48cd6 100644 --- a/kernel/kernel-virusscanner-clamav/AGENTS.md +++ b/kernel/kernel-virusscanner-clamav/AGENTS.md @@ -1,6 +1,6 @@ # kernel-virusscanner-clamav -`VirusScanner`. `spring.factories`. Pins in `kernel/pom.xml`. +`VirusScanner` (`ScanResult.OK` / `VirusFound`). Auto-config: `spring.factories`. Pins in parent `kernel/pom.xml`. ``` kernel-virusscanner-clamav/ @@ -10,7 +10,12 @@ kernel-virusscanner-clamav/ │ ├── java/io/mosip/kernel/virusscanner/clamav/ │ │ ├── impl/VirusScannerImpl.java │ │ └── constant/VirusScannerErrorCodes.java - │ └── resources/META-INF/spring.factories logback.xml - └── test/java/.../test/VirusScannerServiceTest.java VirusScannerExceptionTest.java - resources/ application.properties logback.xml files/test1.docx + │ └── resources/ + │ ├── META-INF/spring.factories + │ └── logback.xml + └── test/ + ├── java/.../clamav/test/ + │ ├── VirusScannerServiceTest.java + │ └── VirusScannerExceptionTest.java + └── resources/ application.properties logback.xml files/test1.docx ``` diff --git a/kernel/kernel-virusscanner-clamav/README.md b/kernel/kernel-virusscanner-clamav/README.md index 242520ab8ed..f2dff21911d 100644 --- a/kernel/kernel-virusscanner-clamav/README.md +++ b/kernel/kernel-virusscanner-clamav/README.md @@ -1,10 +1,11 @@ -# Kernel Virus Scanner — ClamAV +# kernel-virusscanner-clamav -Reference `VirusScanner` using [ClamAV](https://www.clamav.net/) via `xyz.capybara:clamav-client` **2.1.2**. +Reference `VirusScanner` using [ClamAV](https://www.clamav.net/). -- **Artifact**: `io.mosip.kernel:kernel-virusscanner-clamav:1.4.1-SNAPSHOT` -- **Parent**: `kernel-ref-parent` (Boot **4.1.1**) -- **Logging**: `kernel-core` (commons) +Pins live in parent [`kernel/pom.xml`](../pom.xml). Module description lives in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.kernel:kernel-virusscanner-clamav` +- **Impl**: `VirusScannerImpl` via `META-INF/spring.factories` - **Config**: `mosip.kernel.virus-scanner.host`, `mosip.kernel.virus-scanner.port` To integrate another scanner, see [Integrating Virus Scanner](docs/av.md). @@ -17,7 +18,7 @@ mvn -pl kernel-virusscanner-clamav clean install -Dmaven.javadoc.skip=true -Dgpg mvn -pl kernel-virusscanner-clamav clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -JaCoCo LINE covered ratio **0.90**. Scan API: `ScanResult.OK` / `VirusFound` (clamav-client 2.1.2). +JaCoCo LINE covered ratio is gated in the parent `pom.xml`. Scan API: `ScanResult.OK` / `VirusFound`. Fat JAR from the assembly plugin (no classifier). ## License diff --git a/kernel/kernel-virusscanner-clamav/pom.xml b/kernel/kernel-virusscanner-clamav/pom.xml index 8c337e38b88..87b9a33e1f7 100644 --- a/kernel/kernel-virusscanner-clamav/pom.xml +++ b/kernel/kernel-virusscanner-clamav/pom.xml @@ -3,6 +3,12 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + + io.mosip.kernel kernel-ref-parent @@ -13,9 +19,19 @@ 1.4.1-SNAPSHOT kernel-virusscanner-clamav - Reference VirusScanner SPI using ClamAV (clamav-client 2.1.2). - kernel-core (commons) supplies logging; do not add kernel-logger-logback. + Reference VirusScanner SPI (Boolean / InputStream) using ClamAV via + xyz.capybara clamav-client. VirusScannerImpl connects lazily to + mosip.kernel.virus-scanner.host and mosip.kernel.virus-scanner.port; + scan returns true on ScanResult.OK and false on VirusFound. Unreachable + daemon or missing files throw VirusScannerException. Auto-loaded via + META-INF/spring.factories. kernel-core supplies logging; do not add + kernel-logger-logback. clamav-client version is pinned on + kernel-ref-parent. Module description lives in this pom, not in + README.md or AGENTS.md. Fat JAR (assembly jar-with-dependencies, + appendAssemblyId false) for drop-in on the consumer classpath. + Another AV: see docs/av.md. + https://github.com/mosip/mosip-ref-impl @@ -32,6 +48,7 @@ + org.apache.maven.plugins maven-assembly-plugin diff --git a/kernel/pom.xml b/kernel/pom.xml index 1e3322b6d71..4b892788a3b 100644 --- a/kernel/pom.xml +++ b/kernel/pom.xml @@ -4,6 +4,13 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + org.springframework.boot spring-boot-starter-parent @@ -17,8 +24,20 @@ pom kernel - Parent of MOSIP kernel reference implementations (id object validator, MSG91 SMS, ClamAV). - Boot 4.1.1, Java 21, no kernel-bom. MOSIP kernel jars pinned here. + Parent POM (packaging=pom) of MOSIP kernel reference implementations: + IdObjectValidator (identity JSON vs schema and masterdata; tests use + --enable-preview), MSG91 SMSServiceProvider (META-INF/spring.factories, + outbound tokens via kernel-auth-adapter), and ClamAV VirusScanner + (VirusScanner<Boolean, InputStream>, ScanResult.OK / VirusFound). + Spring Boot 4.1.1 parent, Java 21. No kernel-bom — MOSIP jars (kernel-core, + kernel-auth-adapter) and third-party pins (commons-collections4, json-path, + json-smart, clamav-client, JAXB 2.3 javax line) live in this pom, not in + README.md or AGENTS.md. Logging is in kernel-core (commons); do not depend + on kernel-logger-logback. Jackson 2 via spring-boot-jackson2 because Boot 4 + defaults to Jackson 3. Spring Cloud Oakwood is imported for config/bootstrap. + JaCoCo LINE covered-ratio gate and git-commit-id (service-git.properties) + apply to children. Swap an impl by swapping the child JAR on the consumer + classpath. https://github.com/mosip/mosip-ref-impl @@ -49,11 +68,6 @@ 0.11.0 3.8.0 - - - - 1.4.1-SNAPSHOT - 1.4.1-SNAPSHOT 2025.1.3 4.6.0 @@ -68,6 +82,12 @@ ${project.build.directory}/site/jacoco/jacoco.xml 0.90 + + + + + 1.4.1-SNAPSHOT + 1.4.1-SNAPSHOT diff --git a/pre-registration-booking-service/pom.xml b/pre-registration-booking-service/pom.xml index 5f5190dc599..b1553bc8d7c 100644 --- a/pre-registration-booking-service/pom.xml +++ b/pre-registration-booking-service/pom.xml @@ -4,6 +4,12 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + org.springframework.boot spring-boot-starter-parent @@ -16,8 +22,27 @@ 1.4.1-SNAPSHOT pre-registration-booking-service - MOSIP Pre-registration appointment booking REST service (Spring Boot 4.1.1, Java 21). - No kernel-bom. MOSIP versions are pinned here — not in README.md. + MOSIP Pre-registration appointment booking REST service. BookingApplication + scans io.mosip.* (kernel crypto and keymanager packages excluded) and serves + BookingController under /appointment/** on context /preregistration/v1: + slot availability, single and multi book, get by pre-registration id, cancel, + batch cancel, delete, and centre/date queries. Roles come from the + authorizedRoles bean. Slot contention uses BookingLock (registration centre, + date, timeslot). Spring Boot 4.1.1 parent, Java 21. No kernel-bom. MOSIP pins + (pre-registration-core, kernel-core, kernel-auth-adapter, + kernel-ref-idobjectvalidator) and third-party pins (springdoc, jjwt, + json-path, json-smart, JAXB 2.3 javax line, javassist, + logstash-logback-encoder) live in this pom — not in README.md or AGENTS.md. + kernel-auth-adapter and kernel-ref-idobjectvalidator are packaged in the + service JAR; do not wget them at container start. Logging is in kernel-core + (commons); do not depend on kernel-logger-logback. Jackson 2 via + spring-boot-jackson2 because Boot 4 defaults to Jackson 3. Spring Cloud + Oakwood is imported for config/bootstrap (pre-registration properties). + git-commit-id writes service-git.properties. JaCoCo LINE covered-ratio gate. + Tests are JUnit 4 + Mockito (junit-vintage-engine); Surefire adds + --enable-preview. JVM flags come from Helm prereg-booking javaOpts as + JDK_JAVA_OPTIONS, not from the Dockerfile. CI waits for kernel publish + before this module. https://github.com/mosip/mosip-ref-impl @@ -25,13 +50,6 @@ 21 false - - - - 1.4.0-SNAPSHOT - 1.4.1-SNAPSHOT - 1.4.1-SNAPSHOT - 1.4.1-SNAPSHOT 2025.1.3 3.1.1 @@ -60,6 +78,14 @@ **/dto/**,**/entity/**,**/config/** ${project.build.directory}/site/jacoco/jacoco.xml 0.90 + + + + + 1.4.0-SNAPSHOT + 1.4.1-SNAPSHOT + 1.4.1-SNAPSHOT + 1.4.1-SNAPSHOT diff --git a/registration-processor/AGENTS.md b/registration-processor/AGENTS.md index 3f2f5785924..431f5f83f03 100644 --- a/registration-processor/AGENTS.md +++ b/registration-processor/AGENTS.md @@ -1,10 +1,14 @@ # registration-processor -`registration-processor-ref-parent` (`packaging=pom`). Child → that `AGENTS.md`. Pins in `pom.xml`. CI artifact: `registration-processor` (both Boot JARs). +`registration-processor-ref-parent` (`packaging=pom`). No `pre-processor`. Child → that folder’s `AGENTS.md`. Pins in `pom.xml`. CI artifact: `registration-processor` (both Boot JARs). ``` registration-processor/ -├── pom.xml AGENTS.md -├── registration-processor-external-stage/ → AGENTS.md -└── registration-processor-external-integration-service/ → AGENTS.md +├── pom.xml README.md AGENTS.md +├── registration-processor-external-stage/ Vert.x → EIS → AGENTS.md +└── registration-processor-external-integration-service/ EIS stub REST → AGENTS.md +``` + +```bash +mvn -f registration-processor/pom.xml -pl clean install -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` diff --git a/registration-processor/README.md b/registration-processor/README.md index 473dec3196e..594026c557e 100644 --- a/registration-processor/README.md +++ b/registration-processor/README.md @@ -1,6 +1,13 @@ # registration-processor -Parent **`registration-processor-ref-parent`** (`packaging=pom`). Spring Boot **4.1.1**, Java 21. No MOSIP `pre-processor` parent and no `kernel-bom`. MOSIP registration-processor jars are pinned in `registration-processor/pom.xml`. Logging via `kernel-core` (commons). +Parent `registration-processor-ref-parent` (`packaging=pom`) for the MOSIP registration-processor reference implementations (Vert.x external stage and the country EIS stub). + +Pins (Boot parent, MOSIP jars, plugins, JaCoCo gate) and the module description live in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.registrationprocessor:registration-processor-ref-parent` +- **Logging**: `kernel-core` (commons) — do not add `kernel-logger-logback` +- **Git info**: `service-git.properties` +- **CI**: both Boot JARs publish as artifact `registration-processor` ## Modules @@ -23,7 +30,7 @@ mvn clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true External-stage needs unpublished MOSIP SNAPSHOTs (`registration-processor-core`, status-service-impl, rest-client) installed locally if they are not on Central snapshots. EIS can be built with `-pl` on its own. -JaCoCo LINE covered ratio **0.90** on `verify`. Git info: `service-git.properties`. +JaCoCo LINE covered ratio is gated in `pom.xml` (`target/site/jacoco/index.html` per child). ## Config diff --git a/registration-processor/pom.xml b/registration-processor/pom.xml index 4f080ad337c..d2c9cbeebf1 100644 --- a/registration-processor/pom.xml +++ b/registration-processor/pom.xml @@ -4,7 +4,13 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 - + org.springframework.boot spring-boot-starter-parent @@ -18,9 +24,24 @@ pom registration-processor - Parent of MOSIP registration-processor reference implementations (external-stage, EIS stub). - Boot 4.1.1, Java 21, no kernel-bom, no pre-processor parent. - MOSIP registration-processor-* jars pinned here. + Parent POM (packaging=pom) of MOSIP registration-processor reference implementations: + external-stage (Vert.x ExternalStage, EXTERNAL_STAGE_BUS_IN → POST ApiName.EISERVICE + → EXTERNAL_STAGE_BUS_OUT, status via registration-status-service-impl) and + external-integration-service (country EIS stub; POST + /registration-processor/external-integration-service/v1.0 returns true when + MessageRequestDTO.request is non-null; Swagger Authorize = Authorization apiKey). + Spring Boot 4.1.1 parent, Java 21. Independent of the MOSIP registration + pre-processor parent. No kernel-bom — MOSIP jars (registration-processor-core, + registration-processor-registration-status-service-impl, + registration-processor-rest-client, kernel-auth-adapter) and third-party pins + (springdoc-openapi, vertx-unit, javax.inject) live in this pom, not in README.md + or AGENTS.md. Logging is in kernel-core (commons, transitive); do not depend on + kernel-logger-logback. Jackson 2 via spring-boot-jackson2 because Boot 4 defaults + to Jackson 3. Spring Cloud Oakwood is imported for config/bootstrap. JaCoCo LINE + covered-ratio gate and git-commit-id (service-git.properties) apply to children. + kernel-auth-adapter is packaged in the service JAR (not fetched at container + start). CI publishes both Boot JARs as artifact registration-processor. Config: + mosip/mosip-config. Stage property prefix: mosip.regproc.external. https://github.com/mosip/mosip-ref-impl diff --git a/registration-processor/registration-processor-external-integration-service/AGENTS.md b/registration-processor/registration-processor-external-integration-service/AGENTS.md index 496b9821d40..0411347510a 100644 --- a/registration-processor/registration-processor-external-integration-service/AGENTS.md +++ b/registration-processor/registration-processor-external-integration-service/AGENTS.md @@ -1,18 +1,21 @@ # registration-processor-external-integration-service -EIS stub REST. Authorize = `Authorization` (`SwaggerConfig`). Pins in parent `pom.xml`. +EIS stub. `POST .../v1.0` → `true` if body non-null. Swagger Authorize = `Authorization` apiKey (`SwaggerConfig`). Pins in parent `registration-processor/pom.xml`. ``` registration-processor-external-integration-service/ ├── pom.xml Dockerfile README.md AGENTS.md └── src/ - ├── main/java/io/mosip/registrationprocessor/eis/ - │ ├── ExternalIntegrationServiceApplication.java - │ ├── controller/ExternalController.java - │ ├── config/SwaggerConfig.java OpenApiProperties.java - │ └── entity/BaseRestRequestDTO.java MessageRequestDTO.java - ├── main/resources/bootstrap.properties - └── test/java/.../ExternalIntegrationControllerTest.java - test/java/.../config/SwaggerConfigTest.java - test/resources/application.properties + ├── main/ + │ ├── java/io/mosip/registrationprocessor/eis/ + │ │ ├── ExternalIntegrationServiceApplication.java + │ │ ├── controller/ExternalController.java + │ │ ├── config/SwaggerConfig.java OpenApiProperties.java + │ │ └── entity/BaseRestRequestDTO.java MessageRequestDTO.java + │ └── resources/bootstrap.properties + └── test/ + ├── java/.../eis/ + │ ├── ExternalIntegrationControllerTest.java + │ └── config/SwaggerConfigTest.java + └── resources/application.properties ``` diff --git a/registration-processor/registration-processor-external-integration-service/README.md b/registration-processor/registration-processor-external-integration-service/README.md index 139a2d17435..e97395f2a5d 100644 --- a/registration-processor/registration-processor-external-integration-service/README.md +++ b/registration-processor/registration-processor-external-integration-service/README.md @@ -2,9 +2,10 @@ Country stub REST service that receives POSTs from `registration-processor-external-stage`. Replace the controller body with country-specific integration logic. -- **Artifact**: `io.mosip.registrationprocessor:registration-processor-external-integration-service:1.4.1-SNAPSHOT` -- **Parent**: `registration-processor-ref-parent` (Boot **4.1.1**) -- **Logging**: `kernel-core` (commons) +Pins live in parent [`registration-processor/pom.xml`](../pom.xml). Module description lives in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.registrationprocessor:registration-processor-external-integration-service` +- **Logging**: `kernel-core` (commons) — do not add `kernel-logger-logback` - **Git info**: `service-git.properties` ## Overview @@ -70,7 +71,7 @@ Click **Authorize**, paste the authmanager token, then Try-it-out. mvn -pl registration-processor-external-integration-service clean verify -Dmaven.javadoc.skip=true -Dgpg.skip=true ``` -JaCoCo LINE covered ratio **0.90**. Boot 4 tests use `org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest`. +JaCoCo LINE covered ratio is gated in the parent `pom.xml`. Boot 4 tests use `org.springframework.boot.webmvc.test.autoconfigure.WebMvcTest`. ## Deployment (Kubernetes) diff --git a/registration-processor/registration-processor-external-integration-service/pom.xml b/registration-processor/registration-processor-external-integration-service/pom.xml index 176dbf29423..d7cb146b89a 100644 --- a/registration-processor/registration-processor-external-integration-service/pom.xml +++ b/registration-processor/registration-processor-external-integration-service/pom.xml @@ -3,6 +3,12 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + + io.mosip.registrationprocessor registration-processor-ref-parent @@ -14,14 +20,23 @@ 1.4.1-SNAPSHOT registration-processor-external-integration-service - MOSIP External Integration Service stub. Spring Boot 4.1.1 via parent - registration-processor-ref-parent. No pre-processor parent. Logging via kernel-core (commons). + Country External Integration Service stub (Boot web). ExternalController + POST /registration-processor/external-integration-service/v1.0 returns HTTP 200 + true when MessageRequestDTO.request is non-null, otherwise false. Replace the + controller body with country-specific logic. bootstrap.properties sets + server.servlet.path=/registrationprocessor/v1/eis. Swagger UI Authorize is an + Authorization header apiKey (SwaggerConfig, OpenApiProperties, springdoc; + openapi.* keys). spring-boot-starter-webmvc-test supplies Boot 4 @WebMvcTest. + Actuator exposes info, health, refresh; git metadata from service-git.properties. + Logging via kernel-core (transitive); do not add kernel-logger-logback. Versions + from parent registration-processor-ref-parent; module description lives in this + pom, not in README.md or AGENTS.md. https://github.com/mosip/mosip-ref-impl org.springframework.boot diff --git a/registration-processor/registration-processor-external-stage/AGENTS.md b/registration-processor/registration-processor-external-stage/AGENTS.md index 44f6c073fcc..e88d1cf6af4 100644 --- a/registration-processor/registration-processor-external-stage/AGENTS.md +++ b/registration-processor/registration-processor-external-stage/AGENTS.md @@ -1,18 +1,20 @@ # registration-processor-external-stage -Vert.x `ExternalStage` → EIS POST. Adapter in JAR. Pins in parent `pom.xml`. +Vert.x `ExternalStage`. `EXTERNAL_STAGE_BUS_IN` → POST EIS → `EXTERNAL_STAGE_BUS_OUT`. Adapter in JAR. Pins in parent `registration-processor/pom.xml`. ``` registration-processor-external-stage/ ├── pom.xml Dockerfile README.md AGENTS.md └── src/ - ├── main/java/io/mosip/registrationprocessor/externalstage/ - │ ├── ExternalStageApplication.java - │ ├── stage/ExternalStage.java - │ ├── config/Externalconfig.java - │ ├── entity/BaseRestRequestDTO.java MessageRequestDTO.java - │ └── utils/StatusMessage.java - ├── main/resources/ bootstrap.properties logback.xml - └── test/java/.../ExternalStageApplicationTests.java - test/java/.../stage/ExternalStageTest.java + ├── main/ + │ ├── java/io/mosip/registrationprocessor/externalstage/ + │ │ ├── ExternalStageApplication.java + │ │ ├── stage/ExternalStage.java + │ │ ├── config/Externalconfig.java + │ │ ├── entity/BaseRestRequestDTO.java MessageRequestDTO.java + │ │ └── utils/StatusMessage.java + │ └── resources/ bootstrap.properties logback.xml + └── test/java/.../externalstage/ + ├── ExternalStageApplicationTests.java + └── stage/ExternalStageTest.java ``` diff --git a/registration-processor/registration-processor-external-stage/README.md b/registration-processor/registration-processor-external-stage/README.md index cb41cf49e4e..2cd2549a32b 100644 --- a/registration-processor/registration-processor-external-stage/README.md +++ b/registration-processor/registration-processor-external-stage/README.md @@ -2,9 +2,10 @@ Vert.x stage that reads `EXTERNAL_STAGE_BUS_IN`, POSTs to the External Integration Service, then emits `EXTERNAL_STAGE_BUS_OUT`. -- **Artifact**: `io.mosip.registrationprocessor:registration-processor-external-stage:1.4.1-SNAPSHOT` -- **Parent**: `registration-processor-ref-parent` (Boot **4.1.1**) -- **Logging**: `kernel-core` (commons) +Pins live in parent [`registration-processor/pom.xml`](../pom.xml). Module description lives in [`pom.xml`](pom.xml) — not here. + +- **Artifact**: `io.mosip.registrationprocessor:registration-processor-external-stage` +- **Logging**: `kernel-core` (commons) — do not add `kernel-logger-logback` - **Git info**: `service-git.properties` ## Overview @@ -75,7 +76,7 @@ docker build -t registration-processor-external-stage . ``` -JaCoCo LINE covered ratio **0.90**. Needs MOSIP `registration-processor-core` / status-service-impl / rest-client SNAPSHOTs on the classpath. +JaCoCo LINE covered ratio is gated in the parent `pom.xml`. Needs MOSIP `registration-processor-core` / status-service-impl / rest-client SNAPSHOTs on the classpath. `kernel-auth-adapter` is packaged in the Boot JAR. ## Configuration diff --git a/registration-processor/registration-processor-external-stage/pom.xml b/registration-processor/registration-processor-external-stage/pom.xml index 15391a1c7ce..0126eb25115 100644 --- a/registration-processor/registration-processor-external-stage/pom.xml +++ b/registration-processor/registration-processor-external-stage/pom.xml @@ -3,6 +3,12 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 + + io.mosip.registrationprocessor registration-processor-ref-parent @@ -14,15 +20,25 @@ 1.4.1-SNAPSHOT registration-processor-external-stage - MOSIP registration-processor Vert.x stage that POSTs to the External Integration Service. - Spring Boot 4.1.1 via parent registration-processor-ref-parent. No pre-processor parent. - Logging via kernel-core (commons); do not add kernel-logger-logback. + Vert.x registration-processor stage. ExternalStage extends MosipVerticleAPIManager: + consumes EXTERNAL_STAGE_BUS_IN, POSTs registration ids to EIS (ApiName.EISERVICE) + via registration-processor-rest-client, updates status through + registration-processor-registration-status-service-impl, then emits + EXTERNAL_STAGE_BUS_OUT. Property prefix mosip.regproc.external. (message + expiry-time-limit, eventbus kafka commit/poll/group, eventbus port, server port, + servlet path). bootstrap.properties sets eventbus.port, server.port, and + server.servlet.path=/registrationprocessor/v1/external. kernel-auth-adapter is + packaged in the Boot JAR (no container wget). Logging via kernel-core; do not + add kernel-logger-logback. Versions from parent registration-processor-ref-parent; + module description lives in this pom, not in README.md or AGENTS.md. Git info: + service-git.properties. Needs registration-processor-core, status-service-impl, + and rest-client SNAPSHOTs on the classpath. https://github.com/mosip/mosip-ref-impl org.springframework.boot From b47b5194625487a76cfa3e6866113c4fd9dc344f Mon Sep 17 00:00:00 2001 From: JanardhanBS-SyncByte Date: Wed, 30 Sep 2026 13:04:36 +0530 Subject: [PATCH 6/6] [issue-1633] pom error Signed-off-by: JanardhanBS-SyncByte --- kernel/kernel-ref-idobjectvalidator/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/kernel-ref-idobjectvalidator/pom.xml b/kernel/kernel-ref-idobjectvalidator/pom.xml index b32000dbac2..c91fb93e6e8 100644 --- a/kernel/kernel-ref-idobjectvalidator/pom.xml +++ b/kernel/kernel-ref-idobjectvalidator/pom.xml @@ -6,7 +6,7 @@