Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2,322 changes: 1,133 additions & 1,189 deletions e2e/package-lock.json

Large diffs are not rendered by default.

14 changes: 13 additions & 1 deletion e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,25 @@
"cross-env": "^10.1.0",
"execa": "^9.6.1",
"mocha-multi": "^1.1.7",
"mochawesome": "^7.1.4",
"mochawesome": "^8.1.1",
"puppeteer": "^24.33.1",
"terminate": "^2.8.0",
"ts-node": "^10.9.2",
"typescript": "^5.9.3",
"wait-on": "^9.0.3"
},
"overrides": {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This PR adds overrides blocks here and in ilc, registry and registry/client, but nothing records which advisory each pin addresses, and the PR description is empty. Overrides keep forcing a version regardless of what upstream later declares, so without a reference nobody can tell when one is safe to drop. Two examples from this block:

  • editorconfig → minimatch ^9.0.7: editorconfig 1.0.7's own range (^9.0.1) already admits the patched 9.0.9, so a lockfile refresh gives the same result without a permanent pin.
  • mocha → diff ^8.0.3: right for the mocha 11.7.5 locked here (diff 7 is the affected one), but once mocha moves to 12 (which wants diff ^9) this override will force diff 8 back onto it.

Could you add a one-line comment or PR note per override naming the GHSA/CVE it fixes?

@stas-nc stas-nc Oct 15, 2026 •

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Added in PR desc, package.json could not commented in a good way.

"codeceptjs": {
"axios": "^1.20.0",
"joi": "^18.2.9",
"@xmldom/xmldom": "^0.9.12",
"uuid": "^11.1.1"
},
"mocha@11": {
"serialize-javascript": "^7.0.5",
"diff": "^8.0.3"
}
},
"engines": {
"node": ">=22"
},
Expand Down
2,502 changes: 1,097 additions & 1,405 deletions ilc/package-lock.json

Large diffs are not rendered by default.

13 changes: 8 additions & 5 deletions ilc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@
"license": "Apache-2.0",
"dependencies": {
"@fastify/request-context": "^6.2.1",
"@fastify/static": "^8.1.1",
"@fastify/static": "^10.1.5",
"@namecheap/error-extender": "^2.2.1",
"@namecheap/tailorx": "^8.2.1",
"@newrelic/native-metrics": "^12.0.0",
"@newrelic/native-metrics": "^13.1.0",
"agentkeepalive": "^4.6.0",
"axios": "^1.13.2",
"config": "^4.1.1",
Expand All @@ -40,7 +40,7 @@
"js-cookie": "^3.0.5",
"lodash": "^4.17.21",
"lzutf8": "^0.6.3",
"newrelic": "^13.8.0",
"newrelic": "^14.4.0",
Comment thread
stas-nc marked this conversation as resolved.
"node-html-parser": "^7.0.1",
"parseurl": "^1.3.3",
"safe-json-stringify": "^1.2.0",
Expand Down Expand Up @@ -80,11 +80,11 @@
"karma-mocha-reporter": "^2.2.5",
"karma-sourcemap-loader": "^0.4.0",
"karma-webpack": "^5.0.1",
"mocha": "^11.7.5",
"mocha": "^12.0.2",
"nanohtml": "^1.10.0",
"nock": "^14.0.10",
"nodemon": "^3.1.11",
"nyc": "^17.1.0",
"nyc": "^18.0.0",
"pino-pretty": "^13.1.3",
"rimraf": "^6.1.2",
"sinon": "^21.0.0",
Expand All @@ -96,6 +96,9 @@
"webpack-cli": "^6.0.1",
"webpack-dev-middleware": "^7.4.5"
},
"overrides": {
"hyperid": "^4.0.0"
},
"engines": {
"node": ">= 22"
}
Expand Down
78 changes: 78 additions & 0 deletions ilc/server/registry/factory.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
import axios from 'axios';
import { expect } from 'chai';
import config from 'config';
import nock from 'nock';
import sinon from 'sinon';
import reportPlugin from '../plugins/reportingPlugin';
import Registry from './Registry';
import { registryFactory } from './factory';

const registryConfig = {
apps: {},
routes: [],
specialRoutes: [],
settings: {},
sharedLibs: {},
dynamicLibs: {},
};

describe('registryFactory', () => {
const registryAddress: string = config.get('registry.address');

let logger: { debug: sinon.SinonStub; info: sinon.SinonStub; warn: sinon.SinonStub; error: sinon.SinonStub };

beforeEach(() => {
logger = { debug: sinon.stub(), info: sinon.stub(), warn: sinon.stub(), error: sinon.stub() };
sinon.stub(reportPlugin, 'getLogger').returns(logger);
});

afterEach(() => {
sinon.restore();
nock.cleanAll();
});

it('creates a Registry that fetches config from the configured registry address', async () => {
const scope = nock(registryAddress).get('/api/v1/config').reply(200, registryConfig);

const registry = registryFactory();

expect(registry).to.be.instanceOf(Registry);
expect(await registry.getConfig()).to.deep.equal(registryConfig);
expect(scope.isDone()).to.be.true;
});

it('logs a warning when the registry cache evicts an entry after exceeding 1000 keys', async () => {
const requestsCount = 1001;
sinon.stub(axios, 'get').resolves({ data: registryConfig });

const registry = registryFactory();

// Every domain filter produces a distinct cache key, so the 1001st entry evicts the oldest one
await Promise.all(
Array.from({ length: requestsCount }, (_, index) =>
registry.getConfig({ filter: { domain: `domain-${index}.example.com` } }),
),
);

sinon.assert.calledOnceWithExactly(
logger.warn,
{ key: sinon.match.string },
sinon.match('ILC registry cache eviction: maxSize (1000) exceeded.'),
);
});

it('does not log an eviction warning while the cache stays within 1000 keys', async () => {
const requestsCount = 1000;
sinon.stub(axios, 'get').resolves({ data: registryConfig });

const registry = registryFactory();

await Promise.all(
Array.from({ length: requestsCount }, (_, index) =>
registry.getConfig({ filter: { domain: `domain-${index}.example.com` } }),
),
);

sinon.assert.notCalled(logger.warn);
});
});
28 changes: 19 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading