PEG-2766 Migrate progression from cp-file-service to Azure Blob Storage#322
Open
allanmckenzie wants to merge 2 commits into
Open
PEG-2766 Migrate progression from cp-file-service to Azure Blob Storage#322allanmckenzie wants to merge 2 commits into
allanmckenzie wants to merge 2 commits into
Conversation
…Azure Blob Storage SDK v12 Replaces FileStorer/FileRetriever (PostgreSQL-backed cp-file-service) with a BYO Azure Blob Storage container. Each uploaded file uses its UUID as the blob name, with fileName/templateName stored as blob metadata. Key changes: - New AzureBlobConfiguration and AzureBlobContainerClientProducer CDI beans (JDK HTTP transport; @dependent producer to avoid WELD-001410 on final class) - FileService, FileUtil, DocumentGeneratorService, CourtRegisterEventProcessor, OnlinePleaEventProcessor, NotificationNotifyEventProcessor and SystemDocGeneratorEventProcessor all migrated to BlobContainerClient - All unit tests updated to mock BlobContainerClient/BlobClient instead of FileStorer - Root pom.xml: parent bumped to service-parent-pom 17.104.3; azure-core-http-jdk-httpclient version property + dependencyManagement entry added
…DI ambiguity - Add ProgressionServiceFileInterceptor: replaces InputStreamFileInterceptor, uploads multipart file bytes directly to Azure Blob Storage via BlobContainerClient, injects UUID as fileServiceId in the command envelope - Add ProgressionCommandApiInterceptorChainProvider registering the interceptor at priority 6000 - Remove duplicate AzureBlobContainerClientProducer and AzureBlobConfiguration from progression-command-api (were causing WELD-001409 ambiguous dependency on the single-WAR deployment); event-processor's producer now serves the entire WAR - Fix AzureBlobContainerClientProducer catch block: HttpResponseException + 409 check matches the platform pattern (other migrated contexts); rethrows non-409 errors - Add FILE_STORE_HEALTHCHECK_NAME to ProgressionIgnoredHealthcheckNamesProvider - Update runIntegrationTests.sh to start azurite Docker profile alongside es profile - Add progression-domain-message as POJO generator plugin dep in command-handler pom to resolve listing schema $ref at code generation time - Add unit tests: ProgressionServiceFileInterceptorTest, ProgressionCommandApiInterceptorChainProviderTest, AzureBlobConfigurationTest, AzureBlobContainerClientProducerTest (updated for HttpResponseException pattern)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
cp-file-service(shared PostgreSQL BLOB store) with direct Azure Blob Storage SDK v12 acrossprogression-event-processorandprogression-command-apiprogression-filescontainerfileServiceIdfield name is preserved in all schemas for backward compatibility with unmigrated producersChanges
progression-event-processor (previous commit)
FileService,FileUtil,DocumentGeneratorService,NotificationServicemigrated fromFileStorer/FileRetrievertoBlobContainerClientCourtRegisterEventProcessor,NotificationNotifyEventProcessor,OnlinePleaEventProcessor,SystemDocGeneratorEventProcessorupdatedAzureBlobConfiguration+AzureBlobContainerClientProducerCDI beans added (JDK HTTP transport; avoids WildFly Netty conflict)progression-command-api (this commit)
ProgressionServiceFileInterceptorreplacesInputStreamFileInterceptor— streams multipart upload bytes directly to Azure, injects UUID asfileServiceIdprogression-command-api; single-WAR deployment now has one@Produces BlobContainerClient(WELD-001409)AzureBlobContainerClientProducercatch block aligned with platform pattern (HttpResponseException 409 = container exists, rethrow others)FILE_STORE_HEALTHCHECK_NAMEadded to ignored healthchecks providerInfrastructure
runIntegrationTests.shupdated to start Azurite Docker profile (--profile azurite) — required for blob storage operations during IT runsTest plan
mvn clean test)progression-filescreated on startup viacreateIfNotExists()Outstanding (not blocking merge)
azure.filestore.endpoint+ container name not yet in AKS manifestsprogression-filescontainer not yet provisioned (BYOFS-1.1)file-alfrescoandfile-apideps inprogression-command-api/pom.xml— confirm whether still needed before removing