-
-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Experiment with generating all API data statically #311
base: master
Are you sure you want to change the base?
Conversation
Thanks for your pull request, @wilzbach! |
source/app.d
Outdated
@@ -33,7 +33,7 @@ void startMonitoring() | |||
sleep(1.seconds()); // give the cache a chance to warm up first | |||
while(true){ | |||
if (s_mirror.length) s_registry.mirrorRegistry(s_mirror); | |||
else s_registry.updatePackages(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
uhh you do realize this code is the same as the production code and you removed package updates with this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes of course I do. That's why it's called experiment / WIP. It crashes sometimes when trying to update the registry while wget/curl is fetching. I just wanted to see how far I can get with a simple curl loop.
Anyhow, I can/will remove this once --no-monitoring
is a thing (-> #310)
So I guess this would have to use a different approach, like
|
how about limiting packages to a select few? I doubt we will need all packages. And whenever packages are needed for a test they can get added (such as when people might want packages with different readme names, with different languages, with different metadata, different logos, different repo types, etc) |
This is not about previewing PRs, this is about having a static registry mirror on a CDN. See: #309 |
oh ok nvm then, though for netlify PRs I think that would be a good idea |
FYI: They are already limited because at the moment there's no way to reach a package if not via the main list view and dependencies of such a a package. So if you go to https://dub.pm at the moment (that's the static snapshot = to what you see on the previews), only ~ 20 packages are reachable. Maybe a bit more with their dependencies. |
Not sure that's the best move, #309 (comment). |
See #309
A start, probably
curl
is too slow and this should would need to be done directly in the registry.TODO: