fix: downloads path broken link in export(MAPCO-10645)#96
Merged
Conversation
CL-SHLOMIKONCHA
approved these changes
May 20, 2026
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.
This pull request refactors how file paths and URLs for export artifacts (GPKG and JSON files) are constructed and managed throughout the application. It introduces a new
ArtifactPathBuilderutility class to centralize and standardize path building logic, removes hardcoded directory settings, updates configuration and Helm charts, and adapts the codebase and tests to use the new approach.Key changes include:
Path and URL Management Refactor:
Introduced the
ArtifactPathBuilderclass to encapsulate logic for building local file paths, S3 keys, and public download URLs for export artifacts, replacing direct path manipulation and hardcoded directory references. (src/utils/storage/artifactPathBuilder.ts)Updated
ExportJobHandlerto useArtifactPathBuilderfor all artifact path and URL construction, removing the use of thegpkgsRootDirconfig and direct path manipulation. (src/job/models/export/exportJobHandler.ts)Configuration and Helm Updates:
Changed configuration files (
config/default.json,config/custom-environment-variables.json,helm/values.yaml) to remove the obsoletegpkgsRootDirsetting and introduce a structuredstorage.internalPvcconfig for mount paths and subpaths.Testing Improvements:
ArtifactPathBuilderto verify correct path and URL construction. (tests/unit/utils/artifactPathBuilder.spec.ts)tests/unit/job/exportJobHandler/exportJobHandler.spec.ts,tests/unit/job/exportJobHandler/exportJobHandlerSetup.ts,tests/unit/mocks/configMock.ts)