elastic / docs

246 stars 332 forks source link

Speed up link checking #677

Open nik9000 opened 5 years ago

nik9000 commented 5 years ago

Right now link checking is one of the slowest parts of ./build_docs --all because it checks all links from all books. I'd like to speed this up somehow. I suspect we could do something as simple as skipping checking the links for books that weren't modified and don't point to modified books. We may be able to do better and store the list of extracted links. That process may be faster to do once we've fully converted to Asciidoctor because we can do it on the asciidoc AST rather than the generated html.

nik9000 commented 4 years ago

It turns out that building a file with the outgoing links from each project and the anchors would be useful for folks to look at as well. I think that is the right way to do this - do the link and id extraction into a file after building the book and then do the actual link checking by reading the file.