Skip to content

Improve startup performance on large repos#108

Open
krauterbaquette wants to merge 2 commits intomock-server:masterfrom
krauterbaquette:startup-performance
Open

Improve startup performance on large repos#108
krauterbaquette wants to merge 2 commits intomock-server:masterfrom
krauterbaquette:startup-performance

Conversation

@krauterbaquette
Copy link

As described in Issue #43 the glob patterns used in downloadJar.js are inefficient in large repositories because they scan the whole node_modules folder as well as the rest of the project.

We know that the .jar files can only be inside the node_modules/mockserver-node directory, so we can only check this directory. Therefore the startup time is always the same, and does not increase with the size of the project.

the glob pattern would search in all project files, including the whole node_modules folders
which can take a long time if the project is really big.

However the mockserver jar files can only be placed inside the node_modules/mockserver-node folder,
so we only have to check this location which is a lot faster, also for huge projects
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.

1 participant