Skip to content
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

Update broken & outdated links #13001

Merged
merged 27 commits into from
Feb 6, 2023
Merged

Update broken & outdated links #13001

merged 27 commits into from
Feb 6, 2023

Conversation

hasezoey
Copy link
Collaborator

@hasezoey hasezoey commented Feb 5, 2023

Summary

This PR does:

  • update broken & outdated (308) links
  • add broken-link-checker as a script command to easily run it
  • update api.js (and splitApiDocs.js) to generate all names in one place
  • update api.js to better handle @inherits links for classes that are not external

Notes:

Links Not updated and are broken:

  • any links using "query-js" & "model-js" & "schema-string-js" & "schema-date-js"
  • any links using mongoosearray (not documentarray)
  • any links using utils

there were also broken links because of removed (previously deprecated) options:

  • query option snapshot (in query.js)
  • query option maxScan (in query.js)
  • autoIndexId (in guide.md)
  • connection-limits-and-cluster-tier (in connections.md)

Filters i used and ignored from the output (regex / file path)

re #12691

Full BLC log of still broken URLs
Getting links from: http://127.0.0.1:8089/docs/guide.html
├─BROKEN─ http://127.0.0.1:8089/docs/api/schema-string-js.html#schema-string-js (HTTP_404)
├─BROKEN─ http://www.mongodb.org/display/DOCS/Capped+Collections#CappedCollections-autoIndexId (HTTP_308)
├─BROKEN─ http://127.0.0.1:8089/docs/api/utils.html#utils_exports-toCollectionName (HTTP_404)
├─BROKEN─ http://127.0.0.1:8089/docs/api/schema-date-js.html#schema-date-js (HTTP_404)
Finished! 274 links found. 198 excluded. 6 broken.

Getting links from: http://127.0.0.1:8089/docs/schematypes.html
├─BROKEN─ http://127.0.0.1:8089/docs/api/query-js.html#query-js (HTTP_404)
Finished! 171 links found. 144 excluded. 3 broken.

Getting links from: http://127.0.0.1:8089/docs/connections.html
├─BROKEN─ https://www.mongodb.com/docs/atlas/atlas-limits/#connection-limits-and-cluster-tier (HTTP_404)
├─BROKEN─ http://tldp.org/HOWTO/TCP-Keepalive-HOWTO/overview.html (HTTP_308)
Finished! 148 links found. 120 excluded. 4 broken.

Getting links from: http://127.0.0.1:8089/docs/models.html
├─BROKEN─ http://127.0.0.1:8089/docs/api/model-js.html#model-js (HTTP_404)
├─BROKEN─ http://127.0.0.1:8089/docs/api/query-js.html#query-js (HTTP_404)
Finished! 125 links found. 113 excluded. 4 broken.

Getting links from: http://127.0.0.1:8089/docs/subdocs.html
├─BROKEN─ http://127.0.0.1:8089/docs/api/mongoosearray.html#mongoosearray_MongooseArray-push (HTTP_404)
├─BROKEN─ http://127.0.0.1:8089/docs/api/mongoosearray.html#mongoosearray_MongooseArray-unshift (HTTP_404)
├─BROKEN─ http://127.0.0.1:8089/docs/api/mongoosearray.html#mongoosearray_MongooseArray-addToSet (HTTP_404)
Finished! 110 links found. 101 excluded. 5 broken.

Getting links from: http://127.0.0.1:8089/docs/queries.html
├─BROKEN─ http://127.0.0.1:8089/docs/api/query-js.html#query-js (HTTP_404)
├─BROKEN─ http://127.0.0.1:8089/docs/api/query-js.html#query-js (HTTP_404)
Finished! 141 links found. 127 excluded. 4 broken.

Getting links from: http://127.0.0.1:8089/docs/api/query.html
├─BROKEN─ https://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%7B%7Bsnapshot%28%29%7D%7D (HTTP_308)
├─BROKEN─ https://docs.mongodb.org/v3.2/reference/operator/meta/maxScan/#metaOp._S_maxScan (HTTP_308)
├─BROKEN─ https://www.mongodb.com/docs/manual/reference/operator/snapshot/ (HTTP_404)
Finished! 797 links found. 753 excluded. 5 broken.

Getting links from: http://127.0.0.1:8089/docs/tutorials/ssl.html
├─BROKEN─ https://mongodb.github.io/node-mongodb-native/2.1/tutorials/connect/ssl/ (HTTP_404)
Finished! 95 links found. 85 excluded. 3 broken.

Getting links from: http://127.0.0.1:8089/docs/migrating_to_5.html
├─BROKEN─ https://github.com/mongodb/node-mongodb-native/blob/master/CHANGES_3.0.0.md#geonear-command-helper (HTTP_404)
Finished! 165 links found. 149 excluded. 4 broken.

@hasezoey hasezoey added the docs This issue is due to a mistake or omission in the mongoosejs.com documentation label Feb 5, 2023
@hasezoey hasezoey added this to the 6.9.1 milestone Feb 5, 2023
@hasezoey
Copy link
Collaborator Author

hasezoey commented Feb 5, 2023

did a force-push because there was a stray fixup commit still left in (had most of the work on the basis of a "quick & dirty" test branch)

@vkarpov15 vkarpov15 modified the milestones: 6.9.1, 6.9.2 Feb 6, 2023
Copy link
Collaborator

@vkarpov15 vkarpov15 left a comment

Choose a reason for hiding this comment

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

This is great, thanks! Maybe put in a separate PR to add a GitHub action to run checks automatically?

@vkarpov15 vkarpov15 merged commit 4e18a07 into Automattic:master Feb 6, 2023
@hasezoey
Copy link
Collaborator Author

hasezoey commented Feb 7, 2023

@vkarpov15

Maybe put in a separate PR to add a GitHub action to run checks automatically?

that is what i wanted to do at first, but currently BLC's scripting API is quite bad. also it would also be better to just occasionally run it instead of of every normal CI run, because it hits external serves too, so the best option would be to put it on a timer (like weekly)

also what to do about the mentioned unresolved broken links?

@hasezoey hasezoey deleted the useBLC branch February 7, 2023 07:16
@vkarpov15
Copy link
Collaborator

Just remove the remaining broken links. Remove any references to the deprecated options. And for connection-limits-and-cluster-tier just remove the link, leave the text.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs This issue is due to a mistake or omission in the mongoosejs.com documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants