Skip to content

feat: expose service module through package exports (#1539)#1542

Merged
kriswest merged 3 commits into
finos:mainfrom
rajeevr-g:feature/expose-service-module
Jun 2, 2026
Merged

feat: expose service module through package exports (#1539)#1542
kriswest merged 3 commits into
finos:mainfrom
rajeevr-g:feature/expose-service-module

Conversation

@rajeevr-g
Copy link
Copy Markdown
Contributor

Description

Exposes the service module through package exports and updates configuration exports to support service module accessibility.

General changes:

  • Added package exports entry for the service module
  • Updated src/config/index.ts to expose the required configuration exports
  • Ensured service module accessibility through package-level exports
  • Verified project build and TypeScript publish build complete successfully
  • Validated linting, formatting, and type checks pass successfully

Related Issue

Resolves #1539

Checklist

General

Documentation

  • Documentation has been added/updated for any new features

Configuration

  • If configuration schema (config.schema.json) was modified:

    • TypeScript types regenerated (npm run generate-config-types)
    • Schema reference docs regenerated (npm run gen-schema-doc)

Tests

  • Unit tests pass (npm test)
  • Linting and formatting pass (npm run lint and npm run format:check)
  • Type checks pass (npm run check-types)

@rajeevr-g rajeevr-g requested a review from a team as a code owner May 20, 2026 18:52
@netlify
Copy link
Copy Markdown

netlify Bot commented May 20, 2026

Deploy Preview for endearing-brigadeiros-63f9d0 canceled.

Name Link
🔨 Latest commit 02300d3
🔍 Latest deploy log https://app.netlify.com/projects/endearing-brigadeiros-63f9d0/deploys/6a1de53cdc0ecd00099b0309

@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla Bot commented May 20, 2026

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: rajeevr-g / name: rajeevr-g (002903d)

@rajeevr-g rajeevr-g force-pushed the feature/expose-service-module branch from f81915a to 002903d Compare May 20, 2026 19:13
@rajeevr-g rajeevr-g changed the title #1539: Expose service module through package exports feat: expose service module through package exports (#1539) May 20, 2026
@re-vlad re-vlad self-requested a review May 21, 2026 14:57
@codecov
Copy link
Copy Markdown

codecov Bot commented May 22, 2026

Codecov Report

❌ Patch coverage is 50.00000% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 90.62%. Comparing base (ffd6937) to head (02300d3).

Files with missing lines Patch % Lines
src/config/index.ts 50.00% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1542      +/-   ##
==========================================
- Coverage   90.65%   90.62%   -0.03%     
==========================================
  Files          69       69              
  Lines        5690     5694       +4     
  Branches      985      985              
==========================================
+ Hits         5158     5160       +2     
- Misses        514      516       +2     
  Partials       18       18              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@re-vlad
Copy link
Copy Markdown

re-vlad commented May 26, 2026

Hi @andypols @kriswest @jescalada, @Andreybest, dear @git-proxy-maintainers,

Could you please prioritize a review of this PR #1542 “feat: expose service module through package exports (#1539)”?

This change is critical for us because we need the service module to be available through package exports in order to validate our migration path to the 2.0.0 release.

If anything needs adjustment from our side, we can respond quickly.

Thank you for your help and for maintaining the project,
Vlad (re-vlad)

Signed-off-by: Juan Escalada <97265671+jescalada@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@jescalada jescalada left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for the contribution @rajeevr-g! It'll need an extra review, however, as I fixed merge conflicts in the latest commit 👍🏼

@jescalada jescalada requested a review from a team May 27, 2026 11:15
@rajeevr-g
Copy link
Copy Markdown
Contributor Author

Hi @andypols @kriswest, dear @git-proxy-maintainers,

Could you please help prioritize the review of PR #1542:
#1542

This change is important for us because we need the service module to be exposed through package exports to validate our migration path for the 2.0.0 release and ensure our integration works successfully.

If any adjustments or updates are needed from our side, we’ll be happy to address them promptly.

Thank you for your time and for maintaining the project.

Best regards,
Rajeev

Copy link
Copy Markdown
Contributor

@kriswest kriswest left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have a problem with this being exposed, however, it could be handled in a way that's more consistent with the exposure of other parts of the config, via a get* function. I don't like the fact that this part of the config sets defaults differently and that we can't set many of these settings from a config file (with the exception of GIT_PROXY_COOKIE_SECRET which can be set in config and overridden by an ENV var).

Personally, I think this should be refactored and made consistent with the rest of the config handling and worry that directly exporting it will lock in the current, inconsistent design.

@jescalada could you take another look? Is there an advantage to us only setting some of these thrings through env vars or using the defaults? Why not have config variables and defaults (set via the same approach as all others) for some of these critical settings?

Copy link
Copy Markdown
Contributor

@kriswest kriswest left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To avoid locking in the technical debt relating to env.ts / serverConfig, it should not be exported but a get function added to allow access to those settings. Even better would be a quick refactor to allow those settings to come from config in addition to env vars and to move their defaults into proxy.config.json.

GIT_PROXY_COOKIE_SECRET is the one variable that is currently settable from both config file and environment variable and can be used as an example:

see:

cookieSecret:
serverConfig.GIT_PROXY_COOKIE_SECRET ||
userSettings.cookieSecret ||
defaultConfig.cookieSecret,

and:

export const getCookieSecret = (): string => {
const config = loadFullConfiguration();
if (!config.cookieSecret) {
throw new Error('cookieSecret is not set!');
}
return config.cookieSecret;
};

I'm fine with the rest of this PR!

Comment thread src/config/index.ts Outdated
@kriswest
Copy link
Copy Markdown
Contributor

kriswest commented Jun 2, 2026

I've created issue #1553 to describe whats needed to fix the server config env variables properly.

Copy link
Copy Markdown
Contributor

@kriswest kriswest left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, as far as it goes.

@kriswest kriswest added this to the 2.1.0 milestone Jun 2, 2026
@kriswest kriswest merged commit 2beab81 into finos:main Jun 2, 2026
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Expose 'service' module as a public export for dashboard also slightly changed config/index.js configurations

5 participants